Forum: µC & Digital Electronics STM32F1xx: Injected simultanous ADC doesn't work

von hochsitzcola (Guest)

Rate this post
not useful
I want to read in two phase currents of a BLDC motor, simultanous with 
injected ADC1 and ADC2 triggered by Timer1 Capture Compare Channel 4. 
See chapter 5.1 of the STM manual UM1052:

The interrupt of Timer1 Capture Compare Channel 4 works properly, but no 
injected ADC conversion is started :-(

If I start the conversion by software in the Timer1 Capture Compare 
Channel 4 callback, it works.

here are two screenshots of the relevant registers at runtime.


Any idea what's going wrong?

you can find the project at github.
(earlier commit, the recent commit is with the workaround via Tim1CC4 
we can discuss the problem on register level....

I've asked this question at several forums already, but no help so 



Entering an e-mail address is optional. If you want to receive reply notifications by e-mail, please log in.

Rules — please read before posting

  • Post long source code as attachment, not in the text
  • Posting advertisements is forbidden.

Formatting options

  • [c]C code[/c]
  • [code]code in other languages, ASCII drawings[/code]
  • [math]formula (LaTeX syntax)[/math]

Bild automatisch verkleinern, falls nötig
Note: the original post is older than 6 months. Please don't ask any new questions in this thread, but start a new one.