I recalled a few years ago there were shockingly inexpensive MCUs at LCSC and similar far east vendors, but they were never heard before names, so I just checked again out of curiosity and here's a $0.05 one by Cypress.
They are huge step ahead: the upcoming CH32H417 has pretty much all PHYs integrated (!). For 10/100M Ethernet, USB-C 5GBbps and USB HS 480Mbps. That dramatically reduces the components needed to get that stuff running.
I also build a small robot with the ultra cheap CH32V003. That's a full fledged 48MHz microcontroller with 16kb flash and 2kb SRAM. Fun little thing.
If you are used to the ST HAL you will be able to work with them within 10 minutes. Their API style is similar.
That's out of stock, though. Here are my other shockingly inexpensive MCUs at LCSC that were in stock at the time:
links from 02025-03-16:
https://www.lcsc.com/product-detail/Microcontrollers-MCU-MPU... #LCSC #pricing for 16-pin #CH32V003 #microcontrollers #electronics #hardware: 14.21¢ in quantity 500. Not the cheapest, but it’s a RISC-V with IIRC an on-board op-amp, though the linked datasheet only covers the CPU really.
https://www.lcsc.com/product-detail/Microcontrollers-MCU-MPU... new cheapest #microcontrollers: Cypress CY8C4045FNI-DS400T, 1.5¢ in quantity 1000. It purports to be a 48MHz Cortex-M0 ARM with 32KiB of Flash and 4KiB of SRAM in a 1.6mm x 2mm package, 0.31-0.37 mm thick, with nine GPIO pins. I think that’s 4000 Dhrystone MIPS per dollar. #electronics #hardware #pricing
As of today (02025-10-15), the CH32V003A4M6, the PY32F002BD15S6TU, the PFS122, and the PMC251-S14 are in stock. The CY8C4045FNI-DS400T, the CY8C4013SXI-400, and the NY8A051H (not an 8051 despite the name) are out of stock. Today what I see are:
https://www.lcsc.com/product-detail/C49173938.html Currently cheapest #microcontrollers #pricing on LCSC: PMS150G-U06 (a SOT-23-6) for 2.02¢ in quantity 3000. #Padauk has broken the 3¢ barrier! One-time programmable. #electronics #hardware
https://www.lcsc.com/product-detail/C2857167.html Almost cheapest #microcontrollers #pricing on LCSC: NY8A054ES8, a SOP-8, for 3.91¢ in quantity 1000. This is from JSMSEMI (Shenzhen JSMicro Semiconductor Co., Ltd.) 1T 8-bit 8MHz chip, 128 bytes RAM, 2k × 14-bit EPROM program memory (but no quartz window, so one-time programmable). 8-level hardware stack. The datasheet is full of descriptions of peripheral registers and pin circuit schematics, and then the 55-instruction instruction set is documented on pp. 76–91.
While I mostly agree, I have some small quibbles which I think will present a more complete picture.
I've had a good developer experience with 74LS00-family SSI chips (like the quad-NAND-gate 74LS00 and the hex-inverter 74LS04), so your mileage may vary.
Just to clarify, the Padauk and Nyquest chips I linked above are one-time programmable (PROM), not mask ROM, except the PFS122 (3.53¢), which is reprogrammable Flash. (It's advisable to debug your code with a Flash chip or an ICE before you start consuming PROM chips, unless you really like to desolder.) Padauk doesn't seem to make mask-ROM chips at all, and I haven't seen any from Nyquest.
I'm not sure what you mean by "highly specialized". They're tiny, slow 8-bit microcontrollers, so you will certainly be disappointed if you go in hoping for STM32-like capabilities. But they're programmable, and their peripherals don't include things like LiDAR pulse timing circuits or AES encryption hardware or anything like that. It's just very general-purpose stuff like watchdog timers and PWM generators.