GETCPUACCOUNT
This functionality is not available on PLC runtime system under Windows CE!
The PLC task cycle ticker can be read with this function block. The PLC task cycle ticker is only incremented while the task is being executed. The numerical value is a 32 bit integer, which, independently of the CPU's internal clock rate, is output in a form converted into 100ns ticks. The number is refreshed to a precision of 100ns every time the PLC task is called, and can be used, for instance, for timing purposes. One unit is equivalent to 100 ns.
VAR_INPUT
(*none*)
VAR_OUTPUT
VAR_OUTPUT
cpuAccountDW :UDINT;
END_VAR
cpuAccountDW: the current value of the PLC task ticker;
Requirements
Development environment |
Target system type |
PLC libraries to include |
---|---|---|
TwinCAT v2.7.0 |
PC or CX (x86) |
PLCSystem.Lib |
TwinCAT v2.8.0 |
PC or CX (x86) |
TcSystem.Lib |