<?xml version="1.0" encoding="UTF-8"?><rss xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:atom="http://www.w3.org/2005/Atom" version="2.0" xmlns:media="http://search.yahoo.com/mrss/"><channel><title><![CDATA[Justin Unterreiner]]></title><description><![CDATA[Software development, arcade restoration, and the internet of things.]]></description><link>http://www.justin-credible.net/</link><generator>Ghost 0.11</generator><lastBuildDate>Sat, 31 Jan 2026 20:49:51 GMT</lastBuildDate><atom:link href="http://www.justin-credible.net/rss/" rel="self" type="application/rss+xml"/><ttl>60</ttl><item><title><![CDATA[Donkey Kong Junior conversion]]></title><description><![CDATA[<p><img src="http://www.justin-credible.net/content/images/2024/07/dk-jr-after-cropped-small.png" style="float: right; padding-left: 10px; width: 200px;"></p>

<p>I picked up a Midway-style cabinet that had been converted to a Street Fighter II a few years back. After some inspection I noticed it has previously been a Ms. Pac-Man, which was made apparent by the signature bright blue paint that was over-sprayed onto the inside of the cabinet.</p>]]></description><link>http://www.justin-credible.net/2024/07/07/donkey-kong-junior-conversion/</link><guid isPermaLink="false">1966b982-f46a-4239-88c1-9a8c3528918d</guid><category><![CDATA[Arcade Restoration]]></category><dc:creator><![CDATA[Justin Unterreiner]]></dc:creator><pubDate>Sun, 07 Jul 2024 21:59:21 GMT</pubDate><content:encoded><![CDATA[<p><img src="http://www.justin-credible.net/content/images/2024/07/dk-jr-after-cropped-small.png" style="float: right; padding-left: 10px; width: 200px;"></p>

<p>I picked up a Midway-style cabinet that had been converted to a Street Fighter II a few years back. After some inspection I noticed it has previously been a Ms. Pac-Man, which was made apparent by the signature bright blue paint that was over-sprayed onto the inside of the cabinet.</p>

<p>I have a fondness for this style of cabinet, but I already have several in my collection and didn't feel like I needed another. So it sat in the garage for a few years until a friend of mine mentioned he was looking for an arcade for his game room.</p>

<p>He had nostalgia for Donkey Kong Junior; the bright orange paint and the classic artwork, but didn't care so much for the form factor of the Nintendo cabinet. He felt the monitor marquee was too close and that it didn't allow you to really lean into the machine, like a Pac-Man cabinet would. I realized then I had the purpose use for my frankenstein'd Ms. Pac-Man cabinet!</p>

<div class="photo-gallery">  
    <a href="http://www.justin-credible.net/content/images/2024/07/before-1.jpg" title="" data-width="1536" data-height="2048">
        <img src="http://www.justin-credible.net/content/images/2024/07/before-1-1.jpg" alt="">
    </a>
    <a href="http://www.justin-credible.net/content/images/2024/07/before-2.JPG" title="" data-width="2048" data-height="1536">
        <img src="http://www.justin-credible.net/content/images/2024/07/before-2-1.JPG" alt="">
    </a>
    <a href="http://www.justin-credible.net/content/images/2024/07/before-3.JPG" title="" data-width="2048" data-height="1536">
        <img src="http://www.justin-credible.net/content/images/2024/07/before-3-1.JPG" alt="">
    </a>
</div>

<p>I ended up doing a restoration / conversion combination on the cabinet. This required some custom artwork to be put together as the marquee, monitor bezel, and control panel are all different sizes between the two machines. Instead of a single game, we went with the ArcadeSD game board, which is a great multi-game board, especially for cabinets with a monitor mounted in the vertical position.</p>

<p>It includes a joystick, three buttons, and a trackball and has all the classics: all three Donkey Kongs, Ceneipede, Millipede, Missile Command, Mario Bros, Frogger, Galaga, Ms. Pac-Man, and the list goes on.</p>

<p>It was a really fun and unique build and I'm happy with how it turned out. It's definitely much more appealing than the cramped Street Fighter 2 was!</p>

<div class="photo-gallery">  
    <a href="http://www.justin-credible.net/content/images/2024/07/after-1.jpg" title="" data-width="1536" data-height="2048">
        <img src="http://www.justin-credible.net/content/images/2024/07/after-1-1.jpg" alt="">
    </a>
    <a href="http://www.justin-credible.net/content/images/2024/07/after-2.jpg" title="" data-width="1536" data-height="2048">
        <img src="http://www.justin-credible.net/content/images/2024/07/after-2-1.jpg" alt="">
    </a>
    <a href="http://www.justin-credible.net/content/images/2024/07/after-3.jpg" title="" data-width="1536" data-height="2048">
        <img src="http://www.justin-credible.net/content/images/2024/07/after-3-1.jpg" alt="">
    </a>
</div>

<h2 id="timelapsevideo">Timelapse Video</h2>

<p>I've put together a timelapse video showing the complete restoration that runs at about 20x speed, which you can find on my YouTube channel.</p>

<iframe width="854" height="480" src="https://www.youtube.com/embed/dtUk6Al0rdM" frameborder="0" allowfullscreen></iframe>

<h2 id="partslist">Parts List</h2>

<p>The marquee, monitor bezel, and control panel are all my custom design built in <a href="https://www.photopea.com">Photopea</a> (a free Photoshop clone) and were printed by Szabo's Arcades.</p>

<h3 id="artwork">Artwork</h3>

<ul>
<li>Szabo's Arcades ▶ <a href="https://www.szabosarcades.com/">https://www.szabosarcades.com/</a></li>
<li>Side Art ▶ <a href="https://www.szabosarcades.com/products/donkey-kong-jr-side-art">https://www.szabosarcades.com/products/donkey-kong-jr-side-art</a></li>
<li>Bezel ▶ <a href="https://www.szabosarcades.com/products/multicade-bezel">https://www.szabosarcades.com/products/multicade-bezel</a></li>
<li>Marquee ▶ <a href="https://www.szabosarcades.com/products/multicade-marquee">https://www.szabosarcades.com/products/multicade-marquee</a></li>
<li>Control Panel Overlay ▶ <a href="https://www.szabosarcades.com/products/multicade-control-panel-overlay">https://www.szabosarcades.com/products/multicade-control-panel-overlay</a></li>
</ul>

<h3 id="electrical">Electrical</h3>

<ul>
<li>ArcadeSD PCB ▶ <a href="https://www.phoenixarcade.com/products/arcadesd/arcadesd-pcb-us-shipping">https://www.phoenixarcade.com/products/arcadesd/arcadesd-pcb-us-shipping</a></li>
<li>Multicade Upright Harness - JS/Trackball ▶ <a href="https://www.arcadeshop.com/i/517/multicade-upright-harness-js-tb.htm">https://www.arcadeshop.com/i/517/multicade-upright-harness-js-tb.htm</a></li>
<li>Happ 20 AMP Switching Power Supply ▶ <a href="https://www.arcadeshop.com/i/806/switching-power-supply-20-amp.htm">https://www.arcadeshop.com/i/806/switching-power-supply-20-amp.htm</a></li>
</ul>

<h3 id="controls">Controls</h3>

<ul>
<li>Multicade Årcade Classics Metal Panel ▶ <a href="https://www.phoenixarcade.com/products/multicade-arcade-classics/multicade-arcade-classics-metal-panel">https://www.phoenixarcade.com/products/multicade-arcade-classics/multicade-arcade-classics-metal-panel</a></li>
<li>2¼" Trackball Unit White Ball Atari/Happ ▶ <a href="https://www.arcadeshop.com/i/19/2-trackball-unit-white-ball-atari-happ.htm">https://www.arcadeshop.com/i/19/2-trackball-unit-white-ball-atari-happ.htm</a></li>
<li>Wico Red 8-Way Ball 3.5" Handle Leaf Joystick ▶ <a href="https://www.arcadeshop.com/i/1489/wico-3.5-red-ball-handle-joystick.htm">https://www.arcadeshop.com/i/1489/wico-3.5-red-ball-handle-joystick.htm</a></li>
<li>CLASSX True-Leaf Pro Red Push Buttons ▶ <a href="https://groovygamegear.com/webstore/index.php?main_page=product_info&amp;products_id=356">https://groovygamegear.com/webstore/index.php?main<em>page=product</em>info&amp;products_id=356</a></li>
</ul>

<h3 id="misc">Misc</h3>

<ul>
<li>White Smooth 3/4" T-Molding ▶ <a href="https://www.arcadeshop.com/i/866/white-smooth-3-4-t-molding.htm">https://www.arcadeshop.com/i/866/white-smooth-3-4-t-molding.htm</a></li>
</ul>]]></content:encoded></item><item><title><![CDATA[Super Mario Bros. Pinball Mods]]></title><description><![CDATA[<p><img src="http://www.justin-credible.net/content/images/2024/04/smb-pinball-cropped.png" style="float: right; padding-left: 10px; width: 200px;"></p>

<p>Manufactured by Gotlieb and released in April of 1992, this pinball version of Mario was pretty unique for its time. I have fond memories of first discovering this game in a Chuck E Cheese entertainment center; it was the first time I had ever heard Mario as a fully voiced</p>]]></description><link>http://www.justin-credible.net/2024/04/14/super-mario-bros-pinball-mods/</link><guid isPermaLink="false">3a37e296-c3f8-48a9-9eac-de683f2223bf</guid><category><![CDATA[Gaming]]></category><category><![CDATA[Pinball]]></category><dc:creator><![CDATA[Justin Unterreiner]]></dc:creator><pubDate>Sun, 14 Apr 2024 16:16:53 GMT</pubDate><content:encoded><![CDATA[<p><img src="http://www.justin-credible.net/content/images/2024/04/smb-pinball-cropped.png" style="float: right; padding-left: 10px; width: 200px;"></p>

<p>Manufactured by Gotlieb and released in April of 1992, this pinball version of Mario was pretty unique for its time. I have fond memories of first discovering this game in a Chuck E Cheese entertainment center; it was the first time I had ever heard Mario as a fully voiced video game character. Many people wouldn't experience this until Super Mario 64 was released on the Nintendo 64 some 4 years later.</p>

<p>The music, sound, artwork, and stunning lightshow brought Mario's world to life in a way I had never seen before and it made a big impression on me. So much so that many years later, once I had gotten further into the arcade hobby, I knew I would one day own my own table.</p>

<p>I was lucky enough to find one for sale last year and I jumped at the opportunity. While many seasoned pinball players will dismiss the table as too easy, I'm still having a ton of fun with it.</p>

<p>In this video I just wanted to share some of the modifications I've made to my table. I've included links below the video to all the mods I installed just in case there is a certain one you'd like to check out.</p>

<h3 id="video">Video</h3>

<iframe width="854" height="480" src="https://www.youtube.com/embed/xrE-ZuNXUd0" frameborder="0" allowfullscreen></iframe>

<h3 id="mods">Mods</h3>

<ul>
<li><a href="https://pinside.com/pinball/market/shops/1424-daddio-s-3d-printed-mods/08208-the-super-mario-bros-pinball-speaker-star-inserts">Speaker Star Inserts</a></li>
<li><a href="https://www.cometpinball.com/products/lighting-strips">LED Strips</a></li>
<li><a href="https://www.cometpinball.com/products/outhole-lighting-kit">Outhole/Trough Lighting Kit</a></li>
<li><a href="https://pinside.com/pinball/market/shops/1424-daddio-s-3d-printed-mods/08214-acorn-nut-replacements-mushroom-design-6-32-sized">Acorn Nuts (Mushroom)</a></li>
<li><a href="https://pinside.com/pinball/market/shops/1424-daddio-s-3d-printed-mods/10081-acorn-nut-replacements-bob-omb-design-6-32-sized">Acorn Nuts (Bob-omb)</a></li>
<li><a href="https://pinside.com/pinball/market/shops/1424-daddio-s-3d-printed-mods/07295-mini-castle-nuts-and-screw-covers-for-slingshots-and-inlanes">Acorn Nuts (Castle)</a></li>
<li><a href="https://pinside.com/pinball/market/shops/1424-daddio-s-3d-printed-mods/08210-the-super-mario-bros-pinball-5-piece-hole-protector-set">Hole Protectors</a></li>
<li><a href="https://www.cometpinball.com/products/pop-bumper-discs">Pop Bumper LED Discs</a></li>
<li><a href="https://pinside.com/pinball/market/shops/1424-daddio-s-3d-printed-mods/08211-the-super-mario-bros-pinball-piranha-plant">Pirahna Plant</a></li>
<li><a href="https://www.jakks.com/product/mario-2-5-inch-articulated-figure/">Action Figures</a></li>
<li><a href="https://www.amazon.com/s?k=mounting+putty">Mounting Putty</a></li>
<li><a href="https://pinside.com/pinball/market/shops/1331-twisted-tokens/06733-super-mario-bros-question-cube">Flasher Cover (Question Cube)</a></li>
<li><a href="https://pinside.com/pinball/market/shops/1424-daddio-s-3d-printed-mods/07158-the-super-mario-bros-pinball-flasher-pipe-covers">Flasher Cover (Pipes)</a></li>
<li><a href="https://pinside.com/pinball/market/shops/1424-daddio-s-3d-printed-mods/08220-super-mario-bros-pinball-machine-upper-pipe">Return Ramp Pipe</a></li>
<li><a href="https://pinside.com/pinball/market/shops/1424-daddio-s-3d-printed-mods/07110-the-ultimate-super-mario-bros-pinball-castle-upgrade">Bowser's Castle</a></li>
<li><a href="https://mezelmods.com/products/super-mario-brothers-gameblades">GameBlades (inner side art)</a></li>
<li><a href="https://www.cometpinball.com/products/illuminated-flipper-button-kit">Illuminated Flipper Button Kit</a></li>
<li><a href="https://pinside.com/pinball/market/shops/1424-daddio-s-3d-printed-mods/08209-the-super-mario-bros-pinball-mario-launcher-button-cover">Launcher Button Cover</a></li>
<li><a href="https://pinside.com/pinball/market/shops/1424-daddio-s-3d-printed-mods/08221-super-mario-bros-pinball-machine-launcher-pipe">Launcher Pipe</a></li>
<li><a href="https://pinside.com/pinball/market/shops/1424-daddio-s-3d-printed-mods/08207-the-super-mario-bros-pinball-mystery-box-target-covers">Target Covers</a></li>
<li><a href="https://pinside.com/pinball/market/shops/1424-daddio-s-3d-printed-mods/08206-the-super-mario-bros-pinball-coin-reject-buttons">Coin Reject Buttons</a></li>
<li><a href="https://pin2dmd.com/">Pin2dmd</a></li>
<li><a href="https://pinside.com/pinball/forum/topic/pin2dmd-colorization-of-super-mario-bros">Pin2dmd community colorization</a></li>
<li><a href="https://shop.colordmd.com/colordmd-replacement-display-for-super-mario-bros-pinball-machine/">ColorDMD</a></li>
</ul>

<h3 id="machineinformation">Machine Information</h3>

<ul>
<li><a href="https://pinside.com/pinball/machine/super-mario-bros">Pinside</a></li>
<li><a href="https://www.arcade-museum.com/Pinball/super-mario-bros">KLOV</a></li>
</ul>]]></content:encoded></item><item><title><![CDATA[Locking in TypeScript]]></title><description><![CDATA[<p>If you've worked in a non-JavaScript language, you're likely familiar with the concept of a lock. <a href="https://en.wikipedia.org/wiki/Lock_(computer_science)">Locks</a> are useful in multi-threaded environments to ensure access to a given variable cannot be modified by two threads concurrently. This functionality is usually provided by a runtime structure such as a semaphore. Some</p>]]></description><link>http://www.justin-credible.net/2023/12/04/locking-in-typescript/</link><guid isPermaLink="false">91e6ec3d-8f46-456e-a7b9-e495d3d9fb7d</guid><category><![CDATA[Software Development]]></category><dc:creator><![CDATA[Justin Unterreiner]]></dc:creator><pubDate>Mon, 04 Dec 2023 22:29:13 GMT</pubDate><content:encoded><![CDATA[<p>If you've worked in a non-JavaScript language, you're likely familiar with the concept of a lock. <a href="https://en.wikipedia.org/wiki/Lock_(computer_science)">Locks</a> are useful in multi-threaded environments to ensure access to a given variable cannot be modified by two threads concurrently. This functionality is usually provided by a runtime structure such as a semaphore. Some other languages even provide a locking mechanism as first-class citizen via a language keyword, for example, C# provides the <a href="https://learn.microsoft.com/en-us/dotnet/csharp/language-reference/statements/lock"><code>lock</code> statement</a>.</p>

<p>However, the concept of a lock in a JavaScript environment is not as common. This is due to the fact that most JavaScript environments are single threaded. There is no reason to obtain a lock because the code cannot execute simultaneously.</p>

<p>That being said, there are still cases where a lock-like mechanism can be useful: when working with asynchronous code. I've been working on mobile applications written in TypeScript over the last several years and this is scenario that I've ran into several times:</p>

<ul>
<li>On app startup, several HTTP API calls need to be made</li>
<li>Calls are not centralized; they're made from several different locations (screens)</li>
<li>All API calls have authentication prerequisites (e.g. a cookie or JWT must have been obtained first)</li>
</ul>

<p>Usually this means that there will be a central function used to handle the authentication logic, lets call it <code>executeApiRequest</code>:</p>

<pre><code class="language-typescript">export async function executeApiRequest(apiUrl: string): Promise&lt;Response&gt; {  
  if (!authenticated) {
    // Makes API request and stores token into storage
    await obtainToken();
  }

  // Includes a header with authentication token
  const options = getRequestOptions();

  return fetch(apiUrl, options);
}
</code></pre>

<p>Internally, an <code>obtainToken</code> method will be responsible for determining the authentication state, and if a cookie/JWT/etc is needed, it will make an API request to obtain said token. After the token is obtained, the method will issue the original request.</p>

<p>This works great in most cases, However  if multiple call sites use the method at the same time (such as app startup), it can result in several API requests to obtain an authentication going out in parallel.</p>

<p>We want to ensure that only a single authentication API request is made, otherwise the user could be issued multiple tokens or experience other undefined behavior.</p>

<p>This is where a lock becomes useful; we want to ensure that only a single asynchronous call to a function can be occurring at a given time. All future calls should wait until the first has resolved and then execute in order after that.</p>

<p>We can achieve this using a list of promises and a bit of logic in a function I've called <code>doWithLock</code>:</p>

<pre><code class="language-typescript">export async function doWithLock&lt;T&gt;(lockName: string, task: () =&gt; Promise&lt;T&gt;): Promise&lt;T&gt; { ... }  
</code></pre>

<p>Which can be used in the original example, like this:  </p>

<pre><code class="language-typescript">export async function executeApiRequest(apiUrl: string): Promise&lt;Response&gt; {  
  if (!authenticated) {
    // Makes API request and stores token into storage
    await doWithLock('obtainToken', () =&gt; obtainToken());
  }

  // Includes a header with authentication token
  const options = getRequestOptions();

  return fetch(apiUrl, options);
}
</code></pre>

<p>Now, if several calls to <code>executeApiRequest</code> are made at the same time, they'll all "wait" at the <code>doWithLock</code> call site for the <code>obtainToken</code> function to return. Each additional call will be executed in order.</p>

<p>The helper function is available as a TypeScript source file (with unit tests!) in this <a href="https://gist.github.com/Justin-Credible/693529fa4672a0d97963b95a26897812#file-async-utils-ts">gist</a> on GitHub.</p>

<script src="https://gist.github.com/Justin-Credible/693529fa4672a0d97963b95a26897812.js?file=async-utils.ts"></script>]]></content:encoded></item><item><title><![CDATA[Xbox UWP SDL2 Starter Project]]></title><description><![CDATA[<p><img src="http://www.justin-credible.net/content/images/2020/12/xbox-uwp-collage.png" style="float: right; padding-left: 10px; width: 325px;"></p>

<p>After finishing up my <a href="https://www.justin-credible.net/2020/08/24/pac-man-emulator/">Z80/Pac-Man Emulator</a> I thought it would be fun to port it to a game console. Since it was written in C#, the Xbox seemed like a natural fit.</p>

<p>All Xbox One retail units also support a DevMode out of the box, so there would be</p>]]></description><link>http://www.justin-credible.net/2020/12/04/xbox-uwp-sdl2-starter-project/</link><guid isPermaLink="false">3dbc6bb9-f783-490e-8605-5ed71410037a</guid><category><![CDATA[Software Development]]></category><category><![CDATA[Game Dev]]></category><dc:creator><![CDATA[Justin Unterreiner]]></dc:creator><pubDate>Sat, 05 Dec 2020 07:51:41 GMT</pubDate><content:encoded><![CDATA[<p><img src="http://www.justin-credible.net/content/images/2020/12/xbox-uwp-collage.png" style="float: right; padding-left: 10px; width: 325px;"></p>

<p>After finishing up my <a href="https://www.justin-credible.net/2020/08/24/pac-man-emulator/">Z80/Pac-Man Emulator</a> I thought it would be fun to port it to a game console. Since it was written in C#, the Xbox seemed like a natural fit.</p>

<p>All Xbox One retail units also support a DevMode out of the box, so there would be no need for a jailbreak or hacking around security. I knew the Xbox used UWP apps, so I figured it would be a pretty straightforward port.</p>

<p>I was able to get my emulator running on the Xbox, but I did run into a few hurdles along the way.</p>

<p>While getting a Hello World up and running on an Xbox One is quick and easy using Visual Studio, it assumes you'll be building a GUI app using Windows Presentation Foundation (WPF). This means using XAML to build out screens using controls and widgets. If you want to build a game instead of write an app, this is less than ideal. When building a game you probably want to render to the screen yourself.</p>

<p>It took many hours of Googling to find the correct incantations and hidden settings to get this working, so I figured I would document it here for others trying to accomplish the same thing.</p>

<p><img src="http://www.justin-credible.net/content/images/2020/12/splash.jpg" alt=""></p>

<p>The gist of it is:</p>

<ul>
<li>Obtain the source for <a href="https://www.libsdl.org/download-2.0.php">SDL2</a> and compile it for the <code>WinRT</code> platform to get a native code <code>SDL2.dll</code> binary</li>
<li>Use <a href="https://github.com/flibitijibibo/SDL2-CS">SDL2-CS</a> wrapper to call into the native SDL2 library from C#</li>
<li>Set the <code>DISABLE_XAML_GENERATED_MAIN</code> compilation flag to prevent the compiler from auto-generating the <code>Main</code> entrypoint</li>
<li>Remove the <code>*.xaml</code> and <code>*.xaml.cs</code> components</li>
<li>Create your own <code>Main</code> which delegates to <code>SDL_WinRTRunApp(mainFunction, IntPtr.Zero)</code></li>
<li>Write your SDL code to render the screen!</li>
</ul>

<p>I've documented this in much more detail in the project <a href="https://github.com/Justin-Credible/xbox-uwp-sdl2-starter/blob/master/README.md">readme</a> on GitHub. I've also created a <a href="https://github.com/Justin-Credible/xbox-uwp-sdl2-starter/releases">pre-packaged starter project</a> which should allow anyone to download, unzip, and open a Visual Studio solution and immediately get started.</p>

<div class="github-widget" data-repo="Justin-Credible/xbox-uwp-sdl2-starter">  
</div>]]></content:encoded></item><item><title><![CDATA[Pac-Man Emulator]]></title><description><![CDATA[<p><img src="http://www.justin-credible.net/content/images/2020/07/pac-man-emulator-collage.png" style="float: right; padding-left: 10px; width: 325px;"></p>

<p>Once I finished up my Intel 8080 CPU core for my <a href="https://www.justin-credible.net/2020/03/31/space-invaders-emulator/">Space Invaders emulator</a>, I wanted to move onto something a bit more challenging. I knew that the Zilog Z80 CPU was a "cousin" to the 8080; it was largely backwards compatible with the 8080, but also contained a superset</p>]]></description><link>http://www.justin-credible.net/2020/08/24/pac-man-emulator/</link><guid isPermaLink="false">742f507f-a988-4142-b958-c00009abf784</guid><category><![CDATA[Emulators]]></category><category><![CDATA[Software Development]]></category><category><![CDATA[Gaming]]></category><dc:creator><![CDATA[Justin Unterreiner]]></dc:creator><pubDate>Mon, 24 Aug 2020 21:18:15 GMT</pubDate><content:encoded><![CDATA[<p><img src="http://www.justin-credible.net/content/images/2020/07/pac-man-emulator-collage.png" style="float: right; padding-left: 10px; width: 325px;"></p>

<p>Once I finished up my Intel 8080 CPU core for my <a href="https://www.justin-credible.net/2020/03/31/space-invaders-emulator/">Space Invaders emulator</a>, I wanted to move onto something a bit more challenging. I knew that the Zilog Z80 CPU was a "cousin" to the 8080; it was largely backwards compatible with the 8080, but also contained a superset of instructions. If I chose to emulate a Z80-based system, I would be able to reuse a large amount of my 8080 core's code.</p>

<p>I looked around for other systems that used the Z80, and there is no shortage!</p>

<ul>
<li>Home computers: ZX Spectrum, TRS-80, MSX, Amstrad CPC</li>
<li>Handhelds: Nintendo Gameboy, Sega GameGear</li>
<li>Arcades: Pac-Man, Rally X, Dig Dug, Galaga</li>
</ul>

<p>This was great news; if I built a Z80 emulation core, I could then reuse it for other projects! I decided to start with something simple and well documented: Pac-Man. An additional bonus was that with minor changes, I would also be able to emulate Ms. Pac-Man; all Ms. Pac-Man boards are just Pac-Man boards with a daughterboard installed to modify the original CPU behavior and swap/patch certain ROMs. The <a href="https://www.polygon.com/2016/3/25/11287572/ms-pac-man-story">story of Ms. Pac-Man</a> it totally worth reading about.</p>

<p><img src="http://www.justin-credible.net/content/images/2020/08/showcase.gif" alt="My emulator running Pac-Man, Ms. Pac-Man, and a homebrew ROM that generates the effect from The Matrix."></p>

<h2 id="zilogz80">Zilog Z80</h2>

<p>I started with a copy of my Space Invaders repository and began stripping out the Space Invaders-specific code. I then got to work implementing the additional instructions present in the Z80. <a href="http://clrhome.org/table/">This site</a> offers an interactive and searchable list of opcodes, which was extremely useful. Also, the 2016 version of the <a href="http://www.zilog.com/force_download.php?filepath=YUhSMGNEb3ZMM2QzZHk1NmFXeHZaeTVqYjIwdlpHOWpjeTk2T0RBdlZVMHdNRGd3TG5Ca1pnPT0=">Z80 CPU User Manual</a> provided a lot of details.</p>

<p>After implementing the additional instructions, it was time to go back and fix areas of the code that I hadn't completely finished for Space Invaders. I hadn't implemented the auxiliary carry flag and a few other opcodes that Space Invaders didn't use. <a href="https://retrocomputing.stackexchange.com/a/1612">This StackOverflow post</a> was a great starting point for identifying the differences between the 8080 and Z80.</p>

<p>This part of the project took the longest; I had to rework all the code that set the flags register. As in the last project, writing unit tests along the way was integral to success.</p>

<p>Also like last time, I was able to verify my Z80 implementation by using a diagnostics program written for the original CPU. The <a href="http://mdfs.net/Software/Z80/Exerciser/">Z80 Instruction Exerciser</a> executes every opcode and then compares checksums of memory to checksums generated on actual hardware. Very cool!</p>

<p>I ended up with over 8000 unit test cases, though many of these were permutations of single tests using every register and/or several different memory location offsets.</p>

<h2 id="video">Video</h2>

<p>The Space Invaders video hardware was dead simple; because the screen was black and white, there was one bit per pixel, and the pixel was either on or off. Memory held the array of pixels, and I just needed to draw them using the SDL library.</p>

<p>There are downsides to this, however. Space Invaders included a dedicated bit shift hardware to make this faster.</p>

<p>Pac-Man is in color, of course, so its video hardware is a bit more advanced. It uses tiles and sprites along with pre-defined color palettes. <a href="https://www.lomont.org/software/games/pacman/PacmanEmulation.pdf">Chris Lomont's Pac-Man Emulation Guide</a> contains a ton of great information on exactly how it works, so I won't recap it all here.</p>

<p>Once I had written the code to draw the tiles, I needed to verify it, but I couldn't yet boot the game. Because the tile drawing code just reads the tile number and palette numbers out of memory, I fired up MAME and got a dump of Pac-Man at a couple of points during the attract screens. I then added this dump to my unit test and visually verified that my code generated a bitmap that matched MAME.</p>

<p>I did something similar to test the sprite hardware; I simply hard-coded the X/Y coordinates and sprite and palette numbers and then ran my render code via a unit test.</p>

<p>You can see the various test results <a href="https://github.com/Justin-Credible/pac-man-emulator/tree/master/emulator.tests/ReferenceData">here</a>.</p>

<p><img src="http://www.justin-credible.net/content/images/2020/08/Screen-Shot-2020-08-01-at-3.39.05-PM.png" alt=""></p>

<h2 id="audio">Audio</h2>

<p>At this point, I was pretty comfortable emulating a CPU and video hardware, but had no idea how audio worked.</p>

<p>For Space Invaders, I opted not to emulate the analog audio hardware, and instead just played back pre-recorded wav files. This worked fine because the audio in Space Invaders is pretty simple.</p>

<p>In Pac-Man, however, the sound is much richer. There are three audio channels for sound effects, and several different music tracks that play during the intermission sequences.</p>

<p>Again, <a href="https://www.lomont.org/software/games/pacman/PacmanEmulation.pdf">Chris Lomont's guide</a> was a key resource. However, although I was able to easily implement the behavior of the audio hardware itself, I was at a loss on how to use the audio sample binary data I had to actually play back the audio.</p>

<p>Some Googling eventually led to the article <a href="https://nicolasallemand.com/2019/12/12/let-there-be-sound/">Let there be sound</a>, which begins with the absolute basics and eventually ends with code showing how to play a simple sine wave.</p>

<p>After some trial and error and a lot of static from the speakers, I was finally greeted with a deafening BOOWHAP coin-up sound scared me out of my seat. Pro tip: turn down your speakers before you try out new audio code. 🤣</p>

<h2 id="debugger">Debugger</h2>

<p>I added upon the interactive debugger from the Space Invaders codebase, which was previously implemented in text-mode inside of a standard console window (e.g. <code>Console.WriteLine</code> and <code>Console.ReadKey</code>). I wanted to make the debugger render inside of an SDL window so that I could have more control over the layout. For example, text can now be rendered in color and single pixels can be plotted. This also makes it easier to implement interactive UI elements, which can be seen in the save and load state menu where the arrows can be used instead of being required to type a full file path.</p>

<div class="photo-gallery">  
    <a href="http://www.justin-credible.net/content/images/2020/11/debugger-main.png" title="" data-width="2784" data-height="2188">
        <img src="http://www.justin-credible.net/content/images/2020/11/debugger-main-thumbnail.png" alt="">
    </a>
    <a href="http://www.justin-credible.net/content/images/2020/11/debugger-load-state.png" title="" data-width="2784" data-height="2188">
        <img src="http://www.justin-credible.net/content/images/2020/11/debugger-load-state-thumbnail.png" alt="">
    </a>
    <a href="http://www.justin-credible.net/content/images/2020/11/debugger-breakpoints.png" title="" data-width="2784" data-height="2188">
        <img src="http://www.justin-credible.net/content/images/2020/11/debugger-breakpoints-thumbnail.png" alt="">
    </a>
    <a href="http://www.justin-credible.net/content/images/2020/11/debugger-history.png" title="" data-width="2784" data-height="2188">
        <img src="http://www.justin-credible.net/content/images/2020/11/debugger-history-thumbnail.png" alt="">
    </a>
</div>

<h2 id="bonusxboxport">Bonus: Xbox Port</h2>

<p>I came back a few months later and decided to try and port my emulator to a console. I already had the emulator up and running on Windows, Linux, and macOS courtesy of the cross-platform <a href="https://dotnet.microsoft.com/">.NET Core</a> runtime, C#, and SDL2. So naturally this was a great fit for a port to the Xbox One via a UWP application.</p>

<p>This led me down a bit of a side-adventure learning about how to get SDL2 running on an Xbox One inside of a UWP app, which was quite interesting. This led to me putting together a <a href="https://github.com/Justin-Credible/xbox-uwp-sdl2-starter">starter project template</a> for anyone else who wants to port their SDL2 application to Xbox.</p>

<iframe width="854" height="480" src="https://www.youtube.com/embed/jirb0GSExoI  
" frameborder="0" allowfullscreen></iframe>

<h2 id="results">Results</h2>

<p>This was an awesome project! It was slightly more challenging than Space Invaders, and taught me the basics of playing audio. With some minor modifications, I was able to run Ms. Pac-Man and <a href="http://umlautllama.com/projects/pacdocs/">homebrew ROMs</a>. With a little more work, I should be able to run other games that run on very similar hardware, such as Rally X and Pengo. And now that I have a fully functioning Z80 core, I can continue on to something more advanced, like the Gameboy!</p>

<p>You can find more details on <a href="https://github.com/Justin-Credible/pac-man-emulator">GitHub</a>. The readme contains a <a href="https://github.com/Justin-Credible/pac-man-emulator#resources">resources</a> section with some links to recommended reading.</p>

<div class="github-widget" data-repo="Justin-Credible/pac-man-emulator">  
</div>]]></content:encoded></item><item><title><![CDATA[Booting up the Quake Arcade Tournament Edition hard drive]]></title><description><![CDATA[<p><img src="http://www.justin-credible.net/content/images/2020/08/cabinet-cropped.png" style="float: right; padding-left: 10px; width: 200px;"></p>

<p>Recently, <a href="https://www.pcgamer.com/the-arcade-version-of-quake-is-finally-playable-on-pc/">news broke</a> that Quake: Arcade Tournament Edition (Quake A.T.E.) had become playable on the PC after GitHub user <a href="https://github.com/mills5">mills5</a> posted a <a href="https://github.com/mills5/quakeat-decrypted">decrypted version</a> of the game's binary executable.</p>

<p>Before I heard this news, I honestly had no idea there was a version of Quake made for the</p>]]></description><link>http://www.justin-credible.net/2020/08/16/booting-up-the-quake-arcade-tournament-edition-hard-drive/</link><guid isPermaLink="false">5e0c0da0-9f13-4914-8e9c-95be7d8558c8</guid><category><![CDATA[Arcade Miscellaneous]]></category><dc:creator><![CDATA[Justin Unterreiner]]></dc:creator><pubDate>Mon, 17 Aug 2020 04:45:46 GMT</pubDate><content:encoded><![CDATA[<p><img src="http://www.justin-credible.net/content/images/2020/08/cabinet-cropped.png" style="float: right; padding-left: 10px; width: 200px;"></p>

<p>Recently, <a href="https://www.pcgamer.com/the-arcade-version-of-quake-is-finally-playable-on-pc/">news broke</a> that Quake: Arcade Tournament Edition (Quake A.T.E.) had become playable on the PC after GitHub user <a href="https://github.com/mills5">mills5</a> posted a <a href="https://github.com/mills5/quakeat-decrypted">decrypted version</a> of the game's binary executable.</p>

<p>Before I heard this news, I honestly had no idea there was a version of Quake made for the arcades! My curiosity was immediately piqued, and I began to look for information about the cabinet.</p>

<p><a href="https://quakearcadetournament.blogspot.com/">This blog</a> has some excellent information, and you should check it out if you're interested in the details (edit: this <a href="https://arstechnica.com/gaming/2020/08/you-can-now-play-an-ultra-rare-quake-arcade-cabinet-at-home/">ArsTechnica article</a> is even better). But the gist is that a company named Lazer-Tron developed an arcade platform known as the <em>Quantum3D Quicksilver Arcade PC</em>, essentially a Pentium II computer with a proprietary I/O card and a 3dfx Voodoo video card.</p>

<p><img src="http://www.justin-credible.net/content/images/2020/08/quake-arcade-marquee.jpg" alt=""></p>

<p>Although a dump of the arcade's hard drive has existed for a while, the game's executable was encrypted and required a security dongle, so nobody has been able to run it. Now that the unencrypted executable is available, the game can be run on modern Windows PCs using the game asset files from the <code>quakeat.chd</code> hard disk image, which comes from MAME.</p>

<p>Here're a couple of recordings I took while running the game on a Windows 7 VM showing the attract mode and service menus.</p>

<iframe width="560" height="315" src="https://www.youtube.com/embed/ZYi6eY26lXo" frameborder="0" allow="accelerometer; autoplay; encrypted-media; gyroscope; picture-in-picture" allowfullscreen></iframe>

<p><br></p>

<iframe width="560" height="315" src="https://www.youtube.com/embed/TvdOBfwOUEk" frameborder="0" allow="accelerometer; autoplay; encrypted-media; gyroscope; picture-in-picture" allowfullscreen></iframe>

<h2 id="bootingthehdd">Booting the HDD</h2>

<p>Although MAME doesn't currently run the game, I was curious to see if I could boot the hard drive image on an x86 virtual machine. After all, it's just a customized version of Windows 95 OSR2. I used MAME's <code>chdman</code> tool to write the image to a virtual disk, which I was then able to mount on a Windows 7 virtual machine.</p>

<p><img src="http://www.justin-credible.net/content/images/2020/08/mount-hdd.png" alt=""></p>

<p>Once I was able to confirm I could mount and read the FAT32 file system, I unmounted the disk and created a new virtual machine on my ESXi server. I attached the disk to the new VM, crossed my fingers, and fired it up. Sure enough, it booted! After a bit of ScanDisk and Add New Hardware wizard action, I was dropped into the Windows 95 desktop!</p>

<p>Below are a list of screenshots I took that show all kinds of interesting details: Quake config files, custom config tools, OS customizations, TweakUI settings, bookkeeping data, and more! A bit of digital archeology, if you will. Fascinating stuff!</p>

<p>Using the decrypted executable to launch the game inside of the VM works, but because the VM currently has a 16-color, generic VGA adapter, you can't see much.</p>

<div class="photo-gallery">  
    <a href="http://www.justin-credible.net/content/images/galleries/quake-arcade-hdd/010.png" title="" data-width="640" data-height="509">
        <img src="http://www.justin-credible.net/content/images/galleries/quake-arcade-hdd/thumbnails/010.jpg" alt="ScanDisk was a little unhappy.">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/quake-arcade-hdd/020.png" title="" data-width="640" data-height="509">
        <img src="http://www.justin-credible.net/content/images/galleries/quake-arcade-hdd/thumbnails/020.jpg" alt="There was a lot of new hardware to detect, since the VM wasn't an exact match for the real hardware.">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/quake-arcade-hdd/030.png" title="" data-width="640" data-height="509">
        <img src="http://www.justin-credible.net/content/images/galleries/quake-arcade-hdd/thumbnails/030.jpg" alt="The encrypted executable won't boot without the security dongle.">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/quake-arcade-hdd/031.png" title="" data-width="640" data-height="509">
        <img src="http://www.justin-credible.net/content/images/galleries/quake-arcade-hdd/thumbnails/031.jpg" alt="The desktop with a cool wallpaper applied.">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/quake-arcade-hdd/032.png" title="" data-width="640" data-height="509">
        <img src="http://www.justin-credible.net/content/images/galleries/quake-arcade-hdd/thumbnails/032.jpg" alt="This is a pretty basic Windows 95 install.">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/quake-arcade-hdd/040.png" title="" data-width="640" data-height="509">
        <img src="http://www.justin-credible.net/content/images/galleries/quake-arcade-hdd/thumbnails/040.jpg" alt="The System Properties modal customized with OEM details.">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/quake-arcade-hdd/050.png" title="" data-width="640" data-height="509">
        <img src="http://www.justin-credible.net/content/images/galleries/quake-arcade-hdd/thumbnails/050.jpg" alt="More OEM details. Hint: Use the Wayback machine to check out the Quantum3d.com website in 1999.">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/quake-arcade-hdd/060.png" title="" data-width="640" data-height="509">
        <img src="http://www.justin-credible.net/content/images/galleries/quake-arcade-hdd/thumbnails/060.jpg" alt="Some handy shortcuts for testing the hardware.">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/quake-arcade-hdd/070.png" title="" data-width="640" data-height="509">
        <img src="http://www.justin-credible.net/content/images/galleries/quake-arcade-hdd/thumbnails/070.jpg" alt="Bummer... I definitely don't have the GCI card. 😅">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/quake-arcade-hdd/080.png" title="" data-width="640" data-height="509">
        <img src="http://www.justin-credible.net/content/images/galleries/quake-arcade-hdd/thumbnails/080.jpg" alt="A configuration utility used to set a Quake config for the cabinet's player color for multiplayer matches.">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/quake-arcade-hdd/090.png" title="" data-width="640" data-height="509">
        <img src="http://www.justin-credible.net/content/images/galleries/quake-arcade-hdd/thumbnails/090.jpg" alt="WOW! I had forgotten all about TweakUI. Apparently it was included.">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/quake-arcade-hdd/100.png" title="" data-width="640" data-height="509">
        <img src="http://www.justin-credible.net/content/images/galleries/quake-arcade-hdd/thumbnails/100.jpg" alt="Someone forgot to take out the trash.">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/quake-arcade-hdd/110.png" title="" data-width="640" data-height="509">
        <img src="http://www.justin-credible.net/content/images/galleries/quake-arcade-hdd/thumbnails/110.jpg" alt="These look like developer configs.">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/quake-arcade-hdd/120.png" title="" data-width="640" data-height="509">
        <img src="http://www.justin-credible.net/content/images/galleries/quake-arcade-hdd/thumbnails/120.jpg" alt="Some custom batch files used to set up each machine.">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/quake-arcade-hdd/130.png" title="" data-width="640" data-height="509">
        <img src="http://www.justin-credible.net/content/images/galleries/quake-arcade-hdd/thumbnails/130.jpg" alt="More Windows customizations.">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/quake-arcade-hdd/140.png" title="" data-width="640" data-height="509">
        <img src="http://www.justin-credible.net/content/images/galleries/quake-arcade-hdd/thumbnails/140.jpg" alt="A customized boot batch file.">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/quake-arcade-hdd/150.png" title="" data-width="640" data-height="509">
        <img src="http://www.justin-credible.net/content/images/galleries/quake-arcade-hdd/thumbnails/150.jpg" alt="I believe the config tool writes to this file to change the player name/color.">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/quake-arcade-hdd/160.png" title="" data-width="640" data-height="509">
        <img src="http://www.justin-credible.net/content/images/galleries/quake-arcade-hdd/thumbnails/160.jpg" alt="Bookkeeping data from 1998!">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/quake-arcade-hdd/170.png" title="" data-width="640" data-height="509">
        <img src="http://www.justin-credible.net/content/images/galleries/quake-arcade-hdd/thumbnails/170.jpg" alt="Quake config; note the list of demos and AVI movies for the attract mode loop.">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/quake-arcade-hdd/179.png" title="" data-width="640" data-height="509">
        <img src="http://www.justin-credible.net/content/images/galleries/quake-arcade-hdd/thumbnails/179.jpg" alt="The driver for the ticket printer.">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/quake-arcade-hdd/180.png" title="" data-width="640" data-height="509">
        <img src="http://www.justin-credible.net/content/images/galleries/quake-arcade-hdd/thumbnails/180.jpg" alt="The footer content for the tickets the machine printed.">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/quake-arcade-hdd/190.png" title="" data-width="640" data-height="509">
        <img src="http://www.justin-credible.net/content/images/galleries/quake-arcade-hdd/thumbnails/190.jpg" alt="The header content for the tickets the machine printed.">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/quake-arcade-hdd/200.png" title="" data-width="640" data-height="509">
        <img src="http://www.justin-credible.net/content/images/galleries/quake-arcade-hdd/thumbnails/200.jpg" alt="Ah yes, time to safely shut down.">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/quake-arcade-hdd/210.png" title="" data-width="640" data-height="509">
        <img src="http://www.justin-credible.net/content/images/galleries/quake-arcade-hdd/thumbnails/210.jpg" alt="I haven't seen this shutdown screen in ages.">
    </a>
</div>]]></content:encoded></item><item><title><![CDATA[Multicade]]></title><description><![CDATA[<p><img src="http://www.justin-credible.net/content/images/2020/07/cropped-small.png" style="float: right; padding-left: 10px;"></p>

<p>Even though I grew up with 90's style arcade cabinets, I've always had a soft spot for the "golden age"-era Midway cabinets, which housed games like Galaga, Galaxian, and Pac-Man. When a Ms. Pac-Man cabinet popped up on Craigslist, I jumped at the opportunity to pick it up.</p>

<p>Once</p>]]></description><link>http://www.justin-credible.net/2020/07/26/multicade/</link><guid isPermaLink="false">fafeb65f-4710-4993-90a1-23fb7996b216</guid><category><![CDATA[Arcade Restoration]]></category><dc:creator><![CDATA[Justin Unterreiner]]></dc:creator><pubDate>Sun, 26 Jul 2020 18:59:54 GMT</pubDate><content:encoded><![CDATA[<p><img src="http://www.justin-credible.net/content/images/2020/07/cropped-small.png" style="float: right; padding-left: 10px;"></p>

<p>Even though I grew up with 90's style arcade cabinets, I've always had a soft spot for the "golden age"-era Midway cabinets, which housed games like Galaga, Galaxian, and Pac-Man. When a Ms. Pac-Man cabinet popped up on Craigslist, I jumped at the opportunity to pick it up.</p>

<p>Once I saw the cabinet in person, I noticed several things that indicated it wasn't, in fact, an original Ms. Pac-Man cabinet. The most obvious were the Pac-Man bezel and control panel; someone had painted over the original artwork with the signature blue color and added a Ms. Pac-Man marquee. The signature almost-square Midway coin door had been replaced with an over-under coin door. To accommodate the size of this different coin door, an additional piece of 3/4" plywood had been placed over the front. The cabinet had also seen a bit of water damage, and had extra reinforcements inside and on the base.</p>

<p>Originally, I was planning to restore the cabinet as a Ms. Pac-Man, which has one of my most favorite art designs. However, a few months later I was able to score an original Ms. Pac-Man cocktail cabinet, so there was no point in having two Ms. Pacs.</p>

<div class="photo-gallery">  
    <a href="http://www.justin-credible.net/content/images/galleries/multicade/009.jpg" title="" data-width="2048" data-height="1536">
        <img src="http://www.justin-credible.net/content/images/galleries/multicade/thumbnails/009.jpg" alt="It's a tight fit, but I've found that I can transport Midway cabs in the SUV. :D">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/multicade/010.jpg" title="" data-width="1536" data-height="2048">
        <img src="http://www.justin-credible.net/content/images/galleries/multicade/thumbnails/010.jpg" alt="It's hard to tell from the sunlight, but the sides are splattered with unknown gunk.">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/multicade/020.jpg" title="" data-width="1536" data-height="2048">
        <img src="http://www.justin-credible.net/content/images/galleries/multicade/thumbnails/020.jpg" alt="Dust, dust, and more dust!">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/multicade/040.jpg" title="" data-width="1536" data-height="2048">
        <img src="http://www.justin-credible.net/content/images/galleries/multicade/thumbnails/040.jpg" alt="There was literally a rats' nest in here... 🤮">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/multicade/050.jpg" title="" data-width="2048" data-height="1536">
        <img src="http://www.justin-credible.net/content/images/galleries/multicade/thumbnails/050.jpg" alt="Covered in grime. 😵">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/multicade/060.jpg" title="" data-width="1536" data-height="2048">
        <img src="http://www.justin-credible.net/content/images/galleries/multicade/thumbnails/060.jpg" alt="The coin door from the inside; here you can see how the outer plywood piece holds the over/under coin door, which wasn't as wide as the stock Midway coin door. 😬">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/multicade/070.jpg" title="" data-width="2048" data-height="1536">
        <img src="http://www.justin-credible.net/content/images/galleries/multicade/thumbnails/070.jpg" alt="The extra plywood on the front for the coin door; I ended up leaving it since it's providing most of the structural integrity. 😩">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/multicade/080.jpg" title="" data-width="1536" data-height="2048">
        <img src="http://www.justin-credible.net/content/images/galleries/multicade/thumbnails/080.jpg" alt="Whoever installed this T-molding ran out and started using 2&quot;-3&quot; strips! 😳">
    </a>
</div>

<p>The 3/4" plywood that had been slapped on front had to stay. It would have been difficult to remove, and given the water damage, it was also probably a makeshift reinforcement for the cabinet body. For the next few months, the cabinet sat in my garage, and then I stumbled upon an awesome <a href="https://www.phoenixarcade.com/products/multicade-arcade-classics/multicade-arcade-art-kit">Multicade artwork package</a> by <a href="https://www.phoenixarcade.com/">Phoenix Arcade</a>. I've never been a fan of Multicade art designs before; they always have a weird mix of modern and retro character designs and artwork, and they just don't look quite right to me. This art set, however, was perfect: exclusively original character artwork and pixel art with an 80's Tron aesthetic, and UV reactive to boot! After finding this, I decided to restore the cabinet as a Multicade.</p>

<h2 id="cabinetprep">Cabinet Prep</h2>

<p>As always, I started by stripping down and removing all parts. This didn't take too long because the machine had already been mostly stripped; it had no CRT, PCB, or power supply. What was left inside was a rats' nest, figuratively and literally! That was pretty gross, and required a lot of cleaning. The bottom of the cabinet still looks a little dirty due to the water damage, but it's better than before. Next came general clean-up and sanding down the surfaces. Once everything was relatively clean and smoothed, I began to fix chipped areas with wood filler.</p>

<div class="photo-gallery">  
    <a href="http://www.justin-credible.net/content/images/galleries/multicade/090.jpg" title="" data-width="1536" data-height="2048">
        <img src="http://www.justin-credible.net/content/images/galleries/multicade/thumbnails/090.jpg" alt="After sanding and patching holes.">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/multicade/100.jpg" title="" data-width="1536" data-height="2048">
        <img src="http://www.justin-credible.net/content/images/galleries/multicade/thumbnails/100.jpg" alt="After sanding and patching holes.">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/multicade/110.jpg" title="" data-width="2048" data-height="1536">
        <img src="http://www.justin-credible.net/content/images/galleries/multicade/thumbnails/110.jpg" alt="Sanding the inside areas.">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/multicade/120.jpg" title="" data-width="1536" data-height="2048">
        <img src="http://www.justin-credible.net/content/images/galleries/multicade/thumbnails/120.jpg" alt="After sanding and patching holes.">
    </a>
</div>

<p>As this point I agonized over the color for the cabinet body. I wanted something to match the artwork well, but not take away from it when lit by UV light. I knew I wanted something darker, but definitely not straight black. I eventually decided on the color <a href="https://www.lowes.com/pd/HGTV-HOME-by-Sherwin-Williams-Blue-Midnight-Interior-Paint-Sample-Actual-Net-Contents-8-fl-oz/1000954136">Midnight Blue</a> in an enamel base. It turned out wonderful; it meshes well with the background and secondary blue colors in the artwork, but isn't overbearing.</p>

<div class="photo-gallery">  
    <a href="http://www.justin-credible.net/content/images/galleries/multicade/130.jpg" title="" data-width="1536" data-height="2048">
        <img src="http://www.justin-credible.net/content/images/galleries/multicade/thumbnails/130.jpg" alt="Applying the side art after the paint had dried.">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/multicade/140.jpg" title="" data-width="1536" data-height="2048">
        <img src="http://www.justin-credible.net/content/images/galleries/multicade/thumbnails/140.jpg" alt="Applying the side art after the paint had dried.">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/multicade/150.jpg" title="" data-width="1536" data-height="2048">
        <img src="http://www.justin-credible.net/content/images/galleries/multicade/thumbnails/150.jpg" alt="Side art applied!">
    </a>
</div>

<p>The coin door needed a little work. I went with my go-to <a href="https://www.lowes.com/pd/Rust-Oleum-Professional-Flat-Black-Spray-Paint-Actual-Net-Contents-15-oz/3729781">Rust-oleum enamel</a> black spray paint for the body. The coin mechs were also totally seized up, so needed to be completely disassembled and cleaned.</p>

<div class="photo-gallery">  
    <a href="http://www.justin-credible.net/content/images/galleries/multicade/160.jpg" title="" data-width="1536" data-height="2048">
        <img src="http://www.justin-credible.net/content/images/galleries/multicade/thumbnails/160.jpg" alt="The coin door needed a little work.">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/multicade/170.jpg" title="" data-width="1536" data-height="2048">
        <img src="http://www.justin-credible.net/content/images/galleries/multicade/thumbnails/170.jpg" alt="Here I've stripped the parts before re-painting.">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/multicade/180.jpg" title="" data-width="2048" data-height="1536">
        <img src="http://www.justin-credible.net/content/images/galleries/multicade/thumbnails/180.jpg" alt="Cleaning out the coin mechs.">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/multicade/181.jpg" title="" data-width="1536" data-height="2048">
        <img src="http://www.justin-credible.net/content/images/galleries/multicade/thumbnails/181.jpg" alt="Coin door reinstalled after painting and reassembly--lookin' sharp! ✨">
    </a>
</div>

<h2 id="controlpanel">Control Panel</h2>

<p>The Phoenix Arcade Multicade package included a nice <a href="https://www.phoenixarcade.com/products/multicade-arcade-classics/multicade-arcade-classics-metal-panel">metal control panel</a> that is an exact fit for Midway cabinets. It includes precut holes for a joystick, three action buttons, a trackball, and two player start buttons. I ended up making custom plywood inserts for the underside so I could utilize the cabinet's original latches and pegs to hold the control panel in place.</p>

<div class="photo-gallery">  
    <a href="http://www.justin-credible.net/content/images/galleries/multicade/190.jpg" title="" data-width="2048" data-height="1536">
        <img src="http://www.justin-credible.net/content/images/galleries/multicade/thumbnails/190.jpg" alt="The metal CPO from Phoenix Arcade.">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/multicade/191.jpg" title="" data-width="2048" data-height="1536">
        <img src="http://www.justin-credible.net/content/images/galleries/multicade/thumbnails/191.jpg" alt="The plywood pieces I cut to go under the metal CPO. On the left is the original CPO, which I took measurements from.">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/multicade/192.jpg" title="" data-width="2048" data-height="1536">
        <img src="http://www.justin-credible.net/content/images/galleries/multicade/thumbnails/192.jpg" alt="Test-fitting the plywood pieces.">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/multicade/193.jpg" title="" data-width="1536" data-height="2048">
        <img src="http://www.justin-credible.net/content/images/galleries/multicade/thumbnails/193.jpg" alt="Sketching out where the controls would go. ✏️">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/multicade/194.jpg" title="" data-width="2048" data-height="1536">
        <img src="http://www.justin-credible.net/content/images/galleries/multicade/thumbnails/194.jpg" alt="Getting ready to cut the holes for the controls.">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/multicade/195.mp4" title="" data-width="1536" data-height="2048">
        <img src="http://www.justin-credible.net/content/images/galleries/multicade/thumbnails/195.jpg" alt="Using the drill press to cut the joystick hole. So satisfying! 🗜">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/multicade/196.jpg" title="" data-width="2048" data-height="1536">
        <img src="http://www.justin-credible.net/content/images/galleries/multicade/thumbnails/196.jpg" alt="All cuts done, including the trackball cut-out!">
    </a>
</div>

<p>The Multicade package also included CPO overlay graphics matching the rest of the artwork.</p>

<p>All the new controls use leaf switches, which I've come to prefer over microswitches for their quietness and "softer" feel, which matches the feel of cabinets from that era.</p>

<p>The joystick is a <a href="http://www.arcadeshop.com/i/1538/wico-4-way-red-ball-3.5-handle-leaf-joystick.htm">Wico 4-Way</a> with a <a href="http://www.arcadeshop.com/i/1553/wico-3.5-yellow-ball-joystick-handle.htm">yellow ball top</a>. The trackball is the <a href="http://www.arcadeshop.com/i/19/2-trackball-unit-white-ball-atari-happ.htm">2¼" Atari/Happ unit</a>. All of these parts are from <a href="http://www.arcadeshop.com/">ArcadeShop</a>.</p>

<p>The action buttons are the <a href="https://groovygamegear.com/webstore/index.php?main_page=product_info&amp;cPath=73&amp;products_id=360">CLASSX True-Leaf Pro</a> line from <a href="https://groovygamegear.com/">GroovyGameGear</a>.</p>

<p>The game board I planned to use would support blinking start buttons, so I got two of the <a href="https://groovygamegear.com/webstore/index.php?main_page=product_info&amp;cPath=73&amp;products_id=238">Electric ICE 2 pushbuttons</a>, again from <a href="https://groovygamegear.com/">GroovyGameGear</a>. When enough credits are deposited, the 1 player or 2 player buttons blink!</p>

<div class="photo-gallery">  
    <a href="http://www.justin-credible.net/content/images/galleries/multicade/197.jpg" title="" data-width="1536" data-height="2048">
        <img src="http://www.justin-credible.net/content/images/galleries/multicade/thumbnails/197.jpg" alt="Test-fitting the controls.">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/multicade/198.jpg" title="" data-width="2048" data-height="1536">
        <img src="http://www.justin-credible.net/content/images/galleries/multicade/thumbnails/198.jpg" alt="Aligning the CPO graphics.">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/multicade/199.jpg" title="" data-width="2048" data-height="1536">
        <img src="http://www.justin-credible.net/content/images/galleries/multicade/thumbnails/199.jpg" alt="CPO graphics installed-- nice!">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/multicade/200.jpg" title="" data-width="2048" data-height="1536">
        <img src="http://www.justin-credible.net/content/images/galleries/multicade/thumbnails/200.jpg" alt="I love me some leaf switches. 💚">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/multicade/201.jpg" title="" data-width="2048" data-height="1536">
        <img src="http://www.justin-credible.net/content/images/galleries/multicade/thumbnails/201.jpg" alt="Front view with all controls in place.">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/multicade/202.jpg" title="" data-width="1536" data-height="2048">
        <img src="http://www.justin-credible.net/content/images/galleries/multicade/thumbnails/202.jpg" alt="Wiring up the controls.">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/multicade/203.jpg" title="" data-width="2048" data-height="1536">
        <img src="http://www.justin-credible.net/content/images/galleries/multicade/thumbnails/203.jpg" alt="The wiring after some much-needed cable management.">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/multicade/204.jpg" title="" data-width="2048" data-height="1536">
        <img src="http://www.justin-credible.net/content/images/galleries/multicade/thumbnails/204.jpg" alt="Fits like a glove! 😍">
    </a>
</div>

<h2 id="marqueeandtmolding">Marquee and T-Molding</h2>

<p>The Phoenix Arcade Multicade package included a <a href="https://www.phoenixarcade.com/products/multicade-arcade-classics/multicade-arcade-classics-marquee">UV reactive marquee</a>, so I decided to throw in two blacklight bulbs instead of regular bulbs. Although it's not very noticeable in daylight, it lights up great at night.</p>

<p>In keeping with the UV reactive theme, I chose green UV reactive T-molding from <a href="http://www.arcadeshop.com/">ArcadeShop</a>. I think I would have preferred white T-molding, but I couldn't find any that was UV reactive. It does look great under a blacklight.</p>

<div class="photo-gallery">  
    <a href="http://www.justin-credible.net/content/images/galleries/multicade/209.jpg" title="" data-width="2048" data-height="1536">
        <img src="http://www.justin-credible.net/content/images/galleries/multicade/thumbnails/209.jpg" alt="I have no idea where I got these blacklight bulbs; apparently I was saving them for this very day! 🎉">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/multicade/210.jpg" title="" data-width="2048" data-height="1536">
        <img src="http://www.justin-credible.net/content/images/galleries/multicade/thumbnails/210.jpg" alt="The roll of UV reactive T-molding.">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/multicade/220.jpg" title="" data-width="1536" data-height="2048">
        <img src="http://www.justin-credible.net/content/images/galleries/multicade/thumbnails/220.jpg" alt="Installing T-molding is so satisfying. 💚">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/multicade/230.jpg" title="" data-width="2048" data-height="1536">
        <img src="http://www.justin-credible.net/content/images/galleries/multicade/thumbnails/230.jpg" alt="Marquee and T-molding in place. ✨">
    </a>
</div>

<h2 id="monitor">Monitor</h2>

<p>I had been saving one last <a href="https://en.wikipedia.org/wiki/New_old_stock">NOS</a> CRT for this project. A couple years ago, I was lucky enough to find three new-in-box 21" NOS CRTs (<a href="http://www.weiya.com.tw/products_detail.asp?le=english&amp;fid=70&amp;pid=71&amp;tCatName=">WEI-YA M2621H</a>) on eBay. I used one in my <a href="https://www.justin-credible.net/2019/03/28/multi-williams/">Multi-Williams</a> cabinet and another in my <a href="https://www.justin-credible.net/2015/12/30/galaxian/#2020-update">Galaxian</a>, and this was the last of the three.</p>

<p>I couldn't be happier with these monitors. My only regret is that I didn't order a couple more! The colors are fantastic, and the onboard isolation transformer means that I don't need a large "power board" at the bottom of the cabinet.</p>

<p>I built a custom monitor mount from plywood, identical to the one I made for my Galaxian cabinet, and a custom bezel mask from <a href="https://www.michaels.com/strathmore-400-series-presentation-board/10450295.html">presentation board</a> from <a href="https://www.michaels.com/">Michaels</a>.</p>

<div class="photo-gallery">  
    <a href="http://www.justin-credible.net/content/images/galleries/multicade/240.jpg" title="" data-width="1536" data-height="2048">
        <img src="http://www.justin-credible.net/content/images/galleries/multicade/thumbnails/240.jpg" alt="Here I used a plywood project board, same as my Galaxian cabinet, to create a mounting frame.">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/multicade/250.jpg" title="" data-width="1536" data-height="2048">
        <img src="http://www.justin-credible.net/content/images/galleries/multicade/thumbnails/250.jpg" alt="It's a tight fit, with less than a quarter inch from the monitor frame to the back panel. 😅">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/multicade/260.jpg" title="" data-width="2048" data-height="1536">
        <img src="http://www.justin-credible.net/content/images/galleries/multicade/thumbnails/260.jpg" alt="Preparing to create a bezel mask.">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/multicade/270.jpg" title="" data-width="2048" data-height="1536">
        <img src="http://www.justin-credible.net/content/images/galleries/multicade/thumbnails/270.jpg" alt="When you make your own, you know it will fit the tube perfectly!">
    </a>
<!--  
    <a href="/content/images/galleries/multicade/280.jpg" title="" data-width="1536" data-height="2048">
        <img src="/content/images/galleries/multicade/thumbnails/280.jpg" alt=""/>
    </a>
-->
    <a href="http://www.justin-credible.net/content/images/galleries/multicade/281.mp4" title="" data-width="1536" data-height="2048">
        <img src="http://www.justin-credible.net/content/images/galleries/multicade/thumbnails/281.jpg" alt="It's not everyday you get to pull the factory plastic off a brand-new CRT. 🤩">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/multicade/290.jpg" title="" data-width="1536" data-height="2048">
        <img src="http://www.justin-credible.net/content/images/galleries/multicade/thumbnails/290.jpg" alt="Bezel mask looks good!">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/multicade/300.jpg" title="" data-width="2048" data-height="1536">
        <img src="http://www.justin-credible.net/content/images/galleries/multicade/thumbnails/300.jpg" alt="Now for the plexiglass bezel...">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/multicade/310.jpg" title="" data-width="1536" data-height="2048">
        <img src="http://www.justin-credible.net/content/images/galleries/multicade/thumbnails/310.jpg" alt="Almost done!">
    </a>
</div>

<h2 id="gameboard">Game Board</h2>

<p>I knew I didn't want to go with a generic 60-in-1 board, nor a Raspberry Pi or MAME setup. I've tried both in the past and I still prefer native hardware. In this case I found a good trade-off: the <a href="https://www.phoenixarcade.com/product-category/arcadesd">ArcadeSD board</a>.</p>

<p>Although this is an emulation board, it is best in class and far better than the 60-in-1's I've tried in the past. This board does have an FPGA on board, but I believe it's only used for generating the video signal.</p>

<p>The board can run around 90 games, though I pruned the list for this cabinet down to about 30 of my favorites. It also supports several trackball games, including Missile Command, Centipede, Liberator, Arkanoid, and Crystal Castles.</p>

<p>Another unique feature of this board is its ability to run a few <em>horizontal</em> games on a <em>vertical</em> screen, such as Mario Bros., Super Mario Bros. VS, Excitebike, Missile Command, and Tapper. A full list of games is available <a href="https://www.phoenixarcade.com/sites/default/files/arcadesd_gamelist2016.pdf">here</a>.</p>

<p>The menu system is best in class as well, with beautiful game logos and screenshots or icons. I can't recommend this board enough.</p>

<div class="photo-gallery">  
    <a href="http://www.justin-credible.net/content/images/galleries/multicade/320.jpg" title="" data-width="2048" data-height="1536">
        <img src="http://www.justin-credible.net/content/images/galleries/multicade/thumbnails/320.jpg" alt="The ArcadeSD PCB. I love this thing! ⚡️">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/multicade/321.mp4" title="" data-width="1536" data-height="2048">
        <img src="http://www.justin-credible.net/content/images/galleries/multicade/thumbnails/321.jpg" alt="The attract mode menu cycling through games. Both start buttons are blinking because I put in enough credits for 2 players.">
    </a>
</div>

<p>For wiring, the <a href="http://www.arcadeshop.com/i/517/multicade-upright-harness-js-tb.htm">JAMMA harness I wanted to use</a> was out of stock, and I was impatient, so I went with a cheap/generic JAMMA harness. I can tell you that I will never skimp on a harness again. The one I got was super short, poorly soldered (wires came off of the connector a couple times), and used an insufficient wire gauge for the 5V lines. Lesson learned: if you're spending under 30 bucks for a JAMMA harness, you're gonna have a bad time. Stick with the ones in the $50+ range and you'll be much happier. In the end I got it working, but it took many hours of re-soldering and troubleshooting.</p>

<p>For power, I went with my standby: the <a href="http://www.arcadeshop.com/i/806/switching-power-supply-20-amp.htm">HAPP Pro</a> from <a href="http://www.arcadeshop.com/">ArcadeShop</a>. I like this power supply because it has an AC outlet for the CRT and remote power switch capability, which I use to power the machine on/off via a <a href="https://en.wikipedia.org/wiki/Switch#Contact_terminology">DPST toggle switch</a> on the top of the cabinet.</p>

<div class="photo-gallery">  
    <a href="http://www.justin-credible.net/content/images/galleries/multicade/330.jpg" title="" data-width="1536" data-height="2048">
        <img src="http://www.justin-credible.net/content/images/galleries/multicade/thumbnails/330.jpg" alt="Wiring it all up on the workbench.">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/multicade/340.jpg" title="" data-width="2048" data-height="1536">
        <img src="http://www.justin-credible.net/content/images/galleries/multicade/thumbnails/340.jpg" alt="Wiring in the cabinet.">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/multicade/350.jpg" title="" data-width="1536" data-height="2048">
        <img src="http://www.justin-credible.net/content/images/galleries/multicade/thumbnails/350.jpg" alt="The power supply.">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/multicade/351.jpg" title="" data-width="2048" data-height="1536">
        <img src="http://www.justin-credible.net/content/images/galleries/multicade/thumbnails/351.jpg" alt="Wiring the DPST toggle switch.">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/multicade/352.jpg" title="" data-width="2048" data-height="1536">
        <img src="http://www.justin-credible.net/content/images/galleries/multicade/thumbnails/352.jpg" alt="Wiring the DPST toggle switch.">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/multicade/353.jpg" title="" data-width="2048" data-height="1536">
        <img src="http://www.justin-credible.net/content/images/galleries/multicade/thumbnails/353.jpg" alt="The toggle switch seen from the top of the cabinet.">
    </a>
</div>

<h2 id="endresult">End Result</h2>

<p>Like every project I finish, this is my new favorite! It looks great under the blacklights in the game room. I love the artwork! The game line-up is awesome! It has blinking start buttons! It can play trackball games! I love it!!!</p>

<div class="photo-gallery">  
    <a href="http://www.justin-credible.net/content/images/galleries/multicade/360.jpg" title="" data-width="1536" data-height="2048">
        <img src="http://www.justin-credible.net/content/images/galleries/multicade/thumbnails/360.jpg" alt="">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/multicade/370.jpg" title="" data-width="1536" data-height="2048">
        <img src="http://www.justin-credible.net/content/images/galleries/multicade/thumbnails/370.jpg" alt="">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/multicade/380.jpg" title="" data-width="2048" data-height="1536">
        <img src="http://www.justin-credible.net/content/images/galleries/multicade/thumbnails/380.jpg" alt="">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/multicade/390.jpg" title="" data-width="1536" data-height="2048">
        <img src="http://www.justin-credible.net/content/images/galleries/multicade/thumbnails/390.jpg" alt="">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/multicade/400.jpg" title="" data-width="1536" data-height="2048">
        <img src="http://www.justin-credible.net/content/images/galleries/multicade/thumbnails/400.jpg" alt="">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/multicade/410.jpg" title="" data-width="2048" data-height="1536">
        <img src="http://www.justin-credible.net/content/images/galleries/multicade/thumbnails/410.jpg" alt="">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/multicade/420.jpg" title="" data-width="1536" data-height="2048">
        <img src="http://www.justin-credible.net/content/images/galleries/multicade/thumbnails/420.jpg" alt="">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/multicade/430.jpg" title="" data-width="2048" data-height="1536">
        <img src="http://www.justin-credible.net/content/images/galleries/multicade/thumbnails/430.jpg" alt="">
    </a>
</div>]]></content:encoded></item><item><title><![CDATA[Galaxian: AC to DC Modification]]></title><description><![CDATA[<p><img src="http://www.justin-credible.net/content/images/2020/05/galaxian-player-icon.png" style="float: right; width: 150px; padding-left: 20px; padding-bottom: 10px;"></p>

<p>I'm working on converting my <a href="http://www.justin-credible.net/2015/12/30/galaxian/">Galaxian</a> MAME cabinet back into an OG cabinet with an original PCB and CRT. In this cabinet, I will be using a JAMMA switcher to switch between Galaxian and Galaga.</p>

<p>An original Galaxian board expects to receive 7 volts AC and has hardware on the</p>]]></description><link>http://www.justin-credible.net/2020/05/17/galaxian-ac-to-dc-modification/</link><guid isPermaLink="false">79c0dd85-15c3-40ab-84c8-c9be51db530f</guid><category><![CDATA[Arcade Miscellaneous]]></category><dc:creator><![CDATA[Justin Unterreiner]]></dc:creator><pubDate>Mon, 18 May 2020 02:50:08 GMT</pubDate><content:encoded><![CDATA[<p><img src="http://www.justin-credible.net/content/images/2020/05/galaxian-player-icon.png" style="float: right; width: 150px; padding-left: 20px; padding-bottom: 10px;"></p>

<p>I'm working on converting my <a href="http://www.justin-credible.net/2015/12/30/galaxian/">Galaxian</a> MAME cabinet back into an OG cabinet with an original PCB and CRT. In this cabinet, I will be using a JAMMA switcher to switch between Galaxian and Galaga.</p>

<p>An original Galaxian board expects to receive 7 volts AC and has hardware on the PCB to convert this into 5 volts DC. However, since I am using a JAMMA harness and power supply with my JAMMA switcher, I have 5 volts DC supplied by a switching power supply. To allow the Galaxian board to work with my JAMMA setup, I needed to modify my Galaxian PCB to accept 5 volts DC directly.</p>

<p>Paul Swan has written an excellent guide on how to accomplish this, which can be found on the internet in several locations, including <a href="http://www.mikesarcade.com/cgi-bin/spies.cgi?action=url&amp;type=conv&amp;page=GalaxianToJAMMA.txt">Mike's Arcade</a>, <a href="http://www.macros-arcade.com/galjamm2.htm">Marco's Arcade</a>, and the <a href="http://www.ukvac.com/forum/tut-how-to-dc-mod-a-pacman-pcb_topic343979.html">UK VAC forums</a>.</p>

<p>However, as of this post, none of those sources include pictures. The instructions are straightforward, but when you have a vintage PCB in your possession and are about to take a soldering iron to it, it's a bit more comforting to have some pictures to confirm you're following the steps correctly. I put this post together to provide some pictures for reference.</p>

<p>Again, I didn't write these instructions, but I can confirm they work. If you want more information on the mechanics, the aforementioned <a href="http://www.ukvac.com/forum/tut-how-to-dc-mod-a-pacman-pcb_topic343979.html">UK VAC forums</a> post goes into more detail.</p>

<p>With that...let's get started! To perform this modification you'll need:</p>

<ul>
<li>Wire cutters</li>
<li>Wire (solid, not stranded)</li>
<li>Soldering iron</li>
<li>Solder</li>
</ul>

<p>Here is a list of the components you'll need to remove from the board using the wire cutters. A few of the components will need to be replaced with a jumper wire. In addition to part number, the board quadrant is also listed for each part below.</p>

<style>  
.parts {
    margin-top: 10px;
    margin-bottom: 10px;
    width: 100%;
}

.parts thead {
    font-weight: bold;
}

.parts tr:nth-child(even),
.parts thead {
    background-color: #f2f2f2;
}
</style>

<table class="parts">  
    <thead>
        <tr>
            <td>ID</td>
            <td>Part</td>
            <td>Action</td>
        </tr><tr>
    </tr></thead>
    <tbody>
        <tr>
            <td>IR1</td>
            <td>78GU I.C.</td>
            <td>Remove</td>
        </tr>
        <tr>
            <td>IR2</td>
            <td>D44VM4 transistor</td>
            <td>Remove</td>
        </tr>
        <tr>
            <td>R87</td>
            <td>4 Ohm 10W resistor</td>
            <td>Remove and replace with wire</td>
        </tr>
        <tr>
            <td>R88</td>
            <td>50 Ohm 5W resistor</td>
            <td>Remove</td>
        </tr>
        <tr>
            <td>D4</td>
            <td>A15F diode</td>
            <td>Remove and replace with wire</td>
        </tr>
        <tr>
            <td>D5</td>
            <td>A15F diode</td>
            <td>Remove and replace with wire</td>
        </tr>
        <tr>
            <td>D6</td>
            <td>A14F diode</td>
            <td>Remove and replace with wire</td>
        </tr>
        <tr>
            <td>D7</td>
            <td>A14F diode</td>
            <td>Remove and replace with wire</td>
        </tr>
    </tbody>
</table>

<p>Finally, you may need a wire link between the edge connector pair 5,E to 4,D. I did not need this connector because the <a href="http://pcbjunkie.net/index.php/jamma-adapters/namco-galaxian-to-jamma-adapter/">JAMMA adapter I used</a> already bridged these connections.</p>

<p>On to the pictures! The third picture is annotated with each of the part IDs.</p>

<div class="photo-gallery">  
    <a href="http://www.justin-credible.net/content/images/galleries/galaxian-ac-dc-mod/10.jpg" title="" data-width="2048" data-height="1536">
        <img src="http://www.justin-credible.net/content/images/galleries/galaxian-ac-dc-mod/thumbnails/10.jpg" alt="Getting ready for PCB surgery!">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/galaxian-ac-dc-mod/20.jpg" title="" data-width="2048" data-height="1536">
        <img src="http://www.justin-credible.net/content/images/galleries/galaxian-ac-dc-mod/thumbnails/20.jpg" alt="The area of the PCB we'll be modding.">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/galaxian-ac-dc-mod/21.jpg" title="" data-width="2048" data-height="1536">
        <img src="http://www.justin-credible.net/content/images/galleries/galaxian-ac-dc-mod/thumbnails/21.jpg" alt="Each of the components we'll be removing.">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/galaxian-ac-dc-mod/30.jpg" title="" data-width="2048" data-height="1536">
        <img src="http://www.justin-credible.net/content/images/galleries/galaxian-ac-dc-mod/thumbnails/30.jpg" alt="After removing the components in question.">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/galaxian-ac-dc-mod/40.jpg" title="" data-width="2048" data-height="1536">
        <img src="http://www.justin-credible.net/content/images/galleries/galaxian-ac-dc-mod/thumbnails/40.jpg" alt="The components that were removed.">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/galaxian-ac-dc-mod/50.jpg" title="" data-width="2048" data-height="1536">
        <img src="http://www.justin-credible.net/content/images/galleries/galaxian-ac-dc-mod/thumbnails/50.jpg" alt="After replacing the five components with wire links.">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/galaxian-ac-dc-mod/60.jpg" title="" data-width="2048" data-height="1536">
        <img src="http://www.justin-credible.net/content/images/galleries/galaxian-ac-dc-mod/thumbnails/60.jpg" alt="Testing the board; connecting to the JAMMA adapter.">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/galaxian-ac-dc-mod/70.jpg" title="" data-width="2048" data-height="1536">
        <img src="http://www.justin-credible.net/content/images/galleries/galaxian-ac-dc-mod/thumbnails/70.jpg" alt="Testing the board; connecting the JAMMA adapter to the JAMMA SuperGun.">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/galaxian-ac-dc-mod/80.jpg" title="" data-width="1536" data-height="2048">
        <img src="http://www.justin-credible.net/content/images/galleries/galaxian-ac-dc-mod/thumbnails/80.jpg" alt="Success! Notice the Galaxian attract screen on the LCD in the background.">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/galaxian-ac-dc-mod/90.jpg" title="" data-width="2048" data-height="1536">
        <img src="http://www.justin-credible.net/content/images/galleries/galaxian-ac-dc-mod/thumbnails/90.jpg" alt="The modded PCB installed in the cabinet and connected to the JAMMA switcher along with a Galaga PCB.">
    </a>
</div>]]></content:encoded></item><item><title><![CDATA[Space Invaders Emulator]]></title><description><![CDATA[<p><img src="http://www.justin-credible.net/content/images/2020/03/collage.png" style="float: right; padding-left: 10px; width: 325px;"></p>

<p>I really enjoyed the process of building my <a href="https://www.justin-credible.net/2019/09/03/chip-8-emulator/">CHIP-8 emulator</a>, so after I finished I immediately started looking for another emulator project.</p>

<p>The general consensus on <a href="https://www.reddit.com/r/EmuDev/">r/emudev</a> and the <a href="http://www.emutalk.net/forums/30-Emulator-Programming">EmuTalk Forums</a> seemed to point to the 1978 arcade game: <em>Space Invaders</em>. This was perfect for me since it also</p>]]></description><link>http://www.justin-credible.net/2020/03/31/space-invaders-emulator/</link><guid isPermaLink="false">ad229ee2-7474-4972-94c6-edec9ca53427</guid><category><![CDATA[Software Development]]></category><category><![CDATA[Emulators]]></category><category><![CDATA[Gaming]]></category><dc:creator><![CDATA[Justin Unterreiner]]></dc:creator><pubDate>Wed, 01 Apr 2020 00:41:25 GMT</pubDate><content:encoded><![CDATA[<p><img src="http://www.justin-credible.net/content/images/2020/03/collage.png" style="float: right; padding-left: 10px; width: 325px;"></p>

<p>I really enjoyed the process of building my <a href="https://www.justin-credible.net/2019/09/03/chip-8-emulator/">CHIP-8 emulator</a>, so after I finished I immediately started looking for another emulator project.</p>

<p>The general consensus on <a href="https://www.reddit.com/r/EmuDev/">r/emudev</a> and the <a href="http://www.emutalk.net/forums/30-Emulator-Programming">EmuTalk Forums</a> seemed to point to the 1978 arcade game: <em>Space Invaders</em>. This was perfect for me since it also overlapped my other hobby: arcade machine restoration.</p>

<p>The getting started phase went much quicker than my first emulator since I was able to re-use several components from my CHIP-8's C# codebase: the command line interface program, the SDL GUI program, and the unit test runner. I did take some time to reorganize the project structure.</p>

<blockquote>
  <p>TL;DR: Skip to the <a href="http://www.justin-credible.net/2020/03/31/space-invaders-emulator/#results">Results section</a> for a video clip and link to the source code.</p>
</blockquote>

<h1 id="intel8080cpu">Intel 8080 CPU</h1>

<p>In my CHIP-8 emulator I only had a single project which encompassed the CLI program, GUI, and emulator. This led to tightly coupled modules. While this was fine for a small emulator, I knew this wouldn't work for something larger.</p>

<p>Space Invaders uses an <a href="https://en.wikipedia.org/wiki/Intel_8080">Intel 8080</a> CPU running at 2 MHz along with some of its own specific hardware. I did all the work on the CPU core in its own module to keep it separate from the rest of the game's hardware. This should allow me to re-use much of my CPU core code for future emulation projects that use the Intel 8080 or it's cousin the <a href="https://en.wikipedia.org/wiki/Zilog_Z80">Zilog Z80</a>.</p>

<blockquote>
  <p>An aside: One of my favorite parts of this project was checking out the <a href="https://altairclone.com/downloads/manuals/8080%20Programmers%20Manual.pdf">Intel 8080 Assembly Language Programmers Manual</a>. This manual explains how each opcode works at the byte level and was my main reference. This manual was fascinating because it illustrates how CPUs in this era were simple and understandable. Today's modern CPUs are so complex that even if you write assembly language for them it is not what runs on the bare metal (see: <a href="https://en.wikipedia.org/wiki/Intel_Microcode">microcode</a>) and they even run entire operating systems in their firmware (the <a href="https://en.wikipedia.org/wiki/MINIX_3">MINIX</a> operating system is embedded in Intel CPUs <a href="https://en.wikipedia.org/wiki/Intel_Management_Engine#Hardware">Management Engine</a> for example ).</p>
</blockquote>

<p>One major difference from the CHIP-8 was that CPU speed and the number of cycles executed was important. I needed to count the number of cycles per instruction so that I could throttle the emulation loop to approximately 2 MHz so the game would run at the correct speed.</p>

<p>Additionally, the Intel 8080 CPU has interrupts which can temporarily pause CPU execution in order to temporarily run other opcodes before resuming. Space Invaders fires two different interrupts at 60 Hz; once when the CRT's electron beam is approximately half way down the screen and the other when the beam is at the end (which is also known as VBLANK). We can estimate when these interrupts should occur based on the number of cycles executed.</p>

<h1 id="audiovideoandshifthardware">Audio, video, and shift hardware</h1>

<p>Another interesting aspect was seeing how the Space Invaders PCB connected the CPU to other pieces of hardware. The <code>IN</code> and <code>OUT</code> instructions can be used to read and read bits from other "devices". In this case the code "reads" the state of the buttons (pressed or not pressed) and "writes" bits to tell the analog audio hardware when to play sounds.</p>

<p>In this case I didn't attempt to emulate the analog audio hardware, and up until recently even real emulators like MAME didn't either. From what I understand it is computationally expensive to emulate analog hardware, and simply playing back WAV samples when needed is close enough.</p>

<p>Graphics are handled by writing bits into a specific region of memory. In order to place sprites, frequent bit shifting is needed. Unfortunately the 8080 doesn't have opcodes for shifting, so Space Invaders includes a dedicated shift register. This pieces of hardware is accessible via the <code>IN</code> and <code>OUT</code> instructions as well.</p>

<h2 id="verifyingopcodebehavior">Verifying Opcode Behavior</h2>

<p>As with the CHIP-8 emulator, building unit tests for each opcode at the same time as implementing the opcode was instrumental for success. It's much easier to test each opcode in isolation than trying to track down bugs when the entire game ROM is loaded and running.</p>

<p>While this saved a ton of time, it didn't catch 100% of the bugs of course. Some of my unit tests made assumptions that weren't correct. Also some of my unit tests were just wrong. I used two additional approaches to verify my opcode behavior and track down bugs: integration testing and adding an interactive debugger.</p>

<p>While unit tests verify the behavior of an individual opcode is correct, bugs can still be possible when you have opcodes that interact. For catching these scenarios I used an integration test by leveraging <a href="https://github.com/begoon/i8080-core/blob/master/TEST.ASM">this</a> CPU diagnostics program for the 8080/8085. By assembling and running this program against my CPU I was able to verify it was <em>mostly</em> correct.</p>

<p>The last few bugs I had to track down weren't caught by either my unit tests or the integration test. There were a couple of crashes that occurred consistently during the game's attract mode when the CPU attempted to access memory locations far outside the game's 8K of addressable memory space. Using my IDEs debugger was helpful in tracking down how the illegal memory access occurred, it was nearly impossible to see which combinations of opcodes and how they interacted that resulted in the wrong memory address being calculated. At this pointed I needed a more specialized debugging tool.</p>

<h2 id="interactivedebugging">Interactive Debugging</h2>

<p>I wrote an interactive debugger that would allow me to debug at a higher level. Instead of stepping over lines of C# code that implemented the 8080 opcodes, I needed to step over individual opcodes and verify register and memory values, just as if I was debugging an 8080 program. So I incorporated the <a href="https://k1.spdns.de/Develop/Projects/zasm/Distributions/">zasm disassmebler</a> and built an interactive debugger.</p>

<div class="photo-gallery">  
    <a href="http://www.justin-credible.net/content/images/2020/03/debugger.png" title="" data-width="1056" data-height="916">
        <img src="http://www.justin-credible.net/content/images/2020/03/debugger-thumbnail.png" alt="">
    </a>
</div>

<p>From here I could set breakpoints, inspect register and memory values, single step over opcodes, save and restore CPU state, and view a history of opcode execution. I also implemented a rewind feature so that once I got to the problematic opcode I could them step backwards over opcodes to see how I got there.</p>

<p>This allowed me to track down an issue with the interaction between two opcodes (<code>CALL</code> and <code>RET</code>) which the unit tests and diagnostics program did not catch.</p>

<h2 id="results">Results</h2>

<p><a name="results"></a></p>

<p>Space Invaders is an excellent second step after finishing a CHIP-8 emulator. It adds a few new concepts (timing, interrupts, external hardware) but nothing too hard. I'm also hoping that I can re-use much of my CPU core for my next project since the Intel 8080 is very close to the Zilog Z80 (perhaps <em>Ms. Pac-Man</em>, <em>Galaga</em>, or even the <em>Gameboy</em>).</p>

<style>  
  .screen-capture {
    text-align: center;
    margin-bottom: 20px;
  }
  .post .post-content .screen-capture img {
    max-height: 400px;
  }
</style>

<div class="screen-capture">  
<img src="http://www.justin-credible.net/content/images/2020/03/gameplay.gif" alt="A screen capture of my emulator running on macOS.">
</div>

<p>You can find more details on <a href="https://github.com/Justin-Credible/space-invaders-emulator">GitHub</a>. The readme contains a <a href="https://github.com/Justin-Credible/space-invaders-emulator#resources">resources</a> section with some links for recommended reading.</p>

<div class="github-widget" data-repo="Justin-Credible/space-invaders-emulator">  
</div>]]></content:encoded></item><item><title><![CDATA[Multi-Game Cocktail Cabinet]]></title><description><![CDATA[<p><img src="http://www.justin-credible.net/content/images/2020/03/cropped-small.png" style="float: right; padding-left: 10px;"></p>

<p>I feel quite a bit of nostalgia for a few specific arcade machines that were in my local Round Table pizza when I was growing up: The 4-player beat-em-up <em>Teenage Mutant Ninja Turtles</em>, the 3-player racing game <em>Off Road</em>, the super cool 4-game <em>Neo-Geo</em>, and the cocktail cabinet version of</p>]]></description><link>http://www.justin-credible.net/2020/03/22/multi-game-cocktail-cabinet/</link><guid isPermaLink="false">b158fb7c-6084-4fdf-b0cb-f30f097575db</guid><category><![CDATA[Arcade Restoration]]></category><dc:creator><![CDATA[Justin Unterreiner]]></dc:creator><pubDate>Mon, 23 Mar 2020 03:57:00 GMT</pubDate><content:encoded><![CDATA[<p><img src="http://www.justin-credible.net/content/images/2020/03/cropped-small.png" style="float: right; padding-left: 10px;"></p>

<p>I feel quite a bit of nostalgia for a few specific arcade machines that were in my local Round Table pizza when I was growing up: The 4-player beat-em-up <em>Teenage Mutant Ninja Turtles</em>, the 3-player racing game <em>Off Road</em>, the super cool 4-game <em>Neo-Geo</em>, and the cocktail cabinet version of <em>Ms. Pac-Man</em>.</p>

<p>I remember that last one most vividly. Being able to sit and set down your drink while you took a break from the upright machines was such a nice change. This was the cabinet that first got me interested in Ms. Pac-Man and Arkanoid, among other games.</p>

<p>I purchased a <a href="https://www.harumancustoms.com/products/cocktail-kits/midway-style-cocktail">flatpack cocktail cabinet kit</a> from <a href="https://www.harumancustoms.com/">Haruman's Customs</a> a couple years ago, which took a backseat to other arcade projects. But recently, I finally had some time to tackle this project.</p>

<h2 id="cabinetbody">Cabinet Body</h2>

<p>Haruman's kit comes in melamine, MDF, and baltic birch plywood. I went with the birch, which has a nice natural look, and stained it Dark Walnut with several finishing coats of polyurethane. This was my first time working with an oil-based stain, and although it involved a lot of work and clean-up, I couldn't be more pleased with the results.</p>

<p>I also added <a href="https://www.amazon.com/gp/product/B01AAU9C08/ref=ox_sc_act_title_1">leg levelers</a> from <a href="https://www.retroarcade.us">RetroArcade.us</a>.</p>

<div class="photo-gallery">  
    <a href="http://www.justin-credible.net/content/images/galleries/multi-game-cocktail-cabinet/010.jpg" title="" data-width="2048" data-height="1536">
        <img src="http://www.justin-credible.net/content/images/galleries/multi-game-cocktail-cabinet/thumbnails/010.jpg" alt="">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/multi-game-cocktail-cabinet/020.jpg" title="" data-width="2048" data-height="1536">
        <img src="http://www.justin-credible.net/content/images/galleries/multi-game-cocktail-cabinet/thumbnails/020.jpg" alt="">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/multi-game-cocktail-cabinet/030.jpg" title="" data-width="1536" data-height="2048">
        <img src="http://www.justin-credible.net/content/images/galleries/multi-game-cocktail-cabinet/thumbnails/030.jpg" alt="">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/multi-game-cocktail-cabinet/040.jpg" title="" data-width="2048" data-height="1536">
        <img src="http://www.justin-credible.net/content/images/galleries/multi-game-cocktail-cabinet/thumbnails/040.jpg" alt="">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/multi-game-cocktail-cabinet/050.jpg" title="" data-width="2048" data-height="1536">
        <img src="http://www.justin-credible.net/content/images/galleries/multi-game-cocktail-cabinet/thumbnails/050.jpg" alt="">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/multi-game-cocktail-cabinet/060.jpg" title="" data-width="2048" data-height="1536">
        <img src="http://www.justin-credible.net/content/images/galleries/multi-game-cocktail-cabinet/thumbnails/060.jpg" alt="">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/multi-game-cocktail-cabinet/070.jpg" title="" data-width="2048" data-height="1536">
        <img src="http://www.justin-credible.net/content/images/galleries/multi-game-cocktail-cabinet/thumbnails/070.jpg" alt="">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/multi-game-cocktail-cabinet/080.jpg" title="" data-width="2048" data-height="1536">
        <img src="http://www.justin-credible.net/content/images/galleries/multi-game-cocktail-cabinet/thumbnails/080.jpg" alt="">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/multi-game-cocktail-cabinet/090.jpg" title="" data-width="2048" data-height="1536">
        <img src="http://www.justin-credible.net/content/images/galleries/multi-game-cocktail-cabinet/thumbnails/090.jpg" alt="">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/multi-game-cocktail-cabinet/100.jpg" title="" data-width="2048" data-height="1536">
        <img src="http://www.justin-credible.net/content/images/galleries/multi-game-cocktail-cabinet/thumbnails/100.jpg" alt="">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/multi-game-cocktail-cabinet/110.jpg" title="" data-width="2048" data-height="1536">
        <img src="http://www.justin-credible.net/content/images/galleries/multi-game-cocktail-cabinet/thumbnails/110.jpg" alt="">
    </a>
</div>

<h2 id="monitor">Monitor</h2>

<p>The kit is built specifically for the Dell 2001/2007FP LCD. This is one of the largest 4:3 LCDs available and it has very good left/right viewing angles, which is important on a cocktail cabinet (you'll be viewing the LCD from the sides when it's mounted in portrait orientation). I went with the 2001FP version because that's what I was able to find on eBay for a decent price.</p>

<p>Unfortunately, the kit's mounts weren't big enough for my monitor, even after removing the plastic housing from the screen. I had to improvise a bit with some metal brackets. I also removed the LCD's front panel PCB and mounted it on the bottom to prevent the kit's stop wood panel from depressing the buttons.</p>

<p>Once I had mounted the LCD, I realized I had forgotten to paint the exposed plywood border (oops), so I masked off the LCD panel and did a quick coat of black paint.</p>

<div class="photo-gallery">

    <a href="http://www.justin-credible.net/content/images/galleries/multi-game-cocktail-cabinet/120.jpg" title="" data-width="1536" data-height="2048">
        <img src="http://www.justin-credible.net/content/images/galleries/multi-game-cocktail-cabinet/thumbnails/120.jpg" alt="">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/multi-game-cocktail-cabinet/140.jpg" title="" data-width="2048" data-height="1536">
        <img src="http://www.justin-credible.net/content/images/galleries/multi-game-cocktail-cabinet/thumbnails/140.jpg" alt="">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/multi-game-cocktail-cabinet/150.jpg" title="" data-width="2048" data-height="1536">
        <img src="http://www.justin-credible.net/content/images/galleries/multi-game-cocktail-cabinet/thumbnails/150.jpg" alt="">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/multi-game-cocktail-cabinet/160.jpg" title="" data-width="2048" data-height="1536">
        <img src="http://www.justin-credible.net/content/images/galleries/multi-game-cocktail-cabinet/thumbnails/160.jpg" alt="">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/multi-game-cocktail-cabinet/170.jpg" title="" data-width="2048" data-height="1536">
        <img src="http://www.justin-credible.net/content/images/galleries/multi-game-cocktail-cabinet/thumbnails/170.jpg" alt="">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/multi-game-cocktail-cabinet/180.jpg" title="" data-width="2048" data-height="1536">
        <img src="http://www.justin-credible.net/content/images/galleries/multi-game-cocktail-cabinet/thumbnails/180.jpg" alt="">
    </a>
</div>

<h2 id="cabinethardware">Cabinet Hardware</h2>

<p>The cabinet kit is also pre-cut for several other commonly sized pieces of hardware, such as the speaker, ventilation, coin doors, and glass top.</p>

<p>I got the <a href="http://www.arcadeshop.com/i/917/6x9-speaker-shielded-8-ohm.htm">speaker</a> and <a href="http://www.arcadeshop.com/i/801/6x9-speaker-grill-cover-midway.htm">speaker/ventilation grills</a> from <a href="http://www.arcadeshop.com/">Arcadeshop</a>.</p>

<p>I went with <a href="http://www.twistedquarter.com/index.php?main_page=product_info&amp;products_id=926">this coin door</a> from <a href="http://www.twistedquarter.com/">Twisted Quarter</a>. Although the dimensions match, the corners of the door were more rounded than those of the pre-cut hole in the kit, which left small gaps at the corners. I was able to position the coin door such that the gaps aren't visible on the top corners, but they are still slightly visible on the bottom.</p>

<p>The kit's top is cut specifically for the standard Bally Midway glass, so I used <a href="https://www.hollandcomputers.com/store/pc/Replacement-cocktail-table-top-glass-with-3-5-in-radius-Fits-Bally-Midway-tables-plus-other-aftermarket-arcade-cocktail-tables-2963p8154.htm">this replacement</a> by <a href="https://www.hollandcomputers.com/store/pc/RetroArcade-us-b398.htm">RetroArcade.us</a>. Another hiccup here was the clips used to hold the glass in place. Haruman's kit comes with clips, which are listed on the website as "ABS black cocktail glass clips (pressure fit, no screws needed)." Unfortunately, they didn't stay on at all; they fell off easily when touched. I wanted to use a set of the <a href="http://www.twistedquarter.com/index.php?main_page=product_info&amp;cPath=219_228&amp;products_id=1119">metal cocktail glass clips</a> that are used on authentic cocktail cabinets, but those cabinets are built with 3/4" plywood, whereas Haruman's kit uses 1/2" plywood, so that wouldn't work. Ultimately, I had to use screws on the underside of the cabinet to secure the kit's plastic clips in place, which causes them to bow a bit.</p>

<div class="photo-gallery">  
    <a href="http://www.justin-credible.net/content/images/galleries/multi-game-cocktail-cabinet/190.jpg" title="" data-width="1536" data-height="2048">
        <img src="http://www.justin-credible.net/content/images/galleries/multi-game-cocktail-cabinet/thumbnails/190.jpg" alt="">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/multi-game-cocktail-cabinet/200.jpg" title="" data-width="2048" data-height="1536">
        <img src="http://www.justin-credible.net/content/images/galleries/multi-game-cocktail-cabinet/thumbnails/200.jpg" alt="">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/multi-game-cocktail-cabinet/210.jpg" title="" data-width="2048" data-height="1536">
        <img src="http://www.justin-credible.net/content/images/galleries/multi-game-cocktail-cabinet/thumbnails/210.jpg" alt="">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/multi-game-cocktail-cabinet/220.jpg" title="" data-width="2048" data-height="1536">
        <img src="http://www.justin-credible.net/content/images/galleries/multi-game-cocktail-cabinet/thumbnails/220.jpg" alt="">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/multi-game-cocktail-cabinet/230.jpg" title="" data-width="2048" data-height="1536">
        <img src="http://www.justin-credible.net/content/images/galleries/multi-game-cocktail-cabinet/thumbnails/230.jpg" alt="">
    </a>
</div>

<h2 id="controlpanels">Control Panels</h2>

<p>The kit's control panels come pre-cut for a joystick and three buttons, with an additional two buttons on one side for the start buttons. I attached the panels with metal brackets and wood glue to add stability.</p>

<p>I used piano hinges to attach the control panel tops to the body, to allow easy access underneath. I couldn't find any piano hinges that were close in size, so I bought a much longer one and cut it with a Dremel.</p>

<p>I used <a href="https://www.lowes.com/pd/Rust-Oleum-Gloss-Black-Actual-Net-Contents-15-oz/3729773">Rust-Oleum enamel spray</a> to add several coats to the control panel tops. It came out looking very shiny, and seems pretty resistant to scratches and wear so far.</p>

<div class="photo-gallery">  
    <a href="http://www.justin-credible.net/content/images/galleries/multi-game-cocktail-cabinet/240.jpg" title="" data-width="2048" data-height="1536">
        <img src="http://www.justin-credible.net/content/images/galleries/multi-game-cocktail-cabinet/thumbnails/240.jpg" alt="">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/multi-game-cocktail-cabinet/250.jpg" title="" data-width="2048" data-height="1536">
        <img src="http://www.justin-credible.net/content/images/galleries/multi-game-cocktail-cabinet/thumbnails/250.jpg" alt="">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/multi-game-cocktail-cabinet/260.jpg" title="" data-width="2048" data-height="1536">
        <img src="http://www.justin-credible.net/content/images/galleries/multi-game-cocktail-cabinet/thumbnails/260.jpg" alt="">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/multi-game-cocktail-cabinet/270.jpg" title="" data-width="2048" data-height="1536">
        <img src="http://www.justin-credible.net/content/images/galleries/multi-game-cocktail-cabinet/thumbnails/270.jpg" alt="">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/multi-game-cocktail-cabinet/271.jpg" title="" data-width="2048" data-height="1536">
        <img src="http://www.justin-credible.net/content/images/galleries/multi-game-cocktail-cabinet/thumbnails/271.jpg" alt="">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/multi-game-cocktail-cabinet/272.jpg" title="" data-width="2048" data-height="1536">
        <img src="http://www.justin-credible.net/content/images/galleries/multi-game-cocktail-cabinet/thumbnails/272.jpg" alt="">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/multi-game-cocktail-cabinet/273.jpg" title="" data-width="2048" data-height="1536">
        <img src="http://www.justin-credible.net/content/images/galleries/multi-game-cocktail-cabinet/thumbnails/273.jpg" alt="">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/multi-game-cocktail-cabinet/280.jpg" title="" data-width="2048" data-height="1536">
        <img src="http://www.justin-credible.net/content/images/galleries/multi-game-cocktail-cabinet/thumbnails/280.jpg" alt="">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/multi-game-cocktail-cabinet/290.jpg" title="" data-width="2048" data-height="1536">
        <img src="http://www.justin-credible.net/content/images/galleries/multi-game-cocktail-cabinet/thumbnails/290.jpg" alt="">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/multi-game-cocktail-cabinet/300.jpg" title="" data-width="2048" data-height="1536">
        <img src="http://www.justin-credible.net/content/images/galleries/multi-game-cocktail-cabinet/thumbnails/300.jpg" alt="">
    </a>
</div>

<p>By far the most frustrating part of the build was attaching the control panel tops to the cabinet. The kit's instructions suggest using Velcro or magnets, but I was very doubtful that would work well. When playing games, people put a lot of weight on the panels pulling the joysticks (think trying to outrun ghosts in Pac-Man), and I just didn't think Velco or magnets would hold up to the force--or if they did, there would likely be lots of wobble on the panel. I decided to look for my own solution.</p>

<p>I wanted something like the system used by real cocktail cabinets, which have clamp clips accessible on the inside by reaching through the coin door. This keeps the control panels tops extremely tight (no wobbling), and prevents the control panels from being opened unless you have the key to the coin door. </p>

<p>After several trials, eventually I ended up using <a href="https://www.amazon.com/gp/product/B07HD3FH8V/ref=ppx_yo_dt_b_asin_title_o00_s00">chest catch latches</a>. I had to cut some shims from the extra wood that came with the kit so that the latches were at the correct height. This ended up working really well; the panels don't wiggle at all and are easy to unlatch from the inside.</p>

<p>As for the joysticks and buttons, I used the set from <a href="https://www.amazon.com/gp/product/B00F1YQ9LO/ref=ox_sc_mini_detail">this kit</a> by <a href="https://www.retroarcade.us">RetroArcade.us</a>.</p>

<div class="photo-gallery">  
    <a href="http://www.justin-credible.net/content/images/galleries/multi-game-cocktail-cabinet/310.jpg" title="" data-width="2048" data-height="1536">
        <img src="http://www.justin-credible.net/content/images/galleries/multi-game-cocktail-cabinet/thumbnails/310.jpg" alt="">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/multi-game-cocktail-cabinet/320.jpg" title="" data-width="2048" data-height="1536">
        <img src="http://www.justin-credible.net/content/images/galleries/multi-game-cocktail-cabinet/thumbnails/320.jpg" alt="">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/multi-game-cocktail-cabinet/330.jpg" title="" data-width="2048" data-height="1536">
        <img src="http://www.justin-credible.net/content/images/galleries/multi-game-cocktail-cabinet/thumbnails/330.jpg" alt="">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/multi-game-cocktail-cabinet/340.jpg" title="" data-width="2048" data-height="1536">
        <img src="http://www.justin-credible.net/content/images/galleries/multi-game-cocktail-cabinet/thumbnails/340.jpg" alt="">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/multi-game-cocktail-cabinet/350.jpg" title="" data-width="2048" data-height="1536">
        <img src="http://www.justin-credible.net/content/images/galleries/multi-game-cocktail-cabinet/thumbnails/350.jpg" alt="">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/multi-game-cocktail-cabinet/360.jpg" title="" data-width="2048" data-height="1536">
        <img src="http://www.justin-credible.net/content/images/galleries/multi-game-cocktail-cabinet/thumbnails/360.jpg" alt="">
    </a>
</div>

<h2 id="wiringandgameboard">Wiring and Game Board</h2>

<p>The kit came with a fused power switch that uses an IEC C16 connector (standard PC power cable). I connected the switch outlet to a power strip on the inside, which powers the game board, audio amplifier, and monitor.</p>

<div class="photo-gallery">  
    <a href="http://www.justin-credible.net/content/images/galleries/multi-game-cocktail-cabinet/370.jpg" title="" data-width="2048" data-height="1536">
        <img src="http://www.justin-credible.net/content/images/galleries/multi-game-cocktail-cabinet/thumbnails/370.jpg" alt="">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/multi-game-cocktail-cabinet/380.jpg" title="" data-width="2048" data-height="1536">
        <img src="http://www.justin-credible.net/content/images/galleries/multi-game-cocktail-cabinet/thumbnails/380.jpg" alt="">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/multi-game-cocktail-cabinet/390.jpg" title="" data-width="1536" data-height="2048">
        <img src="http://www.justin-credible.net/content/images/galleries/multi-game-cocktail-cabinet/thumbnails/390.jpg" alt="">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/multi-game-cocktail-cabinet/400.jpg" title="" data-width="1536" data-height="2048">
        <img src="http://www.justin-credible.net/content/images/galleries/multi-game-cocktail-cabinet/thumbnails/400.jpg" alt="">
    </a>
</div>

<p>I used a switching power supply and JAMMA harness from <a href="https://www.amazon.com/gp/product/B00F1YQ9LO/ref=ox_sc_mini_detail">this kit</a> by <a href="https://www.retroarcade.us">RetroArcade.us</a>.</p>

<p>The audio amplifier wasn't strictly necessary, but I like to be able to easily adjust the volume with a knob, instead of having to go into the game board's firmware menu. I used the <a href="https://www.amazon.com/gp/product/B01FZKA28Y/ref=ppx_yo_dt_b_asin_title_o00_s00">Lepy LP-2020A</a> amplifier.</p>

<p>There wasn't enough room behind the control panel plexiglass for any bulbs for backlighting, so used some LED strips with adhesive backing (similar to <a href="https://www.amazon.com/Upgraded-LED-Strip-Lights-LEDMO/dp/B01FFWQCKO/ref=sr_1_4">these</a>) and stuck them around the plexiglass edges.</p>

<p>As for the game board, I went with a generic <a href="https://www.amazon.com/BLEE-Classical-Vertical-Cocktail-Machine/dp/B07FY9N87Y/ref=sr_1_3">60-in-1 JAMMA board</a>.</p>

<p>Everything is accessible from a side door, which opens on a piano hinge. It is held on with <a href="http://www.arcadeshop.com/i/216/control-panel-cocktail-top-clamp-1.htm">these latches</a>, which can be opened by reaching through the coin door.</p>

<div class="photo-gallery">  
    <a href="http://www.justin-credible.net/content/images/galleries/multi-game-cocktail-cabinet/405.mp4" title="" data-width="2048" data-height="1536">
        <img src="http://www.justin-credible.net/content/images/galleries/multi-game-cocktail-cabinet/thumbnails/405.jpg" alt="">
    <a href="http://www.justin-credible.net/content/images/galleries/multi-game-cocktail-cabinet/410.jpg" title="" data-width="2048" data-height="1536">
        <img src="http://www.justin-credible.net/content/images/galleries/multi-game-cocktail-cabinet/thumbnails/410.jpg" alt="">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/multi-game-cocktail-cabinet/420.jpg" title="" data-width="2048" data-height="1536">
        <img src="http://www.justin-credible.net/content/images/galleries/multi-game-cocktail-cabinet/thumbnails/420.jpg" alt="">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/multi-game-cocktail-cabinet/430.jpg" title="" data-width="1536" data-height="2048">
        <img src="http://www.justin-credible.net/content/images/galleries/multi-game-cocktail-cabinet/thumbnails/430.jpg" alt="">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/multi-game-cocktail-cabinet/450.jpg" title="" data-width="1536" data-height="2048">
        <img src="http://www.justin-credible.net/content/images/galleries/multi-game-cocktail-cabinet/thumbnails/450.jpg" alt="">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/multi-game-cocktail-cabinet/460.jpg" title="" data-width="2048" data-height="1536">
        <img src="http://www.justin-credible.net/content/images/galleries/multi-game-cocktail-cabinet/thumbnails/460.jpg" alt="">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/multi-game-cocktail-cabinet/470.jpg" title="" data-width="1536" data-height="2048">
        <img src="http://www.justin-credible.net/content/images/galleries/multi-game-cocktail-cabinet/thumbnails/470.jpg" alt="">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/multi-game-cocktail-cabinet/480.jpg" title="" data-width="2048" data-height="1536">
        <img src="http://www.justin-credible.net/content/images/galleries/multi-game-cocktail-cabinet/thumbnails/480.jpg" alt="">
    </a>
</a></div>

<h2 id="results">Results</h2>

<p>Overall, I am thrilled with this build. I couldn't be happier with how the finish on the baltic birch plywood turned out. The staining process was messy and time-consuming, but it looks so much better than black melamine, it was worth the extra time and clean-up.</p>

<p>Although I was faced with several gotcha's, I would absolutely recommend Haruman's cocktail cabinet kit, as long as you know going in that it isn't a turn-key solution and will require a bit of improvisation.</p>

<div class="photo-gallery">  
    <a href="http://www.justin-credible.net/content/images/galleries/multi-game-cocktail-cabinet/530.mp4" title="" data-width="2048" data-height="1536">
        <img src="http://www.justin-credible.net/content/images/galleries/multi-game-cocktail-cabinet/thumbnails/530.jpg" alt="">
    <a href="http://www.justin-credible.net/content/images/galleries/multi-game-cocktail-cabinet/490.jpg" title="" data-width="1536" data-height="2048">
        <img src="http://www.justin-credible.net/content/images/galleries/multi-game-cocktail-cabinet/thumbnails/490.jpg" alt="">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/multi-game-cocktail-cabinet/500.jpg" title="" data-width="1536" data-height="2048">
        <img src="http://www.justin-credible.net/content/images/galleries/multi-game-cocktail-cabinet/thumbnails/500.jpg" alt="">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/multi-game-cocktail-cabinet/510.jpg" title="" data-width="1536" data-height="2048">
        <img src="http://www.justin-credible.net/content/images/galleries/multi-game-cocktail-cabinet/thumbnails/510.jpg" alt="">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/multi-game-cocktail-cabinet/520.jpg" title="" data-width="2048" data-height="1536">
        <img src="http://www.justin-credible.net/content/images/galleries/multi-game-cocktail-cabinet/thumbnails/520.jpg" alt="">
    </a>
</a></div>]]></content:encoded></item><item><title><![CDATA[Capacitor TypeScript definitions for legacy projects]]></title><description><![CDATA[<p><a href="https://capacitor.ionicframework.com/">Capacitor</a> is a cross-platform runtime that allows you to build apps using web technology, while having a native bridge for invoking native SDKs. It is basically the successor to <a href="https://cordova.apache.org/">Cordova</a>.</p>

<p>I'm in the midst of upgrading a Cordova app to use Capacitor, but keeping the original application code, which was</p>]]></description><link>http://www.justin-credible.net/2019/12/15/capacitor-typescript-definitions-for-legacy-projects/</link><guid isPermaLink="false">fe59d9d1-5b1e-4dfb-ac49-b3c2f34c3dea</guid><category><![CDATA[Software Development]]></category><category><![CDATA[Capacitor]]></category><dc:creator><![CDATA[Justin Unterreiner]]></dc:creator><pubDate>Sun, 15 Dec 2019 21:16:21 GMT</pubDate><content:encoded><![CDATA[<p><a href="https://capacitor.ionicframework.com/">Capacitor</a> is a cross-platform runtime that allows you to build apps using web technology, while having a native bridge for invoking native SDKs. It is basically the successor to <a href="https://cordova.apache.org/">Cordova</a>.</p>

<p>I'm in the midst of upgrading a Cordova app to use Capacitor, but keeping the original application code, which was built in TypeScript and uses Ionic 1.x. It uses my <a href="https://www.justin-credible.net/2015/11/10/ionic-typescript-starter-project/">Ionic/TypeScript Starter Project</a> project template.</p>

<p>This template was created a few years back and uses TypeScript namespaces (previously known as "internal modules") as opposed to the more recent module format.</p>

<p>This essentially means that instead of using the more modern ES6 <code>import</code> directive, everything is accessible via namespaces in a single bundle. This is problematic when you want to use TypeScript definitions, which are written in the modern module format, for Capacitor.</p>

<p>I threw together some TypeScript definitions for Capacitor that are compatible with TypeScript projects using namespaces instead of modules. They're up on GitHub as a jumping-off point for others who might want to run their older TypeScript projects in Capacitor.</p>

<div class="github-widget">  
    <div class="github-box repo">
        <div class="github-box-title">
            <h3>
                <a class="owner" href="http://github.com/Justin-Credible" title="http://github.com/Justin-Credible">Justin-Credible</a>/
                <a class="repo" href="https://gist.github.com/Justin-Credible/98301c0cca9f77e701e0e016210eed61" title="https://gist.github.com/Justin-Credible/98301c0cca9f77e701e0e016210eed61">capacitor.d.ts</a>
            </h3>
        </div>
        <div class="github-box-content">
            <p class="description">
                <span>TypeScript definitions for Capacitor, adapted for use in projects that use the namespace ("internal modules") convention.</span>
            </p>
        </div>
    </div>
</div>]]></content:encoded></item><item><title><![CDATA[CHIP-8 Emulator]]></title><description><![CDATA[<p>Emulators have always been magical to me. I vividly remember the first time I fired up an NES emulator and ran <em>Super Mario Bros.</em> on my 486DX. It didn't run fast, and the experience wasn't great, but it was <em>magical</em>. As Pentiums replaced the 486s, emulation became more viable and</p>]]></description><link>http://www.justin-credible.net/2019/09/03/chip-8-emulator/</link><guid isPermaLink="false">d220b3c2-e0ee-4b95-b0de-9de5a5211934</guid><category><![CDATA[Software Development]]></category><category><![CDATA[Emulators]]></category><category><![CDATA[Gaming]]></category><dc:creator><![CDATA[Justin Unterreiner]]></dc:creator><pubDate>Tue, 03 Sep 2019 19:03:46 GMT</pubDate><content:encoded><![CDATA[<p>Emulators have always been magical to me. I vividly remember the first time I fired up an NES emulator and ran <em>Super Mario Bros.</em> on my 486DX. It didn't run fast, and the experience wasn't great, but it was <em>magical</em>. As Pentiums replaced the 486s, emulation became more viable and I suddenly had access to <em>Final Fantasy</em> titles that were only released in Japan, along with fan translations.</p>

<p>Over the years, emulators have allowed me to play rare games that would otherwise cost exorbitant amounts of money on eBay, or re-experience titles I already own without dusting off my original hardware. Emulators also allow us to archive and preserve old games for future generations as older hardware fails and/or becomes more scarce.</p>

<p><img src="http://www.justin-credible.net/content/images/2019/09/Screen-Shot-2019-08-23-at-8.49.40-PM.png" alt="A screenshot of my CHIP-8 emulator early in development."></p>

<p>Beyond playing games, I've always had a technical fascination with emulators as well. I knew the basics of how they worked from my computer architecture and assembly language classes, but even so, they were still shrouded in mystery. I've always wanted to write my own emulator, but sitting down to read how a particular piece of hardware works, or even reading existing emulator code, can be overwhelming.</p>

<p>When I came across an <a href="http://www.multigesture.net/articles/how-to-write-an-emulator-chip-8-interpreter/">article</a> on HackerNews talking about the CHIP-8, and how it was an excellent choice for writing your first emulator, I decided to finally tackle this project.</p>

<p>A lot has been written about the CHIP-8, so I won't go into a lot of detail here. Consider this the ClifNotes version.</p>

<p>Technically, the CHIP-8 wasn't actually a hardware device. Instead, it was an interpreted programming language hobbyist computer, like the <a href="https://en.wikipedia.org/wiki/COSMAC_VIP">COSMAC VIP</a>, from the mid-70s. It allowed software (mostly games) to be written in an intermediary opcode format and then interpreted in different hardware architectures.</p>

<p><img src="http://www.justin-credible.net/content/images/2019/09/4689441488784272480.jpg" alt="No if/then/else constructs here; the CHIP-8 was programmed by typing 16-bit opcodes with a hexadecimal keyboard. (COSMAC VIP, 1977)"></p>

<p>However, <em>language</em> is a bit generous in this case. Instead of writing in a high-level language like Java, you instead type out 16-byte opcodes on a hexadecimal keyboard. Because you're still very low in the hardware stack, it's similar to writing an emulator for a piece of hardware: you have a program counter, registers, a stack, etc. This makes it a great candidate for a first emulation project.</p>

<p>Overall, this was an extremely rewarding project, and I would highly recommend anyone who's thought about doing this to check out <a href="http://www.justin-credible.net/2019/09/03/chip-8-emulator/">the article</a> I linked earlier. It lays the groundwork without giving too much away.</p>

<p><img src="http://www.justin-credible.net/content/images/2019/09/showcase.gif" alt="A screen capture showing my emulator running VBRIX."></p>

<p>I wrote my emulator and assembler in C# targeting the cross-platform .NET Core runtime. It uses SDL2 for the GUI.</p>

<p>You can find more details on <a href="https://github.com/Justin-Credible/CHIP-8-Emulator">GitHub</a>. The readme contains a <a href="https://github.com/Justin-Credible/CHIP-8-Emulator#resources">resources</a> section with some links for recommended reading.</p>

<div class="github-widget" data-repo="Justin-Credible/CHIP-8-Emulator">  
</div>]]></content:encoded></item><item><title><![CDATA[Williams Multigame]]></title><description><![CDATA[<p><img src="http://www.justin-credible.net/content/images/2019/03/cropped-small.png" style="float: right; padding-left: 10px;"></p>

<p>On Christmas eve, as we were driving to visit family, I was browsing Craigslist and stumbled upon an almost comical posting:</p>

<blockquote>
  <p>Free arcade machine, must go today, need to put up Christmas tree</p>
</blockquote>

<p>I didn't realize people put up their Christmas tree <em>the day before Christmas</em>, but who was I</p>]]></description><link>http://www.justin-credible.net/2019/03/28/williams-multigame/</link><guid isPermaLink="false">ca9061f4-6098-4f95-89f6-4e59d891ec67</guid><category><![CDATA[Arcade Restoration]]></category><dc:creator><![CDATA[Justin Unterreiner]]></dc:creator><pubDate>Fri, 29 Mar 2019 04:33:36 GMT</pubDate><content:encoded><![CDATA[<p><img src="http://www.justin-credible.net/content/images/2019/03/cropped-small.png" style="float: right; padding-left: 10px;"></p>

<p>On Christmas eve, as we were driving to visit family, I was browsing Craigslist and stumbled upon an almost comical posting:</p>

<blockquote>
  <p>Free arcade machine, must go today, need to put up Christmas tree</p>
</blockquote>

<p>I didn't realize people put up their Christmas tree <em>the day before Christmas</em>, but who was I to complain? It's hard to beat a <em>free arcade machine</em>. We immediately made a detour to pick up a dolly at the closest hardware store, then headed over to the address to pick up the cabinet.</p>

<p>The cabinet was a Shinobi in rough shape: quite worn, and with kids' stickers all over it. Although nothing would appear on the screen, the machine did power up and play attract mode sound effects, which indicated that the PCB was working. I wasn't surprised the CRT didn't work; there was a severe, hard-to-miss burn mark in the center of the tube.</p>

<div class="photo-gallery" style="clear: both;">  
    <a href="http://www.justin-credible.net/content/images/galleries/multi-williams/010.jpg" title="" data-width="1536" data-height="2048">
        <img src="http://www.justin-credible.net/content/images/galleries/multi-williams/thumbnails/010.jpg" alt="">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/multi-williams/020.jpg" title="" data-width="1536" data-height="2048">
        <img src="http://www.justin-credible.net/content/images/galleries/multi-williams/thumbnails/020.jpg" alt="">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/multi-williams/030.jpg" title="" data-width="1536" data-height="2048">
        <img src="http://www.justin-credible.net/content/images/galleries/multi-williams/thumbnails/030.jpg" alt="">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/multi-williams/040.jpg" title="" data-width="2048" data-height="1536">
        <img src="http://www.justin-credible.net/content/images/galleries/multi-williams/thumbnails/040.jpg" alt="">
    </a>
</div>

<p>The cabinet sat in my garage for a year or two, partly because I was finishing up other projects, and partly because I wasn't sure what the cabinet had been originally. But one day, while reading <a href="https://arcadeblogger.com/2018/01/12/where-did-all-the-defenders-go/">Where did all the Defenders go?</a> over on <a href="https://arcadeblogger.com/">The Arcade Blogger</a>, I was stunned to find a picture of a Defender-to-Shinobi cabinet that looked <a href="https://missilecommand.files.wordpress.com/2018/01/defender-shinobi-2.jpeg?w=525&amp;h=933">almost identical</a> to mine.</p>

<p>Having never played Defender, I wasn't sure that I wanted a dedicated Defender cabinet. However, Robotron 2048, my favorite game, is also made by Williams. A bit of searching indicated that Williams made a multi-game cabinet. That seemed like a worthy fit to me, so I got to work!</p>

<h2 id="cabinetprep">Cabinet Prep</h2>

<p>First things first: the cabinet needed to be stripped of parts and sanded down. The leg levelers had been removed, resulting in a fair bit of damage around the bottom edges. I cut back the loose pieces and filled it all in with wood filler. After another round of sanding, it was ready for primer and paint.</p>

<p>On previous cabinets, I've used vinyl graphics. But for this cabinet, I wanted to try something different: stencils! The first step was a base coat of paint. I used Rust-Oleum Satin black <em>flat</em>, which in retrospect was a mistake: the flat paint scuffs way too easily. I would recommend a gloss or at least a semi-gloss paint for the base coat. I worked this out in the end by applying a clear coat of Krylon Satin Crystal Clear over the finished stencils, after one final wipe down with tack cloth.</p>

<div class="photo-gallery">  
    <a href="http://www.justin-credible.net/content/images/galleries/multi-williams/050.jpg" title="" data-width="1536" data-height="2048">
        <img src="http://www.justin-credible.net/content/images/galleries/multi-williams/thumbnails/050.jpg" alt="">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/multi-williams/060.jpg" title="" data-width="2048" data-height="1536">
        <img src="http://www.justin-credible.net/content/images/galleries/multi-williams/thumbnails/060.jpg" alt="">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/multi-williams/070.jpg" title="" data-width="2048" data-height="1536">
        <img src="http://www.justin-credible.net/content/images/galleries/multi-williams/thumbnails/070.jpg" alt="">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/multi-williams/080.jpg" title="" data-width="1536" data-height="2048">
        <img src="http://www.justin-credible.net/content/images/galleries/multi-williams/thumbnails/080.jpg" alt="">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/multi-williams/090.jpg" title="" data-width="1536" data-height="2048">
        <img src="http://www.justin-credible.net/content/images/galleries/multi-williams/thumbnails/090.jpg" alt="">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/multi-williams/100.jpg" title="" data-width="1536" data-height="2048">
        <img src="http://www.justin-credible.net/content/images/galleries/multi-williams/thumbnails/100.jpg" alt="">
    </a>
</div>

<h2 id="stencils">Stencils</h2>

<p>I got my amazing <a href="https://www.thisoldgame.com/multicade-art/williams-multi-game-stencil-set-for-defender">Multi-Williams stencils</a> from <a href="https://www.thisoldgame.com/">This Old Game</a>. The stencil set for my cabinet has two colors: red and yellow. There were two stencil sets for each side and the front coin door, a total of six altogether.</p>

<p>I had never used stencils prior to this, but the process was very simple. The stencils were shipped in a cardboard tube, so the first step was to lay them out flat and give them time to uncurl. My wife helped me position the first stencils on each side of the cabinet using painters tape. After they were positioned, we peeled back the inner backing layer and used a squeegee to apply the stencil to the cabinet. Once applied, the entire cabinet was masked off with painters plastic and painted with Krylon Gloss Sunburst Yellow spray paint.</p>

<div class="photo-gallery">  
    <a href="http://www.justin-credible.net/content/images/galleries/multi-williams/110.jpg" title="" data-width="2048" data-height="1536">
        <img src="http://www.justin-credible.net/content/images/galleries/multi-williams/thumbnails/110.jpg" alt="">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/multi-williams/120.jpg" title="" data-width="2048" data-height="1536">
        <img src="http://www.justin-credible.net/content/images/galleries/multi-williams/thumbnails/120.jpg" alt="">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/multi-williams/130.jpg" title="" data-width="1536" data-height="2048">
        <img src="http://www.justin-credible.net/content/images/galleries/multi-williams/thumbnails/130.jpg" alt="">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/multi-williams/140.jpg" title="" data-width="1536" data-height="2048">
        <img src="http://www.justin-credible.net/content/images/galleries/multi-williams/thumbnails/140.jpg" alt="">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/multi-williams/150.jpg" title="" data-width="1536" data-height="2048">
        <img src="http://www.justin-credible.net/content/images/galleries/multi-williams/thumbnails/150.jpg" alt="">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/multi-williams/160.jpg" title="" data-width="1536" data-height="2048">
        <img src="http://www.justin-credible.net/content/images/galleries/multi-williams/thumbnails/160.jpg" alt="">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/multi-williams/170.jpg" title="" data-width="1536" data-height="2048">
        <img src="http://www.justin-credible.net/content/images/galleries/multi-williams/thumbnails/170.jpg" alt="">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/multi-williams/180.jpg" title="" data-width="1536" data-height="2048">
        <img src="http://www.justin-credible.net/content/images/galleries/multi-williams/thumbnails/180.jpg" alt="">
    </a>
</div>

<p>Once dry, we slowly peeled back and removed the first stencil layer. Then we applied the second layer over top of the first for the second color. Another round of masking had to occur before we were ready for the second color, Krylon Gloss Banner Red.</p>

<p>The coin door also received a coat of Rust-Oleum Hammered Black, which helps cover its minor dents and scrapes.</p>

<div class="photo-gallery">  
    <a href="http://www.justin-credible.net/content/images/galleries/multi-williams/190.jpg" title="" data-width="2048" data-height="1536">
        <img src="http://www.justin-credible.net/content/images/galleries/multi-williams/thumbnails/190.jpg" alt="">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/multi-williams/200.mp4" title="" data-width="1536" data-height="2048">
        <img src="http://www.justin-credible.net/content/images/galleries/multi-williams/thumbnails/200.jpg" alt="">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/multi-williams/210.jpg" title="" data-width="1536" data-height="2048">
        <img src="http://www.justin-credible.net/content/images/galleries/multi-williams/thumbnails/210.jpg" alt="">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/multi-williams/220.jpg" title="" data-width="1536" data-height="2048">
        <img src="http://www.justin-credible.net/content/images/galleries/multi-williams/thumbnails/220.jpg" alt="">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/multi-williams/230.jpg" title="" data-width="1536" data-height="2048">
        <img src="http://www.justin-credible.net/content/images/galleries/multi-williams/thumbnails/230.jpg" alt="">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/multi-williams/240.jpg" title="" data-width="1536" data-height="2048">
        <img src="http://www.justin-credible.net/content/images/galleries/multi-williams/thumbnails/240.jpg" alt="">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/multi-williams/250.jpg" title="" data-width="1536" data-height="2048">
        <img src="http://www.justin-credible.net/content/images/galleries/multi-williams/thumbnails/250.jpg" alt="">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/multi-williams/260.jpg" title="" data-width="1536" data-height="2048">
        <img src="http://www.justin-credible.net/content/images/galleries/multi-williams/thumbnails/260.jpg" alt="">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/multi-williams/261.jpg" title="" data-width="1536" data-height="2048">
        <img src="http://www.justin-credible.net/content/images/galleries/multi-williams/thumbnails/261.jpg" alt="">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/multi-williams/262.jpg" title="" data-width="2048" data-height="1536">
        <img src="http://www.justin-credible.net/content/images/galleries/multi-williams/thumbnails/262.jpg" alt="">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/multi-williams/263.jpg" title="" data-width="1536" data-height="2048">
        <img src="http://www.justin-credible.net/content/images/galleries/multi-williams/thumbnails/263.jpg" alt="">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/multi-williams/264.jpg" title="" data-width="1536" data-height="2048">
        <img src="http://www.justin-credible.net/content/images/galleries/multi-williams/thumbnails/264.jpg" alt="">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/multi-williams/309.jpg" title="" data-width="2048" data-height="1536">
        <img src="http://www.justin-credible.net/content/images/galleries/multi-williams/thumbnails/309.jpg" alt="">
    </a>
</div>

<p>Though it was my first time working with stencils, I was very happy with the outcome. It isn't perfect; if you look closely, you can see spots where the paint ran or edges that aren't perfectly straight. However, this lends the cabinet a certain air of authenticity; during the arcade heyday, when these cabinets were churned out of the factories at a blistering pace, many were painted with stencil sets instead of printed graphics. You'll see the same imperfections on authentic cabinets as well.</p>

<p>If you are considering stencils, I'd highly recommend it. The paint colors pop in a way they do not on printed vinyl graphics. <a href="https://www.thisoldgame.com">This Old Game</a> makes a great set of stencils that apply and remove very easily.</p>

<div class="photo-gallery">  
    <a href="http://www.justin-credible.net/content/images/galleries/multi-williams/280.jpg" title="" data-width="1536" data-height="2048">
        <img src="http://www.justin-credible.net/content/images/galleries/multi-williams/thumbnails/280.jpg" alt="">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/multi-williams/290.jpg" title="" data-width="1536" data-height="2048">
        <img src="http://www.justin-credible.net/content/images/galleries/multi-williams/thumbnails/290.jpg" alt="">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/multi-williams/300.jpg" title="" data-width="1536" data-height="2048">
        <img src="http://www.justin-credible.net/content/images/galleries/multi-williams/thumbnails/300.jpg" alt="">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/multi-williams/310.jpg" title="" data-width="2048" data-height="1536">
        <img src="http://www.justin-credible.net/content/images/galleries/multi-williams/thumbnails/310.jpg" alt="">
    </a>
</div>

<h2 id="controlpanel">Control Panel</h2>

<p>To prepare the control panel, I first needed to remove the existing hardware and overlay. It's surprising how well the adhesive holds up after all this time; a simple pull won't budge it. But with a little heat from a hairdryer, it peels off quickly. Underneath, you can see the original holes for the Defender layout.</p>

<div class="photo-gallery">  
    <a href="http://www.justin-credible.net/content/images/galleries/multi-williams/320.jpg" title="" data-width="2048" data-height="1536">
        <img src="http://www.justin-credible.net/content/images/galleries/multi-williams/thumbnails/320.jpg" alt="">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/multi-williams/330.jpg" title="" data-width="1536" data-height="2048">
        <img src="http://www.justin-credible.net/content/images/galleries/multi-williams/thumbnails/330.jpg" alt="">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/multi-williams/340.jpg" title="" data-width="1536" data-height="2048">
        <img src="http://www.justin-credible.net/content/images/galleries/multi-williams/thumbnails/340.jpg" alt="">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/multi-williams/350.jpg" title="" data-width="2048" data-height="1536">
        <img src="http://www.justin-credible.net/content/images/galleries/multi-williams/thumbnails/350.jpg" alt="">
    </a>
</div>

<p>The Multi-Williams layout I chose is very similar to the Defender layout; I only needed to add three new holes. I used a drill press to do this. I also used a little wood filler to fill in a pitted area on the top right of the board.</p>

<p>The overlay art I used was about an eighth of an inch shorter than the original, leaving some exposed wood. A quick spray of black Rust-Oleum covered it right up.</p>

<p>The <a href="https://www.thisoldgame.com/multicade-art/mult-williams-defender-version">overlay</a> and <a href="https://www.thisoldgame.com/plex/multi-williams-defender-plexi-">plexiglass</a> are from <a href="https://www.thisoldgame.com">This Old Game</a>.</p>

<div class="photo-gallery">  
    <a href="http://www.justin-credible.net/content/images/galleries/multi-williams/351.jpg" title="" data-width="1536" data-height="2048">
        <img src="http://www.justin-credible.net/content/images/galleries/multi-williams/thumbnails/351.jpg" alt="">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/multi-williams/360.jpg" title="" data-width="2048" data-height="1536">
        <img src="http://www.justin-credible.net/content/images/galleries/multi-williams/thumbnails/360.jpg" alt="">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/multi-williams/370.jpg" title="" data-width="2048" data-height="1536">
        <img src="http://www.justin-credible.net/content/images/galleries/multi-williams/thumbnails/370.jpg" alt="">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/multi-williams/380.jpg" title="" data-width="2048" data-height="1536">
        <img src="http://www.justin-credible.net/content/images/galleries/multi-williams/thumbnails/380.jpg" alt="">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/multi-williams/390.jpg" title="" data-width="2048" data-height="1536">
        <img src="http://www.justin-credible.net/content/images/galleries/multi-williams/thumbnails/390.jpg" alt="">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/multi-williams/400.jpg" title="" data-width="2048" data-height="1536">
        <img src="http://www.justin-credible.net/content/images/galleries/multi-williams/thumbnails/400.jpg" alt="">
    </a>
</div>

<p>To reduce noise, I went with leaf switches on the buttons and joysticks instead of microswitches. The joysticks are the <a href="http://www.arcadeshop.com/i/1489/wico-3.5-red-ball-handle-joystick.htm">Wico 8-Way</a> from <a href="https://www.arcadeshop.com">Arcadeshop</a> and the buttons are the <a href="https://groovygamegear.com/webstore/index.php?main_page=product_info&amp;products_id=356">CLASSIX</a> in the True-Leaf Pro configuration from <a href="https://groovygamegear.com">GroovyGameGear</a>.</p>

<p>I wired everything up and tested the inputs on the workbench before re-installing the control panel.</p>

<div class="photo-gallery">  
    <a href="http://www.justin-credible.net/content/images/galleries/multi-williams/410.jpg" title="" data-width="2048" data-height="1536">
        <img src="http://www.justin-credible.net/content/images/galleries/multi-williams/thumbnails/410.jpg" alt="">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/multi-williams/420.jpg" title="" data-width="2048" data-height="1536">
        <img src="http://www.justin-credible.net/content/images/galleries/multi-williams/thumbnails/420.jpg" alt="">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/multi-williams/430.jpg" title="" data-width="2048" data-height="1536">
        <img src="http://www.justin-credible.net/content/images/galleries/multi-williams/thumbnails/430.jpg" alt="">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/multi-williams/440.jpg" title="" data-width="2048" data-height="1536">
        <img src="http://www.justin-credible.net/content/images/galleries/multi-williams/thumbnails/440.jpg" alt="">
    </a>
</div>

<h2 id="marqueeandtmolding">Marquee and T-Molding</h2>

<p>Lately, I've been using LEDs instead of fluorescent lights for my cabinet marquees. Unfortunately, the NovaMatrix 2 is no longer in production, so I went with a <a href="https://www.pickperfect.com/wanweileshop/product/led-strip-light-flexible-tape-300led-dc12v-indoor-outdoor-lighting-rope-a">generic roll of 12v LEDs</a>.</p>

<p>The <a href="https://www.escapepodonline.com/products/multi-williams-arcade-marquee?variant=26943686278">marquee</a> is from <a href="https://www.escapepodonline.com">Escape Pod</a> and the <a href="http://www.arcadeshop.com/i/864/red-smooth-3-4-t-molding.htm">T-Molding</a> is from <a href="http://www.arcadeshop.com/">Arcadeshop</a>.</p>

<div class="photo-gallery">  
    <a href="http://www.justin-credible.net/content/images/galleries/multi-williams/450.jpg" title="" data-width="2048" data-height="1536">
        <img src="http://www.justin-credible.net/content/images/galleries/multi-williams/thumbnails/450.jpg" alt="">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/multi-williams/460.jpg" title="" data-width="2048" data-height="1536">
        <img src="http://www.justin-credible.net/content/images/galleries/multi-williams/thumbnails/460.jpg" alt="">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/multi-williams/470.jpg" title="" data-width="2048" data-height="1536">
        <img src="http://www.justin-credible.net/content/images/galleries/multi-williams/thumbnails/470.jpg" alt="">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/multi-williams/480.jpg" title="" data-width="2048" data-height="1536">
        <img src="http://www.justin-credible.net/content/images/galleries/multi-williams/thumbnails/480.jpg" alt="">
    </a>
</div>

<h2 id="monitor">Monitor</h2>

<p>I was lucky enough to find a seller on Ebay with a lot of several brand new in box (old stock) 21" CGA CRTs. Though they weren't an exact fit for Defender's 19" screen, I couldn't pass up brand new, <em>never used</em> CRTs. It's not often you get to peel the protective plastic from a CRT and fire it up for the first time, especially since CRTs have been out of production since the early '00s.</p>

<p>Specifically, the monitor is a <a href="http://www.weiya.com.tw/products_detail.asp?le=english&amp;fid=70&amp;pid=71&amp;tCatName=">WEI-YA M2621H</a>. Powering it on for the first time was a treat. The colors are amazing. I can't wait to install CRTs in a couple of my existing cabinets that currently have LCDs.</p>

<div class="photo-gallery">  
    <a href="http://www.justin-credible.net/content/images/galleries/multi-williams/487.jpg" title="" data-width="2048" data-height="1536">
        <img src="http://www.justin-credible.net/content/images/galleries/multi-williams/thumbnails/487.jpg" alt="">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/multi-williams/488.jpg" title="" data-width="2048" data-height="1536">
        <img src="http://www.justin-credible.net/content/images/galleries/multi-williams/thumbnails/488.jpg" alt="">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/multi-williams/489.jpg" title="" data-width="2048" data-height="1536">
        <img src="http://www.justin-credible.net/content/images/galleries/multi-williams/thumbnails/489.jpg" alt="">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/multi-williams/490.jpg" title="" data-width="1536" data-height="2048">
        <img src="http://www.justin-credible.net/content/images/galleries/multi-williams/thumbnails/490.jpg" alt="">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/multi-williams/500.mp4" title="" data-width="2048" data-height="1536">
        <img src="http://www.justin-credible.net/content/images/galleries/multi-williams/thumbnails/500.jpg" alt="">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/multi-williams/510.jpg" title="" data-width="2048" data-height="1536">
        <img src="http://www.justin-credible.net/content/images/galleries/multi-williams/thumbnails/510.jpg" alt="">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/multi-williams/520.jpg" title="" data-width="2048" data-height="1536">
        <img src="http://www.justin-credible.net/content/images/galleries/multi-williams/thumbnails/520.jpg" alt="">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/multi-williams/530.jpg" title="" data-width="1536" data-height="2048">
        <img src="http://www.justin-credible.net/content/images/galleries/multi-williams/thumbnails/530.jpg" alt="">
    </a>
</div>

<p>One issue arose from the use of a 21" screen instead of a 19": all the available existing bezels have artwork created for the 19" screen, and thus wouldn't work. Instead, I went with plain smoked plexiglass, which actually looks good considering how busy the artwork on the marquee and control panel is.</p>

<p>Finally, I made a custom bezel using <a href="https://www.michaels.com/strathmore-400-series-presentation-board/10450295.html">presentation board</a> from <a href="https://www.michaels.com">Michaels</a>.</p>

<div class="photo-gallery">  
    <a href="http://www.justin-credible.net/content/images/galleries/multi-williams/540.jpg" title="" data-width="2048" data-height="1536">
        <img src="http://www.justin-credible.net/content/images/galleries/multi-williams/thumbnails/540.jpg" alt="">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/multi-williams/550.jpg" title="" data-width="2048" data-height="1536">
        <img src="http://www.justin-credible.net/content/images/galleries/multi-williams/thumbnails/550.jpg" alt="">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/multi-williams/560.jpg" title="" data-width="2048" data-height="1536">
        <img src="http://www.justin-credible.net/content/images/galleries/multi-williams/thumbnails/560.jpg" alt="">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/multi-williams/561.jpg" title="" data-width="2048" data-height="1536">
        <img src="http://www.justin-credible.net/content/images/galleries/multi-williams/thumbnails/561.jpg" alt="">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/multi-williams/570.jpg" title="" data-width="2048" data-height="1536">
        <img src="http://www.justin-credible.net/content/images/galleries/multi-williams/thumbnails/570.jpg" alt="">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/multi-williams/580.jpg" title="" data-width="2048" data-height="1536">
        <img src="http://www.justin-credible.net/content/images/galleries/multi-williams/thumbnails/580.jpg" alt="">
    </a>
</div>

<h2 id="gameboard">Game Board</h2>

<p>I wanted to avoid software emulation for this cabinet. Running PC hardware with a full operating system and MAME sometimes seems like overkill. In this case, I was able to use an <a href="https://en.wikipedia.org/wiki/Field-programmable_gate_array">FPGA</a> PCB that runs the original ROMs <em>without</em> any software emulation. The <a href="http://www.arcadeshop.com/i/1121/williams-multigame-jamma-pcb.htm">wSYSFPGA</a> by <a href="http://www.jrok.com">JROK</a> is absolutely amazing. Instant boot-up, just like the arcade hardware. An FPGA board is as close to the original hardware you can get without buying an original PCB.</p>

<p>I used a <a href="http://www.arcadeshop.com/i/383/jamma-harness-super.htm">Super JAMMA wiring harness</a> and the <a href="http://www.arcadeshop.com/i/806/switching-power-supply-20-amp.htm">HAPP Pro</a> power supply from <a href="http://www.arcadeshop.com">Arcadeshop</a>.</p>

<div class="photo-gallery">  
    <a href="http://www.justin-credible.net/content/images/galleries/multi-williams/590.jpg" title="" data-width="1536" data-height="2048">
        <img src="http://www.justin-credible.net/content/images/galleries/multi-williams/thumbnails/590.jpg" alt="">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/multi-williams/600.jpg" title="" data-width="2048" data-height="1536">
        <img src="http://www.justin-credible.net/content/images/galleries/multi-williams/thumbnails/600.jpg" alt="">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/multi-williams/610.jpg" title="" data-width="2048" data-height="1536">
        <img src="http://www.justin-credible.net/content/images/galleries/multi-williams/thumbnails/610.jpg" alt="">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/multi-williams/620.jpg" title="" data-width="1536" data-height="2048">
        <img src="http://www.justin-credible.net/content/images/galleries/multi-williams/thumbnails/620.jpg" alt="">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/multi-williams/630.jpg" title="" data-width="2048" data-height="1536">
        <img src="http://www.justin-credible.net/content/images/galleries/multi-williams/thumbnails/630.jpg" alt="">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/multi-williams/640.jpg" title="" data-width="2048" data-height="1536">
        <img src="http://www.justin-credible.net/content/images/galleries/multi-williams/thumbnails/640.jpg" alt="">
    </a>
</div>

<h2 id="endresult">End Result</h2>

<p>I am extremely pleased with this build. This project included several firsts for me: stencils instead of vinyl artwork, a brand-new CRT instead of an LCD, and an FPGA instead of software emulation.</p>

<p>I suspect I will soon be retrofitting my existing cabinets to have CRTs and FPGAs as well!</p>

<div class="photo-gallery">  
    <a href="http://www.justin-credible.net/content/images/galleries/multi-williams/650.jpg" title="" data-width="1536" data-height="2048">
        <img src="http://www.justin-credible.net/content/images/galleries/multi-williams/thumbnails/650.jpg" alt="">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/multi-williams/660.jpg" title="" data-width="2048" data-height="1536">
        <img src="http://www.justin-credible.net/content/images/galleries/multi-williams/thumbnails/660.jpg" alt="">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/multi-williams/670.mp4" title="" data-width="2048" data-height="1536">
        <img src="http://www.justin-credible.net/content/images/galleries/multi-williams/thumbnails/670.jpg" alt="">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/multi-williams/680.jpg" title="" data-width="2048" data-height="1365">
        <img src="http://www.justin-credible.net/content/images/galleries/multi-williams/thumbnails/680.jpg" alt="">
    </a>
</div>]]></content:encoded></item><item><title><![CDATA[Donkey Kong]]></title><description><![CDATA[<p><img src="http://www.justin-credible.net/content/images/2018/06/cropped-small.png" style="float: right; padding-left: 10px;"></p>

<p>I've always been drawn to Nintendo's cabinet style, so when I saw a Nintendo cabinet on Craigslist only an hour's drive away, I jumped at the chance to get it.</p>

<p>The cabinet I picked up was orange. It had been converted to Arkanoid and had a beautiful original Sanyo CRT</p>]]></description><link>http://www.justin-credible.net/2018/06/24/donkey-kong/</link><guid isPermaLink="false">c4b70b2b-ed4f-4990-815e-2f225fa5bbd8</guid><category><![CDATA[Arcade Restoration]]></category><dc:creator><![CDATA[Justin Unterreiner]]></dc:creator><pubDate>Mon, 25 Jun 2018 02:08:53 GMT</pubDate><content:encoded><![CDATA[<p><img src="http://www.justin-credible.net/content/images/2018/06/cropped-small.png" style="float: right; padding-left: 10px;"></p>

<p>I've always been drawn to Nintendo's cabinet style, so when I saw a Nintendo cabinet on Craigslist only an hour's drive away, I jumped at the chance to get it.</p>

<p>The cabinet I picked up was orange. It had been converted to Arkanoid and had a beautiful original Sanyo CRT with no burn in. The monitor bezel was for <em>Donkey Kong Jr.</em>, though it had been flipped backwards so the artwork was hidden.</p>

<p>There were two ID plates on the back of the cabinet: <code>DJR1-UP</code> and <code>DKC1-UP-US</code>. The former was obviously for <em>Donkey Kong Jr.</em> (which matched the bezel), and at the time I assumed the latter was for <em>Donkey Kong</em>, so I began the project as a plain <em>Donkey Kong</em> restoration.</p>

<p>It wasn't until well into the project that I found <a href="https://www.mikesarcade.com/cgi-bin/spies.cgi?action=url&amp;type=info&amp;page=NintendoList.html">this list</a>, which indicates that <code>DKC</code> was for <em>Donkey Kong 3</em>. That means the cabinet was probably a <em>Jr.</em> that was converted to a <em>DK3</em>, or visa versa.</p>

<p>I'm a little disappointed that I didn't find this out before I started the project, but at least it's still in the <em>DK</em> family.</p>

<div class="photo-gallery">  
    <a href="http://www.justin-credible.net/content/images/galleries/donkey-kong/010.jpg" data-width="1536" data-height="2048">
        <img src="http://www.justin-credible.net/content/images/galleries/donkey-kong/thumbnails/010.jpg" alt="The cabinet as I received it; an Arkanoid conversion.">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/donkey-kong/030.jpg" data-width="1536" data-height="2048">
        <img src="http://www.justin-credible.net/content/images/galleries/donkey-kong/thumbnails/030.jpg" alt="After removal of the control panel, marquee, and bezel.">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/donkey-kong/020.jpg" data-width="1536" data-height="2048">
        <img src="http://www.justin-credible.net/content/images/galleries/donkey-kong/thumbnails/020.jpg" alt="After removal of the control panel, marquee, bezel, and coin door.">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/donkey-kong/305.jpg" data-width="2048" data-height="1536">
        <img src="http://www.justin-credible.net/content/images/galleries/donkey-kong/thumbnails/305.jpg" alt="The ID plates for Donkey Kong Jr. (left) and Donkey Kong 3 (right).">
    </a>
</div>

<h2 id="base">Base</h2>

<p>The cabinet was in pretty good condition, but there were some rough areas I wanted to take care of first.</p>

<p>Nintendo cabinets have two wheels in back so you can tilt the cabinet up and taxi it around easily. The cabinet rests on a board in front, which can get quite beaten up over time. I decided to build a new base after watching this <a href="https://www.youtube.com/watch?v=O5sYknlL3-s">video</a> by <em>The Canadian Arcade</em>. My base is much simpler, but it gets the job done.</p>

<div class="photo-gallery">  
    <a href="http://www.justin-credible.net/content/images/galleries/donkey-kong/040.jpg" data-width="2048" data-height="1536">
        <img src="http://www.justin-credible.net/content/images/galleries/donkey-kong/thumbnails/040.jpg" alt="The worn out front stand board.">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/donkey-kong/050.jpg" data-width="2048" data-height="1536">
        <img src="http://www.justin-credible.net/content/images/galleries/donkey-kong/thumbnails/050.jpg" alt="Painting the newly constructed base.">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/donkey-kong/060.jpg" data-width="1536" data-height="2048">
        <img src="http://www.justin-credible.net/content/images/galleries/donkey-kong/thumbnails/060.jpg" alt="Mounting the newly constructed base.">
    </a>
</div>

<h2 id="marqueelighting">Marquee Lighting</h2>

<p>It's always so satisfying to see a cabinet's marquee light up, so I took care of that next. I used the <a href="http://groovygamegear.com/webstore/index.php?main_page=product_info&amp;products_id=307">NovaMatrix Linx 2 marquee LED strips</a> from <a href="https://www.groovygamegear.com">GroovyGameGear</a>. I used a previous version of this same product on my <em>Galaxian</em> restoration, and I was very happy with it. They are low voltage, so you can run them directly off of a 12v DC line.</p>

<div class="photo-gallery">  
    <a href="http://www.justin-credible.net/content/images/galleries/donkey-kong/061.jpg" data-width="2048" data-height="1536">
        <img src="http://www.justin-credible.net/content/images/galleries/donkey-kong/thumbnails/061.jpg" alt="Initial installation of the NovaMatrix Linx 2 marquee LEDs.">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/donkey-kong/062.jpg" data-width="2048" data-height="1536">
        <img src="http://www.justin-credible.net/content/images/galleries/donkey-kong/thumbnails/062.jpg" alt="Trying out the new LEDs with the lights out.">
    </a>
</div>

<h2 id="cabinettouchups">Cabinet Touch-ups</h2>

<p>As is normal with cabinets that have seen a lot of moves, this one had several dings that needed attention, especially around the edges. I used <a href="https://www.lowes.com/pd/ELMER-S-Carpenter-s-Color-Change-8-oz-Natural-Wood-Filler/50188271">Elmer's Wood Filler</a> to fill the missing chunks, then sanded down the areas once they dried to make sure they were smooth.</p>

<div class="photo-gallery">  
    <a href="http://www.justin-credible.net/content/images/galleries/donkey-kong/070.jpg" data-width="1536" data-height="2048">
        <img src="http://www.justin-credible.net/content/images/galleries/donkey-kong/thumbnails/070.jpg" alt="This was one of the larger chipped areas that needed filling.">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/donkey-kong/080.jpg" data-width="1536" data-height="2048">
        <img src="http://www.justin-credible.net/content/images/galleries/donkey-kong/thumbnails/080.jpg" alt="Some more dinged up areas that needed filler.">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/donkey-kong/090.jpg" data-width="2048" data-height="1536">
        <img src="http://www.justin-credible.net/content/images/galleries/donkey-kong/thumbnails/090.jpg" alt="Some more dinged up areas that needed filler." "="">
    </a>
</div>

<p>I needed to make sure everything was especially smooth because I decided to use vinyl siding instead of paint. I chose vinyl because it worked out pretty well on my <em>Galaxian</em> cabinet; I went with the <a href="https://www.thisoldgame.com/vinyl/donkey-kong-blue-vinyl-kit">blue vinyl kit</a> from <a href="https://www.thisoldgame.com/">This Old Game</a>.</p>

<div class="photo-gallery">  
    <a href="http://www.justin-credible.net/content/images/galleries/donkey-kong/100.jpg" data-width="1536" data-height="2048">
        <img src="http://www.justin-credible.net/content/images/galleries/donkey-kong/thumbnails/100.jpg" alt="Preparing for vinyl installation.">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/donkey-kong/110.jpg" data-width="1536" data-height="2048">
        <img src="http://www.justin-credible.net/content/images/galleries/donkey-kong/thumbnails/110.jpg" alt="Vinyl installation in progress.">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/donkey-kong/120.jpg" data-width="2048" data-height="1536">
        <img src="http://www.justin-credible.net/content/images/galleries/donkey-kong/thumbnails/120.jpg" alt="Trimming the excess vinyl.">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/donkey-kong/130.jpg" data-width="1536" data-height="2048">
        <img src="http://www.justin-credible.net/content/images/galleries/donkey-kong/thumbnails/130.jpg" alt="Vinyl installation complete for the left side.">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/donkey-kong/140.jpg" data-width="2048" data-height="1536">
        <img src="http://www.justin-credible.net/content/images/galleries/donkey-kong/thumbnails/140.jpg" alt="In progress vinyl installation around the coin door.">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/donkey-kong/150.jpg" data-width="2048" data-height="1536">
        <img src="http://www.justin-credible.net/content/images/galleries/donkey-kong/thumbnails/150.jpg" alt="Using an X-Acto knife to cut out the speaker grill holes.">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/donkey-kong/160.jpg" data-width="2048" data-height="1536">
        <img src="http://www.justin-credible.net/content/images/galleries/donkey-kong/thumbnails/160.jpg" alt="Finished installation of vinyl around the speaker.">
    </a>
</div>

<h2 id="coindoor">Coin Door</h2>

<p>The coin door had taken a lot of abuse. Normally this can be solved by a can of <a href="https://www.amazon.com/Rust-Oleum-7215830-Hammered-Finish-12-Ounce/dp/B00106C9CK">Rust-Oleum Hammered Metal Finish Spray Paint</a>, but in this case, the damage was more than just cosmetic. The door itself was so bent out of shape it would barely close.</p>

<p>I decided to use a <a href="https://forums.arcade-museum.com/showthread.php?t=383892">reproduction coin door</a> from a member of the <a href="https://forums.arcade-museum.com/">KLOV forums</a>. I also got new <a href="https://www.mikesarcade.com/cgi-bin/store.pl?sku=730AFACEKIT">coin mech face kits</a> from <a href="https://www.mikesarcade.com">Mike's Arcade</a>.</p>

<div class="photo-gallery">  
    <a href="http://www.justin-credible.net/content/images/galleries/donkey-kong/180.jpg" data-width="1536" data-height="2048">
        <img src="http://www.justin-credible.net/content/images/galleries/donkey-kong/thumbnails/180.jpg" alt="The brand new, reproduction coin door.">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/donkey-kong/190.jpg" data-width="1536" data-height="2048">
        <img src="http://www.justin-credible.net/content/images/galleries/donkey-kong/thumbnails/190.jpg" alt="New, reproduction coin door hardware.">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/donkey-kong/200.jpg" data-width="1536" data-height="2048">
        <img src="http://www.justin-credible.net/content/images/galleries/donkey-kong/thumbnails/200.jpg" alt="The hardware installed on the new coin door.">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/donkey-kong/170.jpg" data-width="2048" data-height="1536">
        <img src="http://www.justin-credible.net/content/images/galleries/donkey-kong/thumbnails/170.jpg" alt="The old coin door (left) next to the new one (right).">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/donkey-kong/210.jpg" data-width="1536" data-height="2048">
        <img src="http://www.justin-credible.net/content/images/galleries/donkey-kong/thumbnails/210.jpg" alt="The new coin door, installed.">
    </a>
</div>

<h2 id="graphics">Graphics</h2>

<p><a href="https://www.gameongrafix.com">GameOnGraphix</a> has done great work for me in the past, so I went with them again for the <a href="https://www.gameongrafix.com/side-art-repro/donkey-kong-sideart">side art</a> as well as the <a href="https://www.gameongrafix.com/marquees-repro/donkey-kong-marquee">marquee</a>.</p>

<p>The <a href="https://www.mikesarcade.com/cgi-bin/store.pl?sku=BEZELDKONG">monitor bezel</a> is from <a href="https://www.mikesarcade.com/">Mike's Arcade</a>, which has a great selection of Nintendo parts.</p>

<p>I found out the hard way that some Nintendo cabinets, like this one, need special T-molding with the middle groove offset instead of centered. Fortunately, I was eventually able to find <a href="http://www.chompingquarters.com/store.php/products/true-offset-nintendo-t-molding">Nintendo "True Offset" T-molding</a> from <a href="http://www.chompingquarters.com/">Chomping Quarters</a>.</p>

<div class="photo-gallery">  
    <a href="http://www.justin-credible.net/content/images/galleries/donkey-kong/211.jpg" data-width="1536" data-height="2048">
        <img src="http://www.justin-credible.net/content/images/galleries/donkey-kong/thumbnails/211.jpg" alt="The side art, unrolled after shipping.">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/donkey-kong/212.jpg" data-width="1536" data-height="2048">
        <img src="http://www.justin-credible.net/content/images/galleries/donkey-kong/thumbnails/212.jpg" alt="In progress installation of the side art.">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/donkey-kong/213.jpg" data-width="2048" data-height="1536">
        <img src="http://www.justin-credible.net/content/images/galleries/donkey-kong/thumbnails/213.jpg" alt="The new, reproduction marquee and monitor bezel.">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/donkey-kong/214.jpg" data-width="1536" data-height="2048">
        <img src="http://www.justin-credible.net/content/images/galleries/donkey-kong/thumbnails/214.jpg" alt="In progress installation of the T-molding.">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/donkey-kong/215.jpg" data-width="1536" data-height="2048">
        <img src="http://www.justin-credible.net/content/images/galleries/donkey-kong/thumbnails/215.jpg" alt="Finished with side art and graphics.">
    </a>
</div>

<h2 id="controlpanel">Control Panel</h2>

<p>There is a lot of empty space on a Donkey Kong control panel, and I had planned to build a custom one from scratch so I could include a small trackball and spinner in addition to a joystick with a few extra buttons. While looking for parts for that build, I came across a <a href="https://www.mikesarcade.com/cgi-bin/store.pl?sku=CPDKONG">reproduction control panel</a> on <a href="https://www.mikesarcade.com/">Mike's Arcade</a>. I knew I wouldn't be able to build a custom panel for cheaper, so I went with the Mike's product for now. I can always build a custom panel to swap out in future if I want.</p>

<p>For the control interface, I went with a <a href="http://www.ultimarc.com/minipac.html">Mini-Pac</a> from <a href="http://www.ultimarc.com/">Ultimarc</a> and one of their pre-made wiring harnesses. I hung onto the original wiring harness that came with the control panel, though, so I can use it if I ever decide to install an original Donkey Kong PCB.</p>

<div class="photo-gallery">  
    <a href="http://www.justin-credible.net/content/images/galleries/donkey-kong/220.jpg" data-width="2048" data-height="1536">
        <img src="http://www.justin-credible.net/content/images/galleries/donkey-kong/thumbnails/220.jpg" alt="The new, reproduction control panel.">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/donkey-kong/230.jpg" data-width="2048" data-height="1536">
        <img src="http://www.justin-credible.net/content/images/galleries/donkey-kong/thumbnails/230.jpg" alt="Wiring up the control panel to the Mini-Pac board.">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/donkey-kong/240.jpg" data-width="2048" data-height="1536">
        <img src="http://www.justin-credible.net/content/images/galleries/donkey-kong/thumbnails/240.jpg" alt="Programming the Mini-Pac.">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/donkey-kong/250.jpg" data-width="2048" data-height="1536">
        <img src="http://www.justin-credible.net/content/images/galleries/donkey-kong/thumbnails/250.jpg" alt="The control panel, installed.">
    </a>
</div>

<h1 id="monitor">Monitor</h1>

<p>The cabinet came with an original Sanyo CRT monitor that was in excellent condition. No visible burn in at all! I decided to get the <a href="https://www.ultimarc.com/avgainf.html">ArcadeVGA</a> from <a href="http://www.ultimarc.com/">Ultimarc</a>, which I'd heard good things about, so I could interface the monitor directly with the PC. This is a PCI Express video card that has a custom firmware that allows the card to output the special 15kHZ signal that <a href="https://www.ultimarc.com/monfaq.html">arcade monitors</a> require. I used <a href="http://www.ultimarc.com/">Ultimarc's</a> VGA monitor cable adapter to connect the CRT to the video card.</p>

<div class="photo-gallery">  
    <a href="http://www.justin-credible.net/content/images/galleries/donkey-kong/260.jpg" data-width="2048" data-height="1536">
        <img src="http://www.justin-credible.net/content/images/galleries/donkey-kong/thumbnails/260.jpg" alt="VGA to arcade monitor adapter cable.">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/donkey-kong/270.jpg" data-width="2048" data-height="1536">
        <img src="http://www.justin-credible.net/content/images/galleries/donkey-kong/thumbnails/270.jpg" alt="Testing the monitor connected to a Windows PC.">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/donkey-kong/280.jpg" data-width="1536" data-height="2048">
        <img src="http://www.justin-credible.net/content/images/galleries/donkey-kong/thumbnails/280.jpg" alt="Test run of Donkey Kong on the monitor.">
    </a>
</div>

<h1 id="pcwiring">PC &amp; Wiring</h1>

<p>I decided to go with an Intel Atom 330 Mini-ITX motherboard mounted using a <a href="https://www.logicsupply.com/ct100/">LogicSupply CT100</a> open-frame mount. This mount is nice because it also has spots for the PC's power supply and SSD.</p>

<p>The single speaker audio is driven by a <a href="https://www.amazon.com/dp/B01FZKA28Y/ref=cm_sw_r_cp_ep_dp_yjEkAbRB0F1A8">Lepy LP-2020A</a> mini amplifier. I chose this because it has an integrated volume knob that I can access via the coin door.</p>

<p>To turn the cabinet on/off, I added a standard arcade button to the rear top of the machine, which connects via a custom-built cable to the power-on pin of the PC motherboard. When the PC turns on, it pulls power from a smart power strip that turns on the rest of the outlets, powering on the monitor. Another single press elegantly shuts down the PC, then turns off the monitor.</p>

<div class="photo-gallery">  
    <a href="http://www.justin-credible.net/content/images/galleries/donkey-kong/300.jpg" data-width="2048" data-height="1536">
        <img src="http://www.justin-credible.net/content/images/galleries/donkey-kong/thumbnails/300.jpg" alt="The internals; PC (left), USB hub and audio amplifier (center), smart power strip and monitor power supply (bottom).">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/donkey-kong/301.jpg" data-width="2048" data-height="1536">
        <img src="http://www.justin-credible.net/content/images/galleries/donkey-kong/thumbnails/301.jpg" alt="The PC motherboard, power supply, and ArcadeVGA video card.">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/donkey-kong/302.jpg" data-width="2048" data-height="1536">
        <img src="http://www.justin-credible.net/content/images/galleries/donkey-kong/thumbnails/302.jpg" alt="The audio amplifier with a USB hub on top.">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/donkey-kong/303.jpg" data-width="2048" data-height="1536">
        <img src="http://www.justin-credible.net/content/images/galleries/donkey-kong/thumbnails/303.jpg" alt="The VGA to arcade monitor adapter board, mounted.">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/donkey-kong/304.jpg" data-width="2048" data-height="1536">
        <img src="http://www.justin-credible.net/content/images/galleries/donkey-kong/thumbnails/304.jpg" alt="The audio amplifier, USB hub, as seen from the open coin door.">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/donkey-kong/290.jpg" data-width="2048" data-height="1536">
        <img src="http://www.justin-credible.net/content/images/galleries/donkey-kong/thumbnails/290.jpg" alt="The custom cable used to connect the push button on the top of the machine to the PC motherboard's power-on pin.">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/donkey-kong/291.jpg" data-width="2048" data-height="1536">
        <img src="http://www.justin-credible.net/content/images/galleries/donkey-kong/thumbnails/291.jpg" alt="The push button on the top of the cabinet used to toggle power.">
    </a>
</div>

<h1 id="software">Software</h1>

<p>The PC runs Windows 8.1 and a custom build of MAME v0.197 to disable "nag" screens.</p>

<p>The machine has 11 games on it, and it boots directly into Donkey Kong when powered on.</p>

<p>Using a button key combination, the user can exit to a menu to select a different game. I couldn't find an existing menu system that looked like software from the cabinet's era, so I wrote my own in C#, and have made the source available on <a href="http://github.com/Justin-Credible/game-launcher-lite">GitHub</a>.</p>

<div class="github-widget" data-repo="Justin-Credible/game-launcher-lite">  
</div>

<p>As a bonus, I added a modern game: <a href="https://store.steampowered.com/app/360740/Downwell/">Downwell</a>. This is an excellent arcade-style platformer that was released in 2015, with simple yet addictive gameplay indicative of the golden age of arcade games. It has simple pixel art and color palettes and requires only three buttons (left, right, jump/shoot), so it was a perfect fit for the cabinet. It looks amazing on the CRT.</p>

<div class="photo-gallery">  
    <a href="http://www.justin-credible.net/content/images/galleries/donkey-kong/430.jpg" data-width="1536" data-height="2048">
        <img src="http://www.justin-credible.net/content/images/galleries/donkey-kong/thumbnails/430.jpg" alt="Donkey Kong running on the finished cabinet.">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/donkey-kong/450.jpg" data-width="1536" data-height="2048">
        <img src="http://www.justin-credible.net/content/images/galleries/donkey-kong/thumbnails/450.jpg" alt="My custom game selector frontend software running on the finished cabinet." "="">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/donkey-kong/460.jpg" data-width="1536" data-height="2048">
        <img src="http://www.justin-credible.net/content/images/galleries/donkey-kong/thumbnails/460.jpg" alt="Downwell running on the finished cabinet." "="">
    </a>
</div>

<h1 id="endresult">End Result</h1>

<p>I'm very happy with the way this cabinet turned out. The original CRT is beautiful, and running the games at their original resolution and being able to play a modern game on the hardware is novel.</p>

<p>In the future, I may add original Donkey Kong and/or Donkey Kong Jr. PCBs. Or maybe I'll even go back and build a custom control panel.</p>

<div class="photo-gallery">  
    <a href="http://www.justin-credible.net/content/images/galleries/donkey-kong/400.jpg" data-width="1536" data-height="2048">
        <img src="http://www.justin-credible.net/content/images/galleries/donkey-kong/thumbnails/400.jpg" alt="The finished arcade cabinet (1).">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/donkey-kong/410.jpg" data-width="1536" data-height="2048">
        <img src="http://www.justin-credible.net/content/images/galleries/donkey-kong/thumbnails/410.jpg" alt="The finished arcade cabinet (2).">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/donkey-kong/420.jpg" data-width="1536" data-height="2048">
        <img src="http://www.justin-credible.net/content/images/galleries/donkey-kong/thumbnails/420.jpg" alt="The finished arcade cabinet (3).">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/donkey-kong/470.jpg" data-width="1536" data-height="2048">
        <img src="http://www.justin-credible.net/content/images/galleries/donkey-kong/thumbnails/470.jpg" alt="The finished arcade cabinet (4).">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/donkey-kong/480.jpg" data-width="1536" data-height="2048">
        <img src="http://www.justin-credible.net/content/images/galleries/donkey-kong/thumbnails/480.jpg" alt="The finished arcade cabinet (5).">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/donkey-kong/490.jpg" data-width="1536" data-height="2048">
        <img src="http://www.justin-credible.net/content/images/galleries/donkey-kong/thumbnails/490.jpg" alt="The finished arcade cabinet (6).">
    </a>
    <a href="http://www.justin-credible.net/content/images/galleries/donkey-kong/500.jpg" data-width="1536" data-height="2048">
        <img src="http://www.justin-credible.net/content/images/galleries/donkey-kong/thumbnails/500.jpg" alt="The finished arcade cabinet (7).">
    </a>
</div>

<hr>

<p>A full gallery of pictures showing the restoration process is available via <a href="https://imgur.com/a/wNug0e6">Imgur</a>.</p>]]></content:encoded></item><item><title><![CDATA[Debugging Cordova build hooks]]></title><description><![CDATA[<p>As your Cordova project grows, you'll need to do outside-the-box things that Cordova doesn't offer support for. You can add <a href="https://cordova.apache.org/docs/en/latest/guide/appdev/hooks/">build hooks</a> to your project to perform these tasks.</p>

<p>These hooks can run on specific events (<code>before_platform_add</code>, <code>after_prepare</code>, etc.) to execute your arbitrary code. As your build</p>]]></description><link>http://www.justin-credible.net/2018/05/27/debugging-cordova-build-hooks/</link><guid isPermaLink="false">28a881c6-5d34-49e2-9a93-4428af7694b7</guid><category><![CDATA[Cordova]]></category><category><![CDATA[Software Development]]></category><dc:creator><![CDATA[Justin Unterreiner]]></dc:creator><pubDate>Sun, 27 May 2018 23:10:08 GMT</pubDate><content:encoded><![CDATA[<p>As your Cordova project grows, you'll need to do outside-the-box things that Cordova doesn't offer support for. You can add <a href="https://cordova.apache.org/docs/en/latest/guide/appdev/hooks/">build hooks</a> to your project to perform these tasks.</p>

<p>These hooks can run on specific events (<code>before_platform_add</code>, <code>after_prepare</code>, etc.) to execute your arbitrary code. As your build hooks get more complex, you may find that you want to attach a debugger and step through your script. Because build hooks are generally written in JavaScript to be executed in Node.js, this should be as simple as using the Node <code>--inspect</code> parameter. However, there are two different ways to write build scripts, and only one of these can be used in this way.</p>

<h3 id="legacybuildhooks">Legacy Build Hooks</h3>

<p>The <a href="https://cordova.apache.org/docs/en/latest/guide/appdev/hooks/#via-hooks-directory-deprecated">legacy build hook</a> is easiest method for getting started. To build one, you simply place a file in a subdirectory of the <code>hooks</code> directory of your Cordova project, with the subdirectory name matching the build event you want to hook. For example, to hook the <code>after_prepare</code> event, you would add a file with the following path:</p>

<pre><code class="language-text">hooks/after_prepare/01_your_script.extension  
</code></pre>

<p>This script is executed by Cordova as a <em>shell script</em>. Parameters are passed into this script as <a href="https://cordova.apache.org/docs/en/latest/guide/appdev/hooks/#non-javascript">environment variables</a>.</p>

<p>This complicates things a bit for cross-platform development. On Windows, your script needs to be something the operating system can execute (e.g., a batch file with extension <code>.bat</code> or <code>.cmd</code>). On Unix-y systems, this would be a shell script with its execute bit set (e.g., <code>chmod +x</code>) and a <a href="https://en.wikipedia.org/wiki/Shebang_(Unix)">shebang header</a>:</p>

<pre><code class="language-bash">#!/bin/sh
# Your script here
</code></pre>

<p>Thus, the first reason to avoid legacy build hooks is that they make targeting multi-platform development double the effort; you'll need an equivalent script for both Windows and *nix.</p>

<p>Even if you aren't targeting multi-platform development, the aforementioned problem is still introduced when attempting to debug: even if your script is written in JavaScript using <code>#!/usr/bin/env node</code> to indicate it should be executed in Node.js, it will be executed <em>out of process</em> by Cordova. This means that even though you may be able to attach to the Node process running Cordova, the build hook script is in a separate Node process, so your breakpoint will never be hit.</p>

<p>Before you can debug your scripts, you'll need to convert them to the modern format.</p>

<h3 id="modernbuildhooks">Modern Build Hooks</h3>

<p>The modern build hook format is JavaScript, <em>without</em> a shebang header. This is because the hooks are not executed as shell scripts, but instead loaded and executed by Cordova in the same Node.js process. If you have legacy build scripts written in JavaScript as shell scripts, you'll need to remove the shebang header and convert them to the new format.</p>

<p>Let's look at converting a script from the legacy format to the modern one. This trivial script simply writes out the names of the Cordova plugins that are installed when executed.</p>

<p>Legacy script:  </p>

<pre><code class="language-bash">#!/usr/bin/env node

console.log("Installed plugins are: " + CORDOVA_PLUGINS);  
</code></pre>

<p>Modern script:  </p>

<pre><code class="language-javascript">module.exports = function (context) {  
    console.log("Installed plugins are: " + context.opts.cordova.plugins.toString());
}
</code></pre>

<p>In addition to removing the shebang header, you need to wrap your script in a function that is exported. Your function will receive a <a href="https://cordova.apache.org/docs/en/latest/guide/appdev/hooks/#javascript">context object</a> as a way of passing parameters, instead of passing them via environment variables.</p>

<p>One final change is needed: previously, Cordova enumerated the <code>hook</code> directory's subdirectories looking for shell scripts. Now that the script is no longer a shell script, you need to add an entry in <code>config.xml</code> (or <code>plugin.xml</code>, if you are writing a hook for a plugin) to tell Cordova about the hook:</p>

<pre><code class="language-xml">&lt;hook type="after_prepare" src="hooks/your_script.js" /&gt;  
</code></pre>

<p>Once you've converted your scripts to the new format, you're ready to debug them!</p>

<h3 id="debuggingyourhook">Debugging Your Hook</h3>

<p>It's as simple as executing Cordova using Node with the proper <a href="https://nodejs.org/api/debugger.html#debugger_v8_inspector_integration_for_node_js">inspect parameters</a>. Note that you'll need at least version 6 or newer of Node.js for these parameters.</p>

<p>For example, if you want to debug your <code>after_prepare</code> hook, you invoke the <code>cordova prepare ios</code> command like this:</p>

<pre><code class="language-text">$ node --inspect --inspect-brk ./node_modules/.bin/cordova prepare ios

Debugger listening on 127.0.0.1:9229.  
To start debugging, open the following URL in Chrome:  
    chrome-devtools://devtools/bundled/inspector.html?experiments=true&amp;v8only=true&amp;ws=127.0.0.1:9229/dc9010dd-f8b8-4ac5-a510-c1a114ec7d29
</code></pre>

<p>Navigate to the URL given, and it should be paused courtesy of the <code>--inspect-brk</code> parameter. At this point you should be able to locate your script in the sources panel, set breakpoints, and then resume execution once you are ready. Once Cordova reaches the build hook phase, your breakpoint should hit!</p>

<p>If you are having trouble setting a breakpoint, you can also place a <code>debugger;</code> statement as the first line of your exported function.</p>]]></content:encoded></item></channel></rss>