Hi,
When I call 'CAN_Send(&canMon_instance, TX_MB_PHY, &TxMsg)' by FlexCAN2 to send message, a error happened. The code was executed on Core0 of MPC5746R.
I traced the code, I found that this error appeared when executed '*flexcan_mb |= flexcan_mb_config;'.
The error was as below:
Could anyone help me to fix this strange issue?
Thanks!
Hi,
After call CAN_Init(), MDIS bit enabled the FlexCAN module, and clock sets in PCTL81 are as following:
But, after error happened, the PCTL81 changed to all zero as following. ☹
The clock is set as following:
Is it the clock setting problem?
Thanks!
Hi,
seems clock setting is right. Could this be due to ECC enabled on FlexCAN? If enabled (by default) is all required memory area initialized as mentioned in RM chapter 47.5.13 Detection and Correction of Memory Errors?
BR, Petr
Hi.
*flexcan_mb |= flexcan_mb_config is updating MB CS word, from addresses it should be MB26 on CAN2.
It should work, check if module is clocked (in MC_ME module) and enabled (MDIS bit).
BR, Petr