Esempio n. 1
0
from fancyLED import FancyLED
import board  #pylint: disable=import-error

fancy1 = FancyLED(board.D3, board.D4, board.D5)  #LED 1-3
fancy2 = FancyLED(board.D8, board.D9, board.D10)  #LED 3-6

while True:  #modules to run through in order
    fancy1.alternate()
    fancy2.blink()
    fancy1.chase()
    fancy2.sparkle()
Esempio n. 2
0
import rgb
import board  # pylint: disable=import-error
import time
from fancyLED import FancyLED
# led1 = rgb.RGB(board.D3, board.D4, board.D2)

fancy1 = FancyLED(board.D5, board.D6, board.D7)
fancy2 = FancyLED(board.D2, board.D3, board.D4)

while True:
    fancy1.alternate(.5, 5)

    fancy2.blink(.25, 5)

    for i in range(0, 5):
        fancy2.chase(.1, 1)
        fancy1.chase(.1, 1)

    for i in range(0, 100):
        fancy2.sparkle(.05, 2)
        fancy1.sparkle(.05, 2)
#Lukas
#This is the main for the Fancy Led code this section just told it which code to run
#10/2/19

import board #pylint: disable-msg=import-error
from fancyLED import FancyLED

fancy1 = FancyLED( board.D2, board.D3, board.D4)# setting Leds to the these pins
fancy2 = FancyLED( board.D5, board.D6, board.D7)# setting Leds to the these pins

while True:

    fancy1.alternate()#run the alternate code in my FancyLed.py code
    fancy2.blink()#run the blink code in my FancyLed.py code
    fancy1.chase()#run the chase code in my FancyLed.py code
    fancy2.sparkle()#run the sparkle code in my FancyLed.py code


Esempio n. 4
0
from fancyLED import FancyLED #imports my custom library

fancy1 = FancyLED(2,3,4)
fancy2 = FancyLED(5,6,7) #sets up LEDs

while True:
    fancy1.alternate()
    fancy2.blink() #uses the library
    fancy1.chase()
    fancy2.sparkle()