Skip to content

Commit

Permalink
HAL_ChibiOS: fix SWD config in f3 boards
Browse files Browse the repository at this point in the history
  • Loading branch information
bugobliterator authored and tridge committed Aug 20, 2020
1 parent eddbf7a commit 8dcb973
Show file tree
Hide file tree
Showing 3 changed files with 10 additions and 5 deletions.
7 changes: 4 additions & 3 deletions libraries/AP_HAL_ChibiOS/hwdef/f303-periph/hwdef-bl.dat
Original file line number Diff line number Diff line change
Expand Up @@ -45,9 +45,6 @@ define STM32_SERIAL_USE_USART1 TRUE
define STM32_SERIAL_USE_USART2 TRUE
define STM32_SERIAL_USE_USART3 FALSE

PA13 SWDIO-JTMS SWD
PA14 SWCLK-JTCK SWD

define HAL_NO_GPIO_IRQ
define CH_CFG_ST_TIMEDELTA 0
#define CH_CFG_USE_DYNAMIC FALSE
Expand Down Expand Up @@ -79,6 +76,10 @@ PA12 CAN_TX CAN
define HAL_USE_CAN TRUE
define STM32_CAN_USE_CAN1 TRUE

# debugger support
PA13 JTMS-SWDIO SWD
PA14 JTCK-SWCLK SWD

# make bl baudrate match debug baudrate for easier debugging
define BOOTLOADER_BAUDRATE 57600

Expand Down
4 changes: 4 additions & 0 deletions libraries/AP_HAL_ChibiOS/hwdef/f303-periph/hwdef.dat
Original file line number Diff line number Diff line change
Expand Up @@ -90,6 +90,10 @@ PA12 CAN_TX CAN
define HAL_USE_CAN TRUE
define STM32_CAN_USE_CAN1 TRUE

# debugger support
PA13 JTMS-SWDIO SWD
PA14 JTCK-SWCLK SWD

define HAL_USE_I2C TRUE
define STM32_I2C_USE_I2C1 TRUE

Expand Down
4 changes: 2 additions & 2 deletions libraries/AP_HAL_ChibiOS/hwdef/scripts/STM32F303xC.py
Original file line number Diff line number Diff line change
Expand Up @@ -125,14 +125,14 @@
"PA12:USB_DP" : 14,
"PA13:EVENTOUT" : 15,
"PA13:IR_OUT" : 5,
"PA13:SWDIO-JTMS" : 0,
"PA13:JTMS-SWDIO" : 0,
"PA13:TIM16_CH1N" : 1,
"PA13:TIM4_CH3" : 10,
"PA13:TSC_G4_IO3" : 3,
"PA13:USART3_CTS" : 7,
"PA14:EVENTOUT" : 15,
"PA14:I2C1_SDA" : 4,
"PA14:SWCLK-JTCK" : 0,
"PA14:JTCK-SWCLK" : 0,
"PA14:TIM1_BKIN" : 6,
"PA14:TIM8_CH2" : 5,
"PA14:TSC_G4_IO4" : 3,
Expand Down

0 comments on commit 8dcb973

Please sign in to comment.