Setup Example - Panasonic MN101L Series User Manual

Lsi
Table of Contents

Advertisement

9.10.2

Setup Example

High-Precision IGBT Output Setup Example
Here is an example that, using Timer 7 with HCLK (f
form with the 1/4 duty cycle and 400 Hz is output from TM7IOA output pin using the external interrupt 0 input
signal as a trigger.
The setup procedure and its description are shown below.
IGBT trigger
TM7IO output
Step
Setting
1
Disable the timer counter
2
Select the IGBT output pin
3
4
Set the timer mode register
5
6
7
8
9
Set the external interrupt
10
Set the timer mode register
11
Set the external interrupt
12
Set the interrupt level
13
Enable the interrupt
14
Set the timer mode register
15
Set the IGBT output cycle
16
Set the "High" period of IGBT
17
Enable the timer counter
Figure:9.10.7 Output Waveform of TM7IO output pin
Register
TM7MD.TM7EN = 0
TMIOEN1.TM7OEN = 1
TMIOEN1.TM8OEN = 1
P0DIR.P0DIR4 = 1
P5DIR.P5DIR7 = 1
TM7MD3.T7IGBTEN = 1
TM7MD2.TM7PWM = 1
TM7MD1.TM7CL = 0
TM8MD3.TM8SEL = 1
TM7MD2.TM7BCR = 0
TM7MD2.T7PWMSL = 1
TM7MD4.T7NODED = 1
TM7MD3.T7IGBT1-0 = 01
IRQ0ICR.REDG0 = 1
TM7MD3.T7IGBTTR = 0
TM7MD2.T7ICEDG0 = 1
IRQISEL0.IRQ0SEL = 0
IRQIEN.IRQI0EN = 1
IRQ0ICR.IRQ0LV1-0
IRQ0ICR.IRQ0IE = 1
TM7MD1.TM7CK1-0 = 00
TM7MD1.TM7PS1-0 = 00
TM7PR1 = 0x61A7
TM7PR2 = 0x1869
TM7MD1.TM7EN = 1
= 10 MHz) as clock source, the IGBT output wave-
HCLK
400 Hz
Disable the timer count operation.
Select the IGBT output pin.
[Chapter 7 I/O Port]
Enable the IGBT output.
Select the IGBT output.
Select the TM7BC clear source and the duty determination
source of IGBT output.
Select "No" as the dead time.
Select the IGBT trigger source.
Set the external interrupt valid edge.
Select the IGBT trigger level and IGBT trigger edge.
Enable the external interrupt pin.
Refer to [3.1.3 Maskable Interrupt Control Register Setup].
Select HCLK as the count clock source.
Set the IGBT output cycle.
Setup value: 25000 - 1 = 24999 (0x61A7)
Set the "High" period of IGBT output.
Setup value: 25000 / 4 - 1 = 6249 (0x1869)
Enable the timer count operation.
16-bit High-Precision IGBT Output (with Variable Period/Duty)
Description
Chapter 9
16-bit Timer
IX - 57

Hide quick links:

Advertisement

Table of Contents
loading

This manual is also suitable for:

Mn101lr05dMn101lr04dMn101lr03dMn101lr02d

Table of Contents