Friday, October 28, 2016

TableTop Arcade - Raspberry Pi 3 & RetroPie Setup, Part 2

Project Index



In my last post, we went over how to set up the hardware of the Rasberry Pi.  Now on to the software. In addition to the hardware listed in the hardware listed in the previous post, the configuration will be easier if you have a USB keybord and mouse, so get one ready for this portion of the guide. 

For a much more detailed setup walkthorugh, I recommend heading over to the RetroPie homepage.

RetroPie Setup  -  https://github.com/retropie/retropie-setup/wiki

My guide will be a bit more streamlined, but still the parts that I consider important.

retropie-original-flat-outline


Flash the RetroPie Setup Image

To start, we need to get the RPi3 image from the Retropie website. You can get v.40 of RetroPie here.

In order to flash / install the image, you will need some additional software, and a MIcroSD card.  I listed one on the previous post, but as long as it is 16GB or more, you will be good to go.  The free software you need to flash the RetroPie image to the MicroSD is called Win32 Disk Imager, and can be downloaded here

Once you have installed Win32 Disk Imager, and downloaded the RetroPie image, extract the image to your desktop (using Windows Explorer, 7zip or WinRAR). 

Insert your MicroSD into your computer and it will show up as a USB Drive. 

Launch Win32 Disk Imager application to flash the image on our MicroSD. Simply open the program, select the location of your extracted image (.img file), the drive letter for your microsd card and press “write”. It will put the stock retropie image on the microsd and say write completed.  It will take a few minutes, so be patient unitl it reaches 100%. 


RetroPie Configuration

Make sure your USB Gampads or Arcade Controls are plugged into your RPI3 RetroPie setup.  Insert your newly flashed MicroSD card in the RPI3 and boot it up. The system will boot and automatically re-size the hard drive partition to use all of your microsd card. After an automatic reboot if you connected your controls it will ask you to configure your game pad. 

welcomescreen

Hold down a button on your game pad and go through the prompts. There may be more options than you need to map for your particular controller.  To skip a particular input, hold down any button on the controller until it moves to the next input.  Just hold down a button and it will skip that input. The “A” and “B” are important as they go forward and back in EmulationStation.  Once you complete the button mapping**, press whatever button you designated as “A” on the OK and you will launch into EmulationStation. 



**Quick Note: You have only mapped controls to navigate emulationstation and emulators that utilize the stock RetroArch configuration.  You may need to map the controls again for specific emulators (such as MAME) which we will cover in a later step.

Here is a sample of how a USB Gamepad similar to an SNES controller would look. 

 


In addition to the standard controls and buttons, you can also setup "hot-keys" to perform certain functions in-game.  Here are a few that are standard for EmulationStation. 
  • Select+Start: Exit a game
  • Select+Right Shoulder: Save State
  • Select+Left Shoulder: Load State
  • Select+Right: Input State Slot Increase
  • Select+Left: Input State Slot Decrease
  • Select+X: RGUI Menu
  • Select+B: Reset

Connect to Wifi

When you get past the controller setup, you will see a screen greeting you to the EmulationStation interface.  There aren't any systems or games set up yet, so lets jump to a few more configuration items first. 

 firstboot

Select "RetroPie" to get to the settings, then head to the WiFi menu. The RPi3 has built in Wifi, but if using a RPi2, you may have to install drivers for a USB adapter.  If you are connecting to a network that requires a password, you will also need to plug a USB keyboard into the Pie.  

Follow the prompts, and connect the Pie to your preferred network. 

It will open into this menu:

wifi1

Choose your SSID from a list:

wifi1

Type your Wifi Password (You may need to wait a bit after you finish for the configurations to save)

wifi1

After it's done configuring you should see your wifi info in the original menu:

wifi1

Press Escape on your keyboard and you will go back to EmulationStation.

If you would like to set up SSH to transfer ROMs via WiFi, you can set that up at this point. We are going to skip that step and just transfer the ROMs via a USB flash drive. 


Adding Games

Now we need to add some games or “roms” to our RetroPie folders. This will get the systems / emulators and games to show up whenever you add games for that particular system. 

Grab a USB drive, and do the following:
  • ensure that your USB is formatted to FAT32
  • create a folder called retropie on your USB stick
  • plug it into the pi and wait for it to finish blinking
    • This step allows the Retropie to copy all of the ROM folders to your USB drive
  • pull the USB drive out and plug it into a computer
  • add the roms to their respective folders (in the retropie/roms folder)
    • For some console systems like NES, your ROM files cannot be zipped or in zip files.  The ROM files should end in their native .nes extensions.  Others like MAME can be zippped. 
    • I personally have all systems un-zipped except MAME
  • plug it back into the raspberry pi
  • wait for it to finish blinking
    • This step copies the ROMs from the USB drive to the RetroPie
  • refresh emulationstation rebooting the system



Now your consoles / systems will show up in RetroPie since the ROM files have been added. For a system to show up, you have to add at least 1 ROM file for that particular system. 



If you didn't add ROM files for every system earlier, we will need to repeat this process for all the system you want to add to emulation station.


Adding Game Artwork and MetaData

Let’s get the artwork and data for our games. Retropie has a built in scraper that we will be using for this process. There is another Scraper that has been developed by ssleph that works a bit faster, but for this tutorial we will use the built in option. 

EmulationStation's built in scraper pulls info from thegamesdb. To begin, access the Scraper setting from the start menu in EmulationStation. 

srapermenu

As mentioned before, the default scraper is TheGamesDB.  Go to "Scrape Now". 

srapermenu2

Here you can deiced how many systems you want to scrape.  Your first run will be all at once. You can also let the scrapping process be a bit more automated by turning off "User Decided on Conflicts", but I prefer to verify the correct Metadata is being paired with my ROMs, so I leave User Decide "On".

srapermenu3

If you are only adding a few new ROMs, to a particular system, here you can select those systems individually instead of it trying to re-scrape your entire game library. 

srapermenu4

The screen below is what the matching process looks like. If there is a conflict with the ROM name, you have the ability to go to the input button and try a few different name combinations until the it finds a match.  For the most part the Scraper does a really good job.  Out of around 500 ROMs, I only had about 3 that couldn't find any MetaData or Images. 

srapermenu5

Once the scraping process is completed, all of your ROMs will be accompanied with Cover Art, and Game Data looking similar to the image below. 



Now on to an option Configuration step.  Almost done!


Bluetooth Controller Configuration

Setting up Bluetooth Controllers has a few more steps, but I will provide pictures of the setup process as a walkthorugh.  First head over to the RetroPie Configuration Screen and select the "Setup" menu. 

firstboot



Head to the "Configuration / tools" menu, then "bluetooth".





To add a new bluetooth controller, head to the first menu iteam, "Register and Connect to bluetooth Device".



Select the device you would like to connect, in this case a 8Bitdo NES30 Pro controller. 



Choose the Security Mode # 1 "DisplayYesNo"
























You should now get a message telling you the device has successfully registered. 






Head back to the main bluetooth menu, and select the 3rd option to verify your controller is connected properly. 
















It you have multiple controllers, follow the same steps and you will see them all "Registered" to the Rpie on this screen.



Last thing to do is decide on what kind of connect mode you prefer.  I went with the 2nd option, which looks for the bluetooth device at boot. 



If using the 8Bitdo NES30 Pro, the LEDs will be a solid blue color if connected properly to the Raspberry Pi.  
















I will also go over configuring the controls for an "Arcade Stick & Button" layout, but will cover that in a future post. 

Thats it!! Your Raspberry Pi 3 should be fully configured and ready to play.  On to building the Arcade Cabinet. 

Sunday, October 16, 2016

TableTop Arcade - Raspberry Pi 3 & RetroPie Setup, Part 1

Project Index


I have been using emulators to play old school arcade and NES games since the late 90s, as my original Nintendo Entertainment System (which I received for Christmas in 1988... when I was SIX!) only lasted a few years. Fast-forward almost 2 decades and emulation of older games is now extremity easy to do, all while using very inexpensive hardware, via the Raspberry Pi.

Over the next few weeks, I will be working on setting up a Raspberry Pi 3 as an emulator, and building a TableTop Arcade cabinet to house the micro-computer, screen, and controls.   The first series of posts will be a step by step guide on assembling the various components for the Pi, and installing / setting up RetroPie as the Emulator Front-end. 

Key Terms / Glossary

Before we begin, here is a list of basic terms you should familiarize yourself with if you want to tackle a project like this on your own. 
  • Emulator - In computing, an emulator is hardware or software that enables one computer system (called the host) to behave like another computer system (called the guest). An emulator typically enables the host system to run software or use peripheral devices designed for the guest system.  In this case, the "Host" (Raspberry Pi) will be emulating the "guest" systems of various arcade and game consoles (NES, SEGA, Neo-Geo, etc). 
  • ROM - A game file.  You can copy these files from physical medium (game cartridges, Disks, etc), but they are more commonly sourced from the interwebs. 
  • Raspberry Pi 3 (RPi3) - The latest version of a $35 micro computer with built in Bluetooth & wifi. You will need to source (or may already have) a 5v @ 2.5A MicroUSB power supply and a MicroSD card as well, and I will go over that in more detail in the hardware section.
  • RetroArch - The underlying workhorse software that contains the emulators and configuration files necessary to play games
  • EmulationStation - The front-end software included with RetroPie.  Essentially the pretty, organizational face of how you select your systems and games
  • RetroPie - an image file that you can flash on your sd card that has all the necessary software components to create a retro gaming machine (including both RetroArch & EmulationStation).  As of October 2016, the current version is v4.0
  • Image - A copy of a retropie installation that you can put on your MicroSD card so you do not have to manually configure the majority of the options on your own.
  • SSH - Secure Shell; just a way for you to access your RPI3 with a computer via a wireless network to change settings or add games
  • Scraping - The way to get metadata and boxart for your games from the internet. The scrapers RetroPie uses pull primarily from thegamesdb.net
  • MAME - Multiple Arcade Machine Emulator 


Hardware List - Raspberry Pi Setup




This list is only the components needed to play emulated games on the Raspberry Pi.  The full list of materials for the TableTop arcade cabinet will be in a future post.
  • Raspberry Pi 3 Kit
    • Although the Pi 3 alone is only $35, I suggest the following kit as it has most of what you need to get started
      • Vilros Raspberry Pi 3 Basic Starter Kit, Black Case - $49
        • Raspberry Pi 3 Model B
        • 5v @ 2.5A Power MicroUSB Power Supply (The one with your phone is probably only 2.1A, so I suggest this one to ensure enough power for your Pi.)
        • Set of 2 Heatsinks
        • Black Enclosure Case
  • 16GB Class 10 MicroSD Card
  • USB Gamepad Controller
    • For a basic yet very functional setup, I suggest this wired USB controller that is very similar to the SNES controllers of yore. 
    • If you want to step it up to wireless, analog sticks, and trigger buttons, I am currently using these Bluetooth controllers, and they work very well.   
  • HDMI Cable
    • You will need to plug the Pi into a display.  The Pi has an HDMI output for both video and sound. If your display doesn't have built-in speakers, there is a 3.5mm jack as well. 
    • Type and length of cable will vary depending on individual needs.  
So there is the basic hardware list for the Emulator Setup.  For roughly $70 you can set up a simple gaming platform, capable of emulating thousands of console and arcade games.


Assembly

Truth be told, there really doesn't need to be a "step" for this (super easy and straightforward), but going to post a few pictures anyways.

Here is a quick rundown of specs for the Pi 3, and a diagram showing the component layout

  • Raspberry Pi 3 Model B
    • SoC: Broadcom BCM2837
    • CPU: 4× ARM Cortex-A53, 1.2GHz
    • GPU: Broadcom VideoCore IV
    • RAM: 1GB LPDDR2 (900 MHz)
    • Networking: 10/100 Ethernet, 2.4GHz 802.11n wireless
    • Bluetooth: Bluetooth 4.1 Classic, Bluetooth Low Energy
    • Storage: microSD
    • GPIO: 40-pin header, populated
    • Ports: HDMI, 3.5mm analogue audio-video jack, 4× USB 2.0, Ethernet, Camera Serial Interface (CSI), Display Serial Interface (DSI)







Here is my Pi 3, after adding 2 heatsinks to the CPU and USB controller.  I also added an additional to the chip-set on the bottom of the Pi.  These heatsinks may not really be necessary unless you are doing CPU intensive tasks (like BitCoin mining), but since they come with the Kit, might as well use them.





  • Quick note, I am using a different case than what came in the kit.  The kit case works fine, I just liked the look of the one in these pictures a lot more. 


As far as the Raspberry Pi specific "Hardware" part is concerned, we are done.  In the next post I will cover installing the RetroPie image, and any configuration that needs to happen to work with the selected ROMs and Controllers.

Here is a sneak peak of the setup. Stay tuned!



Tuesday, October 11, 2016

Mini Cattle Prod / Bug & Spider Zapper

This project wasn't one I really planned in advance on doing, but after seeing a box of handheld bug zappers on clearance at the local Walmart for $3 each, I picked a few up and started thinking about ways to make them more "fun".



The bug zapper rackets work really well, and since purchasing them I have taken out around a dozen flies over the course of the summer.  We also occasionally  get spiders in / around the house, so I thought of a modification that I could do to make these more "poke" friendly.



The main idea is to leverage the existing electronics, but add a diode that can be used to prod bugs in situations where the racket shape isn't ideal.



For the terminal I will be using a cheap antenna from an old rabbit-ear setup.  After removing the racket and detaching the wires, it was apparent that a new end piece would have to be manufactured to both keep the electronics within the handle, and provide a mounting point for the terminal.  Decided to use some MDF wood for that part.



Once the height was correct after a bit of filing / sanding, went ahead and drilled a few holes where the plastic parts of the zapper are secured by screws.



A look at how the new end piece lines up in the handle.



Wend ahead and painted it black and drilled the holes to allow for the wires to come out and to attached the antenna. As mentioned before, only 1 blue wire is needed and I taped off the other one inside the handle.  Once you have an idea of how long you want the terminal to be, you will need to add some additional length to the red wire, and throw on some heatshrink or electrical tape.  I used a bit thicker wire than what comes out of the handle to make the end of the terminal a bit stronger.



At this point, I pushed the antenna into the end piece being careful not to damage the wires I had previously pulled through.  Once the end is sticking about just over 1/4in, strip a bit of the end off, and apply some solder so the end wires don't separate.  I also roughed up the end of the antenna a bit with a file to make for a better electrical contact point. You may have to play with how far out the wire sits to get the spark to engage correctly, but once figured out, I used superglue withing the antenna shaft to keep the wire in place.

For the blue wire, you will need to drill a small hole in the base of the antenna and pull it through.  After roughing up a small spot with a file, solder the end of the blue wire to the base of the antenna.



Project completed!  Total build time 30-45min. Zapper length is around 18in.  Still runs off 2x AA batteries, and the LED lights up when the button is depressed.  Check out the video below to see it in action on a paper clip and a spider in the back yard.




YouTube Video























Monday, October 10, 2016

Remington 870 Stock Upgrades Magpul M-Lock, Archangel Shell Carrier

The first firearm I ever purchased myself, was a Remington 870.  I was a senior in High School, and it has been through a lot of hunts and clay shooting over the last 15 years. It has also been beat up a bit, so I have decided to breath new life into the shotgun by adding a new synthetic stock.   Here it is with the original stock.



For the shotgun stock upgrades, I will be using the Magpul M-LOK systems. They feel good in the hand, and the rear offers an adjustable length of pull.  Plus, I really like the way they look.   The install for the standard 870 was really simple, took about 15min. In addition to the M-LOK I also added a Remington SuperCell Recoil Pad.



Looks brand new!

Also got a hold of a Remington 870 Tactical lately, and didn't want it feeling left out.  It will also receive a stock upgrade with the M-LOK system, and a few additional accessories.



For the 870 Tactical, I picked up a small weapon light to be mounted on the fore grip, and a 7 round shell carrier made by Archangel.  I recently upgrade the stock on my Springfield M1A Loaded to a stock made by Archangel, and have been extremely pleased with it. The install took about 10min, and happy to report it is very solid once installed and does not interfere with the pump action at all.



Final product looks pretty dang good, and it feels great.



Going to give the new stocks a try this weekend.  To wrap up the post, here are a few Before/After pics for comparison.