Join GitHub today
GitHub is home to over 28 million developers working together to host and review code, manage projects, and build software together.Sign up
#receiver.py from bibliopixel.drivers.network_receiver import NetworkReceiver from bibliopixel.drivers.LPD8806 import * from bibliopixel.led import Strip #must init with same number of pixels as sender driver = LPD8806(100) led = Strip(driver) receiver = NetworkReceiver(led) receiver.start() #returns immediately, must loop or do other work
#sender.py from bibliopixel.drivers.network import Network from bibliopixel.led import Strip #must init with same number of pixels as receiver driver = Network(100, host = "192.168.1.18") led = Strip(driver) #run animations here
__init__(led, port = 3142, interface = '0.0.0.0')
- led - Instance of Strip or Matrix to send the received LED data to.
- port - Port number to use. Only need to change if port is already in use or if using multiple receivers.
- interface - Network interface for the receiver to listen on. By default all available interfaces are used. Set this to 'localhost' to only accept connections from the current system.
start(join = False)
- join - True causes this method to block until the receiver thread ends.
Starts the receiver thread and returns unless join == True.
Stops the receiver thread and closes all connections.
Clone this wiki locally
Press h to open a hovercard with more details.