* f1_rev3: STM32 is 64-pin

* f1_rev3: enable DAC driver, enable HW block

Co-authored-by: Andrey Gusakov <dron0gus@gmail.com>
This commit is contained in:
rusefillc 2022-08-29 20:12:49 -04:00 committed by GitHub
parent 09872e0d3c
commit 2cc460adba
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
4 changed files with 17 additions and 3 deletions

View File

@ -42,7 +42,7 @@
/*
* MCU type, supported types are defined in ./os/hal/platforms/hal_lld.h.
*/
#define STM32F103xB
#define STM32F103xE
/*
* IO pins assignments.

View File

@ -65,7 +65,7 @@
* @brief Enables the DAC subsystem.
*/
#if !defined(HAL_USE_DAC) || defined(__DOXYGEN__)
#define HAL_USE_DAC FALSE
#define HAL_USE_DAC TRUE
#endif
/**

View File

@ -37,7 +37,10 @@
#define PUMP_DAC_PWM_DEVICE PWMD2
#define PUMP_DAC_PWM_CHANNEL 1
/* TODO: Add DAC for AUX outputs */
// DAC for AUX outputs
#define AUXOUT_DAC_DEVICE DACD1
#define AUXOUT_DAC_CHANNEL_0 0
#define AUXOUT_DAC_CHANNEL_1 1
#define ID_SEL1_PORT GPIOC
#define ID_SEL1_PIN 13

View File

@ -80,6 +80,17 @@
#define STM32_ADC_ADC1_DMA_PRIORITY 2
#define STM32_ADC_ADC1_IRQ_PRIORITY 6
/*
* DAC driver system settings.
*/
#define STM32_DAC_DUAL_MODE FALSE
#define STM32_DAC_USE_DAC1_CH1 TRUE
#define STM32_DAC_USE_DAC1_CH2 TRUE
#define STM32_DAC_DAC1_CH1_IRQ_PRIORITY 10
#define STM32_DAC_DAC1_CH2_IRQ_PRIORITY 10
#define STM32_DAC_DAC1_CH1_DMA_PRIORITY 2
#define STM32_DAC_DAC1_CH2_DMA_PRIORITY 2
/*
* CAN driver system settings.
*/