Panasonic FP Series Programming Manual page 895

Hide thumbs Also See for FP Series:
Table of Contents

Advertisement

High-speed counter instructions
28.3 High-speed counter: writing and reading the elapsed value
The elapsed value is stored as a double word in the special data registers. Access the special data
registers using the system variable sys_diHscChannelxElapsedValue (where x=channel number).
System variables for memory areas used:
FP-Sigma
FP-X, Transistor types
FP-X, Relay types
FP0R
FP0, FP-e
The first example shows how to write an initial value (elapsed value) into the high-speed counter.
Example
The second example shows how to read an elapsed value and copy it to a variable.
All input and output variables used for programming this function have been declared in the POU
header.
Body
An initial value of 3000 (elapsed value) is written into channel 0 of the high-speed counter.
LD
All input and output variables used for programming this function have been declared in the POU
POU header
header.
The elapsed value of the high-speed counter is read from channel 0 of the high-speed counter and
Body
copied to the variable diElapsedValue.
LD
894

Advertisement

Table of Contents
loading

Table of Contents