0
\$\begingroup\$

In STM32 microcontrollers there is a distinction between HSI and HSE(high speed external). This indicates an internal external distinction.

On the other hand as shown in this document there is external clock-source concept as ETR:

enter image description here

Also here it says:

Timers get their clock source from External pins or Internal timer sources.

So it seems there is two types or internal external distinction or am I interpreting something wrong here?

Is HSE and ETR same things? Or HSE is a subset of internal clock source?

\$\endgroup\$

2 Answers 2

2
\$\begingroup\$

No, HSE and ETR are not the same thing.

The HSE is the High Speed External system clock source which is connected to the RCC (Reset & Clock Control) module in the microcontroller.
Is can be driven by an external oscillator, or you can (usually) connect a crystal or resonator to the built-in oscillator.
The HSE can be used as the main system clock and/or many of the bus or peripheral clocks in the micro.

An ETR is a Timer module's External TRigger input, which can be used to clock the timer's counter, or can be used for other purposes related to the timer module.
It can be driven by an external clock or other source of pulses, and does not have any built-in oscillator like the HSE has.
The ETR cannot be used to clock the micro's core, nor can it be used as the bus or peripheral clock for any module other than the timer it's connected to.

\$\endgroup\$
2
\$\begingroup\$

HSE and HSI refers to the system clock source, which provides clock to the entire MCU.

ETR refers to external clock for a timer. The timers can be configured to get their clock derived from the system clock (whether it is HSI or HSE or some other type), or from some other external source via a GPIO pin, using ETR.

The ETR can not clock the entire system, only (some) timers. It also does not actually clock the entire timer peripheral, it only triggers counting of the timer.

\$\endgroup\$

Your Answer

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

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