Timeout constant values are used now.

This commit is contained in:
klaute 2019-02-02 11:58:44 +01:00
parent 740bfc600b
commit ef2a6c15de

View file

@ -57,6 +57,8 @@ void setup() {
#endif #endif
// Pin settings // Pin settings
pinMode(BAT_CHARGED_PIN, INPUT);
pinMode(BAT_CHARGING_PIN, INPUT);
pinMode(STATUS_LED_PIN, OUTPUT); pinMode(STATUS_LED_PIN, OUTPUT);
pinMode(ANEMOMETER_PIN, INPUT_PULLUP); pinMode(ANEMOMETER_PIN, INPUT_PULLUP);
pinMode(A0, INPUT); pinMode(A0, INPUT);
@ -69,9 +71,9 @@ void setup() {
// Establish WiFi connection // Establish WiFi connection
String wifiName = "oko-weather-" + DEVICE_NAME; String wifiName = "oko-weather-" + DEVICE_NAME;
wifiManager.setMinimumSignalQuality(15); wifiManager.setMinimumSignalQuality(16);
wifiManager.setConnectTimeout(60); // the time in seconds to wait for the known wifi connection wifiManager.setConnectTimeout(WIFI_AUTOCONNECT_TIMEOUT_S); // the time in seconds to wait for the known wifi connection
wifiManager.setTimeout(60); // the time in seconds to wait for the user to configure the device wifiManager.setTimeout(WIFI_CONFIG_PORTAL_TIMEOUT_S); // the time in seconds to wait for the user to configure the device
if (!wifiManager.autoConnect(wifiName.c_str(), "DEADBEEF")) { if (!wifiManager.autoConnect(wifiName.c_str(), "DEADBEEF")) {
#ifdef DEBUG #ifdef DEBUG