![rtd DM35820HR Скачать руководство пользователя страница 62](http://html1.mh-extra.com/html/rtd/dm35820hr/dm35820hr_user-manual_1497527062.webp)
RTD Embedded Technologies, Inc.
|
www.rtd.com
62
DMx820 User’s Manual
101
Mode 5 (Hardware Triggered Strobe)
1
0
x denotes “not specified”
Count value of 0 executed 0x10000 count
Table 15: BCD: Operation count mode setting
BCD
Set Contents
0
Binary Count (16-bit Binary)
1
BCD Count (4-decade Binary Coded Decimal)
After setting Read/Load, Mode and BCD in each counter as outlined above, next set the desired count value. (In some Modes, the count value
is set first. In next clock, loading is performed, and then counting starts.) This count value setting must conform to the Read/Load format set in
advance. Note that the internal counters are reset to 0000H during co
ntrol word setting. The counter value (0000H) can’t be read.
The program sequence of the MSM82C54-2 is flexible. Free sequence programming is possible as long as the two following rules are
observed:
(i) Write the control word before writing the initial count value in each counter.
(ii) Write the initial count value according to the count value read/write format specified by the control word.
Note:
Unlike the MSM82C53-2, the MSM82C54-2 allows count value setting for another counter between LSB and MSB settings.
Mode definition
Mode 0
•
Application: Event counter
•
Output operation: The output is set to “L” level by the control word setting, and kept at “L” level until the counter value b
ecomes 0.
•
Gate function: “H” level validates the count operation, and “L”
level invalidates it. The gate does not affect the output.
•
Count value load timing: after the control word and initial count value are written, the count value is loaded to the CE at the falling edge
of the next clock pulse. The first clock pulse does not cause the count value to be decremented. In other words, if the initial count value
is N, the output is not set to “H” level until the input of (N+1) the clock pulse after the initial count value writing.
•
Count value writing during counting: The count value is loaded in the CE at the falling edge of the next clock, and counting with the new
count value continues. The operation for 2-byte count is as follows:
•
The counting operation is suspended when the first byte is written. The output is immediately set t
o “L” level. (No clock pulse is required.)
•
After the second byte is written, the new count value is loaded to the CE at the falling edge of the next clock.
•
For the output to go to “H” level again, N+1 clock pulse are necessary after new count value N is wr
itten.
•
Count value writing when the gate signal is “L” level: The count value is also loaded to the CE at the falling edge of the ne
xt clock pulse
in this case. When the gate signal is set to “H” level, the output is set to “H” level after the lapse of N c
lock pulses. Since the count value
is already loaded in the CE, no clock pulse for loading in the CE is necessary.
Mode 1
•
Application: Digital one-shot
•
Output operation: The output is set to “H” level by the control word setting. It is set to “L” level at
the falling edge of the clock succeeding
the gate trigger, and kept at “L” level until the counter value becomes 0. Once the output is set to “H” level, it is kept at
“H” level until the
clock pulse succeeding the next trigger pulse.
•
Count value load timing: After the control word and initial count value are written, the count value is loaded to the CE at the falling edge
of the clock pulse succeeding the gate trigger and set the output to “L” level. The one
-shot pulse starts in this way. If the initial count value
is N, the one-shot pulse interval equals N clock pulses. The one-shot pulse is not repetitive.
•
Gate function: The gate signal setting to “L” level after the gate trigger does not affect the output. When it is set to “H”
level again from
“L” level,
gate retriggering occurs, the CR count value is loaded again, and counting continues.