aboutsummaryrefslogtreecommitdiffstats
path: root/src/stm32/can.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/stm32/can.c')
-rw-r--r--src/stm32/can.c11
1 files changed, 8 insertions, 3 deletions
diff --git a/src/stm32/can.c b/src/stm32/can.c
index 143766c7..c4d45f9c 100644
--- a/src/stm32/can.c
+++ b/src/stm32/can.c
@@ -28,8 +28,8 @@
#define GPIO_Tx GPIO('B', 9)
#endif
#if CONFIG_CAN_PINS_PI8_PH13
- DECL_CONSTANT_STR("RESERVE_PINS_CAN", "PI8,PH13");
- #define GPIO_Rx GPIO('I', 8)
+ DECL_CONSTANT_STR("RESERVE_PINS_CAN", "PI9,PH13");
+ #define GPIO_Rx GPIO('I', 9)
#define GPIO_Tx GPIO('H', 13)
#endif
#if CONFIG_CAN_PINS_PB5_PB6
@@ -42,6 +42,11 @@
#define GPIO_Rx GPIO('B', 12)
#define GPIO_Tx GPIO('B', 13)
#endif
+#if CONFIG_CAN_PINS_PD0_PD1
+ DECL_CONSTANT_STR("RESERVE_PINS_CAN", "PD0,PD1");
+ #define GPIO_Rx GPIO('D', 0)
+ #define GPIO_Tx GPIO('D', 1)
+#endif
#if CONFIG_MACH_STM32F0
#define SOC_CAN CAN
@@ -64,7 +69,7 @@
#if CONFIG_MACH_STM32F4
#warning CAN on STM32F4 is untested
#if (CONFIG_CAN_PINS_PA11_PA12 || CONFIG_CAN_PINS_PB8_PB9 \
- || CONFIG_CAN_PINS_PI8_PH13)
+ || CONFIG_CAN_PINS_PD0_PD1 || CONFIG_CAN_PINS_PI9_PH13)
#define SOC_CAN CAN1
#define CAN_RX0_IRQn CAN1_RX0_IRQn
#define CAN_RX1_IRQn CAN1_RX1_IRQn