Hello
I have been working on this computer project for quite a while. I had not originally intended it as an entry to the Hackaday prize. My original intent was to finish the project, and document the schematics and code online. I saw another couple computer entries entered into the contest, so I figured, if I was going to give away the design anyway, I might as well post it all here, and get a ~ 1/300 chance of blasting off into space.
I'm am going to make a series of posts in the build log, showing from the beginning of the project, what has happened. I've collected notes and pictures along the way, and I will be presenting these in a time-compressed manner.
Why another computer?
I have been playing around with computers since a young kid. One of the first computers I played with was the Commodore Vic-20. It was very limited in its abilities, but it was a start. I eventually got into PCs, and now I'm a software enginner. I've also been very interested in electronics. For a long time, I've been wanting to build my own computer. In college we simulated computers in FPGAs; that's probably the closest to realizing my own computer design in hardware.
Why 8-bit, why AVR?
I wanted to build it myself. 32-bit and 64-bit devices tend to be surface mount with many pins. I also wanted a device that has a lot of support, was reasonably performant, and with fairly modern components. I wanted to use all through-hole parts, making it more likely that others can learn from, copy and modify the design. Large parts of this project can be built, and run, on a breadboard without even soldering anything. Also, I am considering that someday this could be made as a kit, similar to the Uzebox of Maximite kits available online.
When it comes to microcontrollers, there's 2 big camps: the AVR and the PIC. Both are awesome, and come with flash and itty bitty ram, letting you start off right away. Why did I choose AVR? For two reasons. 1) an AVR can execute most instructions single cycle; PIC cannot, and 2)Arduino is AVR-based, and there is a wealth of information about Arduino. If you can connect an Arduino to a whatevery-do, you can connect an AVR to it as well.
Also, before someone mentions it, I do know about the Propeller. It is a 32-bit 8-core DIP chip, has comfortable 32k of RAM, and can generate VGA signals. I did not want to use this, because simply too much of my project is already done for me.
Why VGA and PS/2?
Why not VGA? Most homebrew computers offer either composite video output, OR a simple terminal. I don't want a TV on my desk too! With VGA output, it can use the same monitor my desktop computer uses. With the right KVM, your keyboard too!
Connectivity
Well, this is a connected device competition! There is a lot of inter-device communication going on in this project:
internal:
- bit-bang SRAM interface: don't take RAM for granted. address, page latch, read and write enable, are all controlled by software
external:
- RS-232: The classic interface.
- VGA: mixed analog/digital output with extremely precise timing required
- PS/2 keyboard protocol: Unusual in both software and hardware. A PS/2 keyboard communicates over a clocked, open collector bus, and the clock is generated by the keyboard.
- SD Card interface: SPI bus with level conversion required
- Planned: Ethernet. This is a stretch goal for the project.
Anyone who builds and programs a Cat-644 is going to learn a lot!
Why SD cards?
SD Cards can be put in an SPI mode. Conveniently, AVR microcontrollers have hardware SPI. In SPI mode, SD cards have no minimum data transfer speed, and a maximum speed of 20 or 25 megabits. That is perfect for a 20 MHz system, which may have a very frazzled CPU that needs to slow down. Data is also read/written in blocks of 512 bytes, which very easily fits in the 4k internal RAM of the atmega. I considered compact flash/IDE, but that takes too many I/O lines. USB mass-storage and SATA are too complex and fast for the poor little AVR. There's also SPI flash chips, with which I could build cartridges, but that's pretty much what the SD card already is!
Discussions
Become a Hackaday.io Member
Create an account to leave a comment. Already have an account? Log In.