Skip to content

russmack/lifxcmd

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

37 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

lifxcmd

A Rust command line program for controlling a LIFX light bulb.

Build Status


Status: OK.


Build

git clone https://github.com/russmack/lifxcmd.git
cargo build

Usage

./lifxcmd -h

USAGE:
    lifxcmd [FLAGS] [OPTIONS]

FLAGS:
    -e, --echo       Display the current state of the device
        --help       Prints help information
    -V, --version    Prints version information

OPTIONS:
    -a, --address <HOST ADDRESS>            Specifies the address of the target device
    -b, --brightness <BRIGHTNESS>           Set the brightness of the device
    -c, --colour <COLOUR NAME>              Changes the colour
    -d, --duration <TRANSITION DURATION>    The duration of the colour transition
    -f, --flash <FLASH COLOUR NAME>         Specifies the name of the colour to flash
    -h, --hue <HUE>                         Set the hue of the device
    -i, --interval <FLASH INTERVAL>         The length of the flash
    -p, --power <POWER LEVEL>               Changes the power level on/off
    -s, --saturation <SATURATION>           Set the saturation of the device
    -n, --subnet <SUBNET>                   Specify the device subnet

Examples

Turn light on, with optional subnet.
./lifxcmd -p on -n 192.168.1.255

Change colour to slate_gray instantly, by colour name:
./lifxcmd -c slate_gray

Change colour to green instantly by hue, saturation, brightness:
./lifxcmd -h 140 -s 100 -b 100

A three second flash to coral:
./lifxcmd -f coral -i 3000

Turn light off.
./lifxcmd -p off

Features

  • Locate device
  • Specify device
  • Power on device
  • Power off device
  • Change device colour
  • Specify duration of colour transition
  • Flash another colour
  • Specify length of flash interval
  • Print current state of device
  • Use HSB to specify colours
  • List supported colour names

License

BSD 3-Clause: LICENSE.txt

LICENSE

About

Command line program to control Lifx devices.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published