From 1e682ea8f3fe68a086f29c2c06a630b5c1c8f670 Mon Sep 17 00:00:00 2001 From: Andrey Klimov Date: Mon, 11 Oct 2021 00:52:05 +0300 Subject: [PATCH] PWA redirection & local --- lighthub/config.cpp | 2 +- lighthub/main.cpp | 17 +++++++++++++---- lighthub/utils.cpp | 3 +++ lighthub/utils.h | 1 + 4 files changed, 18 insertions(+), 5 deletions(-) diff --git a/lighthub/config.cpp b/lighthub/config.cpp index 0726a19..e717a05 100644 --- a/lighthub/config.cpp +++ b/lighthub/config.cpp @@ -3,7 +3,7 @@ String systemConfig::getMACString() { String res; -for (int i=0; i<6; i++) {res+= (((char)mac[i]>>4)+'0');res+=(((char)mac[i]&0xf)+'0');} +for (int i=0; i<6; i++) {res+= ((String(mac[i]>>4,HEX)));res+=((String(mac[i]&0xf,HEX)));} return res; } diff --git a/lighthub/main.cpp b/lighthub/main.cpp index 78fe36b..416876b 100644 --- a/lighthub/main.cpp +++ b/lighthub/main.cpp @@ -237,13 +237,22 @@ uint16_t httpHandler(Client& client, String request, uint8_t method, long conten debugSerial<