2-6
Section
CPM1A Pulse Output Functions
132
2-6-1 Programming Example in Continuous Mode
In this example program, pulse output begins from IR 01000 when input
IR 00004 turns ON, and is stopped when input IR 00005 turns ON.
SPED(64) can be used to stop pulse output. When using SPED(64) for that pur-
pose, specify #0000 (constant or word contents) as the pulse frequency.
@SPED(64)
001
000
#0100
00005 (pulse output stop condition)
@INI(61)
003
000
000
Begins pulse output.
Stops pulse output.
00004 (pulse output condition)
Output from 01000
Continuous mode
Pulse frequency: 1 kHz
2-6-2 Programming Example in Independent Mode
In this example program, pulse output begins from IR 01000 when input
IR 00004 turns ON, and is stopped after the specified number of pulses have
been output. The pulse amount is set in DM 0100 and DM 0101.
@PULS(65)
000
000
DM 0100
@SPED(64)
000
000
#0100
Sets the number of pulses.
Begins pulse output.
Pulse number setting
00004 (pulse output condition)
00004 (pulse output condition)
Independent mode
Pulse frequency: 1 kHz
2-6-3 Using Pulse Output Instructions
Before beginning pulse output using the independent mode use PULS(65) as
shown below to set the number of pulses to be output. This setting is not required
for the continuous mode.
@PULS(65)
000
000
N
In N, set the beginning word address of the words where the number of pulses is
set. Store the number of pulses in words N and N+1, in eight digits BCD, with the
leftmost four digits in N+1 and the rightmost four digits in N.
Make the setting within a range of 00000001 to 16777215 (BCD).
Setting the Number of
Pulses