bread80, to random
@bread80@mstdn.social avatar

I/O on the 2200 (as I'm understanding it) :

The instructions are similar to the i8008. Bits 4 to 1 of the bytecode code the I/O port. 32 addresses, but the first 8 are inputs, mapped to instructions IN 0..7. The remaining 24 are outputs mapped to instructions OUT 0..23.

The Datapoint uses the instruction EX for outputs (short for external IIRC)). Rather than port numbers it uses names. The first 8 are generic:
EX ADR
EX STATUS
EX DATA
EX WRITE
EX COM1 though EX COM4
🧵

bread80, to random
@bread80@mstdn.social avatar

I'm adding a basic terminal to the 2200 simulator. It's listening to output ports (input still to do).

Here's a video of it saying "Hello World" in it's own fashion. Program listing in video comments.

https://youtu.be/FzSDf94Q0Ao

bread80, to random
@bread80@mstdn.social avatar

Returning to the simulator to try and fix a thorny issue that's been eluding me for a while.

The four chips at the bottom are '193 counters which normally house the program counter. Above are a row of '153 4-to-1 multiplexers. These can load an address from the stack, the H, L registers or the temp address register (for inline jump, call addresses).

bread80, to random
@bread80@mstdn.social avatar

"A programmer that's never programmed a computer in binary is like a child that's never run barefoot over Lego."

Also can you spot the schoolboy error in the first line of code? Which means all the jump target addresses are wrong and I need to redo a lot of stuff.

bread80, to random
@bread80@mstdn.social avatar

I fixed the ALU issue. The clock input of the carry flag latch wasn't triggering. The circuit uses a couple of open-collector gates and a pull-up. A bug in my simulator failed to recognise the net's rising edge.

A few upgrades to the simulator so it can free run and some speed ups. Below is after adding 1 to A and looping until the carry flag is set, using a JFC (Jump if Carry False) and HALTing.

bread80, to random
@bread80@mstdn.social avatar

Todays test program: load values into the A and B registers, add (or subtract) them and loop.

I've got the jump working but the ALU ops are not so pretty. It's inverting each bit of A if the bit in B is set. The circuit for the ALU is all standard gates, and I'd be surprised if there's any bugs in there given the rest of the simulator is working so well.

So it's probably a schematic issue, and one which will take a bit of debugging.

bread80, to random
@bread80@mstdn.social avatar

"Hello!!" (Read the registers from top to bottom <g>).

(I had to fix a bug in the 7474 simulation to get this to run. It was listening to the SET and RSET pins if they went low. But the design had both low at the same time, the first one to go high 'lost'. The simulator now updates if either pin changes to any state (it already checks them to overrides CLK updates they're active)).

bread80, to random
@bread80@mstdn.social avatar

I've spent much of the weekend working on my gate level logic simulator of the 2200 serial processor.

Here it is after processing a LA 6 instruction, which loads the immediate value 6 into the A register (6 is also the bytecode for LA n).

So far the schematics have functioned flawlessy, the only bugs have been in the simulator code.

bread80, to random
@bread80@mstdn.social avatar

That's the 74193 (4-bit counter) and 7473 (j-K flip-flop) simulations added and the six-bit Memory Sync counter functioning.

The bottom rows of the screenshot: Z101 is the 74193, Z101-Pad12 is the carry out. Z115 is the 7473.

The screenshot slow slightly over one complete 'rotation' of the memories. This is required for random memory access (reading/writing data).

The Clocks data is actually half-cycles but halving that to >6000 shows how slow this machine is.

bread80, to random
@bread80@mstdn.social avatar

Added code to the simulator to count clock cycles and drive certain inputs as required to initialise the processor (see previous thread).

It's running as far as requiring the WORD_SELECT signal which will initiate the first instruction fetch.

At this point I need to add a few more components to the simulator for the program counter and address counter sync logic which generates WORD_SELECT.

bread80, to random
@bread80@mstdn.social avatar

This feels like a good time to look at what is needed to start the 2200 processor.

The Datapoint has no ROM, not even a boot ROM. On reset it rewinds tape deck 1, loads the first file, and executes it. All of this is done in hardware.

🧵

bread80, to random
@bread80@mstdn.social avatar

The 2200 gate simulator can now import data from multiple projects and I can join boards together via connectors. So I now have the Decoder, Motherboard and Processor boards imported with net data propagating across them.

Some of the nets can have multiple drivers across different boards, so the simulator needs to examine all pins across the joined nets, and propagate the results back to all pins.

I'm now adding tooling ready to try and boot the processor, such as the scaling here.

bread80, to random
@bread80@mstdn.social avatar

My 2200 net simulator is now generating output which matches my analysis of the Decoder board schematic (see comments on the image).

One full cycle takes 80 clocks. First SYS_CLK is divided in two and split into four T states. T0 clocks a decade counter (C0..C4). Most outputs are a combination of counter and T states.

Counts 0 to 7 are when memory and/or registers are clocked (PHIxx). Counts 8 and 9 are when 'other' stuff happens (STROBEx).

The schematic for the timing sequence generator section of the Decoder PCB. Oscillator on the left, counter IC (7490) in the middle, various outputs on the right. 'Child' sheets in the top left are for the SMT LEDs and RP2040Stamp module which can also generate the clock signal (and slow clock it.)

bread80, to random
@bread80@mstdn.social avatar

The processor board is large, expensive, and will take a long time to solder up. It could have errors from my transcribing the schematics or the schematics themselves. It may even have deliberate traps to stop competitors stealing the design.

I really need a way to prove the design works. I could use Logisim for that. But re-entering the whole thing would take ages, and have issues of it's own (and assuming it could cope with the design).

1/n

bread80, to random
@bread80@mstdn.social avatar

With the memory board sent to the fab it's time for the most exciting part of the project: the processor board.

This is A3 sized and houses 117 ICs. I'll be adding as many blinkenlights as I can fit.

I intend to toot as much as I can about the design process. I think it should be ... ahem ... interesting.

But it won't be quick. I'll be fitting it around other projects, and it'll be a ton of work anyway.

bread80,
@bread80@mstdn.social avatar

Current status: proof reading the schematics. I’m following every connection and using highlighter pens to mark where I’ve been. And doing the same to my schematics. The assortment of colours helps to stop me getting muddled.

Thus probably counts as tedious but my brain enjoys this kind of task.

bread80,
@bread80@mstdn.social avatar

Adding a page of spare units, based off the table on the original schematics, but the design checker doesn't like it.

So, the original is hard to read, and I've not double checked what I've copied, but it clearly shows Z95 with some spare units. But Z95 is one of the RAM chips making up the stack. So this table is definitely error prone.

The table or spare units from the original schematics. Each entry has fields for unit number, IC type, input pins and output pins. The scanning of some of the entries is poor to the point of being somewhat unreadable.
Kicad rules checker output: Multiple item Z30 (unit 5) Different values for Z53A (7400) and Z53B (7402) Multiple item Z95 (unit 3) Different values for Z95C (7410) and Z95A (7489) Annotation required!

bread80,
@bread80@mstdn.social avatar

Adding footprints. No difficulty here. There's only 8 different footprints across the board: 3 for connectors; 2 for capacitors; 1 for resistors; and 2 for chips.

This was the early days of 74 series logic so only 14- and 16-pin packages in use.

bread80,
@bread80@mstdn.social avatar

Now this is the dictionary definition of tedium. An entire page of power units for the logic gates.

Gaps are for chips with power connections on the main symbol. Not, BTW, the same as chips containing a single unit - there are several 8-input gates with one unit per chip but those still have a separate power unit.

bread80,
@bread80@mstdn.social avatar

I've copied the Decoder PCB to get the edges of the Processor PCB. I'm using a print out of the decoder PCB and the long edge dimension of the decoder board to work out the scale of the print out.

I can then measure and scale up from the print out.

I'll keep the old decoder components and silk screen for the moment to reuse dimensions and design standards.

bread80,
@bread80@mstdn.social avatar

All components placed - to match the positions on the original board. Still some fettling to do on the edge connectors.

I'm now finally realising how ridiculously large this board is. In a way which, for unknown reasons, I'd been completely oblivious to previously.

bread80,
@bread80@mstdn.social avatar

Next up, H and L registers. Probably the simplest schematic of the lot.

These shift registers output to the /DATA bus via an open collector NAND gate. The /DATA line takes output from all the registers, the memory cards, and the tape board - which reads a file on reboot.

Inverters (top left) output to

  1. the REG_DATA line which is used as input by the B,C,D,E,H,L registers,
  2. the DATA line which is input to everywhere else (IR, ALU, temp addr reg)

bread80,
@bread80@mstdn.social avatar

And the address multiplexers. Data can be loaded into the address registers from 3 sources: the stack, the H and L registers or the temp address register. The multiplexers select the source.

The Temp Address Register is used when reading a call or jump inline address. These are the only instructions which take an immediate address. All other memory references have to go via the H and L registers.

bread80,
@bread80@mstdn.social avatar

It's worth noting that this circuit functions for every opcode in the instruction register even if it's not a branch instruction.

It's only at the next stage that the processor examines whether the opcode is a jump, call or return and sends signals elsewhere to load an immediate address, push the program counter on the stack or pop a return address off the stack.

bread80,
@bread80@mstdn.social avatar

And the current routing status. Nine pages of schematics done. Three left to go.

  • All
  • Subscribed
  • Moderated
  • Favorites
  • JUstTest
  • everett
  • InstantRegret
  • thenastyranch
  • magazineikmin
  • khanakhh
  • rosin
  • Youngstown
  • slotface
  • mdbf
  • cisconetworking
  • kavyap
  • cubers
  • DreamBathrooms
  • megavids
  • ngwrru68w68
  • Durango
  • osvaldo12
  • tacticalgear
  • modclub
  • normalnudes
  • Leos
  • ethstaker
  • GTA5RPClips
  • tester
  • anitta
  • provamag3
  • lostlight
  • All magazines