Sign in to follow this  
Followers 0
ProgrammerPlsHelpMe

How to display variable value in ladder page in decimal not Hexa

7 posts in this topic

How to watch the value in decimal directly in the ladder page ? 

Default Hexadecimal

The only way I can do it is in Watch Tab and I/O map per example

Thank you

Share this post


Link to post
Share on other sites

Values in ladder page all default to decimal.  There is no way to view in hex on the ladder window.

Share this post


Link to post
Share on other sites

Posted (edited)

I have the same problem, my variables when online show up as Hex.

Capture.PNG.a98a02c9b2c233ad949f9cd3e5e7

Edited by StopBreakingMyMachine

Share this post


Link to post
Share on other sites

And you will get the same answer.  It always shows decimal.

Share this post


Link to post
Share on other sites

It will show the format of whatever you declared the variable to be.  As shown below, I have declared two variables that both point to the same address (D0).  You don't have to point tags to addresses, but it worked well to illustrate this concept:

5bb3d8f7945c9_D0Tags.jpg.198c7c86cd1a793

 

I then created some ladder that was always off, just to show the variables in the ladder code.  As you can see in the image below, the D0_as_UINT (unsigned integer) shows a value of 10 (UINT), while D0_as_Word shows the hexadecimal equivalent value of 000A.  

5bb3d8f7241ef_D0Ladder.jpg.a769bde7ef90e

 

Side Note:  The values when entering a Constant default to decimal, so if this code were entered:

5bb3da21563cf_Worddefault.jpg.7278845024

 

The Word#10 value would be entered as a decimal number and the hex value would be 000A (as shown).  

To enter a hexadecimal value of 10, you would enter your code like this Word#16#10:

ConstantHex.jpg.aca5e3e7e6af245bb2fe0716

As you can see in the image above, the value is stored in the memory location as a hex 10, this equates to a decimal 16 (top rung).

Share this post


Link to post
Share on other sites

Must have mixed up with safety editor, that one is always decimal and very annoying for safety error codes.

Share this post


Link to post
Share on other sites
20 minutes ago, Crossbow said:

Must have mixed up with safety editor, that one is always decimal and very annoying for safety error codes.

I agree, at least the decimal values (alongside the HEX values) of the error codes are now in the help files.... 

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!


Register a new account

Sign in

Already have an account? Sign in here.


Sign In Now
Sign in to follow this  
Followers 0