Whenever a product becomes popular, it’s only a matter of time before other companies start feeling the urge to hitch a ride on this popularity. This phenomenon is the primary reason why so many terrible toys and video games have been produced over the years. Yet it also drives the world of electronics. Hence it should come as no surprise that ST’s highly successful ARM-based series of microcontrollers (MCUs) has seen its share of imitations, clones and outright fakes.
The fakes are probably the most problematic, as those chips pretend to be genuine STM32 parts down to the markings on the IC package, while compatibility with the part they are pretending to be can differ wildly. For the imitations and clones that carry their own markings, things are a bit more fuzzy, as one could reasonably pretend that those companies just so happened to have designed MCUs that purely by coincidence happen to be fully pin- and register compatible with those highly popular competing MCU designs. That would be the sincerest form of flattery.
Let’s take a look at which fakes and imitations are around, and what it means if you end up with one.
Anatomy of a forgery
Earlier this year, Keir Fraser posted an informative summary of some fake STM32F103 ICs as found on so-called ‘Blue Pill’ and similar boards on their Github. The forgeries carry the same marks on the packaging as the genuine STM32 parts, but can often be identified by the pattern of dimples on the packaging, or by the quality of the silkscreen.
These forgeries aren’t always fully functional. As noted by Fraser, many of these parts cannot even be programmed properly, or even run code as simple as the universal ‘blinky’ example. It’s possible that these forgeries are in fact defective STM32F103 dies or similar that are being sold via less-than-legal channels.
More insidious perhaps are the near-forgeries that at first glance may look like the real part, but are betrayed by the identification on them: ‘STM32FEBKC6’. That’s not a legitimate ST parts code, and that should be the first tip. This is another clone that’s likely to bring you nothing but grief, as even when it does work, it is a cut-down version of the STM32F103 design, with missing features. Finding detailed information on it is hard as well.
Good artists copy
This leaves the trickiest of the clones, in the form of the aforementioned CS32F103. This clone essentially works like the real deal, and can run Blinky compiled for the STM32F103 just fine. Some of these MCUs may even be marked as the ST part, making them hard to identify conclusively.
Some of these are manufactured by CKS (中科芯微), a Chinese company who have apparently made a feature-complete version of the STM32F103, to the point where they have fixed some of the errata listed in the ST datasheet. An article over at CNXSoft provides some more details on this MCU.
A major difference one will quickly encounter with this chip is when programming it and getting the message "UNEXPECTED idcode: 0x2ba01477"
. The reason for this is that the STM32F103 MCU reports the ID 0x1ba01477
, confusing the programmer. This can be fixed for example in OpenOCD by using a configuration script that specifies either no CPUTAPID (0), or this ID reported by the CS32 MCU.
Giga clones
Probably one of the more famous STM32 clone makers is GigaDevice with their GD32 MCUs. As noted over at SMD Prutser in an article series, the GD32F103 appears to be a faster, more capable version of the STM32F103. It has a higher maximum clock speed and faster Flash storage, with a decapped unit showing that they used two dies inside the package. One for the MCU, and one for the Flash storage, allowing for a rather flexible way to change Flash sizes across their product range.
At first glance the GD32 MCUs look more attractive than the STM32F1 series, with significant increases in clock speed (72 versus 108 MHz) and Flash storage. While the Flash storage on the GD32 should be very slow, being a serial SPI ROM, its use of SRAM on the MCU die to ‘cache’ the Flash storage means that it ends up being much faster than on-die Flash storage, with zero wait states required even at full MCU clock speed.
A disadvantage of more SRAM instead of pure Flash is that it increases power usage, especially in sleep mode. It also causes a (small) boot-up delay when the SPI ROM’s contents are copied into SRAM before the firmware can run. Depending on the application this may be an advantage or disadvantage. This is of course the same approach as the ESP8266 MCU, which also uses an external SPI ROM for firmware.
When it comes to other GD32 devices, however, they seem to be less eager to make direct clones. Their GDF303 MCU kept the same peripherals as the GDF103, even though those of the STM32F3 are arguably better. This also prohibits their use as a drop-in solution for STM32F3xx boards. Depending on one’s opinion of the STM32F1 peripherals, this may also affect one’s decision to use those GD32 MCUs.
They’re everywhere
Although I was aware of the aforementioned fakes and clones, I nevertheless came across a new one recently. This involved the purchase of some ‘Blue Pill’ STM32F103 boards from a big German importer and reseller of all kinds of Maker tat. I wasn’t proud of this, but I needed some cheap boards to use for BlackMagic probes, and they had a good deal. In the comments for the Amazon listing some people mentioned they got a genuine boards, while others mentioned that it was a ‘fake’.
In the spirit of morbid curiosity, I got a couple of these boards and was both horrified and pleased to see that I had in fact received Blue Pill boards that did not carry the promised STM32F103C8T6 MCU, but instead one marked CH32F103C8T6. On the bright side it did not claim to be an ‘ST’ part.
This CH32F103 MCU is produced by a Chinese company called WCH, with the (Chinese-only) datasheets and reference manual both provided for download. At a cursory glance, both the datasheet and manaul show a chip that’s practically identical to the STM32F103, with identical memory mapping and peripheral registers.
Hooking it up to an ST-Link/V2 dongle and connecting to it with OpenOCD results in the same CPUTAPID error as with the CS32F103 MCU when using the STM32F1xx profile file. After making the same change to the stm32f1xx.cfg
file as suggested by others, I was able to flash the ‘Blinky’ example from my Nodate STM32 project onto the board without further issues.
This suggests that at least the basic RCC (reset & clock control), GPIO and SysTick functionality is similar enough for such a basic test to work. Next, I’ll have to explore whether it also handles the USART, DMA, SPI, I2C and I2S functionality the same way as the STM32F103 MCU that I have on a few other boards. If this MCU is anything like the CS32F103 part, the answer is probably ‘yes’.
As for the seller’s response when I contacted them about these Blue Pill boards not featuring the advertised STM32 part, they admitted that they were aware of this and claimed that ‘in two months’ they’d have boards with genuine STM32 parts again. Admittedly that raises a lot more questions than it answers, least of all why they’d knowingly sell boards that do not feature the advertised MCU.
Time to panic?
The eagle-eyed among us may have noticed that virtually all of these clones involve ST’s first-generation Cortex-M MCUs (STM32F1 series). Unless you need to buy Blue Pill boards for commercial projects, this is unlikely to do more than seriously annoy hobbyists and others who like to have a stack of $3 Cortex-M3 boards around for random projects. If one orders MCUs and development boards from reputable sellers such as Digikey and Mouser, it’s also unlikely to be much of a concern.
The Blue Pill and Black Pill boards are also seeing a bit of an overhaul recently with updated versions featuring STM32F4-based MCUs. Although a bit more expensive than the STM32F103-based counterparts, they do bring considerably more resources to the table and the much more pleasant (in my opinion) peripherals of the STM32F4 line. These may just make the market for the STM32F103 and with it these countless clones, counterfeits, and copies dry up.
Until the first batches of counterfeit, cloned and copied STM32F401 and STM32F411 MCUs hit the market, naturally. Because that’s apparently the name of the game.
What’s the legal status of the clones? Are they ARM licensees? Does ST have any rights to their peripheral architecture?
I’m sure the Chinese government says they are A OK 100% legal.
Years ago, Japan had the reputation or being a dishonest manufacturer, which lowered the countries reputation. The Japanese government sorted the fakes out. Chjna needs to do the same thing. I have purchased components rebadged with fake chip IDs. Now my company knly purchases German components as warranty and failures is expensive to our reputable franchise. China is playing the short minded game.
“German components” i.o.w. made in China and a 1000% markup added
Yes, the markup is to cover certification and verification. Just like the old line “the equipment is cheap, the piece of paper that says it works to spec is expensive.”
If they buy an ARM license, and hand their engineers the STM32F103 Technical Reference Manual, and ask them to design peripherals with the same registers. That would be a clean room re-implementation of the peripherals, wouldn’t it? So I guess they’re legal.
Looking at GigaDevice, they’ve got resellers in the west. I guess they wouldn’t if there ware legal issues.
I still buy the clones. At < 2$ a pop, I hot air off the clone and stick down modern stm32l443s or lately stm32l562s a 110mhz CM33 w/TrustZone. ST still supports the same 12yo pinout, LQFP48 which is pretty amazing.
That’s an excellent idea. I should pick up a few of those and try it with the Bluepills I ordered that arrived with CKS chips on them.
I was going to do the same thing with my years old USB Serial adaptors that appear to have hooky Prolific parts. Unfortunately the enclosures are moulded on, so I bit the bullet and bought some genuine FTDI equivalent parts directly. Today they arrived, and I can report that they work just fine. (Of course!)
That’s one of the great things about ST MCU’s, the pinout remains the same across most of them. (I’m kinda annoyed their STM32G series have changed the pinout.)
I see the L433 in an LQFP-48 package at RS, but it seems RS doesn’t offer any L5’s in LQFP-48 package.
It was indeed annoying when all these clones started appearing as the BluePill is something that you could buy in quantity and have it stored in a drawer for quick tests. The wrong resistor on the USB line was already a bit of an annoyance to check but the cloned MCU is indeed a deal-breaker (I have two boards in a drawer and have to remember which one has the real MCU).
This was one of the reasons that I was excited to see GigaDevice create their own RISC-V processor (GD32VF103, note the “VF”), mimicking the STM32F103. The Sipeed Longan Nano has this chip and is really cheap (4u$s, including an OLED screen). Sadly there are some issues while debugging (couldn’t get it to work realiably) which I think are problems in the chip itself. So unless there’s a rev2 fixing that it doesn’t seem to be such a great replacement. I really hope they do release a new version.
I am amazed they still contain the wrong resistor. It shows the producers have no idea what they are making, or do not care as long as it sells. On our part, we should complain way more about these things at aliexpress as the sellers cherish their rating
Lately I’ve been getting boards with the correct R10 resistor… after all those years, it seems, at least some manufacturers, have realised their mistakes.
What problems did you exactly have? Got it to work just fine with the Sipeed debugger, that seeedstudio sells.
Tho I do have to admit, that it’s a bit iffy first to set up. After that, it runs fine
First version was poorly designed, Chinese cloning process kicked in immediately, unfortunately they added another mistake (wrong resistor) and before they realized it they had 100K+ in stock. It’s minor annoyance (having to press a button to reprogram) for most of the stuff and an issue if you’re trying to do some other stuff (attach as flash drive, reattach as 2 x serial). You can get around some things in software and some soldering fixes it permanently.
https://stm32duinoforum.com/forum/viewtopic_f_30_t_780.html
Use a fine tip Sharpie and mark the boards which is real and which is a clone.
I bought some Black Pills clearly labeled as containing Apex APM32 parts not genuine ST parts (From RobotDyn) a couple months ago because I just needed some cheap micros for one-off tasks (being essentially sophisticated USB adapters, generating pulse sequences to drive other things, etc.) on the basis that they were dirt cheap (<$2/board) and adequate.
I haven't been pushing them real hard, but the features I've used have been truly drop-in compatible, they're clearly marked as Apex APM32 parts not fake STs which makes me feel a lot better about them, and they appear to be constructed from licensed compatible IP that just _happens_ to be arranged to exactly match the ST docs, rather than a stolen die mask or something, so I don't feel too weird about them that way. Their documentation does say some misleading things about there being an FPU (as far as I can tell, there isn't), and their CAN bus transceiver is connected differently than in the genuine STM32F103 parts … but in a desirable way so that you can use it simultaneously with the USB.
When I was deciding on them I read this excellent multi-part piece (first part also linked in the comments of the CNXSoft article linked in TFA) that gives some reasonable detail on the different species of drop-in compatibles that may or may not be remarked to look like genuine ST parts.
Thanks for linking to my site about the GD32..
I think the clones are in general compatible but the nitty gritty is in the details of the chips with unknown errors (or features ;)) Prolly good enough for hobbiest to blink a LED but for serious business stick to the authorized resellers. Recently I discovered the USB of the GD32 is not totally compatible with the STM32, probably because of timing or difference in the memory access.
Still interesting the see how the chip clones manufacturers operate, even with penny bases margins.. I’m wondering how easy and cheap it would be to design a chip and get is made in china
Designing and stm32f103 clone is not particularly difficult, especially if you don’t care about things like analog performance or (especially) sleep power consumption.
The core is a block you buy from arm, and many peripherals are either quite trivial to write or you can buy the same one ST licensed.
SRAM and Flash is a block you normally get from the foundry and can just place.
You don’t need a very good process to make this type of CPU, UMC 90nm is cheap and good enough.
Do you have some details about the USB incompatibilities you’re experiencing?
Got some CKS32F103C8T6 (STM32F103C8T6 clone) blue pills. Work without problems as a Maple Mini.
Some heavy timer/dma-related stuff works like the original one.
Good to hear that. I am also working with them well beyond the “LED blinky” level and seeing no problems whatsoever. So I think this talk of “you can’t use them beyond blinking an LED” is alarmist talk from people who aren’t really using them”. On the other hand, if I was going into production with a product, I would likely not be buying my parts on AliExpress.
For production we choose seller we can sue. :-)
I still have a CKS board in my collection of boards:
http://www.zoobab.com/stm32-bluepill-clone-cks32f103c8t6
And the bootloader on those boards is horrible, as it does not wait long enough for the Arduino IDE to detect it, I had to patch it to wait 10 seconds, so that the Arduino IDE is usable:
http://www.zoobab.com/bluepill-arduinoide
And the stm32duino wiki vanished off the web.
Good news that WCH is doing a clone, they have crazzy prices, too bad their datasheets are in chinese only, like the cheap ch552g:
http://www.zoobab.com/ch552g-blink
stm32duino did not vanished, just moved to github:
https://github.com/stm32duino
https://github.com/stm32duino/wiki/wiki
I guess they lost content in the migration, as I cannot find the equivalent of this page:
https://web.archive.org/web/20190220175310/http://wiki.stm32duino.com/index.php?title=Black_Pill
If anybody has a way to restore a website from Archive.org, I am ready to restore it somewhere.
One thing I have noted (and like) about the GD32 clones is that they reliably supply 128K of flash. Not that I have needed it yet mind you, but it is nice. The higher clock rate is also nice, but not something I have needed as yet. If some of the silicon errata are fixed as well, that is just great.
AliExpress…
Don’t ever try to complain! You get (or not) what you pay for.
There is no satisfactory complaints section, or it’s buried so deep you cannot possibly find it. The usual complaint is directly to the supplier, is moderated and apparently doesn’t appear for some months, giving the supplier adequate time to setup a new shop. And they can remove your complaint too. It’s way more shaddy than eBay, and often it’s not cheaper, and usually waaay slower. Ali is just there for their commission, and in so doing, aids the scammers. That’s not to say there aren’t honest suppliers, but there’s plenty of crooks on Ali.
Banggood is no better.
I’ve bought a lot from Ali and all but 3 have gone just fine. Although sometimes you have to wait quite a while.
One time the stuff was not available anymore, the seller told me to submit complaint and i would get my money back. I did and they returned the money.
One time 1/3 of the stuff (1 identical item to the 2) i ordered didn’t arrive, so they sent me a new one.
One time i received a broken device, the most expenssive anything i’ve ever ordered from there (something around $80). That time i had to fight it and i made a video of it not working and also highlighted manual pictures of how it should work. I submitted all those to the complaint and won the case clearly, since all they had to say about it was that i was using it wrong (the Apple excuse). The video and the manual proved otherwise.
Give us even one god damn actual example of your claims or shut it.
“That time i had to fight it and i made a video of it not working and also highlighted manual pictures of how it should work. I submitted all those to the complaint and won the case clearly, since all they had to say about it was that i was using it wrong (the Apple excuse). The video and the manual proved otherwise.
Give us even one god damn actual example of your claims or shut it.”
That hassle seems to underscore [Cluso99]s complaint.
One experience like that is enough to turn me off to any supplier for good!
Can you honestly assure me that things like this never happen with local suppliers?
Well, he had no such example and 2/3 of mine where good straight away.
You also have to have some sense in buying stuff. Thinking you can get that 300 credit glass statue unbroken through mail is going to end up bad.
I bought a $50 Geiger counter on Ali. Came with the tube shattered due to improper packaging. After much ado I had to pay the return shipping of $24 in order to get my $50 refunded. Never bought any valuable item there again. And never will.
I just got 3 clones from eBay, https://www.ebay.com/itm/114565802977 they are advertised as STM32F103C8T6, the chip themselves have the ST logo screen printed on them and also say STM32F103C8T6, but when programming with SM32CubeIDE it won’t recognize it, and with openocd it says
Warn : UNEXPECTED idcode: 0x2ba01477
Error: expected 1 of 1: 0x1ba01477
So if I change my openocd.cfg to include `set CPUTAPID 0x2ba01477` or `set CPUTAPID 0` then I am able to upload blinky code, or USB serial code, and it works.
I do notice that the fake boards have better kerning on the slikscreen pin lettering, and better quality soldering on the 90 degree programming header. So that’s the best way I can tell from pictures that it’s fake. But on this particular eBay listing the pictures also have bad kerning, and the product they sent is nice looking other than it being a clone.
My recommendation. Update to the latest openocd 0.11
then use interface/stlink-dap.cfg in stead of interface/stlink-v2.cfg
This will work with original and clone without modification
It would be great if you would leave a review on eBay for other customers to warn about the counterfeit/fake chips. We had to stop selling these modules because original chips are currently unavailable. It really bugs me when I see that all the lost business goes to sellers of illegal items.
The project Greaseweazle uses the Bluepill board. When you download the zipfile it contains a Blinky_Test.hex file which can be used to test most features of the xx32F103xx that’s mounted. See https://github.com/keirf/Greaseweazle
I really don’t understand the appeal of things like the Blue Pill when we have ESP32. Seems like ultra low power and savings a few dollars is about all the other chips can do better, and there’s not many projects that can’t be improved with some WiFi.
It’s always a shame to see really crappy clones though. The Chinese wild west clone system has proven they can make excellent stuff, just as good as anyone else, when they actually bother to.
A Bluepill (hopefully) is a real ARM Cortex-M3. I program in the Ada language which does not have an ESP32 port. It was reasonably straightforward to move AdaCore’s runtime to the F103. So all my home hacking projects use Ada and ‘some’ form of Bluepill be it an F103, L443 or L562.
http://www.hrrzi.com/2017/11/ada-on-2-ebay-bluepill-board.html
and
http://www.hrrzi.com/2018/02/the-bluepill.html
Props for using Ada – That was my Uni’s teaching language of choice, and it definitely beat a few good habits into me that’ve lasted nigh on 30 years
yep – and as far as I know there are no fake esp32 out there, and I buy quite a few. Though there are quite a few crappy boards that they are on, so it’s best to find a manufacturer you like (and have tested) and stick to them (or do your own board)..
ESP32 does not have USB.
ESP32s don’t have integrated USB; many of the projects I find myself using STM32 parts for are basically fancy USB-[Something] adapters (and an awful lot of the commercial applications are too).
Being simple ARM Cortex parts, the variety of software (Languages, libraries, OSes, etc.) for ESP32s is better, though Espressif has been doing a good job at encouraging support for their Tensilica Xtensa cores.
ESP32s have a large black-box firmware running on them for the radios, which is often undesirable.
ESP32s have radios, which isn’t always desirable (see: Internet of Shit)
STM32s have a much lower power budget than ESP32s, especially in modes where they haven’t turned all their IO off.
Every ESP32 board I’ve run in to (and especially the ESP32-cam modules) has had issues with marginal onboard power supplies (though that isn’t mostly Espressif’s fault, the vendors just all chose barely-adequate buck regulators for boards where the main SoC can burst to 300mA).
ESP32 packages (incl. radio cage) are physically both much larger and also harder to hand-work than the things other families are available in.
…and neither of them have 5V IO pins, so I still find myself reaching for Atmel 32u4 parts despite the compute-per-dollar proposition being terrible because for an awful lot of uC tasks all that matters is IOs that will interoperate with whatever you’re strapping them on to.
Typo, the language/library/toolchain support for _STM32s_ is better.
If you need bidirectional 3.3V 5V translation, you can use a BSS138 N-channel mosfet with two 10K resistors.
Otherwise maybe look at a dedicated voltage translation IC if you need a large amount of pins to be translated.
ADC on stm32 has dual simultaneous capture at 1MHz. And dma that buffer to anywhere automatically.
Esp has only 1 1v adc.
STM32 has true pwm and irq.
Esp does pwm and irq in software. I’d imagine the effective clock rate takes a hit when you use them. I think I’ll make a video on this.
Has anyone been disappointed that pwm doesn’t slice a half duty cycle up into many on/off cycles instead of a long off/long on cycle?
It’s only the ESP8266 that does PWM in software
And at least on the ESP8266 the ADC is not really accurate, in one project it was barely usable for battery voltage monitoring. To me it seems, it is just a byproduct of the radio front end needing RSSI monitoring (received signal strength indication).
I don’t get why there are “good” clones. I mean look at this CKS company and their clone that is so good they even corrected some of the known errata from the original. If a company is capable of doing that then why aren’t they just designing their own legitimate platform‽ I guess it’s hard to break into a market that is already dominated by big names but they certainly seem capable of competing on price. Is reverse engineering really that much less expensive to do than original design?
If you design a new CPU, why not make the peripherals similar to another liked platform (stm32f103 is popular in china)? 16650 UART for example was ‘cloned’ many times.
There is a quite long thread about the “variants” on:
https://www.eevblog.com/forum/microcontrollers/cheap-bluepill-very-likely-it-has-fake-stm32-right/
Somewhere in those 9 pages:
– Link to a site with more pictures and also decapped chips of all variants: https://www.richis-lab.de
– Search on LCSC without the “STM” prefix. (They sell most variants directly, and have links to datasheets too)
– Link to https://robotdyn.com which sells both board with (claimed) genuie ST parts (USD3.5) and cheaper “alternatives”
– Link to github with a KiCad project, so you can order your own empty pcb’s.
I have stopped buying blue pills because the sources have become too unreliable, which is quite a shame because I really liked the small form factor and compatibility with breadboard and matrix board for quick projects, but having to deal with 8 possible clones with fake STM branding and different operation of those and figuring out the details without even knowing for sure which chip you have is too annoying. In the near feature I may try the robotdyn boards. Price is fair and they also have resellers in the EU, which promises quick shipping.
When you “buy” an EUR 1.5 Blue pill you can be pretty sure it does not have a STM chip, even if it’s printed on it. Some of the boards I have, have the STM part number, but not the ST Logo.
Just to be clear, I’m OK with the clones of the chips, but abhor the removal of the type numbers and printing STM on the package, because this hides the differences, and makes it very difficult to even know which part you have. And dealing with incompatibilities in even one of the peripherals can easily lead to several hours of debugging frustration. Is that really worth the price difference?
As low volume customer I see a few options to battle the fakes.
First, buy the EUR3.5 variants from (hopefully?) reliable sources such as robotdyn.
Second: If it claims to be a STM part, and it is not. Complain and ask for a full refund. Also tell the shop you are willing to add the price difference if they send you the genuine parts. There can not be much profit on a EUR1.5 board including shipping from china. I guess that if 10 to 20% of their customers complain for a refund, they can not make a profit anymore from these practices.
On the plus side. You can download datasheets of these variants (again: links on LCSC site), and some of the descriptions of a peripheral may be clearer if you look at another datasheet.
Then there are also explicit differences, which can be useful. I would not call a difference between 72MHz and 108MHz very significant for a small uC. If you need some MHz, then get a 400MHz chip for 30ct more.
The variant from MindMotion claims that their variant is a 5V part, and this can be very handy for some applications.
APM has apparently added some floating point instructions.
In itself I quite like the idea of an “universal” microcontroller with the same peripherals and software compatibility for the “base” peripherals, and then add some competition in the improvement or addition of extra features.
(I’ve used the AVR parts in the past, and quite dislike it because they’ can’t even put 2 of the same timers in the same chip, and across variants of the ATMega series it’s even much worse. When I started with ARM, there is a description of a timer in the datasheet, and a single line that says: Oh, there are 5 of these timers in this chip)
Could you please give the 400Mhz part number?
For the APM part, do I need to use a GCC flag to enable the hardware floating point?
Dammit! I was perfectly happy until I read that and found out that the last batch of bluepills I bought and hadn’t started using yet all had a ch32/cs32 chip with an STM marking on the packaging. At least they seem to work fine after adding a new OpenOCD config file. I tried a quick blink and QMK firmware and all is good. Also they have 128K of flash (tried writing reading the full range with AAs or 55s and found no errors). If at least the chip was clearly labeled as a clone it wouldn’t be so bad.
Oh what a world we live in when one cannot buy boards from china under the price of the chip they support without getting fakes.
Price is what it all comes down to – while there are a bunch of people just looking to pay the lowest price we continue to support the dubious market.
This stuff only happens because there is a consumer that demands it and Im sure most of us are guilty of it…
Relabelled chips are a problem indeed. Some sellers offer the choice between STM32 and CS32 these days. That is something I like to see.
But you can not rule out fakes just by paying more.
ended up using some in a project once. They were ok, but you couldnt run the code in debug mode, you could only flash a hex onto them.
Which brand of clone?
ST has currently a portfolio of over 1000 microcntrollers, yet only one model has been cloned ,and not just once ,but several times in a different fashion. From the decapping pic’s it can be seen that there is not just one clone being copied over and over again.
My thought is that there has been a leak somewhere at ST’s subcontractors. Not a leak of the design, but the test vectors.
Having the correct test vectors ,makes it so many times easier to clone a digital design. Besides that ,it is extremely difficult to prove such a fact, let alone in court.
The purpose of these clones can only be guessed ,but it is certaily not appropriate to develop any product based upon any of these clones. My thought is they end up in all kind of electric motors , for fans,electric bikes ,hoverboards ,drones and the like. Develop using the original STM , than drop in a clone and see if it works. That’s how the chinese shave off cents.
For us in the western world ,these parts are a no-go ,neither for development ,nor for mass production.
Whoah. Stop. Reverse. No.
A ‘Clone’ is not a fake.
knockoff != counterfeit
A counterfeit is trying to BE a thing. It is Fraud.
A knockoff, ‘borrows’ the look or functionality of something without trying to ACTUALLY be the thing.
A clone wants to be a thing. But does not SAY it is that thing.
Let’s compare:
— Real Levi’s Jeans.
— Counterfeit jeans. Labels say Levi’s. Pattern is close to the real ones. Fabric is lower quality. Rivets in most of the same places. Fraudulent. Fake.
— Knockoff jeans. Labels say Lovl’s. Pattern is close to the real ones, but with as many corners as possible cut. No rivets. Fabric is the cheapest they can get and still appear similar. Single stitching.
— Cloned jeans. Labels say Daring Denim. Pattern is similar and changes don’t appear to be exclusively for cost cutting. Fabric is different, but of reasonable quality, maybe even better for some things. Rivets in similar places, but are steel instead of copper.
Counterfeits are illegal.
Knockoffs and Clones are not.
But
A high quality Counterfeit or Clone MIGHT be as good, or better than a real one.
A knockoff will always be worse than a real one. The goal was never to BE the real one. Just appear similar, but at 1/10th the price.
Darling Denim is better the current Levi’s… I rate them higher then irregular Silvertabs.
For flashing a CH32F103 with platformio:
https://www.amazon.fr/AZDelivery-Carte-d%C3%A9veloppement-STM32-Parent/dp/B07CRHX5F5?th=1
“You will need an st-link v2 programmer to program this board and even then you will have problems, as the CH32 does not behave exactly the same as the STM32 with regards to programming. After several hours, I managed to program the board using platformio. For anyone who’s made the same mistake that I did and bought one of these, the platformio.cfg file that I used is below:
[env:bluepill_f103c8]
platform = ststm32
board = bluepill_f103c8
board_build.mcu = STM32F103C6T6
upload_flags = -c set CPUTAPID 0x2ba01477
framework = arduino
With these settings I was able to flash a modified blink program to the with an st-link v2 programmer and both boot jumpers set to “0”.”
Like those botched discount plastic surgeries.
We have easily purchased 100k of these ICs and never had an issue. Authorized distributors are a thing.
Where can I order a WCH32F103? It seems to have a RISC-V core…
That is the CH32V103. I haven’t found a place to order them yet.
I’ve written some code to tell the STM32F103, GD32F103, CS32F103 and HK32F103 apart. I would like to see if I can add detection for this chip as well. I would like to get my hands on some of these chips for analysis, but I can’t seem to find any on lcsc, aliexpress or ebay (yet).
I’ve made a bootable binary that reads the chip ID code and also tests the Flash to see if your chip has a hidden extra 64KB flash (for a total 128KB flash) so you can run firmware like the Black Magic Probe etc.
https://mecrisp-stellaris-folkdoc.sourceforge.io/stm32f1xx-diagnostics.html
I have bought from Amazon seller 10 STM32F103 bluepill
They have arrived in 2 bags of 5. 5 were CKS32F, the other 5 – CH32F
I load Arduino bootloader to Bluepills via STLink and then program from Arduino IDE via USB
SKC32F works great.
CH32F are really low quality. One out of 5 had USB port not communicating. And re-programming is terribly slow – both via STLink and via USB.
Terribly. More than 10x slower. They are kind of usable. But using them is such a pain that I threw them into a trash bin.
Bottom line: do not buy CH32F.
I had same experience with my 214pcs. USB device Not recognized. I given up and turn to STMF103C6T6 on aliexpress. I had tested on arduinon IDE. My sketch runs like a charm.
We buy about 10k of them annually, and we have always problems with counterfeit chips. At least I can say we do everything to make sure only genuine STM32F103C8T6 ship out to our customers.
Recently I received several warnings from suppliers in China that there are no genuine chips anywhere available anymore. I checked with Chinese distributors and also Octopart. Nothing. Not a single chip anywhere.
I just received samples from 3 suppliers on Alibaba, and 2 of them appear to be legit. But the price is double of what is was 6 weeks ago.
We still have some in stock and I hope to get more by end of March.
https://www.universal-solder.ca/product-category/arduino-stm-esp8266-raspberry-beaglebone-boards/stm32-stm8-arduino
You are right. Genuine stm32f103 chips become super expensive nowadays in China market, Since ST announced the prince increase http://www.semimedia.cc/?p=8890 some chip prices rose 5 times comparing to the price last year.
I buy it around 2$, and it works as USB HID. Dunno if it’s fake or not
Chips shortage is anywhere, many manufactures in China mainland are struggling to migrate to domestic replacements. It’s a hard time for most of them. Won’t be a surprise if you see more clones in the market.
Aliexpress is full of ads with Blue Pills carrying STM32 chips. At the time of writing, there is not a single piece on Aliexpress or Banggood or whatever Chinese outlet with a genuine chip. We were hunting for them still in March and early April, before we finally gave up. Every sample we received with STM32 chips turned out to be GD32. Surprising. I expected to see a lot more CKS chips. Blue Pills with CS32 and GD32 are of course available, and they work just fine for many applications.
We also carry Black Pills with STM32F411 MCU but there is no new supply available anymore. We have maybe 200 still in stock, and then that’s it.
http://www.universal-solder.com
And, CortexM4 clone is coming…
https://www.stcmcudata.com/STC8F-DATASHEET/STC32M4.PDF (only Chinese version)
Skimming through that datasheet, looking at the pinouts, it doesn’t look pinout compatible with STM32.
These days I see STM32F103C6T6 Blue Pills on AliExpress.
I have 214pcs of Blue pill with label or relabel STM32F103C8T6 and black jumper on it. The only problem is USB device not recognized when the MCU runs as a USB device. and ID Device is 0x2ba01477. I don’t know exactly what the spec of my blue pill. I think I gonna turn to STM32F103C6T6 on aliexpress. I had tested using arduino and my sketch running like a charm.
ATAFOK we buy 300 peaces of stm32F103C6t8 all counterfeited, works in basics rule but dont work a lots of rules like Sleep.
I’ve got a lot of stm32f103 blue pill and stm32f411 black pill boards, so I wanted to buy a small plastic box for these boards. However, searching for “blue pill box” did not show electronics enclosures. I then tried searching “black pill box” only to find the “Rhino Black Male Enhancement Pill”.
Anyone can help me out?
Do anyone knows why does the CH32F103 has two usb micro ports?
CH32F103 is a chip. Chips don’t have micro USB ports.
If you don’t buy from China, how can you get Chinese Clones? The price tag already told you that they are clones and you still buy it, what does that say? “I bought a lot of them because they are cheap and works, and for the worst part, it’s better! That’s why I buy them so that I can hate them!”. Chinese clones are licensed by ARM. It takes a lot to manufacture a small chip like STM32, no body can just clone it without millions invested. All these clones helped millions of people like hobbist and small tech companies and students to become great ones. And because they used clones when they grow, their choice of selection are always STM32 when they become mature and professional, and that, makes ST more profit than spending billions on marketing. I highly doubt a mature company would choose aliexpress instead of Digikey to buy clones for their production.
Great comment. Many people make me believe they truly think that every car in the world is a clone of the Benz Patent-Motorwagen and every phone with a touch screen is an iPhone clone. Too many people misuse the words clone, knockoff and fake, to declassify something that is legit, sometimes even better than the big brand model, but is made in China, Malaysia or Taiwan.
You would be surprised that STM32FEBKC6 is a legitimate ST part sold for Chinese market for e-bike industries. See here for its datasheet: https://opensourceebikefirmware.bitbucket.io/development/EmbeddedFiles/75-STM32FEBKC6T6.pdf
I would be surprised if that was a legitimate ST datasheet.
well this explains a lot… I just assumed my clones were made from badly scanned authentic chips, I didn’t even consider that they might be a completely different chip.
Most of the clones are even better than their as “authentic” recognized siblings. It is only stupid to print “STM” on a chip that’s actually something even better, but less famous.