I was wondering what the most barebones code for transmitting a command if a condition is met can be over the CAN BUS could be. Hypothetically I would want to send something along the lines of: "3D 11 04 00 C3" on the CAN BUS if the speedometer reads 20 km/h. I found this:
// Do awesome things with message!
Expressed in:[km] h
Frequency: 6.7 Hz
Minimum Timestamp: 100
But I think that I am missing something. Ideally I would want this to be standalone (so no serial printing required). What could I do?
How does one turn 8 bit messages in hex numbers?
Thank you very much