A 4$, 4ICs, Z80 homemade computer on breadboard: Z80-MBC (Mobile Breadbord Computer)

Anything not related to STM32
User avatar
ahull
Posts: 1528
Joined: Mon Apr 27, 2015 11:04 pm
Location: Sunny Scotland
Contact:

Re: A 4$, 4ICs, Z80 homemade computer on breadboard: Z80-MBC (Mobile Breadbord Computer)

Post by ahull » Sun Dec 18, 2016 12:33 pm

RogerClark wrote:I recall the Sinclair computers (Z80) vs the BBC (6502), but I don't recall the BBC being any faster - but perhaps it was.
It is a moot point given that we now have multi GHz machines, but the 6502 instruction set gave it a slight edge. A 4MHz Z80 was argued to be roughly equivalent to a 1MHz 6502.. for some tasks... Of course like the vi vs emacs debate, this one has the risk of ending in a flame war. :D

I used both, and even machines with multiple Z80s, I even wrote a bit of machine code for both back in the day and the simpler instruction set of the 6502 meant less brain ache when writing code. The 6502 could also be argued to be the grand daddy of the ARM family. The 6800, 6809 etc are pretty close cousins to the 6502 with similar registers and similar instruction sets (but not op-code compatible as they were from different competing companies).

The z80 turns up in all sorts of interesting places... a while back I dumped the firmware of a hard disk and it appeared to be running some weird flavour of MP/M on an embedded Z80 based SOC.

@Just4Fun I see porting CP/M is on your to-do list for this 4$ marvel. Time to dust off the old VT220 and head back to 1983 :D
- Andy Hull -

User avatar
ahull
Posts: 1528
Joined: Mon Apr 27, 2015 11:04 pm
Location: Sunny Scotland
Contact:

Re: A 4$, 4ICs, Z80 homemade computer on breadboard: Z80-MBC (Mobile Breadbord Computer)

Post by ahull » Sun Dec 18, 2016 3:12 pm

Just4Fun wrote:Hi all,
I've just finished my last crazy useless project :lol: (those I like more...):

More info here:

https://hackaday.io/project/19000-a-4-4 ... breadboard

Cheers.
Liked and followed on HAD :D I may have a crack at running that Z80 Basic on a STM32F103->Z80 emulator if I get the time.
- Andy Hull -

User avatar
Just4Fun
Posts: 51
Joined: Tue Jan 05, 2016 9:48 pm
Contact:

Re: A 4$, 4ICs, Z80 homemade computer on breadboard: Z80-MBC (Mobile Breadbord Computer)

Post by Just4Fun » Sun Dec 18, 2016 5:03 pm

Pito wrote:I wonder why not use it at 20MHz and Z80 at 10MHz. A worth of a 20MHz canned oscillator (or a crystal) to add.
Thanks Pito!
I've done some tests and it seems that the "A" AVR variant doesn't like quartz on breadboard very much, so I decided for the internal oscillator. An "active" oscillator would be away from the "4$, 4ICs" rule... :D
ahull wrote: Liked and followed on HAD :D I may have a crack at running that Z80 Basic on a STM32F103->Z80 emulator if I get the time.
Thanks ahull! Yes the Z80 emulator on the STM32F103 is another interesting way... :mrgreen:

User avatar
Pito
Posts: 1237
Joined: Sat Mar 26, 2016 3:26 pm
Location: Rapa Nui

Re: A 4$, 4ICs, Z80 homemade computer on breadboard: Z80-MBC (Mobile Breadbord Computer)

Post by Pito » Sun Dec 18, 2016 5:10 pm

would be away from the "4$, 4ICs" rule...
.. you cannot do it in $4.. the solderless breadboard you are using costs more :) ..so adding 20cents would not hurt :)
Great work, I like it ;)

PS: what I am missing today is a good Basic interpreter for the MCUs. In '83 I got the PC1251 pocket computer/calculator (Z80 based afaik) and since then I cannot find a similar Basic like the one was/is (but written in C) :evil:
Pukao Hats Cleaning Services Ltd.

User avatar
zoomx
Posts: 445
Joined: Mon Apr 27, 2015 2:28 pm
Location: Mt.Etna, Italy

Re: A 4$, 4ICs, Z80 homemade computer on breadboard: Z80-MBC (Mobile Breadbord Computer)

Post by zoomx » Mon Dec 19, 2016 8:27 am

RogerClark wrote: I recall the Sinclair computers (Z80) vs the BBC (6502), but I don't recall the BBC being any faster - but perhaps it was.
I recall Spectrum vs C64. I had a C64 and somewhere I still have a C128.

User avatar
RogerClark
Posts: 6096
Joined: Mon Apr 27, 2015 10:36 am
Location: Melbourne, Australia
Contact:

Re: A 4$, 4ICs, Z80 homemade computer on breadboard: Z80-MBC (Mobile Breadbord Computer)

Post by RogerClark » Mon Dec 19, 2016 8:38 pm

There were 128k Spectrums as well I think, but the RAM had to be paged in and out, as its a 8 bit cpu with 16bit addressing, so can only addresss 64k of RAM and ROM.

I dont know how that was handled by the 6502, but it was probably paged as well.

User avatar
martinayotte
Posts: 1177
Joined: Mon Apr 27, 2015 1:45 pm

Re: A 4$, 4ICs, Z80 homemade computer on breadboard: Z80-MBC (Mobile Breadbord Computer)

Post by martinayotte » Mon Dec 19, 2016 9:10 pm

That's remind me that Apple-III (3 not 2) had 128K also.
Yes, it was also by doing paging, usually 48K base RAM, and the ROM were switched with several banks of 16K of the remaining RAM.

User avatar
Pito
Posts: 1237
Joined: Sat Mar 26, 2016 3:26 pm
Location: Rapa Nui

Re: A 4$, 4ICs, Z80 homemade computer on breadboard: Z80-MBC (Mobile Breadbord Computer)

Post by Pito » Mon Dec 19, 2016 9:42 pm

FYI - an 8051 - for example the 33MHz single clock 40pin DIL DS89c450 (or any others probably) - can use up to 16MB of rom/ram via banking the 64k (256x64kB, banking via an 8bit port). Supported automatically by C in Keil and IAR. And it works. The only limitation is an array or a function has to be < 64kB (such it fits inside a bank).
Not sure how the 6502 or the Z80 is supported in C with such tricks today :)
I got ZX81, ZX Spectrum, Atari 520 but no C was available for it at that time (80ties) as far as I can remember. It could be done in asm too, but lot of effort required :roll:
Pukao Hats Cleaning Services Ltd.

User avatar
zoomx
Posts: 445
Joined: Mon Apr 27, 2015 2:28 pm
Location: Mt.Etna, Italy

Re: A 4$, 4ICs, Z80 homemade computer on breadboard: Z80-MBC (Mobile Breadbord Computer)

Post by zoomx » Tue Dec 20, 2016 9:47 am

Pito wrote: I got ZX81, ZX Spectrum, Atari 520 but no C was available for it at that time (80ties) as far as I can remember. It could be done in asm too, but lot of effort required :roll:
No C only asm, but it was not very difficult for 6502 family since there are few instructions. Today I don't remember none of them.
The official programming C64 big manual talk about asm only and all asm routines.
I remember basic, forth, pascal and maybe some other strange languages.
It was possible to mix basic and asm using peek, poke and sys that was like a jump to an asm routine.

User avatar
RogerClark
Posts: 6096
Joined: Mon Apr 27, 2015 10:36 am
Location: Melbourne, Australia
Contact:

Re: A 4$, 4ICs, Z80 homemade computer on breadboard: Z80-MBC (Mobile Breadbord Computer)

Post by RogerClark » Wed Dec 21, 2016 10:04 am

From what I recall, the Sinclair Z80 based machines, could store assembler in a REM statement in the first line of the BASIC, as it was always in the same position in RAM.

I recall having to enter assembler op code numbers directly in to the keyboard, as I don't recall there even being something as complex as an assembler (but they may have been some available).

I still remember some of the decimal op code numbers for things like call JMP which was 195 decimal and I recall to load one of the 16 bit registers was op code 33 decimal for load HL I think

Post Reply

Who is online

Users browsing this forum: No registered users and 1 guest