| 24 | unsigned long debounceTime = 200; |
| 25 | |
| 26 | void wifiscanSetup() { |
| 27 | Serial.begin(115200); |
| 28 | u8g2.setFont(u8g2_font_6x10_tr); |
| 29 | |
| 30 | WiFi.mode(WIFI_STA); |
| 31 | WiFi.disconnect(); |
| 32 | |
| 33 | pinMode(BTN_PIN_UP, INPUT_PULLUP); |
| 34 | pinMode(BTN_PIN_DOWN, INPUT_PULLUP); |
| 35 | pinMode(BTN_PIN_SELECT, INPUT_PULLUP); |
| 36 | pinMode(BTN_PIN_BACK, INPUT_PULLUP); |
| 37 | |
| 38 | for (int cycle = 0; cycle < 3; cycle++) { |
| 39 | for (int i = 0; i < 3; i++) { |
| 40 | u8g2.clearBuffer(); |
| 41 | u8g2.setFont(u8g2_font_ncenB08_tr); |
| 42 | u8g2.drawStr(0, 10, "Scanning WiFi"); |
| 43 | |
| 44 | String dots = ""; |
| 45 | for (int j = 0; j <= i; j++) { |
| 46 | dots += " ."; |
| 47 | setNeoPixelColour("white"); |
| 48 | } |
| 49 | setNeoPixelColour("0"); |
| 50 | |
| 51 | u8g2.drawStr(80, 10, dots.c_str()); |
| 52 | |
| 53 | u8g2.sendBuffer(); |
| 54 | delay(300); |
| 55 | } |
| 56 | } |
| 57 | |
| 58 | scan_StartTime = millis(); |
| 59 | isScanComplete = false; |
| 60 | } |
| 61 | |
| 62 | void wifiscanLoop() { |
| 63 | unsigned long currentMillis = millis(); |
nothing calls this directly
no test coverage detected