
403
When TCNT3 and TCNT4 count up to H'FFFF, a compare-match occurs with TGR3A, and
TCNT3 and TCNT4 are both cleared. At this point, TSR3’s TCFV bit is not set, but the TCFV bit
of TSR4 is set.
This can be avoided by sync setting for channel 3 and channel 4. Set the SYNC3 and SYNC4 bits
of the timer sync register (TSYR) to 1, compare-match with TGR3A by TCR3 for the counter
clear source, and sync clear with TCR4. This gives the sync setting for channels 3 and 4.
Figure 12.89 shows a TCFV bit operation example in reset sync PWM mode with a set value for
cycle register TGR3A of H'FFFF, when a TGR3A compare-match has been specified without
synchronous setting for the counter clear source.
TGR3A
(H'FFFF)
H'0000
TCF3V
TCF4V
TCNT3 = TCNT4
Counter cleared by compare match A3
Not set
Set
Figure 12.89 Reset Sync PWM Mode Overflow Flag
•
A mask operation
For A mask, the above operation is modified as follows:
When set to reset sync PWM mode, TCNT3 and TCNT4 start counting when the CST3 bit of
TSTR is set to 1. At this point, TCNT4’s count clock source and count edge obey the TCR3
setting.
In reset sync PWM mode, with cycle register TGR3A’s set value at H'FFFF and specifying
TGR3A compare-match for the counter clear source,
the operation of the overflow flag TCFV
bit for both TSR3 and TSR4 will be the same.
When TCNT3 and TCNT4 count up to H'FFFF, a compare-match occurs with TGR3A, and
TCNT3 and TCNT4 are both cleared.
At this point, TCFV bits for TSR3 and TSR4 are not set.
Figure 12.90 shows a TCFV bit operation example in reset sync PWM mode with a set value
for cycle register TGR3A of H'FFFF, when a TGR3A compare-match has been specified
without synchronous setting for the counter clear source.
Summary of Contents for SH7041 Series
Page 2: ......
Page 6: ......
Page 38: ...xvi ...
Page 44: ...6 ...
Page 46: ...8 ...
Page 48: ...10 ...
Page 82: ...44 ...
Page 114: ...76 ...
Page 118: ...80 ...
Page 124: ...86 ...
Page 170: ...132 ...
Page 250: ...212 ...
Page 492: ...454 ...
Page 506: ...468 ...
Page 604: ...566 ...
Page 684: ...646 ...
Page 706: ...668 ...
Page 778: ...740 ...
Page 780: ...742 ...
Page 818: ...780 ...
Page 850: ...812 ...
Page 923: ...SH7040 SH7041 SH7042 SH7043 SH7044 SH7045 Group Hardware Manual REJ09B0044 0600O ...