Skip to content

Agile Innovative Implementation

BlinkStick devices with multi-LED support

This module contains the low-level implementation details for Agile Innovative devices, including enumerations, bit fields, and state management classes.

Available Components

Agile Innovative BlinkStick implementation details.

Classes

busylight_core.vendors.agile_innovative.implementation.State

State(*, report, nleds)

BlinkStick State manager for multi-LED devices.

BlinkStick devices store colors in Green-Red-Blue (GRB) format internally, while the public API uses the standard Red-Green-Blue (RGB) format. This class handles the conversion automatically and supports multiple device variants with different LED counts and report formats.

Initialize BlinkStick state.

:param report: HID report number for this device variant :param nleds: Number of LEDs supported by this device

Attributes
busylight_core.vendors.agile_innovative.implementation.State.report instance-attribute
report = report
busylight_core.vendors.agile_innovative.implementation.State.nleds instance-attribute
nleds = nleds
busylight_core.vendors.agile_innovative.implementation.State.channel instance-attribute
channel = 0
busylight_core.vendors.agile_innovative.implementation.State.colors instance-attribute
colors = [(0, 0, 0)] * nleds
busylight_core.vendors.agile_innovative.implementation.State.color property writable
color

Get the current RGB color of the first lit LED.

Returns the color of the first LED that has a non-zero color value, converted from internal GRB format to standard RGB format.

Functions
busylight_core.vendors.agile_innovative.implementation.State.blinkstick classmethod
blinkstick()

Create state for original BlinkStick (single LED, report 1).

busylight_core.vendors.agile_innovative.implementation.State.blinkstick_pro classmethod
blinkstick_pro()

Create state for BlinkStick Pro (192 LEDs, report 2).

busylight_core.vendors.agile_innovative.implementation.State.blinkstick_square classmethod
blinkstick_square()

Create state for BlinkStick Square (8 LEDs, report 6).

busylight_core.vendors.agile_innovative.implementation.State.blinkstick_strip classmethod
blinkstick_strip()

Create state for BlinkStick Strip (8 LEDs, report 6).

busylight_core.vendors.agile_innovative.implementation.State.blinkstick_nano classmethod
blinkstick_nano()

Create state for BlinkStick Nano (2 LEDs, report 6).

busylight_core.vendors.agile_innovative.implementation.State.blinkstick_flex classmethod
blinkstick_flex()

Create state for BlinkStick Flex (32 LEDs, report 6).

busylight_core.vendors.agile_innovative.implementation.State.rgb_to_grb staticmethod
rgb_to_grb(color)

Convert RGB color tuple to internal GRB representation.

:param color: RGB color tuple (red, green, blue) :return: GRB color tuple (green, red, blue)

busylight_core.vendors.agile_innovative.implementation.State.grb_to_rgb staticmethod
grb_to_rgb(color)

Convert internal GRB color tuple to RGB representation.

:param color: GRB color tuple (green, red, blue) :return: RGB color tuple (red, green, blue)

busylight_core.vendors.agile_innovative.implementation.State.get_led
get_led(index)

Get the RGB color of a specific LED.

:param index: LED index (0-based) :return: RGB color tuple, or (0,0,0) if index is invalid

busylight_core.vendors.agile_innovative.implementation.State.set_led
set_led(index, color)

Set the RGB color of a specific LED.

:param index: LED index (0-based) :param color: RGB color tuple to set