TP Pulse timer (TP)
Also called: pulse, timer pulse, one-shot timer, monostable
European style only: the American style has no such instruction.
Pulse: a rising edge of IN / EN sets Q / DN to 1 for exactly PT / PRE.Pulse: a rising edge of IN sets Q to 1 for exactly PT.Pulse: a rising edge of EN sets DN to 1 for exactly PRE.
What it does
The TP block makes a fixed-length pulse: on the rung's rising edge, Q / DN turns 1 for PT / PRE, whether the rung stays 1 or not.The TP block makes a fixed-length pulse: on the rung's rising edge, Q turns 1 for PT, whether the rung stays 1 or not.The TP block makes a fixed-length pulse: on the rung's rising edge, DN turns 1 for PRE, whether the rung stays 1 or not.
When to use it
For a fixed-length command: horn blast, pulse to a cylinder, timed dose.
Operands
| European mnemonic | American mnemonic | Name | Data type | Direction | Required | Access | Meaning |
|---|---|---|---|---|---|---|---|
| Instance | Instance | Instance (the timer’s memory) | IEC_TIMER / TIMER | Input | Yes | — | Instance (T1…): the timer's memory. One instance per timer. |
| IN | EN | Enable | BOOL | Input | Yes | Read (T1.IN / T1.EN) | The bit that says the instruction is active: the rung’s power reaches the instruction. |
| PT | PRE | Preset | TIME / DINT | Input | Yes | Read and write (T1.PT / T1.PRE) | Preset: the time to reach. A constant on the box is only the starting value; the program can change it with a MOVE / MOV. |
| Q | DN | Done | BOOL | Output | No | Read (T1.Q / T1.DN) | Pulse of length PT / PRE started by a rising edge of IN / EN. |
| ET | ACC | Accumulator: elapsed time | TIME / DINT | Output | No | Read (T1.ET / T1.ACC) | Accumulator: the elapsed time, from 0 up to PT / PRE. |
| — | TT | Timing | BOOL | Output | No | Read (T1.TT) | 1 during the pulse. American style only: not in the European style. |
| Mnemonic | Name | Data type | Direction | Required | Access | Meaning |
|---|---|---|---|---|---|---|
| Instance | Instance (the timer’s memory) | IEC_TIMER | Input | Yes | — | Instance (T1…): the timer's memory. One instance per timer. |
| IN | Enable | BOOL | Input | Yes | Read (T1.IN) | The bit that says the instruction is active: the rung’s power reaches the instruction. |
| PT | Preset | TIME | Input | Yes | Read and write (T1.PT) | Preset: the time to reach. A constant on the box is only the starting value; the program can change it with a MOVE. |
| Q | Done | BOOL | Output | No | Read (T1.Q) | Pulse of length PT started by a rising edge of IN. |
| ET | Accumulator: elapsed time | TIME | Output | No | Read (T1.ET) | Accumulator: the elapsed time, from 0 up to PT. |
| Mnemonic | Name | Data type | Direction | Required | Access | Meaning |
|---|---|---|---|---|---|---|
| Instance | Instance (the timer’s memory) | TIMER | Input | Yes | — | Instance (T1…): the timer's memory. One instance per timer. |
| EN | Enable | BOOL | Input | Yes | Read (T1.EN) | The bit that says the instruction is active: the rung’s power reaches the instruction. |
| PRE | Preset | DINT | Input | Yes | Read and write (T1.PRE) | Preset: the time to reach. A constant on the box is only the starting value; the program can change it with a MOV. |
| DN | Done | BOOL | Output | No | Read (T1.DN) | Pulse of length PRE started by a rising edge of EN. |
| ACC | Accumulator: elapsed time | DINT | Output | No | Read (T1.ACC) | Accumulator: the elapsed time, from 0 up to PRE. |
| TT | Timing | BOOL | Output | No | Read (T1.TT) | 1 during the pulse. American style only: not in the European style. |
Readable anywhere in the program, for example T1.Q / T1.DN. Writable members can be changed by the program (MOVE).Readable anywhere in the program, for example T1.Q. Writable members can be changed by the program (MOVE).Readable anywhere in the program, for example T1.DN. Writable members can be changed by the program (MOVE).
Timing diagram
Timing diagram checked against the simulator (the same engine as the editor).
Example
H1 turns on for 2 s each time S1 is pressed.
Try it in the simulatorThe example opens in the free simulator; your own program stays as it was.
Behaviour in detail
- Not retriggerable: a new edge during the pulse is ignored (at 3 s in the timing diagram).
- After the pulse, ET / ACC stays at PT / PRE while IN / EN is 1, then goes back to 0.After the pulse, ET stays at PT while IN is 1, then goes back to 0.After the pulse, ACC stays at PRE while EN is 1, then goes back to 0.
- A new pulse needs a new rising edge.
European (IEC) and American styles
European: TP, a fixed-length pulse (IEC 61131-3).
American: there is no TP in ladder; a pulse comes from the TT bit of a TON, 1 while it is timing. Difference: TT drops if the rung drops before the end; for a fixed length, keep the rung at 1 (seal-in) until DN. Here, TP is offered in the European style only.