31.14.3.6 System Variables Indicating Execution Results - SAL/SALP

Program Example

SAL

  1. When the variable of the positive transition instruction turns ON, the SAL instruction is run. When the SAL instruction is executed, the result of the bit shift is stored in D1. The most significant bit is not shifted, and zero is stored in the least significant bit.

    • When using a normally open instruction, the SHR instruction is always executed as long as the normally open bit is ON.

SALP

The SALP and SAL instructions have different ways of detecting when to execute. In the SALP instruction, even when using a normally open instruction, the SALP instruction is executed only when a positive transition is detected. Even if the bit of the normally open instruction remains ON, the SALP instruction is executed only for one scan.