UM-0085-B09
DT80 Range User Manual
Page 338
RG
Schedule Triggers
Counter channels can be configured to trigger a schedule when the counter reaches its specified wrap value (at which
point it resets to 0). See
Trigger on External Event (P53)
for more details. For example,
RA2C(10) 1TK
will measure a temperature on every 10th pulse received on digital input
2D
.
Presetting Counters
The count value for a digital input channel can be preset using an expression, e.g.
RA1M 8C=1000 RB2S 8C
will reset the counter to 1000 once per minute. So if a 1Hz signal is now applied to input 8D you would expect the values
returned every 2s for channel
8C
to follow a sequence similar to:
1000, 1002, 1004 ... 1056, 1058, 1000, 1002 ...
Setting Counter Wrap Value
A counter’s wrap value (channel factor) is applied when the channel is defined (i.e. when the job is entered), not when it
is evaluated. Also, setting the wrap value has the side effect of resetting the count value to zero. This implies that:
•
a particular counter’s wrap value need only be specified once in the job. It does not need to be specified every
time the counter is evaluated.
•
If querying a counter using the immediate schedule (e.g. by periodically typing "
1C
"), do not specify a wrap
value each time. Each time you evaluate an immediate channel you are also defining it, so the counter value will
always be returned as zero if you specify a wrap value each time.
Counters – High Speed
The DT80 provides four dedicated counter inputs, labeled
1C-4C
(7 counters
1C-7C
on DT85/85L Series 3). These
provide for high speed pulse counting (100kHz typical) and can also function as phase encoder inputs.
The
HSC
(high speed counter) channel type is used to access these counters. For example,
2HSC
will return the number
of positive transitions seen on the
2C
counter input.
Figure 162: High Speed Counter Channels
This above figure shows a simplified circuit diagram for the DT80’s hardware counter inputs. As can be seen, the
channels can be divided into pairs of inputs,
1C-2C
(counter channels
1HSC
and
2HSC
) and
3C-4C
(
3HSC
and
4HSC
);
also
5C-6C
on DT85/ 85L Series 3. Each pair can be used as either:
•
two independent counter inputs, for pulse counting, or
•
a single phase encoder (quadrature) input, for use with position sensors that provide phase encoded outputs
("A" and "B"). See
Note:
on the DT81, only the
3C-4C
inputs can be used with a phase encoder.