Instruction list – Rockwell Automation 1761-HHP-B30 MicroLogix 1000 with Hand-Held Programmer (HHP) User Manual

Page 281

Advertising
background image

Chapter 14
Using High-Speed Counter Instructions

14–31

Instruction List

File 2, Rung 0

Initializes the high–speed counter each time the RRUN mode is entered.
The high–speed counter data area (N7:5 – N7:9) corresponds with the
starting address (source address) of the HSL instruction. The HSC
instruction is disabled each entry into the RRUN mode until the first time
that it is executed as true. (The high preset was ”pegged” on
initialization to prevent a high preset interrupt from occurring during
the initialization process.)

FUN GRAPHIC PARAMETER
CODE SYMBOL MNEMONIC NAME ADDRESS VALUE FORCES
–––– ––––––– –––––––– –––– ––––––– ––––– ––––––
20 |–] [– LD 1’st Pass

S1/15 0

106 MOV SRC 1
0000H
Output Mask (only use bit 0 ie. O:0/0)
DEST N5

106 MOV SRC 0
0000H
High Output Pattern (turn off O:0/0)
DEST N6

106 MOV SRC 32767
0000H
High Preset Value (counts to next hole)
DEST N7

106 MOV SRC 1
0000H
Low output pattern (turn on O:0/0 each reset)
DEST N8

106 MOV SRC 0
0000H
Low preset value (cause low preset intat reset)
DEST N9

171 HSL
High Speed Counter
CNTR C0

Output Mask (only use bit 0 ie. O:0/0)
SRC N5
LEN 5

File 2, Rung 1

This HSC instruction is not placed in the high–speed counter interrupt
subroutine. If this instruction were placed in the interrupt subroutine,
the high–speed counter could never be started or initialized (because an
interrupt must first occur in order to scan the high–speed counter
interrupt subroutine).

FUN GRAPHIC PARAMETER
CODE SYMBOL MNEMONIC NAME ADDRESS VALUE FORCES
–––– ––––––– –––––––– –––– ––––––– ––––– ––––––
170 HSC TYPE Encoder (Res,Hld)

High Speed Counter 1250
CNTR C0 0000H
PRE
ACC

Advertising