ICONICS Modbus OPC Server: ความแตกต่างระหว่างWord Swap กับ Swap bit

38 views
Skip to first unread message

GEN32

unread,
Jan 29, 2015, 1:48:25 AM1/29/15
to genesis...@googlegroups.com


• Word swap: Swaps the first word with the second when reading/writing DINT, UDINT or float values. Word swapping is checked by default to make it consistent with the DVT way of storing multi-byte variables. 
• RSwap bits: Reverses the order of bits in word-sized values (least significant bit becomes the most significant bit). 


EXAMPLE: 
A) Swap bits 
byte ABCDEFGH -> byte HGFEDCBA 
(A, B, C, D, E, F, G, H are bits inside byte) 

B) Word swap (word = 2 bytes) 
word XY -> word YX 
(X, Y are bytes inside word)

Reply all
Reply to author
Forward
0 new messages