Note that any description here is subject to change, and suggestions for improvements are welcome
Legion is a designed from scratch, home built computer using discrete TTL Logic. It's a personal project (meaning: no deadlines, no promises) to learn about computer design. The end goal is to produce a working 'home computer' with a CPU, video output, keyboard and joystick input.
These are the key goals of the project
- Entirely new design - Legion is a ground up new CPU and computer.
- No complex chips - Legion uses only standard 74-series logic that is currently in production. No obsolete parts, Ebay finds or programmable logic.
- Video output - a useable (at least 256 pixels by 192) video output compatible with any monitor with a VGA socket.
- Performant - the CPU should be fast enough to play simple games. This means it should be at least capable of clearing the screen in a couple of frames.
- Easy to program - Legion should be able to run user code directly, and have an instruction set that can be readily understood.
- Aesthetic - Legion is not going to win beauty contests, but it should be compact, neat and easy to move around.
- Can be hand built - All components are through hole, and can easily hand soldered.
There are also some 'non-goals'
- No Minimum chip count - There are other, better machines that achieve remarkable results with a handful of components. Legion is not that.
- No Compatability - This is a ground up, new design. Legion is not planned to leverage existing toolchains. If you want to run <X>, buy the device that runs <X> properly
To meet these goals, and my limited ability, these are the key features of Legion.
RISC Instruction Set
Legion has a load and store, RISC instruction set. In fact there are planned to be only two instructions - a conditional operate-and-move, and a memory access instruction. In order to keep performance high, there is no microcode (avoiding microcode lookup penalties). The instruction bit pattern completely describes the data and operations needed to execute the instruction.
The consequence is that Legion uses a wide instruction format - 16 bits. Move instructions take a single cycle, and memory access instructions take two.
Supporting the 16 bit instruction format, and keeping memory access logic simple, Legion has a 16 bit data bus. It's easier to have two 8 bit memory chips than complex logic to read instructions in two parts.
In order to make it easy to write code directly, Legion avoids a Harvard Architecture, instead having a unified memory map (ROM and RAM) and 16 bit address bus. Code can be loaded and executed from anywhere in memory.
To simplify Video output, Legion is synchronised to a standard 25.175 MHz video clock (though the clock is divided down to 3.125MHz). Video access is shared with CPU access, with video data being read on clock-high and instruction/memory access on clock-low.
Therefore, in a clock cycle, a 16 bit word of pixel data can be read. This is output as four, four bit pixels (ie. a 12.5Mhz pixel clock). This gives a resolution of 320x240 - which is compatible with the standard 640x480 VGA mode.
A stretch goal is to have a simple palette look up to enable a wider colour palette (eg. 2 or 3 bit RGB)
Legion will be built as modules that plug into a 'motherboard'. The motherboard combines busses, power and some control logic. Hopefully incrementally building and testing each module will make the design process more managable. The module construction will be the largest concession to modern techniques, with four plane PCBs that should be more reliable and resistant to noise.