genericSTM32F103C8 vs Blue Pill F103C8 vs genericSTM32F103CB vs Blue Pill F103C8(128K)

Hello,
I’m a little bit confused on what are the differences between the 4 boards in my topic subject…
In older versions of PlatformIO core, I remember that the boards definition named “Blue Pill xxxxxx”, did use, by default,the Maple core; now (PlatformIO core 4.3.1), instead, it seems they use the stm core, while the ones named genericSTM32F103xx now use of the Maple core…Am I wrong?

Intuitively, would not have been better for the naming to be the exact opposite? I mean, when “Blue Pill” name was born, only Maple core was available… moreover associating an OFFICIAL part number naming (genericSTM32F103Cx) to the OFFICIAL arduino core

Arduino_Core_STM32 , by Frederic Pillon,

would have been, in my humble opinion, more intuitive and natural…

Moreover, the name Blue Pill F103C8 (128K) is “technically” wrong, because STMicroelectronics does not produce an mcu having such characteristics: the correct part number for this mcu family, having 128K of flash memory, is STM32F103CB, not STM32F103C8 !

Beyond the comments on the nomenclature, it seems something is wrong with the board definition named “genericSTM32F103CB”: using that board definition and then setting in the platformio.ini the following options

board_build.core = stm
upload_protocol = dfu

allows a correct program upload on an STM32F103CB having the maple bootloader loaded on it but leads to a strange problem: such a programmed board works ONLY until you reset it! Resetting the board, in fact, it comes back again in dfu mode, losing the program previously loaded! This does not happen using the other 3 boards definition, genericSTM32F103C8, Blue Pill F103C8, Blue Pill F103C8(128K), and using the same identical aforementioned options in the platformio.ini file.

You’re not wrong re genericSTM32F103xx using the Maple/Roger Clark core, and Blue Pill using the stm32duino core. But when you actually look at the cores, you’ll see that the stm32duino core references the blue pill as a board type, and the Maple/Roger Clark core instead references the “Generic STM32F103C”, etc. PlatformIO is simply sticking to the conventions already in use in the different cores.

And whilst the C8 isn’t supposed to have 128k of flash, it’s not confusing at all when looking at the official stm32duino core and the “BluePill F103CB (or C8 with 128k)” board type! :open_mouth:

I can’t tell you what’s going on with the DFU mode… as I haven’t played with the different variants, not have I gotten around to trying the official stm32duino dfu bootloader…

1 Like

See https://stm32duinoforum.com/forum/wiki_subdomain/index_title_Blue_Pill.html#128_KB_flash_on_C8_version

The F103C8 ST microcontroller is declared to have 64 KB of flash, but virtually all the C8 microcontrollers tested have 128 KB of flash instead.

So, these MCUs are marked C8 but behave like CB, so that’s where that naming comes from.

1 Like

@pfeerick, @maxgerhardt, thank you for the feedback; I got your point and, while the naming convention Blue Pill VS genericSTM32xxx" has its own “rationale behind” justifying the PlatformIO choice, I do not agree on the Blue Pill F103C8(128K) one: as cited by Max, the fact that “The F103C8 ST microcontroller is declared to have 64 KB of flash, but virtually all the C8 microcontrollers tested have 128 KB of flash instead”, doesn’t change the fact that, as officially stated on the STMicroelectronis site, the correct chip that GUARANTEE 128KB of flash is STM32F103CB, not STM32F103C8.

Searching trough the official core repo,it seems I’m not alone in thinking that such naming is somewhat misleading, and as far as I understood, Frederic Pillon is going to change/modifiy that…(or already have, I’m not sure…) in its official core, see here:

https://github.com/stm32duino/Arduino_Core_STM32/issues/1003

Still, thanks for the clarifications!

1 Like

Already has… it will now state “BluePill F103CB (or C8 with 128k)” … which is still technically wrong but your definition, just perhaps not as confusing. However, as you can see, this is only a recent ‘confusion’, as Matthijs only brought it up a month ago, and it hasn’t yet been included in a release of the STM32 core. When that does happen, I’ll be more than happy to do a PR (unless someone beats me to it) to sync PlatformIOs STM32 definitions with the STM32 core. I suspect Valeros will do it anyway as part of any other necessary changes introduced in what I guess with be 1.9.0 of the STM32duino core.

I believe Frederic’s rationale as to why there are in fact F103C8’s with 128k flash to be correct though - a by-product of the bin process, just like how Intel bin their different CPUs depending on if the silicon meets the spec, or gets crippled to behave like a fewer-core count or lower speed part. I seem to remember in the late 90s Intel had some supply issues with the PII 300Mhz cpus, and underclocked the 400Mhz parts and sold them as PII 300s… meaning industrious overclockers could ‘overclock’ them to 450mhz… as they were running well below design spec. Note… I could be wrong on the speeds… it was the PII, just can’t remember if was 400 down to 300, or 500 down to 400… you get the idea though, I’m sure! :wink: