MPC5748G Multinuclear CAN

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

MPC5748G Multinuclear CAN

802 Views
mengluo
Contributor I

Hello,
   I've got some trouble in using the MPC5748G development board,
I put three CAN on three cores (Z4_0, Z4_1, Z2), When "Z4_1" or "Z2" receives the CAN message, "Z4_0" stops working.

   

The following is the code(CAN configuration is different):

int main(void)
{
#ifdef PEX_RTOS_INIT
PEX_RTOS_INIT();
#endif

#ifdef PEX_RTOS_INIT
PEX_RTOS_INIT();
#endif

CLOCK_SYS_Init(g_clockManConfigsArr, CLOCK_MANAGER_CONFIG_CNT,
g_clockManCallbacksArr, CLOCK_MANAGER_CALLBACK_CNT);
CLOCK_SYS_UpdateConfiguration(0U, CLOCK_MANAGER_POLICY_FORCIBLE);
PINS_DRV_Init(NUM_OF_CONFIGURED_PINS, g_pin_mux_InitConfigArr);

PINS_DRV_ClearPins(LED_PORT, (1 << LED0));

FLEXCAN_DRV_Init(INST_CANCOM1, &canCom1_State, &canCom1_InitConfig0);
FLEXCAN_DRV_ConfigRxMb(INST_CANCOM1, RX_MAILBOX, &dataInfo, RX_MSG_ID);

while(1)
{
FLEXCAN_DRV_Receive(INST_CANCOM1, RX_MAILBOX, &recvBuff);
while(FLEXCAN_DRV_GetTransferStatus(INST_CANCOM1, RX_MAILBOX) == STATUS_BUSY);
if((recvBuff.data[0] == LED0_CHANGE_REQUESTED) &&recvBuff.msgId == RX_MSG_ID)
   {
      PINS_DRV_TogglePins(LED_PORT, (1 << LED0));
   }
}

#ifdef PEX_RTOS_START
PEX_RTOS_START()
#endif
for(;;) {
if(exit_code != 0) {
break;
   }
}
return exit_code;

#ifdef PEX_RTOS_START
PEX_RTOS_START();
#endif

for(;;) {
if(exit_code != 0) {
break;
      }
   }
return exit_code;
}

Labels (1)
Tags (1)
0 Kudos
1 Reply

410 Views
gj3526
Contributor III

Hello,
   I've got the same  trouble  using the MPC5748G ,How do you solve the problem.thanks for help.

0 Kudos