For these devices the microcontroller needs to be super cheap. Microcontrollers like the Puya PY32 Series (e.g., PY32C642, PY32F002/F030) can cost in the $0.02 - $0.05 range for the kind of many-million volumes applicable for disposable vapes. These are 32-bit ARM Cortex M0 MCUs, running at a 24 MHz clock or similar, some with 24 KB of ROM and maybe 3 KB of RAM!
To put into context: this is 3x the ROM/RAM of the ZX81 home computer of the early 1980s. The ARM M0 processor does full 32-bit multiplication in hardware, versus the Z80 that doesn't even offer an 8-bit multiply instruction. If we look at some BASIC code doing soft-float computation, as was most common at the time, the execution speed is about 3 orders of magnitude faster, while the cost of the processor is 2 - 3 orders of magnitudes less. What an amazing time we live in!
The idea that people are smoking arm chips makes me laugh.
It also stood out to me how little stuff is in there - there's the uC itself, 3 transistors for heating the flavor canisters, an op-amp for the microphones, but other than that I don't really see anything - no external oscillator, no vrm (though a charger/BMS circuit must be in there somewhere).
How close are we to smart dust I wonder? How small can we make wireless communications?
> These are 32-bit ARM Cortex M0 MCUs, running at a 24 MHz clock or similar, some with 24 KB of ROM and maybe 3 KB of RAM!
So, probably enough to land on the moon. And cheap enough to justify a dozen backups.
> [...] while the cost of the processor is 2 - 3 orders of magnitudes less.
Is that inflation adjusted? If not, the real cost difference is even starker.
What a world we live in; we have gotten to a point where computers are so small and cheap that they can literally be “disposable”.
It’s beautiful, I love it.
I've bought hundreds of Puya's for my lab stock on LCSC. Neat little things!
Which is why when folks nowadays say "you cannot use XYZ for embedded", given what most embedded systems look like, and what many of us used to code on 8 and 16 bit home computers, I can only assert they have no idea how powerful modern embedded systems have become.
Now that it is a pity that when people talk about saving the planet everyone keeps rushing to dispoable electronics, what serves me to go by bycicle to work, be vegetarian, recicle my garbage, if everyone is dumping tablets, phones and magnificient thin laptops into the ground, and vapes of course.