AP16098
UPS Main Control
XC164CS Implementation of Main Control
Application Note
13
V1.0, 2007-03
4.2
Pin Configuration
Table 2 indicates the configuration for all the XC164CM pins utilized in this UPS
reference design.
Table 2
XC164CM Pins Configuration
Functions
Pin Name
Pin Number
Direction
Modules
CC60
49
COUT60
50
CC61
51
PWM drive signals for inverter
COUT61
52
Out
CAPCOM6
Primary current
AN0
9
IGBT temperature
AN1
10
Output current
AN2
11
DC-bus voltage
AN3
12
Output voltage
AN4
13
Line voltage
AN5
14
Battery voltage
AN10
15
In
ADC
Line voltage zero-crossing signal
CC22
56
In
CAPCOM2
TRIAC control
P1H.0
1
In
Bypass relay control
P1L.4
53
Out
DC-bus relay control
P1L.5
54
Out
Changer control
P3.8
35
Out
Short-circuit signal
P9.1
44
In
Disable inverter signal
P9.2
45
Out
I/O Ports
UART communication with XC866 for
display control
TXD0
37
Out
ASC0
4.3
Initialization Settings
4.3.1
CAPCOM6
The CAPCOM6 initialization for PWM signal generation to drive the full-bridge inverter is
summarized as follows (according to display order in DAvE):
“Module Clock”:
Enable module.
“Pin Control”:
Use pin CC60, CC61, COUT60, COUT61 as output. Pin CC62 is not
used.
“T12”:
fcpu/1 (Resolution: 0.025us), Center-aligned mode, T12 period 50us (carried
frequency 20KHz), Enable interrupt for T12 period match (generating interrupt
per carrier cycle), Dead-time 1.2us.
“T13”:
No initialization is required for it isn’t used here.
“Multi Ch.”:
Disable multi-channel mode.
“Channels”:
Compare and capture modes should be disabled for channel 2. Channel
0,1 should be individually configured as (x=0,1): Compare Mode 3 (Use
pins CC6x/COUT6x as output); Enable T12 modulation for CC6x; The
compare output CC6x drives passive level while CC6xST is “1”; The
compare output COUT6x drives passive level while CC6xST is “0”; The
passive level of CC6x and COUT6x output are all “0”; Enable dead time
generation.