Hi,
from Modbus I read a UDINT value. Unfortunately the variable is incorrect formatted. When I read 0x12 (18 decimal) from Modbus, the variable shows 1179648 as decimal. This is 0x00120000, the words are swapped. So I need to swap the words (not bytes) for this variable. I found the swapUDINT() function but this swaps bytes not words.
The swapUDINT() make the variable more worse: 0x00001200 or in decimal: 4608.
I need to swap words, 0x00120000 → 0x00000012, how can this be done?
Language: ST.
Walter