Skip to main content
SIlia.1
Associate II
February 1, 2024
Question

The oscillatoris not working STM32F103CBU6TR

  • February 1, 2024
  • 4 replies
  • 1502 views

Hi,

I'm using STM32F103CBU6TR and I see that the oscillator that connects to osc_in and osc_out is not working.

The NRST is ih high, the BOOT0 is low and the power to the device is good.

What is the problem?

BR

Shmuel

4 replies

Peter BENSCH
ST Technical Moderator
February 1, 2024

All we know so far is that NRST and BOOT0 are not active and that power is applied. There should also be an oscillator at OSC_IN and OSC_OUT, but you should explain this to us in more detail. The fact that these two pins can also be programmed as GPIOs is not even relevant given the lack of information. Can you contribute anything else?

Regards
/Peter

In order to give better visibility on the answered topics, please click on Accept as Solution on the reply which solved your issue or answered your question.
SIlia.1
SIlia.1Author
Associate II
February 1, 2024

Hi Peter,

I'm not using this pins as GPIOs.

They're only for the oscillator.

What kind of information do you need?

Shmuel

Peter BENSCH
ST Technical Moderator
February 1, 2024

Firstly, the configuration of the STM32, e.g. as an IOC file from CubeMX as well as the schematics (at least the immediate environment) of the STM32.

In order to give better visibility on the answered topics, please click on Accept as Solution on the reply which solved your issue or answered your question.
Lead II
February 2, 2024

How do you know the external OSC pins are not working?

If you probe these pins with a scope - and you have a XTAL oscillator there - it cannot work (except you use really very high resistance, 10 MOhm probes): if you probe with a scope the signals on a real crystal (XTAL) oscillator - you kill the resonance of the XTAL.

The only way to figure out if the HSE XTAL works is:

  • configure the HSE XTAL in void SystemClock_Config(void), e.g.:
    RCC_OscInitStruct.OscillatorType = RCC_OSCILLATORTYPE_HSE;
    RCC_OscInitStruct.HSEState = RCC_HSE_ON;
  • and see if you get all the correct clocks, after programming the PLLs, setting DIViders etc.

Probing the XTAL pins does not tell you anything (it kills all).

It works fine, if you use a CMOS OSC instead (and just HSE_In). Change the system clock config accordingly (to use the BYPASS mode). Here you can probe with a scope.

SIlia.1
SIlia.1Author
Associate II
February 12, 2024

Hi,

The problem was on one of my devices.