RGB Light Support over serial - RhythmLunatic/stepmania GitHub Wiki

A client should be implemented to receive the data sent through the COM port like an arduino. Although I would like to use COBS, the arduino COBS library doesn't seem to work so instead it's limited to 0x01 to 0xFF...

It is intended to use one arduino to control both the left and right light spires. Because of the wattage you will need an external 5v power supply.

modes

enum ArduinoLightModes
{
    LM_NONE,
    LM_TRAVEL, //Travel along the LED strip, percentage is how far along to travel
    LM_REGULAR, //Regular, fill from the bottom
    LM_REVERSED, //Fill from the top
    LM_RAINBOW, //Regular + Ignore RGB values and use a rainbow effect
    LM_BLINKRAPIDLY, //Blink the spire rapidly (It was easier to implement on the arduino side)
    LM_EVERYOTHER, //Light up every other LED (evens)
    LM_EVERYOTHER2, //Light up every other LED (odds)
    LM_MANUAL //There's no way of knowing how many LEDs the arduino has...
};

byte structure

Byte Description
Mode The mode in which the arduino should fill the lights.
Side 0x01 or 0x02, corresponding to left or right spires. (If you have 4 players joined it will do 0x03 and 0x04 also)
R 1-255. Ignored in rainbow mode.
G/S Green value 1-255, or Saturation in rainbow mode.
B/V Blue value 1-255, or Value in rainbow mode.
Percent A byte from 0x01 to FF. In percent mode it's the percentage to fill, in travel mode it's how far along the LED has traveled.