Operations And Setting Procedure Example - Fujitsu 8FX Hardware Manual

8-bit microcontroller new 8fx family
Table of Contents

Advertisement

MB95630H Series
28.5

Operations and Setting Procedure Example

The comparator can be activated by the software according to the setting of the
PD bit in the CMR0C register.
■ Software Activation of Comparator
To activate the comparator using the software, do the settings shown in Figure 28.5-1.
CMR0C
❍ : Bit to be used
× : Unused bit
0 : Set to "0"
After the comparator is activated as shown above, it has to stabilize before starting to operate.
Note:
Before activating the comparator, set the IE bit in the CMR0C register to "0" in advance in
order to avoid any unexpected interrupt generated due to the comparator being unstable
at its startup.
■ Setting Procedure Example
Below is an example of procedure for setting the comparator:
● Initial settings
1. Disable the comparator interrupt request. (CMR0C:IE = 0)
2. Activate the comparator according to the settings shown in Figure 28.5-1.
3. Wait until the comparator stabilizes.
4. Clear the interrupt flag bit. (CMR0C:IF = 0)
5. Enable the comparator interrupt request (CMR0C:IE = 1), and enable the comparator output
(CMR0C:VCOE = 1) if necessary.
MN702-00009-2v0-E
Figure 28.5-1 Settings for Activating Comparator
bit7
bit6
bit5
OS
×
×
FUJITSU SEMICONDUCTOR LIMITED
CHAPTER 28 COMPARATOR
28.5 Operations and Setting Procedure Example
bit4
bit3
bit2
IF
IE
VCID
0
0
bit1
bit0
VCOE
PD
0
0
599

Hide quick links:

Advertisement

Table of Contents
loading

This manual is also suitable for:

Mb95630h series

Table of Contents