Type
| Function blockTON is available as standard (non-safety-related) and safety-related type (TON_S). For the safety-related type, the safety-related data types (SAFE*) are expected at the formal parameters. There is no safety-related type for LTIME. |
Description
| Provides a timer for delayed switching on. When the IN input switches from FALSE to TRUE, the Q output is set to TRUE after the delay time has elapsed. If the IN input is FALSE, Q will be FALSE and the output ET will be 0.If IN changes from FALSE to TRUE, switching on is delayed for the duration of the time interval applied to the input PT. After PT has elapsed, Q is set to TRUE. The elapsed time interval is indicated at the output ET. |
Notes
|
- The input IN and the output Q can be negated.Note: The negation of formal parameters is not supported in safety-related code (SNOLD).
- Function blocks have to be instantiated. The instance name of the function block has to be declared in the 'Variables' table of the POU where the FB is going to be used. The instance name must be unique within the POU.
|
Parameters
| Inputs
IN
Data type: | (SAFE)BOOL |
Description: | If a rising edge is detected, the on-delay timing is started. |
PT
Data type: | TON / TON_S: (SAFE)TIMETON_LTIME: LTIME |
Description: | Preset time interval for the delay. The time value must be positive. |
Outputs
Q
Data type: | (SAFE)BOOL |
Description: | TRUE if IN = TRUE and ET >= PT. FALSE if IN = FALSE or ET < PT. |
ET
Data type: | TON / TON_S: (SAFE)TIMETON_LTIME: LTIME |
Description: | Elapsed time interval. |
|
Timing Diagram
| Timing diagram
0 | The IN input is FALSE. As a result, Q is also set to FALSE. |
1 | IN switches from FALSE to TRUE. The measurement of the elapsed time is started. |
2 | When the delay time PT has elapsed (ET = PT), Q is set to TRUE. |
3 | IN switches from TRUE to FALSE. Q is set to FALSE immediately. |
4 | IN switches from FALSE to TRUE. The measurement of the elapsed time is started once more. |
5 | IN switches back to FALSE before the PT has elapsed. As a result, Q remains FALSE. |
6 | IN switches from FALSE to TRUE. The measurement of the elapsed time is started once more. |
7 | When the delay time PT has elapsed (ET = PT), Q is set to TRUE. |
8 | IN switches from TRUE to FALSE. Q is set to FALSE immediately. |
|