Skip to main content

Example - Ladder Diagram

SWAP​


The SWAP instruction swaps the upper byte of the WORD data register, D, with the lower byte of the WORD data register, D.

Ladder Diagram Example​


When the contact, M0.1 is ON (1), the instruction swaps the upper byte of the data register, D50, with the lower byte of the same data register.


Memory Monitor​

SWAPP​


The SWAPP one-shot instruction swaps the upper byte of the WORD data register, D, with the lower byte of the WORD data register, D.
Every time this instruction executes, it energizes the output only once.

Ladder Diagram Example​


When the contact, M0.1 is ON (1), the instruction swaps the upper byte of the data register, D55, with the lower byte of the same data register.


Memory Monitor​