Store function, Limitation function – Rockwell Automation 1794-ID2 U.MNL INCREMENTAL ENCODER User Manual

Page 20

Advertising
background image

1–8

Overview of the Incremental Encoder Module

Publication 1794ĆUM015B-EN-P - May 2001

Store Function

Use the store function to copy the value in the counter register
(Counter) to the latch register (StoreValue).

The StoreControl parameter determines the store function. Execution
occurs on either the positive or negative edge of input signals G and
Z respectively (see table). The parameter is a 2–bit binary code in
write word 1 (bits 11 and 12)

Word

1 or 2

Bits

11 12

Binary 12

11 StoreControl bits

1 or 2

11-12

0

0

0

Savethecounter valueon thepositiveedgeof Z

(if Stored X = 0)

1

0

1

Savethecounter valueon thepositiveedgeof G

(if Stored X = 0)

2

1

0

Savethecounter valueon thenegativeedgeof G

(if Stored X = 0)

3

1

1

Savethecounter valueon both thepositiveedge

and negative edge of G (if Stored X = 0)

The parameter Stored must be reset (0). Stored is set (1) when the
operation is completed. Reset after the operation with StoreReset.

Store Control = 1

Counter Register

Logic

G

Stored = 0

Thecounter valueis copied to thestoreregister on thepositiveedgeof input signal G.

Example

Store Register

Latched = 1

Limitation Function

If the control bit RangeLimited = 1, the counter counts up to the
preset value and restarts at 0. Counting down, the counter reaches the
preset value on the next pulse if the current counter value = 0.

RangeLimited = 0 corresponds to RangeLimited = 1 if the preset
value = FFFF in hex = 65535 in decimal.

The flag PresetReached is set when the counter is equal to the preset
value. Use PresetReset to reset the flag.

Advertising