Close

Serial Input

A project log for Z80 Computer

Yet another Z80 computer.

james-otsJames Ots 05/05/2017 at 23:150 Comments

Just a small addition today. I tried to work out what the smallest testable thing I could do with the serial port was. (The serial port is on an FT245R breakout board, but I always erroneously refer to it as the FTDI). So I wired the FTDI into the CPLD, and then added a bit to the CPLD schematic so that whenever the CPU tries to read it would ask the FT245R for a byte, and if the serial buffer is empty it sets the WAIT line to low until data is available. I then wired up the green LED to the WAIT line, and connected the red and yellow LEDs to A0 and A1.

Now when the system starts up the green LED immediately goes off, as there's no data waiting. Then every time I send a byte down the serial line, the red and yellow LEDs switch on and off, counting from 0 to 3 in binary, thus proving that it is actually reading data from the serial port.

(Notes to self: I should put the Linux FTDI programme on a public git repo, and I should add screenshots of my schematics. And then switch to using VHDL instead of schematics, and also put it in the repo. And add the KiCAD schematics to the repo.)

Discussions