2019-12-24 05:05 AM
2019-12-28 03:34 AM
it has no effect, but very unusual.
did you check your 25MHz clock on the scope ?
2019-12-28 03:36 AM
no I didn't check, how can I do that?
2019-12-28 03:45 AM
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
2019-12-28 04:56 AM
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.
2019-12-28 05:27 AM
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.
2019-12-28 09:08 AM
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
2019-12-28 09:28 PM
Dear T J
what should I do instead of delays?
2019-12-28 09:31 PM
dont wait,
did you prove the crystal is running, or did you select the onboard oscillator ?
which PCB are you using ?
2019-12-29 05:23 AM
GUYS IT IS SOOOOOLVED!
THANKS everyone who helped me through! :folded_hands: :folded_hands: :folded_hands:
2019-12-29 01:11 PM
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,