Code Monkey home page Code Monkey logo

huehue's Introduction

Huehue

A Rust wrapper for Hue API v2.

Note that the Hue API v2 is in early access at the time of writing, so an upgrade to it could break applications in unpredictable way.

Features

  • Hue Bridge certificate validation.
  • Bridge discovery:
  • Devices:
    • list devices.
  • Light:
  • Smart plug:
    • switch on/off.
    • note: smart plug is exposed as a light, since it is also listed as a light by Hue.
  • XY to RGB and RGB to XY conversion.

Examples

The examples folder has fully functional sample applications to demonstrate some implemented features. The examples aim to be trivial to understand by focusing on specific functionality, and should be easy to copy and build your own application.

Simply use cargo to run the desired example:

$ cargo run --example scan

Scanning for bridges for 5 seconds.
1 bridges found.

> Bridge #1:
        Identifier: 1231231231231234
        Model: BSB002
        Version: 1948086000
        Address: 192.168.2.124
        Supported: true

Code Style

Code style is enforced. It requires a nightly profile and rustfmt to be installed. Once they are installed, create a Git pre-commit hook, so you don't ever have to worry about it again.

$ ln -sr pre-commit .git/hooks/pre-commit

huehue's People

Contributors

vgobbo avatar

Stargazers

 avatar Andy Williams avatar Dushyant Sabharwal avatar Robin Malfait avatar

Watchers

 avatar

Forkers

ttalle olim88

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.