Omron CP1E-NA@@D@-@ Computer Hardware User Manual


 
2 Instructions
2-332
CP1E CPU Unit Instructions Reference Manual(W483)
Operand Specifications
Flags
Function
ACC(888) starts pulse output on the port specified in P using the mode specified in M using the target
frequency and acceleration/deceleration rate specified in S. The frequency is increased every pulse
control period (4 ms) at the acceleration rate specified in S until the target frequency specified in S is
reached.
Pulse output is started each time ACC(888) is executed. It is thus normally sufficient to use the differen-
tiated version (@ACC(888)) of the instruction or an execution condition that is turned ON only for one
scan.
In independent mode, pulse output stops automatically when the specified number of pulses has been
output. In continuous mode, pulse output continues until it is stopped from the program.
An error will occur if an attempt is made to switch between independent and continuous mode during
pulse output.
PLS2(887) can be executed during pulse output for ACC(888) in either independent or continuous
mode, and during acceleration, constant speed, or deceleration. (See note.) ACC(888) can also be exe-
cuted during pulse output for PLS2(887) during acceleration, constant speed, or deceleration.
If ACC(888) is executed in independent or continuous mode with a target frequency of 0 Hz and then
ACC(888) or PLS2(887) is executed before pulse output stops, the target frequency will not change and
pulse output will stop. Execute ACC(888) or PLS2(887) after pulse output stops.
Note 1 Executing PLS2(887) during speed control with ACC(888) (continuous mode) with the same target fre-
quency as ACC(888) can be used to achieved interrupt feeding of a fixed distance. Acceleration will not be
performed by PLS2(887) for this application, but if the acceleration rate is set to 0, the Error Flag will turn
ON and PLS2(887) will not be executed. Always set the acceleration rate to a value other than 0.
2 If ACC (888) or PLS2 (887) is executed during the period from pulse output stop to one cycle after the stop
(when pulse output in-progress flag is ON), pulse output will start again in the next cycle after stopping.
However, if pulse output is stopped by INI (880), the pulse output instruction will become invalid within one
cycle after the stop. Execute the instruction till the pulse output in-progress flag is OFF.
3 ACC instruction can be used only with transistor output type of CP1E N/NA-type CPU Unit.
In case of transistor output type of CP1E E-type CPU Unit or relay output type, NOP processing is applied.
Area
Word addresses Indirect DM addresses
Constants CF
Pulse
bits
TR
bits
CIO WR HR AR T C DM @DM *DM
P, M --- --- --- --- --- --- --- --- --- OK
--- --- ---
S OKOKOKOKOKOKOK OK OK ---
Name Label Operation
Error Flag P_ER ON if the specified range for P, M, or S is exceeded.
ON if pulses are being output using ORG(889) for the specified port.
ON if ACC(888) is executed to switch between independent and continuous mode for a port that is outputting
pulses for SPED(885), ACC(888), or PLS2(887).
ON if ACC(888) is executed in an interrupt task when an instruction controlling pulse output is being executed in a
cyclic task.
ON if ACC(888) is executed for an absolute pulse output in independent mode but the origin has not been estab-
lished.
OFF in all other cases.
Target frequency
Time
Acceleration/deceleration rat
e
ACC
(
888
)
executed.
Pulse frequency
ACC(888) executed.