mirror of
https://github.com/eddyem/stm32samples.git
synced 2026-02-28 03:44:30 +03:00
add SPI (not tested yet)
This commit is contained in:
@@ -22,7 +22,7 @@ uint8_t Config_mode = 0;
|
||||
|
||||
static inline void gpio_setup(){
|
||||
RCC->AHBENR |= RCC_AHBENR_GPIOAEN | RCC_AHBENR_GPIOBEN | RCC_AHBENR_GPIOCEN | RCC_AHBENR_GPIODEN
|
||||
| RCC_AHBENR_DMA1EN | RCC_AHBENR_DMA2EN;
|
||||
| RCC_AHBENR_DMA1EN | RCC_AHBENR_DMA2EN | RCC_APB2ENR_SPI1EN;
|
||||
RCC->APB1ENR |= RCC_APB1ENR_CANEN | RCC_APB1ENR_USART2EN | RCC_APB1ENR_USART3EN
|
||||
| RCC_APB1ENR_UART4EN | RCC_APB1ENR_UART5EN;
|
||||
RCC->APB2ENR |= RCC_APB2ENR_USART1EN;
|
||||
|
||||
Reference in New Issue
Block a user