0
\$\begingroup\$

I am designing a custom PCB with the bluepill MCU, which I want to program over ST link and SWD, which external resonators are a must?

In the standard version, it comes with 32kHz and 8MHz: https://easyeda.com/r3bers/STM32F103C8T6-Test-Board

EDIT: I only want to use SWD programming (so no USB) and read an ADC signal each min. More references on this question are provided here: Link1 Link2

\$\endgroup\$
7
  • 1
    \$\begingroup\$ It depends what do you want to do with it. It does have internal clocks too, but if they are not suitable for what you are doing then you need external clock sources. \$\endgroup\$
    – Justme
    Mar 13, 2021 at 12:57
  • 1
    \$\begingroup\$ Datasheet will have the answer. As far as I remember, STM32 usually work from internal RC by default. \$\endgroup\$
    – Ilya
    Mar 13, 2021 at 12:59
  • \$\begingroup\$ @Ilya thank you, my application is relatively simple, please see my edit. I would like to go for the internal clock then. \$\endgroup\$ Mar 13, 2021 at 13:32
  • 2
    \$\begingroup\$ Well, how exact does your circuit's notion of 1 minute need to be? If the (haven't read the datasheet, but this is the usual order of magnitude) 5% accuracy of the RC built-in oscillator suffice: great! one less thing to power and design. \$\endgroup\$ Mar 13, 2021 at 13:40
  • 1
    \$\begingroup\$ because it wants do demonstrate what it can do with two! For example, run in a low-power mode with only the slow one, and then do high-perf stuff over some digital link with both. Note that if you have the 32 kHz one, you can probably put the thing into a really low-power mode where it only runs the oscillator and a counter, and wakes up only when you program it to. This might indeed be relevant to your application, if you need to run off a small battery. \$\endgroup\$ Mar 13, 2021 at 13:43

1 Answer 1

2
\$\begingroup\$

If you just want to load firmware into flash and read ADC then external clock references are not necessary. The chip will work with internal clocks during JTAG/SWD programming and running your firmware.

\$\endgroup\$
3
  • \$\begingroup\$ In addition to reading ADC, I want it to communicate as slave with a master over I2C. Does this require external resonators? \$\endgroup\$ Mar 13, 2021 at 15:37
  • 1
    \$\begingroup\$ Definitely does not require. \$\endgroup\$
    – Justme
    Mar 13, 2021 at 15:47
  • \$\begingroup\$ thanks for the extra clarification :) \$\endgroup\$ Mar 13, 2021 at 15:52

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.