| Motore di ricerca datesheet componenti elettronici |
|
AN2841 Scheda tecnica(PDF) 23 Page - STMicroelectronics |
|
|
|||||||||||||||||||||||||||||
AN2841 Scheda tecnica(HTML) 23 Page - STMicroelectronics |
|
23 / 31 page ![]() AN2841 Dimming application using an STM32 microcontroller 23/31 More examples of TotalTime for different number of LEDs and PWM resolution can be seen in Table 6. Table 6 shows the time required for processing one PWM step, one buffer load and one buffer latch. With an 8-bit PWM resolution, 256 buffer latches are needed; the maximum LE (Latch Enable) frequency must be divided by 256. These results are shown in Table 7. . Table 7 shows the maximum refresh frequencies for controlled LEDs. But the inverse computation must be used to solve our task. Table 8 shows the inversion of the Table 7 values and gives the required refresh frequency. The LE frequency must be derived and the SysTick timer preload value (SysTick-preload-value) set to generate the LE pulse by generating an interrupt at every counter reload event. Table 7 and Table 8 show that SysTick-reload-frequency will be set between 25.6 kHz and 371.7 kHz according to requested PWM resolution and LED count. The STM32 SysTick timer uses a reference clock of 72 MHz when set to the maximum value. The interrupt period for this timer is the SysTick-preload-value multiplied by 1 / (72 000 000). The reference clock of STM32 evaluation board is set to 48 MHz for the USB to operate correctly. This value should be taken into the account while making measurements on this evaluation board as their computation will influence Equation 3 . The reference clock can be also divided by 8 by using the hardware divider. The divided reference clock is then 9 MHz. In this case, the interrupt period for this timer is equal to a preload value multiplied by 1 / (9 000 000). Preload value = requested SysTick interrupt time / reference period Preload value = reference frequency / requested SysTick interrupt frequency. Table 6. TotalTime necessary for requested dimming parameters LEDs PWM TotalTime Max. LE frequency 8 8-bit 2.25 + 0.055 × 8 = 2.69 µs 371.7 kHz 8 12-bit 2.25 + 0.055 × 8 = 2.69 µs 371.7 kHz 672 8-bit 2.25 + 0.055 × 672 = 39.21 µs 25.5 kHz Table 7. Maximum refresh rate LEDs PWM Max. LE frequency Max. refresh rate 8 8-bit 371.7 kHz 1452 Hz 8 12-bit 371.7 kHz 90.7 Hz 672 8-bit 25.5 kHz 99.6 Hz Table 8. SysTick-reload-time for 100 Hz LEDs PWM Requested refresh rate SysTick-reload-time 8 8-bit 100 Hz 39 µs (25.6 kHz) 8 12-bit 90.7 Hz 2.7 µs (371.7 kHz) 672 8-bit 100 Hz 39 µs (25.6 kHz) 32 8-bit 100 Hz 39 µs (25.6 kHz) |
|
Link URL |
| Lei ha avuto il aiuto da alldatasheet? [ DONATE ] |
Di alldatasheet | Richest di pubblicita | contatti | Privacy Policy | Collegamento alla scheda tecnica | scambio Link | Ricerca produttore All Rights Reserved©Alldatasheet.com |
| Russian : Alldatasheetru.com | Korean : Alldatasheet.co.kr | Spanish : Alldatasheet.es | French : Alldatasheet.fr | Italian : Alldatasheetit.com Portuguese : Alldatasheetpt.com | Polish : Alldatasheet.pl | Vietnamese : Alldatasheet.vn Indian : Alldatasheet.in | Mexican : Alldatasheet.com.mx | British : Alldatasheet.co.uk | New Zealand : Alldatasheet.co.nz |
|
Family Site : ic2ic.com |
icmetro.com |