User defined web pages can be uploaded to esp-link. This is useful if esp-link acts as a web server while MCU provides + the measurement data.
+diff --git a/esp-link/cgi.c b/esp-link/cgi.c index d0f7fb6..825fe52 100644 --- a/esp-link/cgi.c +++ b/esp-link/cgi.c @@ -215,6 +215,7 @@ int ICACHE_FLASH_ATTR cgiMenu(HttpdConnData *connData) { #endif "\"Debug log\", \"/log.html\"," "\"Upgrade Firmware\", \"/flash.html\"" + "\"Web Server\", \"/web-server.html\"" " ], " "\"version\": \"%s\", " "\"name\": \"%s\"" diff --git a/esp-link/cgiservices.c b/esp-link/cgiservices.c index 200039d..ef76287 100644 --- a/esp-link/cgiservices.c +++ b/esp-link/cgiservices.c @@ -68,6 +68,7 @@ int ICACHE_FLASH_ATTR cgiSystemInfo(HttpdConnData *connData) { "\"name\": \"%s\", " "\"reset cause\": \"%d=%s\", " "\"size\": \"%s\", " + "\"upload-size\": \"%d\", " "\"id\": \"0x%02X 0x%04X\", " "\"partition\": \"%s\", " "\"slip\": \"%s\", " @@ -79,6 +80,7 @@ int ICACHE_FLASH_ATTR cgiSystemInfo(HttpdConnData *connData) { rst_info->reason, rst_codes[rst_info->reason], flash_maps[system_get_flash_size_map()], + getUserPageSectionEnd()-getUserPageSectionStart(), fid & 0xff, (fid & 0xff00) | ((fid >> 16) & 0xff), part_id ? "user2.bin" : "user1.bin", flashConfig.slip_enable ? "enabled" : "disabled", diff --git a/html/home.html b/html/home.html index 138222e..de9862f 100644 --- a/html/home.html +++ b/html/home.html @@ -123,6 +123,12 @@
User defined web pages can be uploaded to esp-link. This is useful if esp-link acts as a web server while MCU provides + the measurement data.
+