Fujitsu MB95630H Series Hardware Manual page 363

8-bit microcontroller new 8fx
Hide thumbs Also See for MB95630H Series:
Table of Contents

Advertisement

MB95630H Series
■ Hardware Trigger
"Hardware trigger" refers to PPG activation by signal input to the TRGn input pin. When
EGS1 and EGS0 are set to "0b11" and the hardware trigger is used with TRGn input, PPG
starts operation on a rising edge and halts the operation upon the detection of a falling edge.
Moreover, the PPG timer begins operation of the following rising edge from the beginning.
The operation can be retriggered by a valid TRGn input hardware trigger regardless of the
retrigger setting of the RTRG bit when the TRGn input hardware trigger has been selected.
Counter value
m
n
0
Hardware trigger
PPG
(Normal polarity)
PPG
(Inverted polarity)
■ Setting Procedure Example
Below is an example of procedure for setting the 16-bit PPG timer.
● Initial setup
1. Set the interrupt level. (ILR*)
2. Enable the hardware trigger and interrupts, select the interrupt type, and enable output.
(PCNTLn)
3. Select the count clock and the mode, and enable timer operation. (PCNTHn)
4. Set the cycle. (PCSRHn, PCSRLn)
5. Set the duty. (PDUTHn, PDUTLn)
6. Start the PPG by the software trigger. (PCNTHn:STRG = 1)
*: For details of the interrupt level setting register (ILR), refer to "CHAPTER 5 INTERRUPTS" in this
hardware manual and "■ INTERRUPT SOURCE TABLE" in the device data sheet.
● Interrupt processing
1. Process any interrupt.
2. Clear the interrupt request flag. (PCNTLn:IRQF)
MN702-00009-1v0-E
Figure 19.6-5 Hardware Trigger in PWM Mode
Rising edge detected
(1)
(2)
(1)=n × T ns
(2)=m × T ns
FUJITSU SEMICONDUCTOR LIMITED
CHAPTER 19 16-BIT PPG TIMER
19.6 Operations and Setting Procedure Example
Falling edge detected
T : Count clock cycle
m: Value of PCSRH & PCSRL registers
n : Value of PDUTH & PDUTL registers
Time
343

Advertisement

Table of Contents
loading

Table of Contents