Page 1 of 1
Migration - need more GPIO
Posted: Sat Mar 22, 2025 11:30 pm
by julian_lpp
I'm in the needing of migrating to a UC that provides more timers and GPIO. In this case I dont need more math power/clock freq , etc
I'd like to know if the code that is working in the low enty point F103 series is directly compilable in F103 higher performance line chips
For instance, coming from F103C8T6 and going to STM32F103VD, should the code compile without changes? If its not the case, How about minor changes? Does anyone have experience doing that?
I guess and its only a guess, that a better chip (the same line), has all stuff its predecesor has, plus, the improvements, .... Am I right?
reagards,
julian
Re: Migration - need more GPIO
Posted: Sun Mar 23, 2025 4:00 am
by ag123
I'd guess reviewing the datasheets would be a best option.
A thing I tend to note about stm32 mcus is that for the 'lower ports' e.g. PAxx and possibly PBxx as well, stm32 tends to keep the definitions 'the same'.
I'd guess that in part so that firmware built for a particular mcu could 'just works' say in a different mcu.
That is a good thing as you may have a firmware file without the source codes, but that it could be installed in a different mcu in that sense.
It is likely true for within a series, but I've not fully studied that across series, I think if going across series there may possibly be some differences, e.g. the f1xx vs g0xx likely have somewhat different assignments due to pin count limitations for the smaller pin socs, but that perhaps f1xx vs f4xx are likely 'quite similar' in terms of the lower ports.
it seemed within a same series e.g. f1xx or f4xx, the lower ports (e.g. A and/or B) mirror that across 'smaller' mcus e.g. c8,cb vs rb, rc, ve, vg, zg etc, and the difference are the additional io ports / resources and possibly sram and flash and perhaps some other pheriperials in the larger socs.
so my guess is a binary (or for that matter source) done for say a stm32f103c8 would likely 'just works' in a stm32f103ve.
Re: Migration - need more GPIO
Posted: Sun Mar 23, 2025 9:01 am
by GonzoG
If you're using STM core (without MCU dedicated libraries) code should work with any STM32 MCU. Only difference that you may have is different pins may be assigned to peripherals.
Re: Migration - need more GPIO
Posted: Tue Apr 22, 2025 3:33 am
by Ricardowell
julian_lpp wrote: Sat Mar 22, 2025 11:30 pm
I'm in the needing of migrating to a UC that provides more timers and GPIO. In this case I dont need more math power/clock freq , etc
I'd like to know if the code that is working in the low enty point F103 series is directly compilable in F103 higher performance line chips
For instance, coming from F103C8T6 and going to STM32F103VD, should the code compile without changes? If its not the case, How about minor changes? Does anyone have experience doing that?
I guess and its only a guess, that a better chip (the same line), has all stuff its predecesor has, plus, the improvements, .... Am I right?
reagards,
Slope Game
Good question, Julian! I’ve done similar jumps between F103 chips — usually the code compiles fine if you stay within the same family, especially if you're using standard peripherals (GPIO, timers, USART).