Design of the Kenbak-1
The Design of the Kenbak-1
This overviews some technical aspects of the Kenbak-1 for those with basic knowledge of binary representations, logic circuits, and basic electronics. Much more detail, including full schematics, explanation of logic signals, and the state machine states, are in the "Theory of Operation" manual.
The Logic Circuitry:
The Kenbak-1 was made with small scale integrated circuits (SSI) of the "7400 series TTL" chips which were introduced by Texas Instruments just a few years before. This series contained a wide range of logic components (AND, NAND, OR, NOR gates, flip flops, latches, shift registers, demultiplexers, etc.) They operated on 5 volt power supply, and became available from several manufacturers.
Pictured is the schematic and photo of the first chip of the series, the 7400 Quad NAND gate. The Kenbak-1 used 45 of these 7400 chips, as well as about 90 other 7400 series chips.
For an easy to read overview of the entire Kenbak-1 schematic, see The TinyCAD Schematics here.
7400 TTL Chip,
The Kenbak-1 used Serial Memory:
Memory was expensive and complex in computers of the time. That was a major consideration for John Blankenbaker since he first started thinking about computers 20 years before. Often when John has told his story of making a Kenbak-1, he relates the story of being told that each "flip flop" in a computer costs about $500, and he looked in his wallet, and realized he had to do something different. A flip-flop is a simple electrical circuit which can hold a single "state" such as "on" or "off" so in essence, it's a single "bit" of memory. The $500 figure was because at that time, flip-flops were made of vacuum tubes, so all of the components, chassis, assembly, and power supply would really add up. This pushed him to the idea of a "serial computer" which required far less hardware, at the expense of slower operation.
Many early computers made use of "serial memory" where individual "bits" of data were represented by waves propagating through a medium. Early computers such as the EDSAC and Univac-1 computers of the 1940's and 50's used "Mercury Delay Lines" where waves propagated through a tube of mercury. A transmitter on one end generated a pressure wave, and a receiver on the other end detected the wave, and fed that back into the transmitter. The EDSAC mercury delay line could hold 560 bits of information in a 5 foot tube of mercury. But by the 1960's better types of serial memory became prevalent. "Magnetostrictive Delay Lines" used a long coil of steel wire, which were a transducer twisted one end, making a torsion wave propagate down the wire. This allowed up to 1000 bits of data in a 1 foot by 1 foot board. Many calculators of the 1960's used these magnetostrictive delay lines.
Alternatives to delay line memory were just as cumbersome, such as writing a pattern of dots on a CRT screen, and then quickly reading them back before they fade. Core memory was available at this time, but a 256 byte memory would be terribly expensive and large.
Schematic of a delay line memory, where bytes circulate down a "rope-like" medium from transmitter to receiver.
Digital "Delay Line" Memory:
Luckily, in the late 1960's, a small startup company named "Intel" began making integrated shift-registers which mimicked these physical delay lines, but were much more reliable and small. The Intel 1404A was a 1024-bit shift register, and exactly what John Blankenbaker needed to make his Serial Memory Computer that he had been thinking about for 20 years. Two of them were used to store the 256 bytes (2048 bits) he needed.
The animation the left shows schematically a 1024-bit shift register in action, a clock speed of only 3 hertz, along with a circuit to feed the output back to the input. Each clock cycle, all bits will shift one unit though the device. To read a byte of data, you have to wait until the required location shifts to the "output" and that would average 512 clock cycles for a random byte. Similarly, to write a new byte into memory, one must wait until the correct time, and feed that bit stream in at the correct time.
All that is needed is a byte counter which counts from zero to 127, and a bit counter from 0 to 7 to keep track of where the data currently is.
Incidentally, the red "bits" in the animation to the left, are actually the 7 bytes of the "simple counting program" on the home page.
The actual Kenbak-1 memory circuit is a bit more complex, and is diagramed at the right. There are two shift-register memory chips to hold the entire 2048 bits (256 bytes) of memory. Locations 0-127 are in one chip, and locations 128-255 are in the other. The high order address bit (A7) picks one of the two registers.
The input into the shift registers is a complex circuitry, to determine what should be written to a memory location. Note how the carry and overflow from the ALU operations, and the input switch data gets written into the first few or the last byte of the second memory bank.
Schematic of Memory and Memory MUX circuits
The area of Memory and MUX on PC board
To the left is the schematics of the memory and memory Mux, and above, the area occupied by this on the printed circuit board.
The Arithmetic Logic Unit (ALU):
The ALU is the circuit where primitive arithmetic or logic operations occur. A typical 8-bit computer would be able to add or subtract 8 bit numbers, shift or rotate bits left or right, and perform logical AND and OR operations on 8 bit words.
The heart of the Kenbak-1 is a serial adder, which operates on only one bit at a time. The animation on the right shows two numbers, A and B being added, one bit with each clock tick.
Subtraction is done by converting the second operand to it's "two's complement" where each bit is inverted then one is added. Adding a number in two's complement effectively subtracts that number. More complex operations like multiplication or division are possible through software which shifts bits, and performs the more primitive operations.
The ALU circuitry also handles logical AND/OR and SHIFT /ROTATE operations
Simple Serial Adder Circuit
The State Machine:
The State Machine of the Kenbak-1 computer
The Kenbak-1 uses a "state machine" (or more specifically a "finite-state-machine") to sequence through all the internal steps to load memory and execute instructions. This is a simple electronic circuit composed of logic gates, and and a latch, and it can be very powerful, almost like a "computer within the computer." Fairly complex operations can be performed with a state machine.
To the left is a simple diagram of the Kenbak-1's state machine. While 5 bits would allow up to 32 states, the Kenbak-1 uses 29 states. The QB to QF states primarily are used when machine is "halted" and the front panel switches are entering data into memory or reading it back. The SA to SZ states primarily running when a program is executing. All of these 29 states are are described in the "Theory of Operation" manual.
The State Machine of the Kenbak-1 takes up a large portion of the circuitry. In fact, 31 of the 131 IC chips are used in this state machine. And fully 4 pages of the schematics are devoted just to the state machine circuitry.
The PC board "Real Estate" devoted directly to the State Machine
The Clock and Timing Circuitry:
To keep track of timing of all of the serial bits circulating through the shift register memory, and to perform the sequence of operations under the State Machine's control, clock and timing circuitry is needed.
The Kenbak-1 uses a two transister multivibrator to generate a main clock signal (CP) at approximately 1 MHz rate. This feeds into a two-phase generator so each clock pulse generates either a F1 or an F2 pulse, needed by the 1404A shift register memory. Some have said that cuts the bit rate in half, but the shift registers actually multiplex two different streams, so a new bit is shifted in and out at EITHER of the two pulses, keeping the bit rate at 1 MHz. Level shifters are needed to translate the TTL levels to +5 to -12 volt swings.
The Timing Signals:
The above circuit divides this 1 MHz bit rate clock into separate signals for each bit in an 8-bit byte. And generates a special C7 ̅ signal, which triggers after the last bit of each byte. This is used many places, such as the transition clock for the state machine, which needs to change at the end of each byte time. As can be seen below, the clock and timing circuitry takes up a small portion of the printed circuit board.
Timing and Clock Signals
Most of the remaining circuitry and board space is the glue-logic for various functions. The above gives an overview of the logical components of the Kenbak-1 computer, and an idea of how it works. But a thorough reading of the "Theory of Operation" manual is the best resource to really get into the details.