Page 1 of 1
How to visualize Hex Value of a BIT32
Posted: Wed Apr 25, 2018 11:41 am
by laurent.brugeaud
Hi.
How to simply put on label the Hex value of a Bit32 DPE?
Re: How to visualize Hex Value of a BIT32
Posted: Wed Apr 25, 2018 12:32 pm
by RudiKreiner
Not exactly sure what you really mean, but if you want to display a bit32 value as a hex number, you can do it with this code, where DP_NAME is a string containing the name of your datapoint.
dpSetFormat(DP_NAME, "0X%04x");
bit32 value;
dpGet(DP_NAME, value);
DebugN(dpValToString(DP_NAME, value));
Be aware that the format displayed in the common config the datapoint in para will look strange though, and don't try to change it there.
Re: How to visualize Hex Value of a BIT32
Posted: Thu Apr 26, 2018 9:20 am
by laurent.brugeaud
Thanks you Rudi. It work well.