Home   PlasMa
Page updated: 17-Oct-2021

Construction

The physical design is fairly simple; the 'hardware' is just a set of lights and switches driven by a standard micro-controller unit (MCU). The MCU software handles all the complexity.

The printed circuit boards (PCBs) use standard interface chips so they are not tied to any particular MCU. The current firmware assumes a single MCU executing the opcodes and driving the lights and switches, but future versions may split this over multiple MCUs if more performance is required.

The following items may be useful if you want to experiment or build one yourself:-

  • PlasMaSim simulator program for evaluation or developing programs. The free version supports microcode 1 only (see Downloads); other versions are available supporting either 2 or all 3 microcodes.

  • Machine Manual and Instruction Set manuals as .pdf files.These contain full operating instructions, opcode tables and I/O function tables for each microcode.

  • Plasm assembler program for assembling source code offline. As with the simulator, different versions are available for handling 1, 2 or all 3 microcodes (see Downloads).

The following items may also be available; contact me for details:-

  • Blank PCBs, etched and drilled. The current design uses 26 boards but you donít need to use all of these if you want to simplify the mechanical layout. The boards use standard interface chips so may be useful for other projects.

  • MCU software in compiled .hex format. This will be for the current design, but customised versions may be available by negotiation. The source code will not be made available.

  • Front and rear panel hole positions in .dxf or .svg format (to be confirmed) corresponding to the lights and switches on the PCBs.

  • (To be confirmed) Aluminium panels, cut and drilled.

Build Log

The front and back panels are made from 3mm thick aluminium sheet, separated by spacers. This is the front panel showing the 3mm diameter holes for the register LEDs.



Close-up of the mag tape 'spool' holes.


The overall panel size is approx 500mm x 350mm, limited by the span of the CNC machine.


The finished front panel. The oper screen cutout above the keypad is for a smaller LCD for testing placements.


The first batch of PCBs for the 'phase 1' lights and switches testing. This was a leap of faith as I wasn't sure if there would be any problems with signal path lengths etc.


The boards are mounted on spacers to leave room for connections underneath; edge connectors would be neater but there was no room. A single large PCB was also considered, but it would have been an expensive gamble for a prototype.


Aligning the LEDs and switches caused a few headaches. I didn't want any mounting holes on the front panel so the boards were to be mounted on the rear panel using spacers to allow the LEDs & switches to poke through the front. They also had to be raised off the PCBs so templates were needed to line everything up. One option was to make a template for each board type, but this would involve a lot more drilling so it was decided to use the front panel itself.

Shallow pockets (indents) were milled into the rear of the front panel so the plastic spacers would be a tight fit without being bolted in. The positions correspond to the spacer holes in the bottom panel (the wonders of CNC accuracy!).

Smaller spacers were then bolted temporarily to the component side of the board and these 'clicked' into the pockets to lock the board in place while the LEDs were teased through the front panel holes; the LED flanges determined their height. Gravity then kept them at exactly the right height and position while the legs were soldered.


When soldering is finished, gently tease out the board and all the LEDs are perfectly aligned. The spacers can be removed and the rest of the components soldered.

In hindsight, flush-mounting LEDs may have avoided this hassle, but this would need some tall components and connectors to be relocated to the other side of the PCB.

Below is a finished 'register' PCB holding 3 x 16-bit register rows. The red LED is a 'power ok' indicator; these are fitted to all PCBs for peace of mind as there is minimal cost and effort. They can prevent expensive mistakes by confirming power tracks are correct before soldering anything else.

This board still needs the Break and Load LEDs soldering for each register row, and the driver chip. The 2 single header pins are the solder points for the current limiting (brightness) resistor. The brightness is controlled by firmware but this resistor determines the maximum brightness. If it needs changing after the machine is finished, it's easier to unsolder it from the pins than from the PCB itself. In hindsight a small trimpot might be a better solution.


Below shows a few PCBs fitted to the bottom panel. The status board is at the top, then 3 switch boards, then 3 register boards.

All light and switch boards share layouts where possible to reduce costs, and to allow for different size projects in the future. I hadn't finalised how to drive the boards from the MCU, so the connectors allow for either individual or serial operation, with plenty of ground pins for shielding if required.

Each register board holds 3 x 16-bit registers along with their respective Load and Break LEDs. The middle register board shown is slightly different as it has more LEDs on the top row; it is designed to 'butt up' against a standard board to its left so the top row can be the 32-bit accumulator register. This extended row actually contains 40 LEDs so the spare ones are used for flags.


Below shows all boards for the register lights and switches. The multi-coloured status LEDs are on top, followed by 4 rows of switches.

Row 1 contains the 2-way momentary control switches in banks of 8.
Rows 2 & 3 are the latching Load and Break switches in banks of 16.
Row 4 contains the latching memory address switches in banks of 8.

All switch boards are daisy-chained to form a single shift register so the data signal just needs a single GPIO pin on the MCU. The boards could also be driven by individual GPIO pins if performance is an issue, assuming an MCU with sufficient pins was available.


Below is a close-up of the register boards. Having the LEDs raised so far from the PCB makes them very vulnerable when exposed like this; the coiled anti-static wrist strap seemed to have an affinity for getting tangled!


Below is a close-up of the switch boards. The boards are daisy-chained to form a long serial shift register so the design can be expanded or reduced if needed.

The coloured status LEDs at the right of this picture were eventually changed to be all one colour as I forgot that coloured LEDs have different brightnesses for the same current (they are all driven by a single driver chip).


Below is a mag tape 'spools' PCB being assembled. Each board contains 2 spools and 4 status lights, so each board can emulate one tape deck. I would have liked more but there was not enough space on the panel; the panel size was determined by the CNC machine.

This shot shows the same alignment trick as the register boards. The LEDs just drop into the front panel holes up to their flanges, so they are held in exactly the right place while soldering.


A completed tape deck PCB (upside-down). The board's brightness resister is shown at top-middle soldered to its 2 header pins. The power-ok LED is flush against the PCB near the top-left spacer.


Initial testing of the lights and switches using a large free-standing Mega2560 MCU board at bottom-left. This will be replaced by a smaller Mega Pro board when the case is assembled.


Top panel test-fitted before painting.


Initial tests showed no problems with long signal paths so phase 2 was started and the remaining PCBs were made. Below is the peripheral PCB being tested; this holds the sd-card sockets which emulate the paper tape reader and punch, the 2 mag tape decks and the 2 exchangeable disc drives.


Below shows all PCBs fitted onto the bottom panel; the power board is at top-left (the 6-digit timer board fits over this but is not shown), the sd-card board is at top-middle with the status LED board above it, the oper screen and keypad is at bottom-left, and the MCU board is in the middle. The latter holds the smaller Mega Pro MCU which handles everything (at the time of writing). The small PCB above it is for the optional 2nd MCU if performance becomes an issue:


Phase 2 completed; the machine can now run Toy-A and Toy-B programs. The advanced microcode for PleX is still being designed. Temporary paper labels will be replaced with etched laminated plastic once the wording has been finalised.


A Toy-B test program based on the infinite monkey theorem using weighted averages for sentence and word lengths.

Spot the 3-word sentence in the middle of the oper...
... so close, but no cigar! (honestly, this was not a trick).

PleX instruction set design finished, so can now write programs which utilise the 32-bit accumulator, such as this simple calculator.


Another PleX example; first experiments with a simple mini 'exec' program. This was assembled using Plasm on another computer to generate a paper-tape image file. This was then copied to an sd-card. The card was then inserted into the paper-tape reader socket on PlasMa and loaded into main store using a loader program held in the non-volatile fixed store.


The case edge panels still need making; these will need holes cutting for the sd-cards and various sockets such as the PS/2 keyboard shown here. The nylon/brass spacers between the top & bottom panels are so the exact spacing can be determined.


The spacing is now committed, so custom spacers can be made. These use 1/4" square aluminium rod with M3 tapped holes at each end. The spacers around the perimeter need side holes for fastening the edge panels.
  
The case is probably over-engineered, but I (or my OCD) demanded a tactile/rigid panel which felt (and sounded) solid when the switches were operated, hence the 3mm thick aluminium and 23 metal spacers, 16 round the perimeter and 7 for internal bracing.

Spacers all drilled and tapped; the side holes for the 4 corner spacers are offset - this was very nearly a 'doh' moment.

If you're counting, the extra spacer is a spare.

Now for the edge panels. They say 'measure twice, cut once', but this was 'measure 3 times, cut a test piece... and then cut once (hopefully)!'.

Wooden test piece highlighted a couple of minor adjustments so was worth doing... it had better be right now.


Measurements committed so here goes...
First panel cut out on left is for the rear edge with holes for 6 SD cards for the simulated peripherals, 2 USB sockets for programming the MCUs, 1 USB for the 5v supply and a DC barrel jack for the 9v alternative supply if more current is needed. Currently uses 1/2 amp so USB power is ok for now.


All 4 panels cuts. Panel 3 has holes for the PS/2 keyboard, 5-pin MIDI in and out, and a 25-pin D-type socket for the system printer.


All cleaned up.


Square spacers and edge panels test fitted.


Trial assembly before painting. Extra tapped holes on side panels are a last-minute addition to allow wooden end cheeks to be added for supporting the machine at an angle.


Final close-ups of the inside before sealing everything up. This shows the left-hand side panel with MIDI in & out sockets and the 25-pin printer socket, the 3.5" LCD panel and 16-button keypad.


This shows the 2 MT-deck 'spools' and the 6-digit timer. Underneath the timer is the power distribution PCB with red & black pairs taking 5 volts to all the other PCBs. Top-right is part of the status LED board, and underneath this is the sd-card board. The 2 blue rectangles are level shifters to convert 5v control signals from the MCU to 3.3v for the sd-card sockets.


These are the left-hand register LEDs. The top row contain the flags and ms part of the 32-bit accumulator, the rows below are the 8 even-numbered 16-bit registers. Each register has a yellow breakpoint LED and a red load LED on the left.


These are the right-hand register LEDs. The top 3 are the memory, PC and IR lights, followed by the ls part of the accumulator, then the 8 odd-numbered register LEDs.


This shows the top panel folded out and upside-down. The PCBs hold the switches.


Below shows the two MCU PCBs. The jumpers between the two boards provide power and a 4-bit parallel I/O link. Both MCUs can be programmed independently via USB sockets on the rear panel.

The lower PCB holds an ATmega2560 MCU which currently handles all processing. The upper PCB holds an Arduino nano board fitted with an ATmega328. This currently does nothing, but it can be programmed later to investigate the feasibility of moving the order-code processing to it, in which case the upper PCB can be replaced with one containing a more powerful MCU.


All assembled - phew! 
Printer interface seems ok. MIDI still to test.
Labels and end-cheeks need making, but in theory, all functional mods should now just be via firmware updates.




End cheeks ready for sanding and staining.






Labels engraved onto laminated plastic.
Like watching paint dry.... but slower!
   

Old labels out, new labels in.






The construction phase is now declared... finished!