rgb.blink() # start blinking
sleep(6)
rgb.off()
sleep(1)
# blink red 1s, green 0.5s, blue 0.25s
rgb.blink(on_times=(1, 0.5, 0.25),
colors=((255, 0, 0),
(0, 255, 0),
(0, 0, 255)))
lightbulb
Using .blink()
.blink() will make the LED start blinking.
lightbulb
Using .off()
.off() will stop the LED from blinking.
rgb.pulse() # start pulsing
sleep(12)
rgb.off()
sleep(1)
# 2s to fade from pink to off, 0.5s to pink
rgb.pulse(fade_times=(2, 0.5),
colors=((255, 0, 100),
(0, 0, 0)))
rgb.cycle(fade_times=4)