wenjing liu

Questions about the interrupt of MSCAN in MC9S12XDP512

Discussion created by wenjing liu on Nov 7, 2007
Latest reply on Nov 9, 2007 by wenjing liu
 I am now doing a research on gateway of CAN bus.Inorder to test whether the developing board made by myself is correct, the CAN0 is set to work in the LOOPBACK mode.
         The datasheet said that "Both transmit and receive interrupts are generated"in the LOOPBACK mode. But when I clear the TFLG, it doesn't change and when the receiving buffer receives a message, the RFLG is still zero.why?
      Another problem is: when the TFLG is 1, the interrupt occurs. But after reset, the TFLG is always 1. If i clear the flag  manully, this flag can not be change any more. Because the datasheet said"Read and write accesses to the transmit buffer will be blocked, if the corresponding TXEx bit is cleared
(TXEx = 0)".
   The two  questions have bothered me for several days.

Outcomes