Nike+ Venue Check-In Hardware, a How-To Guide

There are at least two ways to build the Nike+ Check-In Hardware that talks to stumble.to. One is easy, one is a bit difficult. I will first focus on the easy way, and then if you are daring enough with your soldering skills, I will send you off in the right direction for a more difficult way that does not require the very handy SparkFun hardware.

Things you will need:

  • Nike+ Sensor Sport Kit (this is the one with the white receiver and a Nike+ shoe sensor)
  • More Nike+ Sensors for your friends (they sell these slightly cheaper without the white receiver)
  • SparkFun Nike+iPod Serial Adapter
  • Mini USB cable
  • Maybe a nice non-metal box to put it in
  • Maybe some Nike+ sensor clips for non-Nike shoes
  • Any desktop, laptop, or embedded computer system (Unix or Mac OSX is best, Windows may need some extra work)
  • A stumble.to account and API key
  • The stumble.to nike agent

    If you run into trouble:

    Contact our support department, er, i mean, Casey, by emailing casey_nike_support @ mobilesquared.com. Tell me as much as you can about your situation and I will try to steer you in the right direction.

    Step 1: Connecting up the hardware

    Connecting the hardware is very simple, thanks to the prefabricated Nike+iPod SparkFun board. Simply connect the white receiver to the iPod connector. Plug the USB into the SparkFun board and the computer. A red LED will light up, and a new serial port will be created on your computer.

    Step 2: Installing the software

    Python is usually on most unixes and standard with Mac OSX. If not, it should not be too hard to find it with popular packaging systems. One thing that probably isn’t automatically installed is PySerial, but this is easy to. Visit PySerial’s website and follow the installation instructions.

    Step 3: Identifying your serial port

    The Nike+iPod is a standard FTDI serial device, and nearly every operating system will automatically find the drivers on connection. On most unix-based operating systems, check the /dev directory for a new serial port. On my Snow Leopard Mac, this can be as easy as typing ‘ls /dev/*usbserial*’ in the terminal. In my particular case, the Nike+iPod shows up as “/dev/tty.usbserial-A600e18v”. If you still have a hard time seeing it, try unplugging it and plugging it back in and seeing if a new file pops up in /dev that looks like a serial port. Write down whatever the serial port is so you can modify the python script with the correct serial port.

    Step 4: Get yourself a stumble.to account and API key

    Stumble.to supports a variety of authentication systems (I simply just use google to log in). Now that you have an account, you can add your API key. Go to “venues” and create a new test venue (or link it to an existing foursquare venue). After you create your venue, you will see an API key and API secret. Write these down because you will need them for the python script.

    Step 5: Download the stumble.to Nike agent

    You can find the python script here:

    http://www.stumble.to/downloads/stumbleto-shoe-agent.py

    Step 6: Edit the script with your API settings

    Open the python script you downloaded in your favorite editor, and edit the following:

    # Adjust these values as appropriate.
    API_KEY = 'YOUR_API_KEY'
    API_SECRET = 'YOUR_API_SECRET'
    DEVICE = '/dev/tty.usbserial-A600e18v'

    Populate the values you obtained for the API key, secret, and serial port in the above locations.

    Step 7: Run the script and see if it works!

    Run the script (ie: python stumbleto-shoe-agent.py) and watch the console. The script will initialize the Nike+ hardware and start listening on the air. Pick up your Nike+ sensor and jiggle it like you are going to role some dice. Rather shortly, it should see the Nike+ sensor and print out a hex serial number like: 8d-10-92-2f. This is the Nike+ sensor UID number that you will need to put into your stumble.to account. If you have more sensors, repeat the same process and be sure to keep track which is which.

    Go ahead and quit the script for now after you are done with this.

    Step 8: Visit the stumble.to site and enter your Nike+ UID and Foursquare account information

    For the Nike+ sensor:

    Visit the stumble.to site, log in, and click “Add Device”

    For the name, you can put anything, but I suggest looking on the back for the serial number of the Nike+ sensor and using this.

    Select Nike+ sensor for the type.

    Finally, Enter the UID we discovered above where it say UID.

    For the foursquare connection:

    Stumble.to uses oauth for authenticating users on third party services. This means we do not store your login or password information on our server. This step is no more painful than authorizing a third party to use your twitter, facebook, etc. log in information and its used for us to check you into venues.

    Click on “Add Service”, and select foursquare (and possibly twitter and fire eagle if you want to announce your stumble.to check ins to these services as well)

    Step 9: Run the script to Nike+ enable the venue

    Run the stumbleto-shoe-agent.py python script and either walk around your sensor or jiggle it a little. It will see your device. Congratulations! You just made your first Nike+ check in! You can also keep it in a backpack, purse, pocket, etc. so you don’t need to fuss with it again.

    Be sure to let us know about your newly enabled venue!

    And for some value add..

    Stumble.to can also detect any WiFi device in range for auto-checkin (Laptop, iPhone, android, etc). Be sure to check out some of the example scripts you can run on some WiFi routers.

    For those who want to try to the hard way…

    This is actually not too hard if you have a steady hand. You will need a level shifter (FTDI is suggested, as it does have a 3.3V output that can drive the iPod receiver circuitry) and some wire. All you need to do is solder up a few grounds, TX, RX, and 3.3V.

    Here is the SparkFun schematic

    Here is a link to a UW security project that involved soldering directly to the receiver pins.

  • 4 Responses to “Nike+ Venue Check-In Hardware, a How-To Guide”

    1. Isa says:

      So hang on, is this still compatible with other wifi devices as mentioned in the originating article?

    2. admin says:

      @Isa Yes, there is a router script on stumble.to that allows it to detect any wifi device in range for auto checkin (laptop, iphone, android, etc)

    3. Andres Moran says:

      Hi Casey, I read this post when you first published it but was just reminded about it again. Really cool hack!

      Since you’re keen on both Nike+ and Foursquare, you should definitely check us out: http://www.earndit.com. Full disclosure: I’m a co-founder of the company. Naturally I welcome your feedback.

    4. John says:

      Looks cool but your python script download link is dead. :(

    Leave a Reply