![](http://datasheet.mmic.net.cn/30000/M30956FKTGP_datasheet_2359453/M30956FKTGP_209.png)
15. Three-Phase Motor Control Timer Function
Figure 15.7
TB2SC Register, ICTB2 Register
Bit Name
b7
0
b6 b5 b4
b1
b2
b3
Symbol
TB2SC
Address
035Eh
After Reset
00h
b0
Function
Bit Symbol
RW
Timer B2 Special Mode Register(1)
RW
PWCON
TBSOUT
Timer B2
reload timing switch bit
Three-phase output forced cut
off port select bit(3, 4)
0 : U, V, W, U, V, W phase output from ports P7
and P8 cut off
1 : U, V, W, U, V, W phase output from port P3
cut off
0: Timer B2 underflows
1: Timer A outputs odd-number of times(2)
NOTES:
1. Set the TB2SC register after the PRC1 bit in the PRCR register is set to 1 (write enable).
2. Set the PWCON bit to 0 when the INV11 bit in the INVC1 register is set to 0 (three-phase mode 0) or the INV06 bit in
the INVC0 register to 1 (sawtooth wave modulation mode).
3. The TBSOUT bit is enabled only when the INV02 bit in the INVC0 register is set to 1 (three-phase cother control timer function
used).
4. The selected pins are cut off, regardless of function select register settings.
(b6-b1)
Reserved bits
Set to 0
Timer B2 Interrupt Generation Frequency Set Counter(1, 2, 3)
Symbol
ICTB2
Address
030Dh
RW
After Reset
Undefined
NOTES:
1. Use the MOV instruction to set the ICTB2 register.
2. If the INV01 bit in the INVC0 register is set to 1 (selected by the INV00 bit), set the ICTB2 register while the TB2S bit is set to 0
(count stops). If the INV01 bit is set to 0 (ICTB2 counter is incremented by one when timer B2 underflows) and the TB2S bit to 1
(count starts), do not set the ICTB2 register when timer B2 underflows.
3. If the INV00 bit in the INVC0 register is set to 1 (ICTB2 counter is incremented by one at the falling edge of the timer A1 reload
control signal) and the setting value of the ICTB2 counter is n, the first interrupt is generated when timer B2 underflows n-1
times. Subsequent interrupts are generated every n times timer B2 underflows.
WO
-
b7
b0
Function
Nothing is assigned. If necessary, set to 0.
When read, the content is undefined.
1 to 15
Setting Range
When the INV01 bit in the INVC0 register is set to 0 (the ICTB2
counter increments whenever timer B2 underflows) and a setting
value is n, the timer B2 interrupt is generated every nth timer B2
underflow. When the INV01 bit is set to 1 (the INV00 bit selects the
count timing of the ICTB2 counter) and a setting value is
n, the
timer B2 interrupt is generated every nth timer B2 underflow that
meets the condition selected with the INV00 bit.