I am working on CAN communication and I have come across a CAN database (.dbc) file which has signals with "Signed" value type & lengths as shown in snap below:
Now, while testing I have set the Physical value of the signals as -10 on the CAN Bus Analysis Software i.e. BUSMASTER (Refer below snap) & I'm checking whether I'm receiving the exact data at Microcontroller side.
But as shown in the snap above, raw value is changing depeding on the data length of the signals for the same physical value and so that I'm receiving the wrong physical value at Microcontroller side. There is no issue while transmitting "Signed" value type signals.
So how to handle the "Signed" value type of signals at microcontroller side? Please share the example code/code snippet if you have.
Please help. Thanks in advance !