Ejemplo n.º 1
0
def both_tog(ampl, RED, GREEN):
    print("playing both_tog")
    turn_on(RED)
    turn_on(GREEN)
    if ampl >= BASE_1:
        blink(GREEN, 0.01)
        blink(RED, 0.01)
Ejemplo n.º 2
0
def dark_rand(ampl, RED, GREEN):
    print("playing on dark_rand")
    if ampl <= 0.06:
        turn_off(RED)
        turn_off(GREEN)

    if ampl >= 0.03 and ampl < 0.06:
        blink(GREEN)
        turn_on(RED)

    if ampl >= 0.09:
        turn_on(RED)
        blink(GREEN)
Ejemplo n.º 3
0
def no_blink(ampl, RED, GREEN):
    print("playing on no_blink")
    if ampl <= BASE_0:
        turn_on(RED)
        turn_on(GREEN)

    if ampl >= BASE_0 and ampl < BASE_1:
        turn_on(GREEN)
        turn_off(RED)

    if ampl >= BASE_1:
        turn_on(RED)
        turn_off(GREEN)
Ejemplo n.º 4
0
def even_even_less_blinks(ampl, RED, GREEN):
    print("playing on even_even_less_blinks")
    if ampl <= BASE_2:
        turn_on(RED)
        turn_on(GREEN)

    if ampl >= BASE_2 and ampl < BASE_3:
        turn_on(GREEN)
        turn_off(RED)

    if ampl >= BASE_3 and ampl <= BASE_4:
        turn_on(RED)
        turn_off(GREEN)

    if ampl >= BASE_4:
        blink(RED)
        blink(GREEN)
Ejemplo n.º 5
0
def super_random(ampl, RED, GREEN):
    print("playing on super_random")
    if ampl <= BASE_0:
        turn_on(RED)
        turn_off(GREEN)
    if ampl > BASE_0 and ampl <= BASE_1:
        blink(RED)
        turn_on(GREEN)
    if ampl > BASE_1 and ampl <= BASE_2:
        turn_on(GREEN)
        turn_on(RED)
    if ampl >= BASE_2 and BASE_3:
        turn_off(RED)
        turn_off(GREEN)
    if ampl >= BASE_3 and ampl < BASE_4:
        blink(GREEN)
        turn_off(RED)
    if ampl >= BASE_4:
        blink(RED)
        blink(GREEN)
Ejemplo n.º 6
0
def light_rand(ampl, RED, GREEN):
    print("playing on light_rand")
    if ampl <= 0.06:
        turn_on(RED)
        turn_on(GREEN)
    else:
        turn_off(RED)
        turn_off(GREEN)
    if ampl >= 0.03 and ampl < 0.06:
        blink(GREEN)
        turn_off(RED)
    if ampl >= 0.09:
        turn_on(RED)
        turn_off(GREEN)
Ejemplo n.º 7
0
def less_blinks(ampl, RED, GREEN):
    print("playing on less_blinks")
    if ampl <= BASE_1:
        turn_on(RED)
        turn_on(GREEN)

    if ampl >= BASE_1 and ampl < BASE_2:
        blink(GREEN)
        turn_off(RED)

    if ampl >= BASE_2 and ampl < BASE_3:
        turn_on(RED)
        turn_off(GREEN)

    if ampl >= BASE_3:
        blink(RED)
        blink(GREEN)
Ejemplo n.º 8
0
def only_green(ampl, RED, GREEN):
    print("playing only_green")
    turn_off(RED)
    turn_on(GREEN)
    if ampl >= BASE_1:
        blink(GREEN, 0.01)
Ejemplo n.º 9
0
def only_red(ampl, RED, GREEN):
    print("playing only_red")
    turn_off(GREEN)
    turn_on(RED)
    if ampl >= BASE_1:
        blink(RED, 0.01)