cancel
Showing results for 
Search instead for 
Did you mean: 

TOO Many loads!!!

Ala
Senior
 
19 REPLIES 19

it has no effect, but very unusual.

did you check your 25MHz clock on the scope ?

no I didn't check, how can I do that?

you need a scope... oscilloscope

otherwise disconnect the RCC in the cube and use the alternate onboard clock.

just to remove that question of working or not.

its late here, good luck,

using delays are the worst way to program.

its called blocking code.

dont use delays

oeliks
Senior

AC couple channel, gnd to gnd and probe x10 to OSC pin. If triggering this signal is imppssible (but can catch it with single on scope, run stop) than probabbly crystal if faullty and frequency is fluid.

Beside checking base frequency now You can perform math functions if scope allows. Do FFT and check charmonics level.​

oeliks
Senior

And You can also run a timer to blink led 1 s. Its easy to spot when your crystal HSE is not working and switch to lower freqency HSI.

S.Ma
Principal

if you are using a discovery board, check on the schematic that the pins are not connected to soldered components as they likely be.

You can first run the code with HSI 16 MHz internal clock (just don't inject clocks) to see what happens.

Then run a simple test main function

  • enable the peripheral clock
  • configure the GPIOs as push pull outputs (you can directly write the GPIO peripheral registers in 16 bit blocks)
  • use a main loop with delay to toggle these pins (use a global reference uint16_t mask myPort = 0, and use myPort ^= 0xFFFF to toggle, in order not to read the port to toggle it.
  • check pin by pin what you see.

Dear T J

what should I do instead of delays?

T J
Lead

dont wait,

did you prove the crystal is running, or did you select the onboard oscillator ?

which PCB are you using ?

Ala
Senior

GUYS IT IS SOOOOOLVED!

THANKS everyone who helped me through! :folded_hands: :folded_hands: :folded_hands:

T J
Lead

good to hear,

my approach is one step at a time, prove the board first.

but you didn't answer most of the questions, how can we do better than that ?

good work,