| 数据搜索系统,热门电子元器件搜索 |
|
AN4232 数据表(PDF) 10 Page - STMicroelectronics |
|
|
|||||||||||||||||||||||||||||
AN4232 数据表(HTML) 10 Page - STMicroelectronics |
|
10 / 17 page ![]() Application examples AN4232 10/17 DocID024134 Rev 2 2.2 Frequency and pulse width measurement In STM32F30x and STM32F37x devices, the comparator output can be redirected to the input capture of the embedded timers. This feature allows a pulse width and/or frequency measurement. The input signal, whose signal width/frequency has to be measured, is connected to the non-inverting input of the analog comparator. The threshold (reference) can be powered by: • the internal reference voltage VREFINT (1.22V) and sub-multiples (1/4 VREFINT, 1/2 VREFINT, 3/4 VREFINT) • the embedded digital-to-analog converters • an external pin The comparator output is redirected internally to the input capture. In this mode, the timer counter is captured at each effective edge. When the input signal goes higher than the reference voltage, the comparator output is set to a high level generating a rising edge on the timer input capture, and the timer counter is captured in the internal register. When the input signal goes lower than the reference voltage, the comparator output is set to a low level generating a falling edge and the timer counter is captured a second time in the internal register. The time elapsed between the two consecutive captures represents the pulse width. Hence, the pulse width measurement is performed by a simple subtraction of the second and the first capture. 2.3 Analog voltage monitoring STM32F30x and STM32F37x devices embed a 12-bit analog-to-digital converter (ADC) which is very fast with a sampling rate in the order of several mega samples per second. However, with a typical consumption of 1 mA, it may not be suitable for battery-powered applications if it is left powered-on continuously. It is therefore useful to use an analog comparator in application cases where an analog voltage (sensor output) needs to be measured only when a predefined threshold is exceeded. In STM32F30x and STM32F37x devices, the analog comparators are designed to work even in low-power modes (Sleep mode and Stop mode). They are still powered-on and so they are able to wake-up the MCU from low-power modes. In fact, the comparator output is connected to the EXTI controller which also remains powered-on in lower-power modes. Figure 5. Comparator output capability in low-power mode Moreover, the comparator input is an ADC channel so PCB designer doesn't need to make an external connection between the comparator input and the ADC channel. In an analog voltage monitoring application where the sensor output voltage is lower than the threshold, the MCU remains in Stop mode thereby saving power. As soon as the sensor output exceeds the threshold, the analog comparator wakes up the MCU, the ADC is |
|
|
链接网址 |
| ALLDATASHEET是否为您带来帮助? [ DONATE ] |
关于 Alldatasheet | 广告服务 | 联系我们 | 隐私政策 | 数据表链接 | 链接交换 | 制造商名单 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 |