Skip to main content
DU2
Associate II
October 17, 2019
Solved

How to use STM32L0xx 's Comparator in Stop mode?

  • October 17, 2019
  • 1 reply
  • 778 views

I want to use Comparator, for comparing external voltage with Vref in stop mode

so that if external voltage is more than Vref, wake up from stop mode and do something.

I read example code about Comparator, LPTIMER ... but they are not exact solution about my project

so Can you give some idea or example about Using Comparator in stop mode ?

This topic has been closed for replies.
Best answer by Danish1

A thing about examples is that they are just that - examples. It is rare that one exactly matches your intended use.

What I recommend you to do is read relevant parts of the Reference Manual for your stm32l0xx. This is a huge document, but that's only because all these stm32 are amazingly powerful devices. It has sections on comparators and low-power modes. (I say this because I didn't get a clue as to whether or not you've studied this from your question).

My guess is that there will be separate control of VRef (perhaps in the section for the ADC) because VRef and any potential-dividers always burn power.

Hope this helps,

Danish

1 reply

Danish1
Danish1Best answer
Lead III
October 17, 2019

A thing about examples is that they are just that - examples. It is rare that one exactly matches your intended use.

What I recommend you to do is read relevant parts of the Reference Manual for your stm32l0xx. This is a huge document, but that's only because all these stm32 are amazingly powerful devices. It has sections on comparators and low-power modes. (I say this because I didn't get a clue as to whether or not you've studied this from your question).

My guess is that there will be separate control of VRef (perhaps in the section for the ADC) because VRef and any potential-dividers always burn power.

Hope this helps,

Danish