This project has been on my to-do list like forever. Over the last years I acquired a couple of tools and now I have a somewhat decent workshop. The Raspi 3 is there and quite powerful enough to run MAME. I even saved an old TV from the dumpster and had it sitting on the shelves for ages. So it was like now or never.
I have a soft spot for 8-bit arcades. When I was a kid, maybe 13 or 14 (around 1980!), I was on a vacation with a good friend of the family. He was a truck driver and drove always from Germany to Italy and back. A trip usually took 4 to 5 days. So I was on a truck for a week, which felt really cool. We delivered some stuff to Bologna and a couple of more places. Then we drove back to Milan and we had to load arcade machines. I saw these for the first time. At least it felt like that. All machines where running. All coin doors were open! Somebody saw me standing in front of them with huge eyes and showed me how to trigger the switch to get credits for free. BAM! I was hooked.
I played Galaxian for 2 hours straight. As the truck was loaded and we had to leave, they had to peel me of the arcades!
The next couple of years I dumped a lot of coins (Deutsche Mark) into arcade machines and I got quite good at Galaga, BombJack and Gauntlet.
Then, ages later, I stumbled upon MAME, the Multi Arcade Machine Emulator and had fun digging up the old games. I even built a controller box to be able to play at least with proper joystick and buttons.
Then, 4 months ago I decided, that I should have all tools together, that are required to build a complete arcade cabinet. The required skills I would learn by doing, hopefully.
This article is also available in Serbo-Croatian language by Vera Djuraskovic, thanks Vera!
And now also available in Portuguese, thanks Artur!
For quite some time I had my Raspi lying around. And some RGB Pixels as well. So it was about time to bring them together. The last couple of days I built a web interface that I can use to control my pixels. That’s more a technical demo, rather than something useful. But I learned quite a bit.
For the server part I decided to use node.js. For the client I wanted to use Angular.js and Bootstrap. To have the UI work on a mobile as well, I had to include Angular-touchevents.
The pixels are connected to the Raspi vi SPI. Although there are node modules for SPI and Adafruit pixels, they were not working out of the box. I had to poke around a bit to make them work. Changes are included in the node-pixel repository.
When put together, it works like this:
- The browser opens index.html and renders an array of 25 clickable batches.
- Clicking and dragging on a batch changes its color and lighting.
- These changes are send to the server over web sockets.
- The server receives the color changes, updates the pixels over SPI and then sends a broadcast via web sockets to all connected clients
As seen in the demo, there is a very noticeable lag between updates. For a more pro solution you may want custom build clients and your own custom protocol (or maybe DMX?) to get rid of that.