Coder Social home page Coder Social logo

sciguy14 / littlebits-hue-controller Goto Github PK

View Code? Open in Web Editor NEW
10.0 4.0 0.0 2.93 MB

This project pairs the LittleBits Arduino Bit with some 3D printing, a microcomputer, and your Hue smart lights to create a tactile controller for your lights.

Home Page: http://www.jeremyblum.com/2014/12/17/littlebits-hue-lighting-controller

License: Other

Arduino 24.20% Python 75.80%

littlebits-hue-controller's Introduction

LittleBits Hue Controller

The LittleBits Hue Controller is an easy-to-setup, wall-mountable, physical controller for your Philips Hue lightbulbs. The controller makes it easy to turn the lights on/off, change their brightness, and cycle through preset colors. This is a great project for people who hate having to pull their phone out every time they want to adjust their lights.

Getting Setup

What you'll need

3D Print the Enclosure and Assemble the LittleBits

Step 1: Place the Bits on the backer board as shown. Print the button/dial covers. Slightly heat the button/dial covers and press them onto the buttons and covers as shown. Step 1

Step 2: Print the enclosure. Place the front of the enclosure on the panel as shown. Step 2

Step 3: Press the four M3 nuts into the four slots on the top cover as shown. Step 3

Step 4: Place the USB wires into the cutt-out on the rear of the panel as shown. Step 4

Step 5: Screw the bolts into the nuts and apply a velcro backer as shown. Step 5

Program the Arduino Bit

  • Provide Power to the controller, and connect the Arduino cable to your computer (workstation computer, not the linux server computer)
  • Use the provided Arduino Sketch to program the Arduino Bit via the Arduino IDE (select Arduino Leonardo from the device menu)

Install the Python Prerequisites

  • Log into (locally or via SSH) to the network-connected, always-on linux machine that you'll use (Raspberry Pi is good for this)
  • Install Python 2.7 if don't already have it installed: sudo apt-get install python2.7
  • Install Python PIP if you haven't already: sudo apt-get install python-dev python-pip
  • Install the PHue Library: sudo pip install phue
  • Install the PySerial Library: sudo pip install pyserial
  • Install the CronTab Library: sudo pip install python-crontab

Obtain and Setup the Server Script

  • Stay logged into your network linux machine
  • Connect your LittleBits Hue Controller to power, and to a USB port on your linux machine
  • On your linux machine, navigate to your home directory, and clone this GitHub repo: git clone https://github.com/sciguy14/LittleBits-Hue-Controller
  • Navigate to the server script directory: cd LittleBits-Hue-Controller/server
  • Ensure the script is executable: chmod 755 LittleBits-Hue-Controller.py
  • Execute the script in setup mode and follow the instructions to automatically setup the system: ./LittleBits-Hue-Controller.py -s. The output will look something like this: Setup Screenshot
  • That's it! The handler script will now automatically run in the background at boot. You can launch it immediately to observe its output as you toggle the controller, by running: ./LittleBits-Hue-Controller.py. The screenshot shows the behavior as I adjust brightness, color, and state via the control pad. You can also see it automatically recover when the control pad is unplugged and plugged back in: Usage Screenshot

More Info

License

This work is licensed under the GNU GPL v3. Please share improvements or remixes with the community, and attribute me (Jeremy Blum, http://www.jeremyblum.com) when reusing portions of my code.

littlebits-hue-controller's People

Contributors

sciguy14 avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.