3 ms·
You can buy brand new 20MHz Z80s, but with the multiple clock cycles per instruction they'll still be slower overall than a 20MHz AVR. The later chips in the 8
by codebje 5y ago
You can buy brand new 20MHz Z80s, but with the multiple clock cycles per instruction they'll still be slower overall than a 20MHz AVR.
The later chips in the 8-bit family are much more power efficient; I built an eZ80 board whose total power budget is 500mA including SD card and Ethernet module. It runs at 50MHz, but performance isn't really the reason we muck around with 8-bit CPUs, right? :)
- kragen 5y agoThat's pretty neat! How much does your eZ80 board use when it's not accessing the SD card? Performance can substantially ease the difficulties involved with mucking around with 8-bit CPUs. As I explained in https://news.ycombinator.com/item?id=30017810 https://news.ycombinator.com/item?id=30017810, my point of comparison is the Ambiq Apollo3, which purportedly gets about 100 Z80s of performance on about half a milliwatt.
- codebje 5y agoThe board runs at 3v3, the CPU consumes around 140mA, with SD and Ethernet off its just memories and LEDs adding to that, so typically not much higher than 150mA sustained. It's likely a bit less than that over USB Vbus but it's just running a linear regulator down to 3v3 so mostly the difference just becomes heat.
- kragen 5y agoThanks! 140mA is pretty high; it's literally 1% of the battery life (100× the power draw) of a more modern 8-bit processor like a 20-year-old 20MHz AVR, which is a bit faster than a 50MHz Z80. And as I mentioned below the Ambiq processors are orders of magnitude faster at the same power draw, and can scale down to very low power draws. They can self-host compilers but probably not logic synthesis.
- codebje 5y agoThe eZ80 is a better Z80, but it's still a Z80. It's worse in pretty much every way to a modern MPU. The STM32 line is my preference for performant parts - there's an STM32L0 on the board doing USB to serial. I could likely emulate the eZ80 on that faster than the real thing runs, but I couldn't build an 8-bit bus computer with it.
- kragen 5y agoI'm pretty sure the S1 MP3 and the TI-83 CPU don't use 100 mA though. I'd sure like to know if someone is making a low-power Z80 I can actually buy. I mean, it's a little goofy, because a lot of the Z80 design was a response to design constraints that no longer exist, right? You don't need to fit your CPU in 40 pins or 10000 transistors anymore. And even the MuP21 probably would have been a better design under those constraints.
- codebje 5y agoThe TI-84 Plus CE, at least, uses the same CPU as my board (plus or minus revisions) - but it clocks it _much_ lower, at 15MHz. The eZ80 uses around 30mA at that speed; it also has a sleep mode using under 3µA that I would expect a battery powered device to make heavy use of. The Z84C00 at 6Mhz will also "only" use around 30mA, down to 10µA in standby. At 15MHz the Z84C00 uses something more like 80mA, though, so the "turbo" mode in that calculator line probably chews through batteries. I expect TI still uses the eZ80 CPU for the same reason other companies still use Z80-based processors - backwards compatibility. The Z80's got a very long life in industrial control systems, where you want to avoid rewriting the code if you reasonably can. The eZ80 is about as modernised as you can take the Z80 core, but as you say a lot of the Z80 design is due to the constraints of the era. It was also designed to be code compatible with the Intel 8080, and probably would have just quietly fizzled on launch if it didn't have that.
- anthk 5y agoAt 50 mhz, Z-Machine v5 games get usable enough.