Tested on github master (8/7/2022)
demos/STM32/RT-STM32F413ZH-NUCLEO144
Changed halconf.h to use CAN:
Code: Select all
#define HAL_USE_CAN TRUE
and mcuconf.h to enable all 3 CAN devices:
Code: Select all
#define STM32_CAN_USE_CAN1 TRUE
#define STM32_CAN_USE_CAN2 TRUE
#define STM32_CAN_USE_CAN3 TRUE
compile fails with multiple defines needed for CAN3:
This error appears, even if STM32_CAN_USE_CAN3 is set to FALSE:
Code: Select all
#error "STM32_CAN3_MAX_FILTERS not defined in registry"
These missing defines/declarations appear when STM32_CAN_USE_CAN3 is set to TRUE:
Code: Select all
../../../os/hal/ports/STM32/LLD/CANv1/hal_can_lld.c:104:5: warning: implicit declaration of function 'rccEnableCAN3'; did you mean 'rccEnableCAN2'? [-Wimplicit-function-declaration]
104 | rccEnableCAN3(true);
../../../os/hal/ports/STM32/LLD/CANv1/hal_can_lld.c:185:5: warning: implicit declaration of function 'rccDisableCAN3'; did you mean 'rccDisableCAN1'? [-Wimplicit-function-declaration]
185 | rccDisableCAN3();
../../../os/hal/ports/STM32/LLD/CANv1/hal_can_lld.c:536:2: error: #error "STM32_CAN3_TX_HANDLER not defined"
536 | #error "STM32_CAN3_TX_HANDLER not defined"
| ^~~~~
../../../os/hal/ports/STM32/LLD/CANv1/hal_can_lld.c:539:2: error: #error "STM32_CAN3_RX0_HANDLER not defined"
539 | #error "STM32_CAN3_RX0_HANDLER not defined"
| ^~~~~
../../../os/hal/ports/STM32/LLD/CANv1/hal_can_lld.c:542:2: error: #error "STM32_CAN3_RX1_HANDLER not defined"
542 | #error "STM32_CAN3_RX1_HANDLER not defined"
| ^~~~~
../../../os/hal/ports/STM32/LLD/CANv1/hal_can_lld.c:545:2: error: #error "STM32_CAN3_SCE_HANDLER not defined"
545 | #error "STM32_CAN3_SCE_HANDLER not defined"