Enabling CAN bus module kills Harmony
If I use the MPLAB IDE v3.61 with Harmony configurator (Installed version: 18.104.22.168 ), to add a CAN Driver to my hardware design, the resulting code runs but never exits the SYS_Initialise function.
If I use breakpoints to drill down inside SYS_Initialise, I find that it is the function DRV_CAN0_Initialize() that is blocking.
Inside DRV_CAN0_Initialize(), in the file drv_can_static, I find that the following line of code never returns...
while(PLIB_CAN_OperationModeGet(CAN_ID_1) != CAN_NORMAL_MODE);
This would tend to indicate that the preceding code line hasn't worked properly for some reason.
/* Switch the CAN module to Normal mode. Wait until the switch is complete */
Can anyone tell me how to get this Harmony-generated code working, so it doesn't get stuck forever.
I will, for reference, try and attach a screen-grab of the CAN configuration settings.
PS: I am using a PIC32MZ2040EFM100, and this is a production board, not an evaluation kit.