-
Notifications
You must be signed in to change notification settings - Fork 2
Setting DMX values
Rubin Raithel edited this page Oct 5, 2019
·
1 revision
In order to set channels to specific values you need to already be connected to the DMXServer.
After a connection is established you can use the .write() method.
dmxClient.write(message)
The 'message' can be either a string, list of str and int or a dict of int and str.
dmxClient.write("DMX 1 12 2 13") #Str must start with 'DMX' followed by as many channel->value pairs as you like
dmxClient.write(['1', 12, 3, '13']) #Lists just consist out of channel->value pairs
dmxClient.write({'1': 12, 3: '13'}) #Dicts are also consist out of channel->value pairs
If you really need to squeeze that last bit of performance out of your python programm, you may use the ._write() function directly, which can only accept strings as formated before.
dmxClient._write("DMX 1 12 2 13")