217
CHAPTER 18 METER CONTROLLER/DRIVER
(2) Compare control register (MCMPCn)
MCMPCn is an 8-bit register that controls the operation of the compare register and output direction of the PWM
pin.
MCMPCn is set with an 8-bit memory manipulation instruction.
RESET input clears MCMPCn to 00H.
Figure 18-4 shows the MCMPCn format.
Figure 18-4. Compare Control Register n (MCMPCn) Format
Address: FF6BH to FF6EH After Reset: 00H R/W
Symbol
7
6
5
4
3
2
1
0
MCMPCn (n = 1 to 4)
0
0
0
TENn
ADBn1
ADBn0
DIRn1
DIRn0
TENn
Note
Enables Transfer by Register from Master to Slave
0
Disables data transfer from master to slave.
New data can be written.
1
Transfer data from master to slave when MCNT overflows.
New data cannot be written.
ADBn1
Control of 1-bit addition circuit (cos side of meter n)
0
No 1-bit addition to PWM output
1
1-bit addition to PWM output
ADBn0
Control of 1-bit addition circuit (sin side of meter n)
0
No 1-bit addition to PWM output
1
1-bit addition to PWM output
Note TENn functions as a control bit and status flag.
As soon as the timer overflows and PWM data is output, TENn is cleared to “0” by hardware.
The relation among the DIRn1 and DIRn0 bits of the MCMPCn register and output pin is shown below.
DIRn1
DIRn0
Direction Control Bit
SMn1
SMn2
SMn3
SMn4
0
0
PWM
0
PWM
0
0
1
PWM
0
0
PWM
1
0
0
PWM
0
PWM
1
1
0
PWM
PWM
0
Caution
Bits 5 to 7 must be set to 0.
(3) Port mode control register (PMC)
PMC is an 8-bit register that specifies PWM/PORT output.
PMC is set with an 8-bit memory manipulation instruction.
RESET input clears PMC to 00H.
Figure 18-5 shows the PMC format.
Summary of Contents for mPD780973 Series
Page 2: ...2 MEMO ...
Page 66: ...66 MEMO ...
Page 98: ...98 MEMO ...
Page 138: ...138 MEMO ...
Page 164: ...164 MEMO ...
Page 182: ...182 MEMO ...
Page 204: ...204 MEMO ...
Page 244: ...244 MEMO ...
Page 262: ...262 MEMO ...
Page 278: ...278 MEMO ...
Page 290: ...290 MEMO ...