Thursday, November 21, 2013

Web Controller/API for Sonos System

There is node.js Sonos API and web controller interface being written by Jishi over at the Sonos forums. You can follow development and report bugs in this thread on the Sonos forums.

The webcontroller is still under development and has some issues with queues at the moment, but the primary features such as grouping, play/stop/etc and volume seem to work correctly. You can see from the screenshot below it appears a clone of the desktop controller and looks great!


Screenshot of the current state of the web based Sonos controller.
This was my first real foray into node.js and git platforms, something I had somehow managed to avoid until now. I wanted to run the web server on my old Drobo-FS so I first needed to install git and node.js from droboports.com.

To install I then changed directory to the DroboApps folder and ran the following commands:
  1. git clone https://github.com/jishi/node-sonos-web-controller (download the latest master build from the git repository)
  2. npm install (install all of the required dependancies) 
    Terminal showing installation commands
  3. cd node-sonos-web-controller
  4. node server.js (start the node.js web application)
    Service running. You can see it has automatically detected my zones.

You can update the project to the latest development master at any time by running "git pull" from the node-sonos-web-controller folder.
Issued that I encountered were: 
  1. The default apache installation I had installed on my Drobo-FS was running on port 8080. I just killed it as I wasn't using it anyway.
  2. I received "http not found" errors when trying to run "npm install" to get the required modules. Most likely this was a Drobo git/SSL build specific issue and I managed to bypass it with the following command: "git config --global http.sslVerify false"
It's a great project, I'm looking forward to seeing how far they go with it and if eventually new features are even added, such as requiring a PIN code, party mode etc.

Friday, January 11, 2013

Adding WIFI to the Arcade Cabinet in the Shed

I had been using my FRITZ!Box USB N stick in the shed connected to my arcade cabinet had a relatively weak connection to my router in the front of the house. Copying files to and from the machine was pretty slow 1-2MB/s and occasionally I would lose connection and would not be able to use the network when the shed door was closed.

To solve this I ordered from Amazon (via MyUS.com) a reasonably powerful Alfa 2000mW USB Wifi adapter ($39 USD) built into outdoor housing. To attached it to the shed I used the included screw rings to attach it to the gutter.

I then drilled a 10mm hole into the shed and fed through the mini-usb cable to the PC. The other end of the cable is 2 standard USB plugs (one of extra power) which are connected into the back of the computer.

Close up of  mounted Alfa Network WIFI endpoint

Antenna mounted to shed opposite cabinet
The connection in Windows now shows full bars and fluctuates between 130-150Mbit and copying some test files from my NAS transfer at a reasonable 6-9 MB/second. Problem solved :)

Tuesday, January 1, 2013

Building Arcade Hyperspin/Mame cabinet - Part 4

With the help of some friends I got the cabinet built from painted pieces in a solid day. It mostly comes together with IKEA type fasteners and you'd want at least another person to help build it.

I haven't gone into too much detail on the build process as Troy from ArcadeWorx provides very detailed build instructions with the kit.

Half built, adding speakers.
Completed product!
I'm very happy with the result and the colour looks great.

I was hoping to print the artwork at a professional printing shop on a nice material, however I was running out of time so I just measured the perspex panels and printed the artwork to size on multiple pages on my home laser jet. I then cut out the artwork and glued it to the back of the perspex with a UHU waterbased gluestick. My artwork source for the move lists was from Donovan Myers blog.

Street Fighter artwork for the control panel
I got a great hand from a friend with the console wiring. If I had been left to my own devices it would be a birds nest rather than the "milspec" result below.

Very neat wiring.
I'm using two Akishop PS360+ PCBs for the controllers which I purchased from In2Amusements. The autodetect their USB host on the other end when powered up and are compatible with PC, PS3 and XBOX 360.

At the moment I have the controllers configured as XBOX controllers for Windows, as this allows the joysticks to be compatible with Street Fighter 4 Arcade Edition (PC) which doesn't detect the joysticks when they appear to Windows as the "hat" pad. This has also lead to issues with Hyperspin as the Hyperspin 1.3x releases seem to have a compatibility problem issues with XBOX 360 controllers.

At the moment I am working around these issues by disabling the Joysticks in Hyperspin and using Xpadder software (~$10) to make the Joysticks send actions as keyboard key presses. For some reason Xpadder would hang as not responding when I first ran it so I set the executable as "Run as Administrator" and XP Compatability mode and it started working properly.


Every thing was setup for my New Years Eve party (~30 guests) and everyone had a great time reliving some of the classics from their youth. Later in the night I was even asked to attach my two USB joysticks for some 4 player games.
In use - 4 player with 2 USB Sticks connected.

I've still got a lot of work to do with Hyperspin and setting up all the emulators. Currently I'm still in a bit of semi-manual process with the keyboard required for certain features, so I think that the next couple of months will be spent on software configuration and possibly some rewiring of extra buttons and adding new features.