Bug Report: embedded, arm, stm32: Missing Timer definition lazarus / 68-Other OS ---------------------------------------------------------------------- gasensor · 2024-04-07 08:36 In STM32F1, there are up to 17 TIMERS. But in STM32f10x_xl.pp/STM32f10x_ld.pp/STM32f10x_md.pp/STM32f10x_hd.pp, only TIMER1 to 8 are defined. F1 Timer Counts by Series: f103_ld : 3 (1to3) f103_md : 4 (1to4) f103_hd : 8 (1to8) f103_xl : 14 (1to14) f101/102_ld : 2 (1to2) f101/102_md : 3 (1to3) f101/102_hd : 6 (1to6) f101/102_xl : 12 (1to12) f100_ld : 12 1to12) f100_md : 12 (1to12) f100_hd : 16 (1to16) f105/107: 7 (1to7) Data sources : https://www.st.com/en/microcontrollers- microprocessors/stm32-mainstream-mcus.html ---------------------------------------------------------------------- Laksen · 2024-04-07 08:44 In RM0008 section 16: "This section applies to XL-density devices only." ---------------------------------------------------------------------- gasensor · 2024-04-07 08:54 Quote from: Laksen on April 07, 2024, 10:44:16 amIn RM0008 section 16: "This section applies to XL-density devices only." STM32f10x_xl.pp has only 8 timer definitions. In fact the xl series has 14 timers. Providing definitions where hardware does not exist will lead to misunderstandings and errors. ---------------------------------------------------------------------- Laksen · 2024-04-07 08:57 Ah I understand what you are saying now 2 issues: - Missing timers. Those can be added for sure. Should be simple enough for someone who has time - The mismatch between STM32F10x and STM32F100 I think this is likely a bug on my part. Not sure why that code was added to cover STM32F100*, since apparently the family didn't really "exists" yet back then, and it has its own reference manual.. My first reaction is that those controller types likely should be removed. Or someone should double check that the register definitions are correct ---------------------------------------------------------------------- gasensor · 2024-04-08 11:33 Quote from: Laksen on April 07, 2024, 10:57:29 amAh I understand what you are saying now 2 issues: - Missing timers. Those can be added for sure. Should be simple enough for someone who has time - The mismatch between STM32F10x and STM32F100 I think this is likely a bug on my part. Not sure why that code was added to cover STM32F100*, since apparently the family didn't really "exists" yet back then, and it has its own reference manual.. My first reaction is that those controller types likely should be removed. Or someone should double check that the register definitions are correct In fact, the embedded part lacks maintenance. It is not easy to use, so there are no new people to use it. Took a look at git and there are no plans to modify it.