Rev. 1.00
6�
��ne ��� �01�
Rev. 1.00
69
��ne ��� �01�
HT66FM5440
Brushless DC Motor A/D Flash MCU
HT66FM5440
Brushless DC Motor A/D Flash MCU
00: Input capture at rising edge of TPn_0 or TCKn and the counter value will be latched
into CCRA
01: Input capture at falling edge of TPn_0 or TCKn and the counter value will be latched
into CCRA
10: Input capture at falling/rising edge of TPn_0 or TCKn and the counter value will
be latched into CCRA
11: Input capture disabled
PTnTCLR[1:0]=01B or 10B or 11B:
00: Input capture at rising edge of TPn_0 or TCKn and the counter value will be latched
into CCRB
01: Input capture at falling edge of TPn_0 or TCKn and the counter value will be latched
into CCRA
10: Input capture at falling/rising edge of TPn_0 or TCKn and the counter value will
be latched into CCRA at falling edge and into CCRB at rising edge
11: Input capture disabled
Timer/Counter Mode
Unused
These two bits are used to determine how the PTMn output pin changes state when a
certain condition is reached. The function that these bits select depends upon in which
mode the PTMn is running.
In the Compare Match Output Mode, the PTnIO1 and PTnIO0 bits determine how the
PTMn output pin changes state when a compare match occurs from the Comparator A.
The PTMn output pin can be setup to switch high, switch low or to toggle its present
state when a compare match occurs from the Comparator A. When the bits are both
zero, then no change will take place on the output. The initial value of the PTMn
output pin should be setup using the PTnOC bit in the PTMnC1 register. Note that
the output level requested by the PTnIO1 and PTnIO0 bits must be different from the
initial value setup using the PTnOC bit otherwise no change will occur on the PTMn
output pin when a compare match occurs. After the PTMn output pin changes state,
it can be reset to its initial level by changing the level of the PTnON bit from low to
high.
In the PWM Mode, the PTnIO1 and PTnIO0 bits determine how the PTMn output
pin changes state when a certain compare match condition occurs. The PWM output
function is modified by changing these two bits. It is necessary to only change the
values of the PTnIO1 and PTnIO0 bits only after the PTMn has been switched off.
Unpredictable PWM outputs will occur if the PTnIO1 and PTnIO0 bits are changed
when the PTMn is running.
In the Capture Input Mode, the capture input trigger source is selected by the
PTnCAPTS bit in the PTMnC1 register for PTM1, PTM2 and PTM3. However, the
capture input trigger source is also determined by the CINS bit in the NF_VIH register
together with the PT0CAPTS bit in the PTM0C1 register for PTM0.
Bit 3
PTnOC
: PTMn Output control bit
Compare Match Output Mode
0: Initial low
1: Initial high
PWM Mode/Single Pulse Output Mode
0: Active low
1: Active high
This is the output control bit for the PTMn output pin. Its operation depends upon
whether PTMn is being used in the Compare Match Output Mode or in the PWM
Mode/Single Pulse Output Mode. It has no effect if the PTMn is in the Timer/Counter
Mode. In the Compare Match Output Mode it determines the logic level of the
PTMn output pin before a compare match occurs. In the PWM Mode it determines
if the PWM signal is active high or active low. In the Single Pulse Output Mode it
determines the logic level of the PTMn output pin when the PTnON bit changes from
low to high.