We are running a survey to help us improve the experience for all of our members. If you see the survey appear, please take the time to tell us about your experience if you can.
I am writing an application where a number of devices send messages to a common CAN processor in LPC1778 via CAN bus.
FYI-i dont need to use Acceptance Filter because all messages have to be allowed.
My question is that,if Device A sends a message and after Device A finishes sending a frame of data,if Device B sends a data frame,if i have not yet released the receive buffer in CAN in LPC1778,will it over-write the data or will it retry automatically when the receive buffer is released.
If a CAN RX buffer has not been read & interrupt status cleared, a new message will not be received from the bus.
I think you could easily test this behavior using a CAN bus analyzer, by dedicating some messages to send while not servicing the RX buffers and interrupt status registers. Clear the overrun by setting the CDO bit, and read the RX buffer. Your code will need to be efficient, not spending lots of time managing the data payload of the message inside of an interrupt service routine, for example. You may want to create a message queue in the global RAM area where messages are immediately copied once received. A main loop can manage this queue from outside the low level handler...
-arw