Quote:
p1_x is an unsigned char and can only hold a value equal to 0-255.
Therefore it cannot hold 256, 400, or 500 in the above example.
|
could you explain. We are not trying to make p1_x greater than 255, we are just trying to use it to make an int greater than 255...
value = (2)*(p1_x)+256;
I would think that is ok, but if not, how could we correct it to get the same result.
thanks.