26 lines
439 B
C++
Raw Normal View History

2021-06-20 12:57:47 +03:00
#include <Arduino.h>
2021-06-22 15:51:58 +03:00
#include "ota.hpp"
2021-06-23 16:44:37 +03:00
#include "server.hpp"
#include "collector.hpp"
2021-06-28 11:36:43 +03:00
#include "serial.hpp"
2021-06-22 12:35:48 +03:00
const char* ssid = "fan_XXX";
void setup() {
2021-07-01 23:46:32 +03:00
Serial.begin(115200);
ota_setup(ssid);
2021-07-02 23:20:42 +03:00
server_setup();
2021-06-28 15:15:26 +03:00
collector_setup();
2021-06-28 11:36:43 +03:00
DEBUG_OUT.println(F("Setup done"));
DEBUG_OUT.print("IP address: ");
2021-07-01 23:46:32 +03:00
DEBUG_OUT.println(WiFi.softAPIP().toString());
2021-06-20 12:57:47 +03:00
}
2021-06-22 12:35:48 +03:00
void loop() {
ArduinoOTA.handle();
server_loop();
2021-07-02 23:20:42 +03:00
collector_loop();
}