mirror of
https://github.com/lumapu/ahoy.git
synced 2025-07-23 19:27:13 +02:00
added PR #356, prometheus endpoint thanks to @avendretter
changed default wifi IP to 192.168.4.1 (to avoid conflicts with local router configurations) added default pinout for ESP32
This commit is contained in:
parent
d0e7ee393c
commit
1d7b02571d
7 changed files with 132 additions and 25 deletions
|
@ -33,6 +33,14 @@ class web {
|
|||
|
||||
void setProtection(bool protect);
|
||||
|
||||
|
||||
void onUpdate(AsyncWebServerRequest *request);
|
||||
void showUpdate(AsyncWebServerRequest *request);
|
||||
void showUpdate2(AsyncWebServerRequest *request, String filename, size_t index, uint8_t *data, size_t len, bool final);
|
||||
|
||||
void serialCb(String msg);
|
||||
|
||||
private:
|
||||
void onConnect(AsyncEventSourceClient *client);
|
||||
|
||||
void onIndex(AsyncWebServerRequest *request);
|
||||
|
@ -51,13 +59,6 @@ class web {
|
|||
void onLive(AsyncWebServerRequest *request);
|
||||
void showWebApi(AsyncWebServerRequest *request);
|
||||
|
||||
void onUpdate(AsyncWebServerRequest *request);
|
||||
void showUpdate(AsyncWebServerRequest *request);
|
||||
void showUpdate2(AsyncWebServerRequest *request, String filename, size_t index, uint8_t *data, size_t len, bool final);
|
||||
|
||||
void serialCb(String msg);
|
||||
|
||||
private:
|
||||
void onSerial(AsyncWebServerRequest *request);
|
||||
void onSystem(AsyncWebServerRequest *request);
|
||||
|
||||
|
@ -70,6 +71,15 @@ class web {
|
|||
}
|
||||
}
|
||||
|
||||
#ifdef ENABLE_JSON_EP
|
||||
void showJson(void);
|
||||
#endif
|
||||
|
||||
#ifdef ENABLE_PROMETHEUS_EP
|
||||
void showMetrics(void);
|
||||
std::pair<String, String> convertToPromUnits(String shortUnit);
|
||||
#endif
|
||||
|
||||
AsyncWebServer *mWeb;
|
||||
AsyncEventSource *mEvts;
|
||||
bool mProtected;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue