Skip to main content

A Python3 wrapper for interacting with LifeSmart Cololight

Project description

pycololight

A Python3 wrapper for interacting with LifeSmart Cololight.

Supports the following cololight devices:

  • hexagon
  • strip

Usage

from pycololight import PyCololight

# Setup hexagon device
light = PyCololight(device="hexagon", host="1.1.1.1")

# Setup strip device, and include dynamic effects
light = PyCololight(device="strip", host="1.1.1.1", dynamic_effects=True)

# Turn on at 60% brightness
light.on = 60

# Set brightness to 70%
light.brightness = 70

# Set light colour
light.colour = (255, 127, 255)

# Set effect
light.effect = "Sunrise"

# Create custom effect
light.add_custom_effect(
  name="custom effect",
  colour_scheme="Shadow",
  colour="Red, Yellow",
  cycle_speed=11,
  mode=1
)

# Turn off
light.on = 0

Mapping of modes for custom effects can be found here

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

pycololight-2.1.0.tar.gz (7.0 kB view hashes)

Uploaded Source

Built Distribution

pycololight-2.1.0-py3-none-any.whl (8.0 kB view hashes)

Uploaded Python 3

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page