2 setting a two-phase counter, 2 setting of two-phase counter – Hitachi NJI-350B User Manual

Page 222

Advertising
background image

Chapter 8 High-speed counter, PWM / Pulse train output and Analogue I/O

8-13

8.3.2

Setting of Two-Phase Counter

The setting of the two-phase counters are stored in the special internal outputs (WRF072 to WRF07E).

(1)

Phase counting mode

Set the phase counting mode (0-3) in WRF06E. Please see the chapter 8.3.1 about phase counting mode.

WRF06F:

Phase counting mode

Figure 8.19 Special internal output for phase counting mode

(2)

Setting the on-preset value

Set the count value (the on-preset value) at which the counter output is turned on (or off). Any value in the range from 0
to FFFFH (0 to 65, 535) can be set. If the on-preset value is set to the same value as the off-preset value, or smaller than
the off-preset value, the counter will not perform any counting (see (4).).

WRF072:

On-preset value for two-phase counter

Figure 8.20 Special internal output for setting the on-preset value

(3)

Setting the off-preset value

Set the count value (the off-preset value) at which the counter output is turned off (or on). Any value in the range from 0
to FFFFH (0 to 65, 535) can be set. If the off-preset value is set to the same value as the on-preset value, or larger than the
on-preset value, the counter will not perform any counting (see (4).).

WRF076:

Off-preset value for two-phase counter

Figure 8.21 Special internal output for setting the off-preset value

(4)

Setting the counter preload

When preloading is used, the value to be preloaded should be set for each counter used. Any value in the range from 0 to
FFFFH (0 to 65, 535) can be set.

WRF07A:

Preload value for two-phase counter

Figure 8.22 Special internal output for setting the preload value

This special internal output becomes valid immediately after the setting.

(5)

Diagnostic error

If the on-preset and off-preset settings contain the same values for one or more counters when the PI/O function setting
flag (R7F5) is turned on, the corresponding bit in the abnormality display special internal output turns on and the
counters with abnormal settings do not perform any counting. (It does not count even if a counter input is entered.) In
addition, the setting abnormal flag (R7F7) turns on.

Bit:

15

14

13

12

11

10

9

8

7

6

5

4

3

2

1

0

WRF057:

a

Not used

b

c

d

e

f

g

h

I

Figure 8.23 Special internal output for input/output function abnormality

Bit

Description of abnormality

Related terminal

a

Total pulse frequency abnormality

Y100 to Y103

b

Pulse 4 frequency abnormality

Y103

c

Pulse 3 frequency abnormality

Y102

d

Pulse 2 frequency abnormality

Y101

e

Pulse 1 frequency abnormality

Y100

f

Counter 4 preset value abnormality

X6

g

Counter 3 preset value abnormality

-

h

Counter 2 preset value abnormality

-

i

Two-phase counter 1 preset value abnormality

X0 to X3

Advertising