Fujitsu MB91260B Series Hardware Manual page 209

32-bit microcontroller
Table of Contents

Advertisement

CHAPTER 10 PWC (Pulse Width Count: Pulse Width Measurement)
■ Starting and Stopping of Pulse Width Count
The PWCSR (bit15, bit14: STRT, STOP bits) is used to start/restart/forcibly stop operations.
STRT bit starts/restarts a pulse width count, and STOP bit forcibly stops it. They can work when "0" is
written to their bit. But they cannot work unless the value written to both bits is exclusive. Be sure to write
the following combination when an instruction other than bit manipulation instructions (other than byte) is
written.
When a bit manipulation instruction (bit clear instruction) is used, these combinations are written by the
hardware automatically without having to take them into consideration.
Operation after startup
The following describes the operation after starting a pulse width count mode.
Pulse width count mode:
Reactivation
A restart is to start a pulse width count (write "0" to the STRT bit) during operation after the count has been
started. By restarting, the following operation occurs.
There is no influence in the operation, at measurement start edge wait state. If the measurement is in
progress, stops the counting, and then waits for the measurement start edge again. At this time, if a restart
occurs simultaneously with detecting a measurement end edge, the measurement end flag (EDIR) is set,
and the measurement result is transferred to PWCR in continuous measurement mode,
Stop
In single measurement mode, the counter overflow or the measurement end stops the count operation
automatically without having to take this into consideration. In other modes, or to stop operation before
stopping automatically, the operation must be stopped forcibly.
At two input selection of comparison
When the selected PWI1 edge is not inputted before the forced stop, the first measurement result after
the restart becomes erroneous. Perform the forced stop after the PWI1 edge is inputted.
194
Function
Starting / restarting of the pulse width count
Forcibly stopping of the pulse width count
The count will not be performed until the measurement start edge is inputted.
After the measurement start edge is detected, 16-bit up counter is cleared to
"0000
", and the counting is started.
H
STRT
STOP
0
1
1
0

Advertisement

Table of Contents
loading

This manual is also suitable for:

Fr60lite

Table of Contents