2015-09-02 06:30 AM
Hello,
I'm using SPC5Studio V3.6 and SPC564B74. The HAL drivers are limiting FlexCAN mailbox number to 32 but this CPU has 64 MB per FlexCAN. I can change SPC5_CAN_NUM_RX_MAILBOXES and SPC5_CAN_NUM_TX_MAILBOXES définitions in mcuconf.h but this file seems not to be ''patchable''. It has to be changed manually every time the code is generated. Fixes is welcome. Aurélien2015-09-02 08:41 AM
/**
* @brief Number of RX mailboxes. */ #undef SPC5_CAN_NUM_RX_MAILBOXES #if !defined(SPC5_CAN_NUM_RX_MAILBOXES) || defined(__DOXYGEN__) #define SPC5_CAN_NUM_RX_MAILBOXES YOUR_VALUE #endif/**
* @brief Number of TX mailboxes. */ #undef SPC5_CAN_NUM_TX_MAILBOXES #if !defined(SPC5_CAN_NUM_TX_MAILBOXES) || defined(__DOXYGEN__) #define SPC5_CAN_NUM_TX_MAILBOXES YOUR_VALUE_2 #endif#if (SPC5_CAN_NUM_RX_MAILBOXES < 1) || (SPC5_CAN_NUM_RX_MAILBOXES > 64)
#error ''invalid number of RX mailboxes'' #endif #if (SPC5_CAN_NUM_TX_MAILBOXES < 1) || (SPC5_CAN_NUM_TX_MAILBOXES > 64) #error ''invalid number of TX mailboxes'' #endif #if (SPC5_CAN_NUM_RX_MAILBOXES + SPC5_CAN_NUM_TX_MAILBOXES) > 64 #error ''invalid amount of RX and TX mailboxes'' #endif Best regards Erwan