I built a prototype for a z80 computer that uses an arduino for communication and bootstrapping. I can assemble a z80 source program with brass, and send it to the arduino with a small python program. The arduino is running a firmware program that waits for a program to be sent over serial, which it loads into the ram chip for the z80 to execute. The z80 communicates with the arduino via IO requests. The arduino<-->z80 API only contains 3 commands, but these can be used for the z80 to send messages to the PC via serial.

This is a small test program to send "test1" and "12345" to the PC via serial:

Code:

#define output(x, y) ld a,y \ out (x),a
#define command(x) output(PORT_COMMAND, x)
 output(PORT_ADD_LOW, writeTo & FFh)
 output(PORT_ADD_HIGH, writeTo >> 8) ;set data act-on address to writeTo
 ld hl,string1
 ld de,writeTo
 ld bc,6
 ldir ;copy string1 to writeTo
 command(COMMAND_WRITE_SERIEL) ;tell arduino to send data from act-on address to PC
 ;stuff
 ld hl,string2
 ld de,writeTo
 ld bc,6
 ldir ;copy string2 to writeTo
 command(COMMAND_WRITE_SERIEL) ;tell arduino to send data from act-on address to PC
 jr $ ;do nothing
string1:
 .db "test1",0
string2:
 .db "12345",0
writeTo:


Picture:


Todo:

    Use external clock. (Currently arduino is generating a clock signal)
    Upgrade to 128kb ram chip. (Currently i am using a 32kb one)
    Make arduino use pin registers for control signal IO. (minor)
    Make a paging circuit for said ram chip.
    Add an LCD
    Write an OS(?)
    Add an SD card(?)
    Make PCB (?)
[/list]
What LCD do you guys think I should use? And what color modes should be supported? Remember that the drawing is done by a 10mhz z80 and the data will be sent to the LCD by an 16mhz arduino that will also be managing a few other stuff in the background.

No matter what resolution, I plan on having a 16 background/foreground color text mode.

Also, why is it hard to find 16/20mhz z80s? They seem to all be out of stock <_<
c4ooo wrote:
Also, why is it hard to find 16/20mhz z80s? They seem to all be out of stock <_<
Probably because there's basically no demand for the DIP ones. I see digikey stock 20 MHz ones in LQFP and PLCC packages but not DIP (minimum quantity 130).
I believe I have a handful of 20MHz ones somewhere at home, but they may have been misplaced when i moved house ...

I should have said, happy to post you one should I find it!
c4ooo wrote:
What LCD do you guys think I should use? And what color modes should be supported? Remember that the drawing is done by a 10mhz z80 and the data will be sent to the LCD by an 16mhz arduino that will also be managing a few other stuff in the background.


Probably a Hitachi HD44780 20×4 LCD. The command set is standard. I even simulated it a long time ago.
Perhaps this shop could help ..?

https://www.digikey.com/products/en/integrated-circuits-ics/embedded-microprocessors/694?FV=ffe83c93%2Cffe002b6&mnonly=0&ColumnSort=0&page=1&stock=0&pbfree=0&rohs=0&cad=0&datasheet=0&nstock=0&photo=0&nonrohs=0&newproducts=0&quantity=&ptm=0&fid=0&pageSize=25
grosged wrote:

Tari wrote:
I see digikey stock 20 MHz ones in LQFP and PLCC packages but not DIP (minimum quantity 130).

Rolling Eyes
Ah, ebay:

https://www.ebay.com/i/131813909148?chn=ps
Tari wrote:

Yep that's the problem. I don't think i will ever need to have 130 z80s Razz


tr1p1ea wrote:
I believe I have a handful of 20MHz ones somewhere at home, but they may have been misplaced when i moved house ...

I should have said, happy to post you one should I find it!

MateoConLechuga wrote:

Thanks guys. I just hope that a year down the line i will still be able to purchase 10-ish 20mhz chips, as thats probably how many units i will sell :V

oldmud0 wrote:
c4ooo wrote:
What LCD do you guys think I should use? And what color modes should be supported? Remember that the drawing is done by a 10mhz z80 and the data will be sent to the LCD by an 16mhz arduino that will also be managing a few other stuff in the background.


Probably a Hitachi HD44780 20×4 LCD. The command set is standard. I even simulated it a long time ago.

Well, i was anticipating something a bit bigger, and maybe with color. If i do decide to go with a monochrome LCD though, i will probably make text drawing z80 side.
I would probably go for a graphical LCD to be honest, though there are issues with fullscreen updates at high speeds if you have too large of a resolution.
tr1p1ea wrote:
I would probably go for a graphical LCD to be honest, though there are issues with fullscreen updates at high speeds if you have too large of a resolution.

Yea. Unfortunately it to sure how many pixels per second the arduino can send over SPI. (Also don't forget that the pixels data has to be read frame ram and the actual color looked up on a palate >_> )
  
Register to Join the Conversation
Have your own thoughts to add to this or any other topic? Want to ask a question, offer a suggestion, share your own programs and projects, upload a file to the file archives, get help with calculator and computer programming, or simply chat with like-minded coders and tech and calculator enthusiasts via the site-wide AJAX SAX widget? Registration for a free Cemetech account only takes a minute.

» Go to Registration page
Page 1 of 1
» All times are UTC - 5 Hours
 
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum

 

Advertisement