[mcu_periph] set ADC_RESOLUTION in arch headers

This commit is contained in:
Felix Ruess
2016-04-20 20:39:46 +02:00
parent bda5ae78df
commit 7c96aba417
3 changed files with 10 additions and 9 deletions
@@ -32,6 +32,11 @@
#include BOARD_CONFIG
/* Set the correct ADC resolution */
#ifndef ADC_RESOLUTION
#define ADC_RESOLUTION 1024
#endif
/** 8 ADCs for bank 0, others for bank 2 */
#define NB_ADC 8
@@ -32,6 +32,11 @@
#include BOARD_CONFIG
/* Set the correct ADC resolution */
#ifndef ADC_RESOLUTION
#define ADC_RESOLUTION 4096
#endif
enum adc1_channels {
#ifdef AD1_1_CHANNEL
AD1_1,
-9
View File
@@ -45,15 +45,6 @@
microcontroller architecture.
*/
/* Set the correct ADC resolution */
#ifndef ADC_RESOLUTION
#if defined(STM32F1) || defined(STM32F4)
#define ADC_RESOLUTION 4096
#else
#define ADC_RESOLUTION 1024
#endif
#endif
/**
Struct to collect samples from ADC and building an average
over MAX_AV_NB_SAMPLE values.