4. Motion Control Instruction 4.6.24. TOF_ms Explanation of the instruction: When EN is On and the input IN is On, the output TOF turns On and the current value ET is cleared as 0. When the input bit IN turns On -> Off, the current value ET starts timing from 0 on; as the current value ET is greater than or equal to the preset value PT, the output TOF turns Off. After ET reaches PT value, the timing will not be stopped till ET reaches maximum 4294967295. The preset value PT is effective immediately after being changed. TOF_ms is used as an off-delay timer with 1ms as the timing unit. Explanation of input and output parameter of the instruction: Note:
For the sequence chart of TOF_ms, please refer to the program example of TOF_s. 4-128 DVP-MC operating manual API Off-delay timer Controller TOF ms 151 _ 10MC11T Parameter Data Available Explanation name type device EN The execution condition of this instruction. “TOF ms” instruction is executed as “EN” turns on; the _ output TOF and the current value ET keep unchanged as “EN” turns off. BOOL M,I,Q, constant IN As “IN” turns on -> off, the timer starts timing; as “IN” turns on, TOF is on and ET is cleared as 0. BOOL M,I,Q, constant PT Preset value of the timer UDINT Constant TOF “TOF” is off as the current value of the timer is greater than or equal to the preset value PT.
BOOL M,Q ET The current value of the timer. UDINT D