Bartop Arcade Machine: Difference between revisions

From Nottinghack Wiki
Jump to navigation Jump to search
Line 93: Line 93:
** need to develop the atmega16u2 end with AVR gcc and Libc
** need to develop the atmega16u2 end with AVR gcc and Libc
** good hacks of same ilk -- https://github.com/clockfort/Arcade-Controls
** good hacks of same ilk -- https://github.com/clockfort/Arcade-Controls
** 2015-08-02 after some dsicussion with Spencer we have ordered a bunch of cheap [[ATMEGA32U4]] boards
** 2015-08-02 after some discussion with Spencer we have ordered a bunch of cheap [[ATMEGA32U4]] boards

Revision as of 09:06, 3 August 2015

A more portable mini Defender-oriented arcade machine based on Raspberry Pi with separate interchangeable control panels.

Status: getting there

Intro

The Game

Defender is an arcade video game that was released in 1981 (http://www.arcade-museum.com/game_detail.php?game_id=7547). This game was truly groundbreaking and it captured the imagination of myself and many others. It was bright and colourful, loud, futuristic and exciting, but more than anything it was really hard to play with its bizarre collection of controls: an up-down joystick, a "reverse" button, and buttons for "thrust", "fire", "smart-bomb", and "hyperspace". There were 6 different types of enemies, each with different AI and an impossible goal to achieve: protect the defenceless humanoids scattered over the surface of the planet. There was a sense of purpose and real threat, and to a kid it was gobsmackingly awesome!

The Aim

Some years ago I built a full-sized Defender cabinet so that I could play this game, and thanks to the M.A.M.E. project (Multiple Arcade Machine Emulator), thousands of others! When we moved to HackSpace 2.0 I moved the cabinet there as a semi-permanent loan and an example of the sort of thing we do (multi-faceted making and hacking). This cabinet is of course inherently non-portable and I have long thought it would be nice to have a smaller version to take to events and to use at home. I was also less than 100000% happy with the big cabinet: there were too many compromises in both accuracy and execution.

I do a lot of thinking! And I always have way too many projects on the go. A number of events coincided to spawn the actualisation phase of this project: -

  • Mouse started playing Defender, and despite my having over 30 years of "practice" he quickly took over the All-Time High Score table on the big cabinet!
  • The big A0 laser cutter arrived at the HackSpace - every project now became an application of laser design! CAD designs could now be accurately transferred to materials; even if large sheets of ply or MDF could not be cut on the laser, they could be etched into the surface and the cutting could be completed on the bandsaw or similar
  • The Raspberry Pi B+ arrived with a little extra grunt and the smart people of the internet made usable ports of emulation software
  • somebody donated a not-completely broken 17" LCD screen!

So, a culmination of jealousy, emerging technology, and trash: we are looking at a powerful motivation force :)

<TODO photo gallery>

<TODO summary and jump menu>

Braindump of details (to be sorted out)

  • Raspberry Pi
    • PiPlay AdvanceMAME install - http://piplay.org/
    • initially using a Raspberry Pi Model B+ I got from Phenoptix (for £26.99 using a 10% discount code for EMFCAMP 2014)
    • upgraded to a Raspberry Pi 2 Model B to improve performance (£33.94 from CPC with 8Gb NOOBS SD card)
  • Dell e172fpb LCD 17-in monitor with broken controls
  • HDMI-VGA adapter & gender changer
    • from DealExtreme - they have many versions at different prices
    • worked fine with the Pi Model B+ but when I tried to use it on the Pi 2 B it would not work. I spent a few evenings going through many Pi config settings and eventually I came out with a magic combination that worked - I'd better write that down!
  • 2x HP PC speakers from scrap - 16ohm, nice shape
  • cabinet
    • 19mm plywood sides
      • annoyingly the plywood is not even flat! both sides bend off square to one side!
    • Chipboard base
    • Knock-Down joints for assembly -- http://www.screwfix.com/p/white-kd-joints-pack-of-10/87601
    • T-Molding
    • slot cutter - from China for huge discount - 1/4" shaft required use of big router table which isn't flat!
    • living hinge plywood bends with laser polypropylene sheet veneer surface
    • adhesive to use for polypropylene to plywood?
      • 3M‎ Scotch-Weld‎ Hi-Strength 90 Spray Adhesive - damn expensive!
    • backlit marquee panel
  • Control panel: Defender layout
    • original dimensions metricated!
    • laminated laser cut ply and MDF
    • gold leaf switch buttons
    • Sanwa bat joystick
      • with modified mounting plate: a diagonal cut-away that is essential to get the reverse button close enough to the joystick
      • plate 95mm x 78mm
      • square plastic housing is 65mm square. Use 66mm to be safe

Details

Balance

On a project like this there's a balance to be found (if you care about having any spare time at all!) between the work that you put in and the net result. People see my projects and say really nice things but I'm usually quick to point out all of the things that didn't work out the way I wanted - actually my usual phrasing is along the lines of "everything is wrong!". Net result here is not what I see from my project (a half-completed bunch of mistakes) but a collective average of what I see, what another fellow hacker sees, what a muggle sees, and what a little kid sees. The last one is the most important by the way!

I've learned a lot of lessons on this project but I think I have been true to the goal: an accurate reproduction of an imaginary machine!

Control Panel(s)

The separate control panels means the freedom to adapt the machine to various uses: e.g. I imagine taking a Defender-only machine to an event and, of course, nobody can play it without hours of practice which is no fun for anyone.

A Control Panel (CP) of approximate width 600mm is close to full-sized cabinet widths (e.g. original Williams Defender CP is 24.5 inches which is 622mm) and fits aesthetically with the 420mm cabinet width. Also, various stock materials are available in round-about 600mm widths.

HID

  • Joysticks and buttons interfaced as USB HID gamepad
  • http://slagcoin.com/joystick/pcb_wiring.html
  • Problems with PiPlay GUI
  • alternatives: plenty more PS2 dancemat controllers to try out
  • Arduino Mega 2560 as HID Joypad(s)
    • starting point has been UnoJoy https://code.google.com/p/unojoy/
    • using the Mega's atmega16u2 reprogrammed with DFU to act as USB HID (rather than the usual serial CDC)
    • sketch on mega talks continuous serial to the atmega16u2 and relays USB HID info to the PC
    • this is going to be less responsive than the Minimus Joypad I made for BMO due to the latency of the extra serial hop
    • not keen on the code for UnoJoy - very PS3-oriented and needs some QC!
    • need to develop the atmega16u2 end with AVR gcc and Libc
    • good hacks of same ilk -- https://github.com/clockfort/Arcade-Controls
    • 2015-08-02 after some discussion with Spencer we have ordered a bunch of cheap ATMEGA32U4 boards