Unsigned 32bit int not work fine?!

I have:

  • Siemens s7-1500
  • OPC-UA (in siemens cpu)
  • a UDInt plc tag
    when I try to write a number with a 32nd bit to 1 (more than 2147483647) I have this error:

“Invalid data type, unable to convert value ‘Int4’ to data type class java.lang.Long”

For me is a mystery.

Java 32-bit integers are signed. So to provide a value to an unsigned 32-bit integer, you must provide the next larger type: 64-bit. Show your code so a more precise suggestion can be offered.

Perfect … your idea works fine in version 8.12.

Thanks for a fast replay. A couple of :beers: for you

Heh. Next time you come through Atlanta. Or an in-person ICC (crosses fingers).

Quite hard to get bosses to pay for a ride to the ICC. If I can, I’ll be in Atlanta in late January

1 Like