Omron CQM1H - PROGRAM Programming Manual page 292

Programmable controllers; inner boards
Table of Contents

Advertisement

Shift Instructions
Description
Flags
Example
00000
00001
00002
00003
00004
SFTR(84) is used to create a single- or multiple-word shift register that can
shift data to either the right or the left. To create a single-word register, desig-
nate the same word for St and E. The control word provides the shift direction,
the status to be put into the register, the shift pulse, and the reset input. The
control word is allocated as follows:
15 14 13 12
The data in the shift register will be shifted one bit in the direction indicated by
bit 12, shifting one bit out to CY and the status of bit 13 into the other end
whenever SFTR(84) is executed with an ON execution condition as long as
the reset bit is OFF and as long as bit 14 is ON. If SFTR(84) is executed with
an OFF execution condition or if SFTR(84) is executed with bit 14 OFF, the
shift register will remain unchanged. If SFTR(84) is executed with an ON exe-
cution condition and the reset bit (bit 15) is OFF, the entire shift register and
CY will be set to zero.
ER:
St and E are not in the same data area or ST is greater than E.
Indirectly addressed EM/DM word is non-existent.
(Content of *EM/*DM word is not BCD, or the EM/DM area boundary
has been exceeded.)
CY:
Receives the status of bit 00 of St or bit 15 of E, depending on the
shift direction.
In the following example, IR 00000, IR 00001, IR 00002, and IR 00003 are
used to control the bits of C used in @SFTR(84). The shift register is in DM
0010, and it is controlled through IR 00004.
03512
Direction
Status to input
03513
Shift pulse
03514
03515
Reset
@SFTR(84)
035
DM 0010
DM 0010
Not used.
Shift direction
1 (ON):
Left (LSB to MSB)
0 (OFF): Right (MSB to LSB)
Status to input into register
Shift pulse bit
Reset
Address Instruction
00000
LD
00001
OUT
00002
LD
00003
OUT
00004
LD
00005
OUT
00006
LD
00007
OUT
00008
LD
00009
@SFT(10)
DM
DM
Section 5-17
Operands
00000
03512
00001
03513
00002
03514
00003
03515
00004
035
0010
0010
267

Advertisement

Table of Contents
loading
Need help?

Need help?

Do you have a question about the CQM1H - PROGRAM and is the answer not in the manual?

Subscribe to Our Youtube Channel

This manual is also suitable for:

Sysmac cqm1h seriesSysmac cqm1h-cpu series

Table of Contents

Save PDF