From 47446f597720f8635f34a123c969ef74b22d3640 Mon Sep 17 00:00:00 2001 From: Matthew Frost Date: Wed, 27 Dec 2023 21:59:11 +0100 Subject: [PATCH] better logging --- src/main.cpp | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/src/main.cpp b/src/main.cpp index 95ce84f..3a5289d 100644 --- a/src/main.cpp +++ b/src/main.cpp @@ -249,7 +249,7 @@ void handleData1Interrupt() { #ifdef SERIAL_DEBUG Serial.println("Sending Request to Tinance2 for card: " + fullCardID); #endif - + // Create the JSON payload String payload = "{\"full_card_id\":\"" + String(fullCardID) + "\"}"; // Send the HTTP request and get the response @@ -607,8 +607,14 @@ void setup() { if (settings.DoorDisabled() != previousDoorDisabled || isFirstRun) { if (settings.DoorDisabled()) { + #ifdef SERIAL_DEBUG + Serial.println("Disabling Door due to DoorDisabled setting"); + #endif unlockDoor(false); // Provide the required argument } else { + #ifdef SERIAL_DEBUG + Serial.println("Enabling Door due to DoorDisabled setting"); + #endif lockDoor(); }