From 6e39b4d191e5598add355fcc08cebe9d8cc1ba09 Mon Sep 17 00:00:00 2001 From: Marian Buschsieweke Date: Wed, 8 Jan 2020 15:25:20 +0100 Subject: [PATCH] drivers/periph: adc_sample() now returns int32_t Reasoning: This allow support for ADCs with resolution of more than 16 bits on 8 bit and 16 bit platforms. --- drivers/include/periph/adc.h | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/drivers/include/periph/adc.h b/drivers/include/periph/adc.h index d4e6458b3e..16105c355d 100644 --- a/drivers/include/periph/adc.h +++ b/drivers/include/periph/adc.h @@ -56,6 +56,7 @@ #define PERIPH_ADC_H #include +#include #include "periph_cpu.h" #include "periph_conf.h" @@ -125,7 +126,7 @@ int adc_init(adc_t line); * @return the sampled value on success * @return -1 if resolution is not applicable */ -int adc_sample(adc_t line, adc_res_t res); +int32_t adc_sample(adc_t line, adc_res_t res); #ifdef __cplusplus }