Example #1
0
from birdfish.output.lumos_network import LumosNetwork
from birdfish import tween


# create a light show - manages the updating of all lights
show = LightShow()

# Create a network - in this case, universe 3
dmx3 = LumosNetwork(3)

# add the network to the show
show.networks.append(dmx3)

# create an input interface
dispatcher = MidiDispatcher("MidiKeys")
osc_dispatcher = OSCDispatcher(('0.0.0.0', 8998))


p = PulseChase(name="greenpulse",
        start_pos=12,
        end_pos=65,
        speed=3,
        move_tween=tween.IN_OUT_CUBIC,
        )

elementid = 0
for i in range(1,360,3):
    elementid += 1
    l = RGBLight(
            start_channel=i,
            name="pulse_%s" % elementid,
Example #2
0
from birdfish.input.osc import OSCDispatcher
from birdfish.lights import RGBLight, LightShow
from birdfish.output.lumos_network import LumosNetwork

# create a light show - manages the updating of all lights
show = LightShow()

# Create a network - in this case, universe 3
dmx3 = LumosNetwork(3)

# add the network to the show
show.networks.append(dmx3)

# create an input interface
dispatcher = MidiDispatcher("MidiKeys")
osc_dispatcher = OSCDispatcher(('0.0.0.0', 8998))

# create a single RGB light element
single = RGBLight(
    start_channel=10,
    name="singletestb",
    attack_duration=0,
    decay_duration=0,
    release_duration=.75,
    sustain_value=1,
)
single.hue = random.random()
single.saturation = 1
single.update_rgb()
single.bell_mode = True
Example #3
0
from birdfish.output.solriserdmx import SolRiserDmx
from birdfish import tween

# create a light show - manages the updating of all lights
show = LightShow()

# Create a network - in this case, universe 3
dmx = SolRiserDmx('/dev/ttyATH0')
#dmx = SolRiserDmx('/dev/tty.usbmodem1d21')

# add the network to the show
show.networks.append(dmx)

# create an input interface
# dispatcher = MidiDispatcher("MidiKeys")
dispatcher = OSCDispatcher(('0.0.0.0', 8998))

## create a single channel light element
#single = LightElement(
#        start_channel=1,
#        name="singletest",
#        attack_duration=1,
#        release_duration=1.5,
#        )

# add the light to a network
#show.add_element(single, network=dmx)

# the effect is configured by how many times it should pulse per second
# 1 is the default
pulser = Pulser()
Example #4
0
from birdfish.lights import LightElement, LightShow
from birdfish.output.lumos_network import LumosNetwork


# create a light show - manages the updating of all lights
show = LightShow()

# Create a network - in this case, universe 3
dmx3 = LumosNetwork(3)

# add the network to the show
show.networks.append(dmx3)

# create an input interface
midi_dispatcher = MidiDispatcher("MidiKeys")
osc_dispatcher = OSCDispatcher(("0.0.0.0", 8998))


# create a single channel light element
single = LightElement(start_channel=1, name="singletest", attack_duration=1, release_duration=1.5)

# add the light to a network
show.add_element(single, network=dmx3)

# set the input interface to trigger the element
# midi code 41 is the "Q" key on the qwerty keyboard for the midikeys app
midi_dispatcher.add_observer((0, 41), single)
osc_dispatcher.add_trigger("/elements/push2", single)

# startup the midi communication - runs in its own thread
midi_dispatcher.start()
Example #5
0
from birdfish.input.osc import OSCDispatcher
from birdfish.lights import LightElement, LightShow
from birdfish.output.lumos_network import LumosNetwork

# create a light show - manages the updating of all lights
show = LightShow()

# Create a network - in this case, universe 3
dmx3 = LumosNetwork(3)

# add the network to the show
show.networks.append(dmx3)

# create an input interface
midi_dispatcher = MidiDispatcher("MidiKeys")
osc_dispatcher = OSCDispatcher(('0.0.0.0', 8998))

# create a single channel light element
single = LightElement(
    start_channel=1,
    name="singletest",
    attack_duration=1,
    release_duration=1.5,
)

# add the light to a network
show.add_element(single, network=dmx3)

# set the input interface to trigger the element
# midi code 41 is the "Q" key on the qwerty keyboard for the midikeys app
midi_dispatcher.add_observer((0, 41), single)
Example #6
0
from birdfish.lights import RGBLight, LightShow
from birdfish.output.lumos_network import LumosNetwork


# create a light show - manages the updating of all lights
show = LightShow()

# Create a network - in this case, universe 3
dmx3 = LumosNetwork(3)

# add the network to the show
show.networks.append(dmx3)

# create an input interface
dispatcher = MidiDispatcher("MidiKeys")
osc_dispatcher = OSCDispatcher(('0.0.0.0', 8998))

# create a single RGB light element
single = RGBLight(
        start_channel=10,
        name="singletestb",
        attack_duration=0,
        decay_duration=0,
        release_duration=.75,
        sustain_value=1,
        )
single.hue = random.random()
single.saturation = 1
single.update_rgb()
single.bell_mode = True
Example #7
0
}


# create a light show - manages the updating of all lights
show = SolShow()

# Create a network - in this case, the SolRiser DMX shield over serial
#dmx = SolRiserDmx('/dev/ttyATH0')
dmx = SolRiserDmx(config.SERIAL_PORT)

# add the network to the show
show.networks.append(dmx)

# create an input interface
# dispatcher = MidiDispatcher("MidiKeys")
dispatcher = OSCDispatcher(('0.0.0.0', 8998))


# the effect is configured by how many times it should pulse per second
# 1 is the default
#pulser = Pulser()
hueShift = SolHueShift()
hueShift.width = 0.3
#raySwiper = SolSwiper()
#hueShift.add_hue_shift()

show.effects.append(hueShift)
#show.effects.append(raySwiper)

# if you wanted to give the pulse a different characteristic
# pulser = Pulser(on_shape=tween.IN_CIRC, off_shape=tween.OUT_CIRC)
Example #8
0
from birdfish.lights import RGBLight, PulseChase, LightShow
from birdfish.output.lumos_network import LumosNetwork
from birdfish import tween

# create a light show - manages the updating of all lights
show = LightShow()

# Create a network - in this case, universe 3
dmx3 = LumosNetwork(3)

# add the network to the show
show.networks.append(dmx3)

# create an input interface
dispatcher = MidiDispatcher("MidiKeys")
osc_dispatcher = OSCDispatcher(('0.0.0.0', 8998))

p = PulseChase(
    name="greenpulse",
    start_pos=12,
    end_pos=65,
    speed=3,
    move_tween=tween.IN_OUT_CUBIC,
)

elementid = 0
for i in range(1, 360, 3):
    elementid += 1
    l = RGBLight(
        start_channel=i,
        name="pulse_%s" % elementid,
Example #9
0
from birdfish import tween


# create a light show - manages the updating of all lights
show = LightShow()

# Create a network - in this case, universe 3
dmx = SolRiserDmx('/dev/ttyATH0')
#dmx = SolRiserDmx('/dev/tty.usbmodem1d21')

# add the network to the show
show.networks.append(dmx)

# create an input interface
# dispatcher = MidiDispatcher("MidiKeys")
dispatcher = OSCDispatcher(('0.0.0.0', 8998))


## create a single channel light element
#single = LightElement(
#        start_channel=1,
#        name="singletest",
#        attack_duration=1,
#        release_duration=1.5,
#        )

# add the light to a network
#show.add_element(single, network=dmx)

# the effect is configured by how many times it should pulse per second
# 1 is the default
Example #10
0
    31: 'stairs'
}

# create a light show - manages the updating of all lights
show = SolShow()

# Create a network - in this case, the SolRiser DMX shield over serial
#dmx = SolRiserDmx('/dev/ttyATH0')
dmx = SolRiserDmx(config.SERIAL_PORT)

# add the network to the show
show.networks.append(dmx)

# create an input interface
# dispatcher = MidiDispatcher("MidiKeys")
dispatcher = OSCDispatcher(('0.0.0.0', 8998))

# the effect is configured by how many times it should pulse per second
# 1 is the default
#pulser = Pulser()
hueShift = SolHueShift()
hueShift.width = 0.3
#raySwiper = SolSwiper()
#hueShift.add_hue_shift()

show.effects.append(hueShift)
#show.effects.append(raySwiper)

# if you wanted to give the pulse a different characteristic
# pulser = Pulser(on_shape=tween.IN_CIRC, off_shape=tween.OUT_CIRC)