TurboStreetCar
Active member
Well Ive changed my approach slightly. I enlisted the help of my Arduino UNO. I Know the UNO can send and receive CAN because ive connected it to my cars OBD2 port and successfully pulled data.
I set up the Arduino to send ONE message into the bus. Its only coded to write ONE time.
The issue i am getting, is the Teensy 3.6, will read the same message infinitely every time CANbus0.read(rxmsg) is run.
It continues to read the same single message even if the CanH and CanL lines are disconnected from the teensy.
My only conclusion is that it seems the message received by the Teensy, is being stored in a buffer, and not being cleared. So every time read() is run, it continues to pick up the same message.
Is there a function that clears the buffer that i am not aware of? OR Should the read() function clear the buffer on its own?
I set up the Arduino to send ONE message into the bus. Its only coded to write ONE time.
The issue i am getting, is the Teensy 3.6, will read the same message infinitely every time CANbus0.read(rxmsg) is run.
It continues to read the same single message even if the CanH and CanL lines are disconnected from the teensy.
My only conclusion is that it seems the message received by the Teensy, is being stored in a buffer, and not being cleared. So every time read() is run, it continues to pick up the same message.
Is there a function that clears the buffer that i am not aware of? OR Should the read() function clear the buffer on its own?