I am writing a data parser for a robot controller, and what comes from the data log is a number in the range from 0 to 65535 (this is a 16-bit unsigned integer, if I'm not mistaken). I am trying to convert this to a 16-bit integer that will be displayed to the user (since this was the actual data type before he changed it).
Can someone give me a hand?
Example:
What values should be (0, -1, -2, -3, -4)
What are the values (0, 65535, 65534, 65533, 65532).
source
share