Skip to content

foxdog-studios/party-hat

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

29 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Party hat

A Web-enabled party hat.

A partying duck

An example of a meteor app that connects to an Arduino. Originally created for a workshop at the Numbers That Matter hackathon.

Setup

If you're using a Linux based or OSX system, follow the instructions below. If you're using a Window system, install Ubuntu, then follow the instructions below. If you're using another system, try the instructions below and let me know how it goes.

This has been tested with an Arduino Uno with StandardFirmata installed. To install StandardFirmata using the Arduino IDE, go to File -> Examples -> Firmata -> StandardFirmata.

  1. Ensure you have the following programs installed. You may use your system's package manager (preferred) of retrieve them from the Web.

    • A POSIX compliant shell, e.g., bash (you almost certainly have one already).

    • Git

    • Python 2.7

    • cURL (you probably already have this).

    • virtualenv for Python 2.7

  2. Clone the Party hat repository.

    $ git clone https://github.com/foxdog-studios/party-hat.git
  3. Change your working directory to be the repository.

    $ cd party-hat
  4. Run the setup script. This will install Meteor, create a Python 2.7 virtual environment and install the required Python packages.

    $ ./setup.sh

Running

  1. Launch the controller website by running;

    $ cd webapp
    $ meteor

    from the root of the repository.

  2. Connect an Arduino board to your system and find it's device path. On my system, this can be done by running;

    $ ls /dev/ttyACM*
    /dev/ttyACM0
  3. Launch the hat controller by run;

    $ . venv/bin/activate
    $ python hat_controller.py $DEVICE_PATH

    from the root of the repository. Replace $DEVICE_PATH with the path you found in step 2.

  4. Finally, launch a browser and navigate to http://localhost:3000.