1
0
mirror of https://github.com/RIOT-OS/RIOT.git synced 2025-01-18 12:52:44 +01:00
RIOT/cpu/stm32
Marian Buschsieweke f4729c28ec
cpu/stm32/periph_spi: improve prescaler calculation
With only 8 possible prescalers, we can just loop over the values
and shift the clock. In addition to being much easier to read, using
shifts over divisions can be a lot faster on CPUs without hardware
division.

In addition an `assert()` is added that checks if the API contract
regarding the SPI frequency is honored. If the requested clock is too
low to be generated, we should rather have a blown assertion than
hard to trace communication errors.

Finally, the term prescaler is used instead of divider, as divider may
imply that the frequency is divided by the given value n, but
in fact is divided by 2^(n+1).
2023-11-24 08:49:25 +01:00
..
bootloader cpu/stm32: implement reset to bootloader 2020-06-05 18:41:06 +02:00
dist build-system: Allow out of tree BUILD_DIR 2023-05-16 22:23:03 +02:00
include cpu/stm32: Provide spi_mode_t 2023-11-24 08:49:24 +01:00
kconfigs cpu/stm32: Implement GPIO LL IRQ support for STM32F1 2023-03-22 10:40:25 +01:00
lcd_fmc cpu/stm32: add FMC support for LCD with parallel interface 2023-10-12 18:19:03 +02:00
ldscripts cpu/stm32: add FMC RAM as heap 2023-07-26 09:02:10 +02:00
periph cpu/stm32/periph_spi: improve prescaler calculation 2023-11-24 08:49:25 +01:00
stmclk cpu/stm32: enable HSI48 for periph_usbdev 2023-07-05 09:40:24 +02:00
vectors cpu/stm32: Add Kconfig dependency modeling 2021-07-02 15:11:05 +02:00
cpu_common.c cpu/stm32: make bus arg consistent 2023-05-19 10:44:24 -04:00
cpu_init.c cpu/stm32/f1: prevent corrupting AFIO->MAPR 2023-11-20 20:28:52 +01:00
doc.txt treewide/stm32: Make CLOCK_HS* configurable 2022-11-03 11:37:28 +01:00
Kconfig cpu/stm32: add FMC support for LCD with parallel interface 2023-10-12 18:19:03 +02:00
Makefile cpu/stm32: add FMC support for LCD with parallel interface 2023-10-12 18:19:03 +02:00
Makefile.cmsis cpu/stm32: bump cmsis packages version 2023-08-28 09:47:44 +02:00
Makefile.default cpu: make pm_layered a DEFAULT_MODULE 2021-01-27 13:21:20 +01:00
Makefile.dep cpu/stm32: add FMC support for LCD with parallel interface 2023-10-12 18:19:03 +02:00
Makefile.features cpu/stm32: Implement GPIO LL IRQ support for STM32F1 2023-03-22 10:40:25 +01:00
Makefile.include cpu/stm32: add FMC RAM as heap 2023-07-26 09:02:10 +02:00
stm32_info.mk cpu/stm32: add initial support for stm32u5 family 2021-12-23 11:04:41 +01:00
stm32_line.mk cpu/stm32: Add STM32_LINE cases for STM32L1xxx6 2022-03-01 17:20:16 +01:00
stm32_mem_lengths.mk cpu/stm32: fix RAM_LEN for F427, F429, F437, F439 models 2022-11-15 22:29:34 +01:00
stm32_riotboot.mk cpu/stm32: fix riotboot settings for L4 and WB 2023-05-23 17:47:04 +02:00
stm32.config cpu/stm32: Add Kconfig dependency modeling 2021-07-02 15:11:05 +02:00