Delta Electronics — 6.4.2 Explanation of Data Transfer Instructions

Chapter 6 Applied Instructions Symbol S : Data source Explanation 1. The 16-bit instruction exchanges the data in the low byte in S with the data in the high byte in S . 2. The 32-bit instruction exchanges the data in the low byte of the high word in S with the data in the high byte of the 6_ high word in S , and exchanges the data in the low byte of the low word in S with the data in the high byte of the low word in S . 3. Only the 32-bit instructions can use the 32-bit counter, but not the device E. Example 1 When X0.0 is ON, the instruction exchanges the data in the low byte in D0 with the data in the high byte in D0.

D0 6-139 API Instruction code Operand Function 0308 D SWAP P S Exchanging the high byte with the low byte Device X Y M S T C HC D FR SM SR E K 16# “$” F S        BOOL WORD DWORD LWORD UINT INT DINT LINT REAL LREAL TMR CNT STRING Data type S      Pulse instruction 16-bit instruction 32-bit instruction AS AS AS High byte Low byte