Clock Management; Clock Management Overview; Internal Clock; External Clock - ST STM8S Getting Started

Hide thumbs Also See for STM8S:
Table of Contents

Advertisement

Clock management

4
Clock management
4.1

Clock management overview

STM8S and STM8AF devices offer a flexible way of selecting the core and peripheral clocks
(ADC, memory, digital peripherals). As shown in
external clock source inputs and one output clock (CCO).
For more details refer to the section on clock management in the datasheet
4.2

Internal clock

The RC oscillator has an internal capacitor (C) and an internal resistor ladder (R). STM8S
and STM8AF devices have two kinds of internal clock: a high speed internal clock (HSI)
running at 16 MHz and a low speed internal clock (LSI) running at 128 kHz.
After reset, the CPU starts with the internal RC (HSI clock signal) divided by 8, i.e. 2 MHz.
4.3

External clock

STM8S and STM8AF devices can connect to an external crystal or an external oscillator.
Note:
When no external clock is used, OSCIN and OSCOUT can be used as general purpose
I/Os.
Figure 6
12/40

Figure 5. System clock distribution internal clock

1 to 24 MHz
crystal
and external
clock
External clock
16 MHz/128 kHz
internal RC
lnternal clock
describes the external clock connections.
Figure
OSC
IN
OSC
OUT
Prescaler
AN2752 Rev 6
5, these devices have internal and
CCO pin
Clock unit
WDG/AWU
Timer
Clock distribution
AN2752

Advertisement

Table of Contents
loading
Need help?

Need help?

Do you have a question about the STM8S and is the answer not in the manual?

Questions and answers

This manual is also suitable for:

Stm8af

Table of Contents