6
\$\begingroup\$

The clock of my STM32F303CC (links to datasheet; for reference manual see here) sporadically dies away, resulting in highly decreased code execution speed (see picture below). I already replaced the oscillator and experimented with different capacitor values. I also tested this on different boards, all exhibiting the same error.

The firmware of the STM32 always runs the same lines of code, so transitions in firmware code can't be the reason.

The components used are:

Any idea why this happens?

Edit: Replaced layout image as I forgot to render polygons.

Edit: The decoupling capacitors are on the direct opposite of the board, just beneath the STM, and are connected through vias with both top's GND and 3V3 pins (former through PCB wire, latter through the copper plane).

enter image description here enter image description here enter image description here

\$\endgroup\$
6
\$\begingroup\$

I see unconnected VDD, VDDA and VBAT pins in your circuit. You need to connect all those power pins to the chip.

VDDA might be the culprit here, as the crystal OSC might actually be powered by this pin.

\$\endgroup\$
  • 1
    \$\begingroup\$ I'm very sorry, that's my mistake. I forgot to render the polygons before taking the screenshot. I will update the picture as soon as possible. But all those pins mentioned by you are actually connected. \$\endgroup\$ – Seradir Jun 24 at 12:48
  • \$\begingroup\$ AN4206, chapter 5.4: Decoupling caps are missing or too far away to funtion properly. \$\endgroup\$ – Turbo J Jun 24 at 17:10
  • \$\begingroup\$ The decoupling capacitors are on the direct opposite of the board, just beneath the STM, and are connected through vias with both top's GND and 3V3 pins (former through PCB wire, latter through the copper plane). \$\endgroup\$ – Seradir Jun 25 at 2:04

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

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