void MainTask (void) {
PINSEL_ConfigPin(0,4,2);
PINSEL_ConfigPin(0,5,2);
GPIO_SetDir((4), (1 << 15), GPIO_DIRECTION_OUTPUT);
GPIO_OutputValue((4), (1 << 15), 1);
CAN_Init(CAN_ID_2,500000);
CAN_ModeConfig(CAN_ID_2, CAN_OPERATING_MODE, ENABLE);
CAN_IRQCmd (CAN_ID_2, CANINT_RIE, ENABLE);
NVIC_EnableIRQ (CAN_IRQn);
GUI_Init();
while (1) {
_DemoScale();
//CAN_SendMsg (CAN_ID_2, &CAN_msg);
//CAN_ReceiveMsg (uint8_t canId, CAN_MSG_Type *CAN_Msg)
}
}
|
I'm having the same issue and can't find anything in emWin that would change PIN IOCON settings or interrupt settings for CAN controller.
Hi patrick latimer,
Before answer your question, I was wondering if you can tell which MCU you use and share the simple demo with me, then I can replicate the issue and it can help me to figure out the root cause of the issue.
I'm looking forward to your reply.
Have a great day,
Ping
-----------------------------------------------------------------------------------------------------------------------
Note: If this post answers your question, please click the Correct Answer button. Thank you!
-----------------------------------------------------------------------------------------------------------------------