Range of values for a integer tag?

Using 8.1.3.

Have an OPC tag that is reading a TIME type tag from a Beckoff PLC. The value comes through to me as an integer and writing an integer to the tag comes back through as hours,minutes, seconds, etc in the beckoff correctly.

My question is is there a limit to the value that a opc tag with an integer type can take and if so what is it?

The TIME datatype is probably an alias for one of the integer types, and without knowing what that is it’s difficult to answer the question.

If you connect with something like UaExpert you should be able to browse the DataTypes in the address space and discover the parent types of this TIME type.

Ok, so the limit is based on what the PLC can handle, no Ignition limitation in this regard?

I found this documentation page Beckhoff Information System - English and it seems like it can handle up to 4294967295.

Attempting to write that to my int tag gives me an overflow error. So I think I have to change the datatype on the Ignition end to a double to handle such a value.

Yes, it’s an alias to DWORD (unsigned). You’ll need to go up to the next size signed integer in Ignition to handle it.

That’s the max value for a UInt32. A Long/Int8 in Ignition should be able to hold all values.

If the server is correctly aliasing a UInt32 with that type then an appropriate type should have been chosen for you when drag and dropped the tag. If you created it manually or as part of a UDT then you are on your own to choose the correct type.

2 Likes