Hi, in the example code for can_rtx C:\Keil\ARM\Boards\Keil\MCB2300\ the can_hw.c module has a function CAN_hw_tx_empty (U32 ctrl), how does this function or calling function CAN_push (U32 ctrl, CAN_msg *msg, U16 timeout) cater for the TX ISR completing (empty queue) just after the semphore check. As the CAN_push function will think CAN transmission is still busy and push the data onto the queue meanwhile the transmission is completed and nothing will kickstart the ISR ? As semphore check will guard against this prior to the check but not after ?
Kind Regards, Danny
ISR will continue transmitting while there are messages in mailbox to send.
Hi, seems I had an old version, problem has been fixed in version 4.11, can_push() function rechecks the can_empty() function after loading a new message into queue, in case previous messages was completed during the loading of the new message.