How to deal with the display of negative abnormal?

Discuss issues and ideas you have to configuring displays with PowerVision
zlf_ciom
Posts: 6
Joined: Thu Jun 30, 2011 3:54 am

How to deal with the display of negative abnormal?

Post by zlf_ciom » Thu Sep 01, 2011 8:14 pm

I need to display negative in my project .The data sources in CAN transimit ,ande 2 bytes represent a number.I use the following expressions:IF(A>32767,A-65536,A) to calculate the data which has 2 bytes.When I send a negative using other CAN modulate ,most of the time i my design using PV750 can be display correctly,but it also jump to another data occasionally and come back the negative display quickly.How to deal with negative numbers jump .The other question is :how do you deal with the display of negative? Thanks!
ksaenz
Enovation Controls Development
Enovation Controls Development
Posts: 263
Joined: Thu Aug 19, 2010 7:53 am

Re: How to deal with the display of negative abnormal?

Post by ksaenz » Wed Sep 07, 2011 3:55 pm

Hello zlf_ciom,

Sounds like you are receiving signed values.

Normally CAN parameters are unsigned values and if there is a need for negative values, an offset is applied. If you can control the device that sends the parameters I recommend that you make it send unsigned values with an offset if possible.

If you must do the conversion in the PV750 I recommend that you put your converted value in a second variable.
This:
B = IF(A>32767, A-65536, A)
Instead of this:
A = IF(A>32767, A-65536, A)

Regards,

ksaenz