ixjf / MSIRGB

Alternative to MSI Mystic Light for controlling motherboard LEDs, without the fixed 7 colour limitation.
ISC License
398 stars 53 forks source link

Two Colors loop #93

Closed apippuM closed 4 years ago

apippuM commented 4 years ago

is it possible to just cycle 2 colors like purple to sky blue to purple to skyblue............. how the script would be?

ixjf commented 4 years ago
-- make sure the LEDs are configured correctly such that no built-in special effects are enabled
Lighting.SetBreathingModeEnabled(false)
Lighting.SetFlashingSpeed(0)

while true do
    Lighting.BatchBegin()
    for i = 1, 8 do
        Lighting.SetColour(i, 0x8, 0x1, 0x9) -- purple
    end
    Lighting.BatchEnd()

    os.sleep(2000) -- 2 seconds pause

    Lighting.BatchBegin()
    for i = 1, 8 do
        Lighting.SetColour(i, 0x7, 0xd, 0xf) -- sky blue
    end
    Lighting.BatchEnd()

    os.sleep(2000) -- 2 seconds pause
end

Something along these lines.

ixjf commented 4 years ago

I'm closing this. If you have any other doubts, please open a new issue.