The featured image of this blog post is by PublicDomainPictures from Pixabay.
Recently, I bought some ATmega328P-PU (DIP packages) chips in China and was concerned that they might be counterfeit, given that three years ago some ATmega328P clones, which did not support nano-power, had been found on Pro Mini boards. The first check looked as if they were fake chips, but apparently, they are the real thing.
Since my stock of ATmega328P DIP chips had been depleted, I decided to buy a few new ones. Looking around, I noticed that the prices have gone up by a factor of three, though. So, why not order at AliExpress, where you could get them for the pre-Covid price?
After placing the order, I got some second thoughts and looked on the web for reports on counterfeit ATmega328 chips. And indeed, Kevin Darrah had found some very strange counterfeit chips on Pro Mini boards. They act as if they are the real ones, but when it comes to deep-sleep current consumption, they consume around 100 µA instead of 100 nA. In addition, high-voltage programming was not working. By taking the chip apart and analyzing the die, it became apparent that the die was not manufactured by Atmel. As a fast check, Kevin proposed to look at the ROM area after the chip signature and provided a sketch for testing that. It was reported that the fake chips usually had an output as the one below, with a lot of FFs:
boot sig dump 1E B8 95 FF F FF FF 26 FF FF FF FF FF FF 5D FF FF FF FF 0 FF FF FF FF FF FF FF FF FF FF FF FF
When you run the sketch on real ATmegas, there are only very few FFs in this area. So, the first thing I did when the chips arrived was to run this sketch on them. And I got very similar results to the one above:
boot sig dump 1E D4 95 FF F FF FF 26 FF FF FF FF FF FF 58 FF DF FF DF FF FF FF FF FF FF FF FF FF FF FF FF FF
Well, testing the chips with deep-sleep mode, programming them in high-voltage mode, and even trying debugWire on them, did not show any deviation from the expected behavior. So, I guess, looking into the ROM area for a lot of FFs is not enough to decide whether it is a fake chip or not. In any case, I am relieved that the chips I bought are most probably the real thing and that I can use them in low-power projects.
Leave a Reply