This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

TCAN4551-Q1: Watermark interrupt usage

Expert 1940 points
Part Number: TCAN4551-Q1

I am currently using watermark interrupt to read FIFO. I have it set at 48. Things seem to be working fine.

However, I am thinking of a case where there might be some data in the FIFO at the end(of transmission/or during network power down) which may not be large enough to reach watermark threshold.

Is this something that needs to be handled explicitly in the driver? Or does the watermark interrupt gets generated in such cases as well to allow for getting complete data out of the FIFO?

Thanks!

  • Hi G T,

    Yes, this would need to be handled explicitly in the driver.  The watermark interrupt will only get set when the number of messages in the FIFO reaches the watermark level.  If you do not receive enough messages to reach this level, then there could be a delay in receiving the messages while you wait for more messages to arrive.

    You may want to consider adding a periodic read of the RX FIFO Status register to check the RX FIFO Fill Level register field to determine if there are any unread messages in the FIFO.  You could possibly add this into the end of some other function you frequently do, or create a separate function to handle this.

    Regards,

    Jonathan