English
Language : 

UPSD33XX Datasheet, PDF (132/231 Pages) STMicroelectronics – Fast 8032 MCU with Programmable Logic
uPSD33xx
TCM Interrupts
There are 8 TCM interrupts: 6 match or capture in-
terrupts and two counter overflow interrupts. The 8
interrupts are “ORed” as one PCA interrupt to the
CPU.
By the nature of PCA application, it is unlikely that
many of the interrupts occur simultaneously. If
they do, the CPU has to read the interrupt flags
and determine which one to serve. The software
has to clear the interrupt flag in the Status Register
after serving the interrupt.
Table 73. TCMMODE0 - TCMMODE5 (6 Registers, Reset Value 00h)
Bit 7
Bit 6
Bit 5
Bit 4
Bit 3
Bit 2
Bit 1
Bit 0
EINTF
E_COMP
CAP_PE
CAP_NE
MATCH
TOGGLE
PWM[1:0]
Details
Bit
Symbol
Function
7
EINTF 1 - Enable the interrupt flags (INTF) in the Status Register to generate an interrupt.
6
E_COMP 1 - Enable the comparator when set
5
CAP_PE 1 - Enable Capture Mode, a positive edge on the CEXn pin.
4
CAP_NE 1 - Enable Capture Mode, a negative edge on the CEXn pin.
3
MATCH 1 - A match from the comparator sets the INTF bits in the Status Register.
2
TOGGLE 1 - A match on the comparator results in a toggling output on CEXn pin.
01 Enable PWM Mode (x8), fixed frequency. Enable the CEXn pin as a PWM output.
10 Enable PWM Mode (x8) with programmable frequency. Enable the CEXn pin as a
1-0
PWM[1:0] PWM output.
11 Enable PWM Mode (x10 or x16), fixed frequency. Enable the CEXn pin as a PWM
output.
Table 74. TCMMODE Register Configurations
EINTF E_COMP CAP_PE CAP_NE MATCH TOGGLE PWM1 PWM0
TCM FUNCTION
0
0
0
0
0
0
0
0 No operation (reset value)
0
1
0
0
0
0
0
1 8-bit PWM, fixed frequency
0
1
0
0
0
0
1
0
8-bit PWM, programmable
frequency
10-bit or 16-bit PMW, fixed
0
1
0
0
0
0
1
1
frequency(1)
X
1
0
0
1
1
0
0 16-bit toggle
X
1
0
0
1
0
0
0 16-bit Software Timer
X
X
0
1
0
0
0
0 16-bit capture, negative trigger
X
X
1
0
0
0
0
0 16-bit capture, positive trigger
X
X
1
1
0
0
0
0 16-bit capture, transition trigger
Note: 1. 10-bit PWM mode requires the 10B_PWM Bit in the PCACON Register set to '1.'
132/231