
R01UH0336EJ0102 Rev.1.02
Page 845 of 1538
Jul 17, 2014
V850E2/PG4-L
Section 15 TSG2 (TSG20)
(3)
Various Settings of HT-PWM Mode
Mode Setting
HT-PWM can be used when TSnCTL0.TSnMD1 and TSnMD0 is set to 01
B
.
Setting timer output
The output pins TSG2nO1 to TSG2nO6 are controlled by setting TSnIOC0,
TSnIOC2, and TSnIOC3.
The output pin TSG2nO0 indicates the up/down count status of the 16-bit
counter or the 16-bit sub-counter. Switch between the 16-bit sub-counter and
the 16-bit counter is done with the TSnIOC1.TSnTOS bit.
The TSG2nO7 pin outputs pulses of the diagnostic output or the A/D
conversion trigger. Please set it as required.
Enabling error
interrupt generation
Error interrupt (INTTSG2nIER) due to the detection of the simultaneous active
state of the positive phase and inverse phase is enabled by setting
TSnIOC1.TSnEOC to 1. In HT-PWM mode, with any value set in the compare
register, the simultaneous active state of the positive phase and inverse phase
is not possible. Please refer for to Section 15.10, Error/Warning Interrupt, for
details.
Setting register
rewriting timing
with reload function
With TSnCTL3.TSnRMC, reload (simultaneous rewrite) or rewrite (anytime) is
specified for the registers with reload function. The default setting is 0 (reload).
To reload, set TSnCTL4.TSnPRE or TSnVRE to 1.
The reload timing is not generated if both the TSnPRE bits and TSnVRE bits
are set to 0.
When "anytime rewrite" is specified, the unintended output may be generated
depending on the rewrite timing.
Setting interrupts
and skipping
function
Interrupts and the skipping function are set with TSnCTL4. TSnPIE should be
set to 1 when peak interrupt (INTTSG2nIPEK) is necessary and TSnVIE to 1
when valley interrupt (INTTSG2nIVLY) is necessary. To use the skipping
function for peak/valley interrupts, the TSnRCC4 to TSnRCC0 must be set.
Содержание V850 Series
Страница 1556: ...V850E2 PG4 L R01UH0336EJ0102 Back Cover ...