Skip to content
Snippets Groups Projects
Commit fde32bf0 authored by Hauke Petersen's avatar Hauke Petersen
Browse files

Merge pull request #2578 from fnack/msb_feat

boards/msbiot: Extend the provided features
parents 2ebf6006 54d98a4c
No related branches found
No related tags found
No related merge requests found
FEATURES_PROVIDED += cpp FEATURES_PROVIDED += cpp
FEATURES_PROVIDED += periph_uart periph_gpio periph_spi periph_i2c periph_pwm FEATURES_PROVIDED += periph_uart periph_gpio periph_spi periph_i2c periph_pwm periph_random \
periph_adc periph_dac
FEATURES_PROVIDED += transceiver FEATURES_PROVIDED += transceiver
FEATURES_MCU_GROUP = cortex_m4 FEATURES_MCU_GROUP = cortex_m4
...@@ -91,6 +91,56 @@ extern "C" { ...@@ -91,6 +91,56 @@ extern "C" {
#define PWM_0_PIN_AF 3 #define PWM_0_PIN_AF 3
/** @} */ /** @} */
/**
* @name ADC configuration
* @{
*/
#define ADC_NUMOF (1U)
#define ADC_0_EN 1
#define ADC_MAX_CHANNELS 2
/* ADC 0 configuration */
#define ADC_0_DEV ADC1
#define ADC_0_CHANNELS 2
#define ADC_0_CLKEN() (RCC->APB2ENR |= RCC_APB2ENR_ADC1EN)
#define ADC_0_CLKDIS() (RCC->APB2ENR &= ~(RCC_APB2ENR_ADC1EN))
#define ADC_0_PORT GPIOB
#define ADC_0_PORT_CLKEN() (RCC->AHB1ENR |= RCC_AHB1ENR_GPIOBEN)
/* ADC 0 channel 0 pin config */
#define ADC_0_CH0 8
#define ADC_0_CH0_PIN 0
/* ADC 0 channel 1 pin config */
#define ADC_0_CH1 9
#define ADC_0_CH1_PIN 1
/** @} */
/**
* @name DAC configuration
* @{
*/
#define DAC_NUMOF (1U)
#define DAC_0_EN 1
#define DAC_MAX_CHANNELS 2
/* DAC 0 configuration */
#define DAC_0_DEV DAC
#define DAC_0_CHANNELS 2
#define DAC_0_CLKEN() (RCC->APB1ENR |= (RCC_APB1ENR_DACEN))
#define DAC_0_CLKDIS() (RCC->APB1ENR &= ~(RCC_APB1ENR_DACEN))
#define DAC_0_PORT GPIOA
#define DAC_0_PORT_CLKEN() (RCC->AHB1ENR |= RCC_AHB1ENR_GPIOAEN)
/* DAC 0 channel config */
#define DAC_0_CH0_PIN 4
#define DAC_0_CH1_PIN 5
/** @} */
/**
* @name Random Number Generator configuration
* @{
*/
#define RANDOM_NUMOF (1U)
/** @} */
/** /**
* @name UART configuration * @name UART configuration
* @{ * @{
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment