English
Language : 

M37905M4C Datasheet, PDF (71/102 Pages) Mitsubishi Electric Semiconductor – 16 BIT CMOS MICROCOMPUTER
PRELIMINARY NSootimcee: pTahriasmisentroict alimfinitsalasrpeescuifbicjeactitotno. change.
MITSUBISHI MICROCOMPUTERS
M37905M4C-XXXFP, M37905M4C-XXXSP
M37905M6C-XXXFP, M37905M6C-XXXSP
M37905M8C-XXXFP, M37905M8C-XXXSP
16-BIT CMOS MICROCOMPUTER
(2) Repeat mode
Repeat mode is selected when bit 3 of the A-D control register 0 =
“1” and bit 4 = “0”.
The operation of this mode is the same as the operation of one-shot
mode except that when A-D conversion for the selected pin is com-
plete and the result is stored in the A-D register, conversion does not
stop, but is repeated.
No interrupt request is generated in this mode. Furthermore, the A-D
conversion start bit is not cleared.
The contents of the A-D register can be read at any time.
Be sure not to write to the A-D register corresponding to the pins se-
lected for a comparator during operation.
(3) Single sweep mode
Single sweep mode is selected when bit 3 of the A-D control register
0 = “0” and bit 4 = “1”.
In the single sweep mode, the number of analog input pins to be
swept can be selected. Analog input pins are selected by bits 1 and
0 of the A-D control register 1 (address 1F16). Two pins, four pins, or
five pins can be selected as analog input pins, depending on the
contents of these bits.
A-D conversion is performed only for selected input pins. After A-D
conversion is performed for input of AN0 pin, the conversion result is
stored in A-D register 0, and in the same way, A-D conversion is per-
formed for selected pins one after another. After A-D conversion is
performed for all selected pins, the sweep is stopped.
A-D conversion is started when bit 6 of the A-D control register 0
(A-D conversion start bit) is set to “1”. When A-D conversion for all
selected pins end, the interrupt request bit of the A-D conversion in-
terrupt control register is set to “1”. At the same time, A-D conversion
start bit is cleared to “0” and A-D conversion stops.
(4) Repeat sweep mode 0
Repeat sweep mode 0 is selected when bit 3 of the A-D control reg-
ister 0 = “1” and bit 4 = “1”.
The difference from the single sweep mode is that A-D conversion
does not stop after conversion for all selected pins, but repeats again
from the AN0 pin. The repeat is performed among the selected pins.
Also, no interrupt request is generated. Furthermore, the A-D
convension start bit is not cleared. The contents of the A-D register
can be read at any time.
Be sure not to write to the A-D register corresponding to the pins se-
lected for a comparator during operation.
(5) Repeat sweep mode 1
Repeat sweep mode 1 is selected when bit 3 of the A-D control reg-
ister 0 = “1” and bit 4 = “1”, and bit 2 of the A-D control register 1 =“1”.
The differences from the repeat sweap mode 0 are as follows:
• the A-D conversion for one unselected pin is performed each time
when A-D conversion for selected pins is completed, and the A-D
conversion is repeated once again from AN0 pin.
• the number of analog input pins to be swept.
The analog input pins to be repeatedly swept are selected with bits 1
and 0 of the A-D control register 1. The contents of these pins are
used to select one pin, two pins, three pins or four pins.
The unselected pins are converted starting from the pin next to the
pins selected as repeat sweep pins. No interrupt request is gener-
ated. Furthermore, the A-D conversion start bit is not cleared.
The contents of the A-D register can be read at any time.
Be sure not to write to the A-D register, corresponding to the pins se-
lected for a comparator, during operation.
Precaution for A-D conversion interrupts
Clear the interrupt request bit of the A-D conversion interrupt control
register (bit 3 at address 7016) before using an A-D conversion inter-
rupt. It is because this interrupt request bit is undefined just after re-
set.
71