Sunday, April 6, 2014

Streaming XBMC


  I thought I would go through my current Media Center setup since it has changed over the past few months.  I originally had a server setup in the basement with one streamer I built for upstairs.  Now, with another TV in the household I have upped the streamers and went through a few options.

Streamer Choices

  First, I would like to go through the choices I looked at for streamers, and the reason behind why I picked what I did.  So let's start off with one of my favorite little computer!

Raspberry Pi

  Yes, the Raspberry Pi is such a cool little gadget.  I say gadget because you can transform it into just about anything.  I recently used it in my briefcade project, and I knew that it also had development within the XBMC area.  To get a better understanding of the capability of the Pi as a streamer, you need to dive into your software options.  I currently know of three.

    I have used Xbian very little.  I know the tagline for this software is “XBMC on Raspberry Pi, the bleeding edge”  and it shows.  The software will be with the most up to date nightlies, atleast in my usage, and that comes with it's own pros and cons.  I am not able to comment much further on Xbian because I have not used it too much, suffice to say what I did use of it, I was impressed.  Faster menus than I was used to with the Pi and seamless play back.  I would think that heavy usage would turn up some bugs, etc. but for what I used, it was great.

    I love the idea and concept of Openelec so much.  This is a branch of XBMC built from the ground up using a kernel of Linux.  What you get as an end user is, in my opinion, the very epitome of XBMC as a Media Center.  Just about all of the configuration is handled within XBMC, the speed and fluidity of usage is phenomenal.  Setup and usage is fast, quick, and painless, and that is what I love about it so much.  If you have an "older" PC, running XP or something similar, you will get SO MUCH more mileage out of using Openelec instead of applying an OS and running XBMC on top of that.  Having said that I did run into two issues when using Openelec:  
   1) Further customization to bring my Media Streamer to what I wanted could not be fulfilled.  I specifically was looking for Hibernation and Wake On Lan capabilities that I could not get Openelec to do.  I am not sure if it is possible, but when I asked on the forum I was greeted with a stern, no way.
  2) Certain video files would not play within Openelec.  I had a few video files that were ripped the same as all my other files, but for some reason it would only play audio within Openelec.  After searching around, I found some configuration settings within Raspberry Pi Config.txt (file created within Raspberry Pi to configure what the device will do, etc.) to overclock and handle this issue.  As a result, my Openelec Pi started to lock up and freeze.  I couldn't have that so I switch to the third option.

    The rock solid Raspbmc is my go to for the Raspberry Pi.  Setup takes a little time and the menu movement is sluggish when dealing with a large amount of media/artwork/metadata, etc.  The upside to this is a more rock solid media streamer that I have had no issues with playing media over, once so ever.  I make the trade for speed to have a more solid player, and the Raspbmc configuration within XBMC (accessed via My Programs) allows for safe overclocking which can help with menu navigation.

    One reason the Raspberry Pi gets so much love is the price point (around $45 shipped) but there are some caveats to the price.  The Raspberry Pi does not come with everything you need to get started right out of the box, unless you buy a starter kit, which generally go above the cost of just the board.  You will need a SD Card to load the OS for the Pi, and if you are looking for Wireless capabilities you will need to purchase a capable Wifi dongle.  A remote might also need to be purchased depending on your needs, but the Raspberry Pi does use HDMI CEC, meaning you can control your Pi with your TV Remote.  These controls are basic, but they will get the job done for base use, i.e. menu navigation and playing.  
   If you are looking for a remote I would hesitate to suggest the  RII K25 2.4Ghz Wireless Air Mouse Keyboard & Infrared Remote Control.  I will go further into this when I explain my setup, but it is an advanced remote that gets the job done with a few caveats.  


  Ouya, the little gaming computer that could.  The OUYA was originally a kick starter campaign that held the title of fastest successful kick starter.  The OUYA is an Android based micro PC that comes with one gaming controller, power supply, and HDMI cable.  If you are good to navigate the menus via a gaming controller, than the $99 price tag is all you have to worry about, else you will need to look into the what remotes work with the OUYA, etc.  I used the RII K25 2.4Ghz Wireless Air Mouse Keyboard & Infrared Remote Control and it worked surprisingly well with OUYA.
  My main gripe with the OUYA seems a lack of support and foresight, and I am not speaking on the games.  There seems to be about one or two people supporting an actual OUYA XBMC, and everyone else is side loading, installing software not through the OUYA store, the Gotham builds for the machine.  The issue with this is, the OUYA gets some quirks, i.e. crashes, when trying and use the machine as a media streamer.  After around a month of constant restarts, and buffering issues, I gave up and went back to the Pi.  
  Side note, the Wifi in the OUYA is Atrocious!  Do not think for a second you can use this machine to stream media without a hard line, it is not even worth it.  I heard new units had a better Wifi module installed, but there is no way to tell a newer unit from an older one.  My advice, do not rely on the Wifi to stream anything, you will just be left heartbroken.

Build your own



 I went the build your own PC route for a streamer, when I was not able to get what I wanted from the first two options.  What I had laid out was this.  I want an all in one box, that can handle playing all my media in a timely manner, display all the eye candy for a somewhat intensive skin(user interface design for XBMC), play all disc based media (DVD and Blu Ray), handle TV streams coming from the server, and hide behind my TV.
  To accomplish this, I built my own PC with the Gigabyte AMD E-350D APU AMD A45 FCH Mini ITX DDR3 1333 Motherboard/CPU Combo GA-E350N.  This motherboard came with an APU processor that I had read would handle BluRay playback.  This was the smallest form factor for Mobo I could get for my price range.  Below I have listed out the rest of my build.

Mobo + ProcessorGigabyte AMD E-350D APU AMD A45 FCH Mini ITX DDR3 1333 Motherboard/CPU Combo GA-E350N
Ram:Corsair XMS3 4GB (2x2GB) DDR3 1333 MHz (PC3 10666)
BluRay Player: Asus Black 12X BD-ROM 16X DVD-ROM 48X CD-ROM SATA Internal Blu-Ray Drive
Case:In-Win 200-Watt Mini-ITX Case, Black BP655.200BL
OS: Win 7 Home
Remote: Tivo (Premiere)

In total to complete the build was around $450, and the machine is still chugging along.  The build was around a year ago so the hardware is holding up nicely so far.  I installed Win 7, but a free linux install can also be used for a build your own, to not increase cost.  The main reason I used Win 7 was to handle TV streams and Bluray play back.  

In summary, my two streaming units are 1 Raspberry Pi and 1 home built PC.  I am happy with each as a streamer and the entire infrastructure/design in general.  Below is my quick summary/round up for Cost, Pros, and Cons of each option.

Round Up 

Money $:
Raspberry Pi: Around $45 Shipped (additional $4.50 or so for codec usage)
      SD Card (8 Gig) $6 on Amazon
      Wifi Dongle (Edimax on Amazon) $9.99
OUYA: $99 + Tax (if applicable)
Build Your Own $450 +

Raspberry Pi: Small, Cheap, gets the job done, can hide behind your TV and use the USB port as power
OUYA: Fast, mostly an all in one package, also play some android games for "free"
Build your own: Limitless possibilities just hindered by your pocketbook, any OS of your choice to use, Fast as you want it to be.

Raspberry Pi: Slow menu, somewhat hidden fees, 
OUYA: Little support, crashes like crazy, wifi is unusable
Build Your Own: Cost prohibitive, can be loud, larger than micro pc options

Next time:
  In my next post I will go into my current setup with the Raspberry Pi and self built HTPC streamers.  My main server setup has not changed, but I will touch on the hibernation and wake up I use for the setup.  

Thanks for reading, until next time...

Tuesday, December 17, 2013

Briefcase Arcade

  This project came about in an odd way.  Where I work, we have an arcade club.  Basically, a group of guys get together and play old school video games.  The only problem is I am the only guy in the club that has an arcade we can use.  So, after getting tired of hosting the arcade club every time we wanted to play, I started thinking about how to make an arcade portable.  I finally arrived at the conclusion to make one into a briefcase.  Also, I watched Iron Man 2 and saw Tony Stark put the Iron Man suit into one, so I figured I could put an arcade into one.  

  I started with an idea of having a bartop style arcade that would break down into a portable .  After that idea sank in the planning phase, I thought about just placing an arcade within an old style (80's) briefcase.  After finally finding one at goodwill for around $5, I could begin the project.

After gutting the briefcase, I started try to figure out the layout and how the components would fit into the case.  I then took apart my LCD monitor to mount within the briefcase.  The LCD I used has an external power supply of 12 volts.  This is important for ease of powering the briefcase  arcade.  The monitor had metal brackets to attach to the inside of the plastic case.  I simply reused these to mount the monitor within the briefcase.  After figuring out that I would need to lengthen the cables for the monitor to fit within the case, I realized I could flip the monitor upside down and not have to change any cables, etc.  I would need to change a setting within Raspberry Pi to flip the monitor 180 degrees.  This is a simple change that you can implement within the config file.

After acquiring the briefcase, I had to think about what computer would be able to run within the case.  Fortunately, I had a raspberry pi sitting around after I no longer needed it for streaming.  This would be perfect for the briefcase arcade, now formally known as the Briefcade.  So, with the small computer in place, I needed to work out the joysticks and buttons.  Using the traditional joystick and buttons I used for my last arcade build would not fit within the form factor I had to work with, within the Briefcade. 

  I searched on the internet and found the smallest joystick (height) and button were Sanwa style.  After receiving these in the mail, I still had an issue with height of the joystick.   With the balltop placed on the joystick shaft I could not close the Briefcade with the monitor in place.  I finally had to settle on leaving the joystick balltop removed while the case is closed.  This isn't too inconvenient but not optimal...

I then had to create the control panel.  I first cut the holes for where I wanted the joystick and buttons.  I wanted be able to open up the panel to access the computer, wiring, etc.  I made the "main" board (Joystick and Gameplay buttons) the area that can be lifted, and the other buttons (Exit, 1 player start, and coin up), the non moving area. 

After making the cuts and holes, I mounted joystick and buttons.  I then found out the level for the joystick to function, i.e. move around and not scrap the bottom of the case, and also be able to close.  After getting the height correct, I made mounts to hold the control panel in place, and then screwed all of these within place.  Then I mounted the hinge to be able to open the control panel. 

The next step was figuring out controller input from the control panel.  With my last build I went with the iPac controller that you wire in the buttons and connect to your PC with USB or PS/2.  The Raspberry Pi however has a GPIO (General Purpose Input and Output).  With this you can send signals to the PI.  The layouts of ground, +5 V, etc. can be found on the Pi wiki page.  I found my correct model, and went about wiring all the buttons and joystick up to the proper inputs with these 40p dupont wires.  These are great as they connect up to the GPIO pins perfectly.  Once I got the connections up, I then worked with a Linux script that takes the GPIO inputs and translates them into keyboard presses.  With this, you can then create the correct inputs for MAME emulator.

The Raspberry Pi has a lot of support and a great community.  There are several builds of Linux that will run MAME on the Pi.  I used Shea Silverman's PiMame.  This has a great menu, easy setup, and terrific support.  After getting this setup and running, I had to do some minor tweaks to get the controls working correctly. 

My last step was power for the Pi and monitor.  My monitor uses 12v to be powered, and the pi required 5v.  I made a hole on the side of the Briefcade I was able to use a female power connector.  The incoming wires then go to a switch I bought at RadioShack that has a nice On Off sign on top.  I then split the wires, with one pair going directly to the monitor, and the other going into a USB car charger.  The USB car charger is the kind that plugs into your cigarette lighter..  These convert the voltage from 12v to 5v.

Here is all the internals for the Briefcade

Here is the finished product.  The Briefcade or Arcase or Businesscade.  I personally like the Businesscade but most people call it the Briefcade, so I will go with that.

Briefcade Closed

Briefcade Open

Briefcade getting some attention

Saturday, June 8, 2013

MAME Guitars

I have not posted in awhile, and it has mainly been because life has gotten in the way of my arcade hobby.  I have found time to work on a few additions to the arcade though.

Guitar Freaks

  Guitar Freaks is an arcade game that was released only in Japan, and was the basis of the Guitar Hero and subsequently Rock Band, Band Hero, etc. line of games.  The novelty of playing a guitar controller has already gone through its 15 minutes of fame, and now not many people care for the rhythm based rock star role-playing genre anymore.  It is still fun to pick up and "belt out" a few tunes, especially if they are the crazy J-Pop ones I have on Guitar Freaks and Guitar Freaks 2.  Since the Guitar Freaks arcades never saw their way to western shores, they never went through the "Americanization" process of changing out all the J-Pop songs with American rock songs.  I for one, like this, as I think the games have a fresh appeal to them, in the sense that I am not playing through the classic hits of the 70's, 80's and 90's like so many radio stations seem to put on repeat in this day in age.

How to Play
  Guitar Freaks controls just like all the other guitar based games, although there are only 3 buttons to press instead of the US standard of 5.

Now, this can be done with the buttons I have on the control panel of my Arcade, but that would not be fitting for such a game.

Making the Controllers
I went down to Goodwill and found some PS2 Guitar Hero guitars ($3 each) and also bought a PS2 to USB converter for the MAME computer.

This converter can take in 2 PS2 plugs, so it is perfect for the 2 guitars I have.

A simple hook up and I am ready to play.  The MAME computer recognized the guitars as controller. After that it was a simple configuration in MAME for each Guitar Freaks game, and I was good to go, but there was a problem.

Guitar Freaks game color layout for buttons 1,2, and 3, are red, green, and blue respectively.

The Guitar Hero controller layout is green, red, yellow. blue, and orange.  This presents a problem if you are picking up the controller for the first time, and do not know the difference in layout.  To fix this I took apart each guitar and moved the buttons so they correlated correctly.

After that I just reassembled the red guitar, but my "problem" didn't stop there.

 I want a universal feel to my arcade, and one of the main things I want to keep consistent is color. Right now, 1 player is blue, 2 player is red, 3 player is green, and 4 player is yellow.

 I kept this up with the arcade guns I bought with blue and red being 1 player and 2 player respectively.

To keep this up I disassembled the other guitar controller.

Took the red portions, and spray painted them blue with a plastic coating spray paint.  I used Rust-Oleum Gloss Protective Enamel spray paint.  It has held up with the plastic so far.

With the controllers ready to go, I needed a way to hold them, and what better way than...

Guitar Hangers!

These were a cheap eBay find, about $6 total, and they were a simple assembly onto the side of the Arcade.

Well, now the Arcade has guitars to play any Guitar Freaks games I need to.  Next, I think I want to add a steering wheel :)  Until next time, thanks for tuning in!

Friday, December 28, 2012

MAMEcade Rev 1.2

Lightguns and Stickers
  I know I have not updated the blog in awhile, but I have recently updated my arcade with light guns and also a few stickers to make it go faster.

  I hopped by my local Hobby Lobby and grabbed a pack of alphabet and number stickers in Red, Green Yellow, and Blue.  I wanted to indicate the coin up buttons with 1P Coin, 2P Coin etc.  I also wanted to indicate the exit game button in the center of the CP.  I tried to line up with lettering as best I could, but I feel I fell short on this.  The letters tend to go either down or are not all in a straight line.  Still, I am happy with the way it turned out.

After I had the stickers in place, I went back over the areas with mod podge to give it all a consistent look. I think it turned out pretty well.

Light Guns
  Now onto the really fun stuff.  I ordered a pair of light guns from, they have a pair of guns plus a sensor bar for $168, which is not too shabby.  I got the sensor bar uncased since I will be mounting it to my bezel.  When the package came it contained the two guns with 10 ft usb cables, and the sensor bar with around a 5 ft. cable.  The cables for the guns were plenty long, but I wish the sensor bar cable had been longer, as I had to move my computer around in the cabinet, but it was not a huge deal.  The package also came with some manuals.  I picked these guns specifically since they used the Ultrimarc Aim Trac components which I read were the best.  I was not disappointed.

My first tasks (after moving the computer), was to mount the sensor bar behind the bezel.  I drilled holes for all the IR sensors (5 on left and 1 on the right) to poke through.  I was able to get a snug fit, and the sensor bar did not need anymore mounting as the led's held it in place.

  Here are the leds in the bezel (They do not light up where the human eye can see them, so they are pretty incognito when you have it all rigged up.)

  One of the hardest (if not the hardest) parts of the light gun MAME setup is the calibration.  I spent a few hours tweaking the calibration by re calibrating the guns and judging were the best place to stand was.  I finally figured out that the best place it a few feet away and in the center, this was hard for me to figure out as I was calibrating the 1 player gun to be standing just to the left, and 2 player gun standing just to the right. After I found this out, I calibrated the guns in the center, and I haven't felt it to be really off, although I still need to play test it with friends more.  If anyone knows any good calibrating tips, please let me know by posting in the comments, I would be very appreciative!

  The final part to have the guns added to the mamecade was having holsters for them.  I searched around online, and saw a few ideas of using towel holders, bike mounts, etc, but what I was looking for was more of the big metal pentagon holster that I remember from the arcades.  I found that HAPP sells something like this, but it would have to be modified, and I did not want to pay $30 for them, so I headed over to Home Depot, and I found what I was looking for.  In total it cost me around $5 and a lot of sweat equity.
  First I found some sheet metal that were  bent at a 70 or so degree angle, and they were longer on one side then the other.  I bought 4 each for each gun, and a mounting hurricane bracket for each gun.

  Next I started to solder the "plates" together to start to form my pentagon.

Yes, Yes I am awesome at soldering...

After I got to the last two plates I had to duct tape them together as they didn't quite reach, I then solder the tops together and voila!

I have my holster.

I then drilled two holes to mount the hurricane bracket at an angle, and then spray painted it black.

After that I took off my control panel and screwed the holster to the back of the front end of the CP.

Rinse and repeat for gun #2 and I have my holsters.

They look pretty snazzy!

Thanks for tuning in!