Implementation
High Level time calculation example
›
Part 1: 64534 increments before the first overflow: 65534 - 1000 = 64534
(Maximum value of T12 - counter value at rising edge = total increments)
›
Part 2: 65534 increments between the first and last (before falling edge) overflow:
1 * 65534 = 65534 (1 overflows * maximum value of T12 = total increments)
›
Part 3: 63955 increments after the last overflow: 63955 (counter value at rising edge)
›
Total increments between the rising and falling edges: 64534 + 65534 + 65244 =
195312
T12 count
(between 0 and 65534)
PWM signal (2 Hz)
Period of PWM signal 0.5 s
t
t
Interrupt on previous rising edge
T12 counter value: 1000
T12 counter value: 65244
Interrupt on current rising edge
2 overflows of timer T12 during high level time
Part 1
Part 2
Part 3
13
2020-01-17
Copyright © Infineon Technologies AG 2020. All rights reserved.