Add support across dev boards
This commit is contained in:
parent
7fd5e9b867
commit
c0f1ce590e
@ -61,7 +61,7 @@
|
||||
/* #define HAL_SD_MODULE_ENABLED */
|
||||
/* #define HAL_MMC_MODULE_ENABLED */
|
||||
#define HAL_SPI_MODULE_ENABLED
|
||||
/* #define HAL_TIM_MODULE_ENABLED */
|
||||
#define HAL_TIM_MODULE_ENABLED
|
||||
#define HAL_UART_MODULE_ENABLED
|
||||
/* #define HAL_USART_MODULE_ENABLED */
|
||||
/* #define HAL_IRDA_MODULE_ENABLED */
|
||||
|
@ -61,7 +61,7 @@
|
||||
/* #define HAL_SD_MODULE_ENABLED */
|
||||
/* #define HAL_MMC_MODULE_ENABLED */
|
||||
#define HAL_SPI_MODULE_ENABLED
|
||||
/* #define HAL_TIM_MODULE_ENABLED */
|
||||
#define HAL_TIM_MODULE_ENABLED
|
||||
#define HAL_UART_MODULE_ENABLED
|
||||
/* #define HAL_USART_MODULE_ENABLED */
|
||||
/* #define HAL_IRDA_MODULE_ENABLED */
|
||||
|
@ -61,7 +61,7 @@
|
||||
#define HAL_SD_MODULE_ENABLED
|
||||
/* #define HAL_MMC_MODULE_ENABLED */
|
||||
#define HAL_SPI_MODULE_ENABLED
|
||||
/* #define HAL_TIM_MODULE_ENABLED */
|
||||
#define HAL_TIM_MODULE_ENABLED
|
||||
#define HAL_UART_MODULE_ENABLED
|
||||
/* #define HAL_USART_MODULE_ENABLED */
|
||||
/* #define HAL_IRDA_MODULE_ENABLED */
|
||||
|
@ -91,7 +91,7 @@ const mcu_spi_nss_obj_t mcu_spi_nss_list[6] = {
|
||||
TIM_TypeDef * mcu_tim_banks[14] = {TIM1, TIM2, TIM3, TIM4, TIM5, NULL, NULL, TIM8, TIM9, TIM10,
|
||||
TIM11, TIM12, TIM13, TIM14};
|
||||
|
||||
const mcu_tim_pin_obj_t mcu_tim_pin_list[66] = {
|
||||
const mcu_tim_pin_obj_t mcu_tim_pin_list[56] = {
|
||||
TIM(2,1,1,&pin_PA00),
|
||||
TIM(5,2,1,&pin_PA00),
|
||||
TIM(2,1,2,&pin_PA01),
|
||||
|
@ -43,8 +43,8 @@ extern const mcu_spi_nss_obj_t mcu_spi_nss_list[6];
|
||||
|
||||
#define TIM_BANK_ARRAY_LEN 14
|
||||
TIM_TypeDef * mcu_tim_banks[14];
|
||||
#define TIM_PIN_ARRAY_LEN 66
|
||||
const mcu_tim_pin_obj_t mcu_tim_pin_list[66];
|
||||
#define TIM_PIN_ARRAY_LEN 56
|
||||
const mcu_tim_pin_obj_t mcu_tim_pin_list[56];
|
||||
|
||||
|
||||
#endif // MICROPY_INCLUDED_STM32F4_PERIPHERALS_STM32F405XX_PERIPH_H
|
@ -120,3 +120,55 @@ const mcu_spi_nss_obj_t mcu_spi_nss_list[12] = {
|
||||
};
|
||||
|
||||
//UART, Etc
|
||||
|
||||
//Timers
|
||||
//TIM6 and TIM7 are basic timers that are only used by DAC, and don't have pins
|
||||
TIM_TypeDef * mcu_tim_banks[14] = {TIM1, TIM2, TIM3, TIM4, TIM5, NULL, NULL, NULL, TIM9, TIM10,
|
||||
TIM11, NULL, NULL, NULL};
|
||||
|
||||
const mcu_tim_pin_obj_t mcu_tim_pin_list[44] = {
|
||||
TIM(2,1,1,&pin_PA00),
|
||||
TIM(5,2,1,&pin_PA00),
|
||||
TIM(2,1,2,&pin_PA01),
|
||||
TIM(5,2,2,&pin_PA01),
|
||||
TIM(2,1,3,&pin_PA02),
|
||||
TIM(5,2,3,&pin_PA02),
|
||||
TIM(2,1,4,&pin_PA03),
|
||||
TIM(5,2,4,&pin_PA03),
|
||||
TIM(9,3,1,&pin_PA02),
|
||||
TIM(9,3,2,&pin_PA03),
|
||||
TIM(3,2,1,&pin_PA06),
|
||||
TIM(3,2,2,&pin_PA07),
|
||||
TIM(1,1,1,&pin_PA08),
|
||||
TIM(1,1,2,&pin_PA09),
|
||||
TIM(1,1,3,&pin_PA10),
|
||||
TIM(1,1,4,&pin_PA11),
|
||||
TIM(2,1,1,&pin_PA15),
|
||||
TIM(3,2,3,&pin_PB00),
|
||||
TIM(3,2,4,&pin_PB01),
|
||||
TIM(2,1,2,&pin_PB03),
|
||||
TIM(3,2,1,&pin_PB04),
|
||||
TIM(3,2,2,&pin_PB05),
|
||||
TIM(4,2,1,&pin_PB06),
|
||||
TIM(4,2,2,&pin_PB07),
|
||||
TIM(4,2,3,&pin_PB08),
|
||||
TIM(10,2,1,&pin_PB08),
|
||||
TIM(4,2,4,&pin_PB09),
|
||||
TIM(11,2,1,&pin_PB09),
|
||||
TIM(2,1,3,&pin_PB10),
|
||||
TIM(3,2,1,&pin_PC06),
|
||||
TIM(3,2,2,&pin_PC07),
|
||||
TIM(3,2,3,&pin_PC08),
|
||||
TIM(3,2,4,&pin_PC09),
|
||||
TIM(4,2,1,&pin_PD12),
|
||||
TIM(4,2,2,&pin_PD13),
|
||||
TIM(4,2,3,&pin_PD14),
|
||||
TIM(4,2,4,&pin_PD15),
|
||||
TIM(9,3,1,&pin_PE05),
|
||||
TIM(9,3,2,&pin_PE06),
|
||||
TIM(1,1,1,&pin_PE09),
|
||||
TIM(1,1,2,&pin_PE11),
|
||||
TIM(1,1,3,&pin_PE13),
|
||||
TIM(1,1,4,&pin_PE14),
|
||||
};
|
||||
|
||||
|
@ -41,4 +41,9 @@ extern const mcu_spi_mosi_obj_t mcu_spi_mosi_list[14];
|
||||
extern const mcu_spi_miso_obj_t mcu_spi_miso_list[12];
|
||||
extern const mcu_spi_nss_obj_t mcu_spi_nss_list[12];
|
||||
|
||||
#define TIM_BANK_ARRAY_LEN 14
|
||||
TIM_TypeDef * mcu_tim_banks[14];
|
||||
#define TIM_PIN_ARRAY_LEN 44
|
||||
const mcu_tim_pin_obj_t mcu_tim_pin_list[44];
|
||||
|
||||
#endif // MICROPY_INCLUDED_STM32F4_PERIPHERALS_STM32F411VE_PERIPH_H
|
@ -121,3 +121,71 @@ const mcu_spi_nss_obj_t mcu_spi_nss_list[12] = {
|
||||
};
|
||||
|
||||
//UART, Etc
|
||||
|
||||
//Timers
|
||||
//TIM6 and TIM7 are basic timers that are only used by DAC, and don't have pins
|
||||
TIM_TypeDef * mcu_tim_banks[14] = {TIM1, TIM2, TIM3, TIM4, TIM5, NULL, NULL, TIM8, TIM9, TIM10,
|
||||
TIM11, TIM12, TIM13, TIM14};
|
||||
|
||||
const mcu_tim_pin_obj_t mcu_tim_pin_list[60] = {
|
||||
TIM(2,1,1,&pin_PA00),
|
||||
TIM(5,2,1,&pin_PA00),
|
||||
TIM(2,1,2,&pin_PA01),
|
||||
TIM(5,2,2,&pin_PA01),
|
||||
TIM(2,1,3,&pin_PA02),
|
||||
TIM(5,2,3,&pin_PA02),
|
||||
TIM(2,1,4,&pin_PA03),
|
||||
TIM(5,2,4,&pin_PA03),
|
||||
TIM(9,3,1,&pin_PA02),
|
||||
TIM(9,3,2,&pin_PA03),
|
||||
TIM(3,2,1,&pin_PA06),
|
||||
TIM(13,9,1,&pin_PA06),
|
||||
TIM(3,2,2,&pin_PA07),
|
||||
TIM(14,9,1,&pin_PA07),
|
||||
TIM(1,1,1,&pin_PA08),
|
||||
TIM(1,1,2,&pin_PA09),
|
||||
TIM(1,1,3,&pin_PA10),
|
||||
TIM(1,1,4,&pin_PA11),
|
||||
TIM(2,1,1,&pin_PA15),
|
||||
TIM(3,2,3,&pin_PB00),
|
||||
TIM(3,2,4,&pin_PB01),
|
||||
TIM(2,1,2,&pin_PB03),
|
||||
TIM(3,2,1,&pin_PB04),
|
||||
TIM(3,2,2,&pin_PB05),
|
||||
TIM(4,2,1,&pin_PB06),
|
||||
TIM(4,2,2,&pin_PB07),
|
||||
TIM(4,2,3,&pin_PB08),
|
||||
TIM(10,2,1,&pin_PB08),
|
||||
TIM(4,2,4,&pin_PB09),
|
||||
TIM(11,2,1,&pin_PB09),
|
||||
TIM(2,1,3,&pin_PB10),
|
||||
TIM(2,1,4,&pin_PB11),
|
||||
TIM(12,9,1,&pin_PB14),
|
||||
TIM(12,9,2,&pin_PB15),
|
||||
TIM(3,2,1,&pin_PC06),
|
||||
TIM(3,2,2,&pin_PC07),
|
||||
TIM(3,2,3,&pin_PC08),
|
||||
TIM(3,2,4,&pin_PC09),
|
||||
TIM(8,3,1,&pin_PC06),
|
||||
TIM(8,3,2,&pin_PC07),
|
||||
TIM(8,3,3,&pin_PC08),
|
||||
TIM(8,3,4,&pin_PC09),
|
||||
TIM(4,2,1,&pin_PD12),
|
||||
TIM(4,2,2,&pin_PD13),
|
||||
TIM(4,2,3,&pin_PD14),
|
||||
TIM(4,2,4,&pin_PD15),
|
||||
TIM(9,3,1,&pin_PE05),
|
||||
TIM(9,3,2,&pin_PE06),
|
||||
TIM(1,1,1,&pin_PE09),
|
||||
TIM(1,1,2,&pin_PE11),
|
||||
TIM(1,1,3,&pin_PE13),
|
||||
TIM(1,1,4,&pin_PE14),
|
||||
TIM(10,3,1,&pin_PF06),
|
||||
TIM(11,3,1,&pin_PF07),
|
||||
TIM(13,9,1,&pin_PF08),
|
||||
TIM(14,9,1,&pin_PF09),
|
||||
TIM(5,2,1,&pin_PF03),
|
||||
TIM(5,2,2,&pin_PF04),
|
||||
TIM(5,2,3,&pin_PF05),
|
||||
TIM(5,2,4,&pin_PF10),
|
||||
};
|
||||
|
@ -42,4 +42,9 @@ extern const mcu_spi_mosi_obj_t mcu_spi_mosi_list[14];
|
||||
extern const mcu_spi_miso_obj_t mcu_spi_miso_list[12];
|
||||
extern const mcu_spi_nss_obj_t mcu_spi_nss_list[12];
|
||||
|
||||
#define TIM_BANK_ARRAY_LEN 14
|
||||
TIM_TypeDef * mcu_tim_banks[14];
|
||||
#define TIM_PIN_ARRAY_LEN 60
|
||||
const mcu_tim_pin_obj_t mcu_tim_pin_list[60];
|
||||
|
||||
#endif // MICROPY_INCLUDED_STM32F4_PERIPHERALS_STM32F411VE_PERIPH_H
|
Loading…
x
Reference in New Issue
Block a user