Source code for lpf2.color

"""LEGO Powered-Up colour indices (LWP ``ColorIDX``).

Used by :meth:`lpf2.port.setRgbColorIdx`, :class:`lpf2.devices.hub_led`
and the colour-sensor family.
"""

[docs] BLACK: int = 0
"""Black / off."""
[docs] PINK: int = 1
"""Pink."""
[docs] PURPLE: int = 2
"""Purple."""
[docs] BLUE: int = 3
"""Blue."""
[docs] LIGHTBLUE: int = 4
"""Light blue."""
[docs] CYAN: int = 5
"""Cyan."""
[docs] GREEN: int = 6
"""Green."""
[docs] YELLOW: int = 7
"""Yellow."""
[docs] ORANGE: int = 8
"""Orange."""
[docs] RED: int = 9
"""Red."""
[docs] WHITE: int = 10
"""White."""
[docs] NUM_COLORS: int = 11
"""Number of concrete colour entries (BLACK..WHITE)."""
[docs] NONE: int = 255
"""Sentinel: no colour / unknown."""