From d0c9072f2a95b2879a3774fa07a1ea4fc24cbcc8 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ebbe=20Ba=C3=9F?= Date: Wed, 14 Feb 2024 23:05:32 +0100 Subject: [PATCH] testing some stuff MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: Ebbe Baß --- server/exampleReceiver.py | 18 ++---------------- 1 file changed, 2 insertions(+), 16 deletions(-) diff --git a/server/exampleReceiver.py b/server/exampleReceiver.py index c3dff32..6f34a1e 100644 --- a/server/exampleReceiver.py +++ b/server/exampleReceiver.py @@ -38,23 +38,9 @@ while True: artNetPacket = artNet.readPacket() # Make sure we actually *have* a packet if artNetPacket is not None and artNetPacket.data is not None: - print("Packet: "+str(artNetPacket)) print("Universe: "+str(artNetPacket.universe)) - print("Data: "+str(artNetPacket.data)) - print(" ") - # Checks to see if the current packet is for the specified DMX Universe - if artNetPacket.universe == artnetUniverse: - # Stores the packet data array - dmxPacket = artNetPacket.data - - # Then print out the data from each channel - print("Received data: ", end="") - for i in range(dmxChannels): - # Lists in python start at 0, so to access a specific DMX channel you have to subtract one - print(dmxPacket[i-1], end=" ") - - # Print a newline so things look nice :) - print("") + # Stores the packet data array + dmxPacket = artNetPacket.data except KeyboardInterrupt: break