From 71bff35130217571be343dc4988eb058f4c345f6 Mon Sep 17 00:00:00 2001 From: GHOSCHT <31184695+GHOSCHT@users.noreply.github.com> Date: Sun, 10 Apr 2022 22:13:39 +0200 Subject: [PATCH] Fix pincommit not working after setup --- Firmware/src/main.cpp | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/Firmware/src/main.cpp b/Firmware/src/main.cpp index 35a01a5..a04ab3c 100644 --- a/Firmware/src/main.cpp +++ b/Firmware/src/main.cpp @@ -11,6 +11,8 @@ const int STEPS = 5; const int WIFI_TIMEOUT = 20; +const int bjtCount = 4; +const int bjtPin[bjtCount] = {SIG1A, SIG1B, SIG2A, SIG2B}; BluetoothSerial bt; AsyncWebServer server(80); @@ -21,9 +23,6 @@ Communicator *phone; Communicator *websocket; LightController *light; -void TaskBlink(void *pvParameters); -void TaskAnalogRead(void *pvParameters); - void websocketTask(void *parameter) { while (true) @@ -65,12 +64,13 @@ void connectWifi(int timeout) Serial.println(""); Serial.println(WiFi.localIP()); + digitalWrite(LEDB, HIGH); } void setup() { - const int bjtCount = 4; - const int bjtPin[bjtCount] = {SIG1A, SIG1B, SIG2A, SIG2B}; + pinMode(LEDB, OUTPUT); + digitalWrite(LEDB, LOW); computer = new SerialCommunicator(Serial, 9600, 5, 50); phone = new BluetoothCommunicator(bt, 5, 50); light = new LightController(bjtPin, bjtCount);