From 6aa4f5dc517c4ebede09fc8cbc5ea4f52100f005 Mon Sep 17 00:00:00 2001 From: RaffaelW Date: Tue, 15 Apr 2025 21:47:16 +0200 Subject: [PATCH] remove unnecessary DMX connection logs and disconnection handling --- src/main.cpp | 32 -------------------------------- 1 file changed, 32 deletions(-) diff --git a/src/main.cpp b/src/main.cpp index 4173d24..6844aa4 100644 --- a/src/main.cpp +++ b/src/main.cpp @@ -488,13 +488,6 @@ void loop() /* We should check to make sure that there weren't any DMX errors. */ if (!dmx1_packet.err) { - /* If this is the first DMX data we've received, lets log it! */ - if (!dmx1_IsConnected) - { - Serial.println("DMX1 in is connected!"); - dmx1_IsConnected = true; - } - /* Don't forget we need to actually read the DMX data into our buffer so that we can print it out. */ @@ -517,15 +510,6 @@ void loop() Serial.println("A DMX 1 error occurred."); } } - else if (dmx1_IsConnected) - { - /* If DMX times out after having been connected, it likely means that the - DMX cable was unplugged. When that happens in this example sketch, we'll - uninstall the DMX driver. */ - Serial.println("DMX 1 was disconnected."); - dmx1_IsConnected = false; - // dmx_driver_delete(dmx1); - } if (direction2 == Input && dmx_receive(dmx2, &dmx2_packet, 0)) { @@ -543,13 +527,6 @@ void loop() /* We should check to make sure that there weren't any DMX errors. */ if (!dmx2_packet.err) { - /* If this is the first DMX data we've received, lets log it! */ - if (!dmx2_IsConnected) - { - Serial.println("DMX2 in is connected!"); - dmx2_IsConnected = true; - } - /* Don't forget we need to actually read the DMX data into our buffer so that we can print it out. */ @@ -572,13 +549,4 @@ void loop() Serial.println("A DMX 2 error occurred."); } } - else if (dmx2_IsConnected) - { - /* If DMX times out after having been connected, it likely means that the - DMX cable was unplugged. When that happens in this example sketch, we'll - uninstall the DMX driver. */ - Serial.println("DMX 2 was disconnected."); - dmx2_IsConnected = false; - // dmx_driver_delete(dmx2); - } }