CQM1 1 and 2 read the PV value of PLC high-speed counter

There are 2 ways to read PV value, 1th from SR232 and SR233 (port 1) or SR234 and SR235 (port 2) read the 2nd use PRV () instructions.
1) read SR232 and SR233 or SR234 and SR235.
High speed counter 1 PV is stored in SR232 and SR233, high speed counter 2 PV is stored in SR234 and SR235, as shown below. In linear mode, when the leftmost bit is f.
These words each time through the loop is only 1 times and therefore can differ from the actual PV value.
 
2) PRV () instructions.
 
PRV () read the instructions of high speed counter 0 PV, high speed counter specified in the p 1 or 2 (P=001/002). P1 is the PV for the first word.
Specifies high speed counter PV storage below. In linear mode, when the leftmost bit is f. PRV () read the instructions to implement PV.
There are 2 ways to change high-speed counters 1 and 2 of the PV. The first is reset with the reset method. This PV is reset to 0. The second is to use INI () instructions.
INI () instructions changing PV are as follows:
Linear mode specified in the negative, in the leftmost bits are set to f.
Instance 1 standard output pulse from the port, 1 with high-speed counter counts the pulses.
Solution high speed counter in increase/decrease mode, CW pulse pulse output increment the counter (input b). CCW Pulse counter decrement (a phase). In implementing the program, PLC settings proceed as follows to set and start PLC.
DM6611:0000 (high speed counter mode).
DM6643:002 (port 1: standard pulse output, linear count mode z signal and software reset, increase/decrease mode).
PLC set other settings with the default settings (input does not refresh when the interrupt handling).
In addition, the comparison table to store the following data:
DM0000 0003 comparison criteria: 3
Target value for DM0001 2500 1:2,500
DM0002 0000
DM0003 0100 1 interrupt subroutine number: 100
DM0004 7500 target 2:7,500
DM0005 0000
DM0006 0101 2 interrupt handling subroutine number: 101
DM0007 0000 target 3:10,000
DM0008 0001
DM0009 0102 3 interrupt subroutine number: 102

Leave a Reply

Your email address will not be published. Required fields are marked *