Sample Setup Procedure For Non-Overlapping Pulse Output; Figure 10.8 Setup Procedure For Non-Overlapping Pulse Output (Example) - Renesas H8SX/1500 Series Hardware Manual

32-bit cisc microcomputer
Hide thumbs Also See for H8SX/1500 Series:
Table of Contents

Advertisement

10.4.5

Sample Setup Procedure for Non-Overlapping Pulse Output

Figure 10.8 shows a sample procedure for setting up non-overlapping pulse output.
TPU setup
PPG setup
TPU setup

Figure 10.8 Setup Procedure for Non-Overlapping Pulse Output (Example)

Non-overlapping
pulse output
Select TGR functions
Set TGR values
Set counting operation
Select interrupt request
Set initial output data
Enable pulse output
Select output trigger
Set non-overlapping groups
Set next pulse
output data
Start counter
Compare match A?
Yes
Set next pulse
output data
Section 10 Programmable Pulse Generator (PPG)
[1]
Set TIOR to make TGRA and TGRB
output compare registers (with output
disabled).
[1]
[2]
Set the pulse output trigger cycle in
TGRB and the non-overlapping margin
in TGRA.
[2]
[3]
Select the counter clock source with bits
[3]
TPSC2 to TPSC0 in TCR. Select the
counter clear source with bits CCLR1
and CCLR0.
[4]
[4]
Enable the TGIA interrupt in TIER. The
DMAC can also be set up to transfer
[5]
data to NDR.
[6]
[5]
Set the initial output values in PODR.
[6]
Set the bits in NDER for the pins to be
[7]
used for pulse output to 1.
[7]
Select the TPU compare match event to
[8]
be used as the pulse output trigger in
PCR.
[9]
[8]
In PMR, select the groups that will
operate in non-overlapping mode.
[9]
Set the next pulse output values in NDR.
[10]
[10] Set the CST bit in TSTR to 1 to start the
No
TCNT counter.
[11] At each TGIA interrupt, set the next
output values in NDR.
[11]
Rev. 3.00 Mar. 14, 2006 Page 361 of 804
REJ09B0104-0300

Advertisement

Table of Contents
loading

Table of Contents