Archiv für den Monat: November 2017

RasPiSound also for WPC

After quite some time (raspinsound started in January 2017) I finally managed to get WPC sound running. The main difference to the first approach with dataeast is the different bus speed, that is used in WPC systems. This is because in WPC systems the bus between the main cpu and the sound subsystem is shared between the dmd controller and the sound card. This requires a higher bus speed and additional addressing wires.

sound-cmd-wpc1 My first try was to translate all the control wires 5 address lines, RW and WDEN directly to GPIO of the Pi. The idea was to simply do the address decoding in software within the interrupt service routine.

Looking at the output of the logic analyser and on the schematics you can see that writing to the 374 buffer requires CA0 and CA1 to be low, while CA2-4 need to be high. The CLK for the 374 buffer will go high exactly when WDEN goes high while RW is still on low.

Exactly this transition can be seen on the right.wpc-sound-schematics

The solution finally was to do the address decoding in hardware. This has reduced the frequency of interrupts dramatically. Effectively an interrupts only occurs, if a command byte is transferred to the sound card. The fact that wpc to some extend uses multi byte commands can be handled by the software. Sequences of command bytes are send with a 1ms delay between bytes so that the maximum interrupt frequency is around 1kHz.

Another improvement as I need to design a new adapter shield anyways was to consolidate the level shifter and the buffering of the sound data byte in a single chip that can be operated at 3v3 and has 5v tolerant inputs. Additionally I make use of the new Raspberry Pi Zero which has enough power and memory for the sound generation.

This results in a smaller and also cheaper design for wpc and with some smaller changes in the software the same approach could be used for dataeast as well.

As soon as the final shield is ready and tested, I will provide PCBs and kits in my shop at //go-dmd.de/shop.

Finally you can see the first working demo here:

Schematics for shield:

RasPiSound-schematicUpdate: today the PCBs arrived from manufacturer. Works like a charm. Also easy to assemble if you have some soldering experience, if not order a ready to use set here.

//go-dmd.de/produkt/fertig-bestuecktiges-raspberry-pinball-sound-board-v1-7/

20171201_135742xs

And finally another video from the first installment in a getaway!