KNOT modbus 64-bit

If you post the data you’re getting or spec, that help…

In 7.16 and above, the :convert can do some of the arithmetic. And all version support bit shifts/OR/XOR/ANDs when dealing a number type. Exactly the right incantation, some recieved output help…

At a high-level, you can do:
:put [:convert from=hex to=num FFFFFFFFFFFFFFFF]
18446744073709551615
:put [:convert from=hex to=num FFFFFFFFFFFFFFFE]
18446744073709551614

And you can also use to=byte-array (or to=bit-array-msb, -lsb), to get an array from the 64-bits - this is useful for flags and “groups of bit” flags.
:put [:convert from=hex to=byte-array FFFFFFFFFFFFFFFF].

I have an rough example of using this things to parse LoRa data here (but it doesn’t deal with num types):
http://forum.mikrotik.com/t/experiments-with-convert-for-bits-bytes-csv-from-iot/179268/1