From 5e50c7fa93e43e90b288dec7d8387b5a6e9917c5 Mon Sep 17 00:00:00 2001 From: abratchik Date: Tue, 20 Dec 2022 18:36:24 +0400 Subject: [PATCH] Web UI for network configuration --- API.md | 1 + Docs/data-folder.png | Bin 0 -> 15886 bytes Docs/html/app__cam_8h_source.html | 8 +- Docs/html/app__component_8h_source.html | 54 +- Docs/html/app__config_8h_source.html | 84 ++- Docs/html/app__conn_8h.html | 62 +-- Docs/html/app__conn_8h_source.html | 317 +++++++----- Docs/html/app__httpd_8h_source.html | 32 +- Docs/html/class_c_l_app_cam.html | 2 + Docs/html/class_c_l_app_component.html | 27 + Docs/html/class_c_l_app_conn.html | 658 +++++++++++++++++++++++- Docs/html/class_c_l_app_httpd.html | 2 + Docs/html/functions.html | 27 +- Docs/html/functions_func.html | 26 +- Docs/html/functions_vars.html | 1 - Docs/html/globals.html | 17 +- Docs/html/globals_defs.html | 3 - Docs/html/globals_enum.html | 1 + Docs/html/globals_eval.html | 5 + Docs/html/index.html | 76 ++- Docs/html/md__a_p_i.html | 1 + Docs/html/menudata.js | 2 + Docs/html/search/all_3.js | 9 +- Docs/html/search/all_4.js | 5 +- Docs/html/search/all_5.js | 77 +-- Docs/html/search/all_7.js | 15 +- Docs/html/search/all_a.js | 4 +- Docs/html/search/all_e.js | 66 ++- Docs/html/search/defines_4.js | 6 +- Docs/html/search/defines_5.js | 4 +- Docs/html/search/enums_1.html | 37 ++ Docs/html/search/enums_1.js | 4 + Docs/html/search/enumvalues_1.html | 37 ++ Docs/html/search/enumvalues_1.js | 5 + Docs/html/search/enumvalues_2.html | 37 ++ Docs/html/search/enumvalues_2.js | 4 + Docs/html/search/enumvalues_3.html | 37 ++ Docs/html/search/enumvalues_3.js | 4 + Docs/html/search/enumvalues_4.html | 37 ++ Docs/html/search/enumvalues_4.js | 4 + Docs/html/search/functions_3.js | 3 +- Docs/html/search/functions_4.js | 76 +-- Docs/html/search/functions_6.js | 8 +- Docs/html/search/functions_b.js | 47 +- Docs/html/search/searchdata.js | 6 +- Docs/html/search/variables_1.js | 5 +- Docs/html/struct_station.html | 16 - Docs/index.png | Bin 0 -> 37446 bytes Docs/logo.svg | 131 +++++ Docs/simpleviewer.png | Bin 188721 -> 0 bytes Docs/streamview.png | Bin 118961 -> 0 bytes Docs/wifi-setup-ap.png | Bin 0 -> 382485 bytes Docs/wifi-setup.png | Bin 0 -> 521743 bytes README.md | 121 ++++- data/default_conn.json | 4 + data/www/css/style.css | 24 +- data/www/index.html | 167 ++---- data/www/js/cam.js | 2 +- data/www/js/setup.js | 130 +++++ data/www/js/utils.js | 159 +++++- data/www/setup.html | 103 +++- esp32-cam-webserver.ino | 10 - platformio.ini | 4 +- src/app_cam.cpp | 13 +- src/app_component.cpp | 12 +- src/app_component.h | 9 +- src/app_config.h | 8 - src/app_conn.cpp | 323 ++++++++---- src/app_conn.h | 62 ++- src/app_httpd.cpp | 105 ++-- 70 files changed, 2512 insertions(+), 834 deletions(-) create mode 100644 Docs/data-folder.png create mode 100644 Docs/html/search/enums_1.html create mode 100644 Docs/html/search/enums_1.js create mode 100644 Docs/html/search/enumvalues_1.html create mode 100644 Docs/html/search/enumvalues_1.js create mode 100644 Docs/html/search/enumvalues_2.html create mode 100644 Docs/html/search/enumvalues_2.js create mode 100644 Docs/html/search/enumvalues_3.html create mode 100644 Docs/html/search/enumvalues_3.js create mode 100644 Docs/html/search/enumvalues_4.html create mode 100644 Docs/html/search/enumvalues_4.js create mode 100644 Docs/index.png create mode 100644 Docs/logo.svg delete mode 100644 Docs/simpleviewer.png delete mode 100644 Docs/streamview.png create mode 100644 Docs/wifi-setup-ap.png create mode 100644 Docs/wifi-setup.png create mode 100644 data/www/js/setup.js diff --git a/API.md b/API.md index b631a87..9503fb6 100644 --- a/API.md +++ b/API.md @@ -9,6 +9,7 @@ this makes controlling all functions of the camera via GET requests possible. * - stream: starting video capture with full screen mode * - still: taking a still image with full screen mode * `/dump` - Status page (automatically refreshed every 5 sec) +* `/setup` - Configure network settings (WiFi, OTA, etc) ### Special *key / val* settings and commands diff --git a/Docs/data-folder.png b/Docs/data-folder.png new file mode 100644 index 0000000000000000000000000000000000000000..31a2cf0b389d160c5c09d9676993cffc8c560f1b GIT binary patch literal 15886 zcmZX*1y~$Glr22C1PK;gf;)q|1b26L3GVJ8xZB|Ft_cL!;BEne4?zPAuK#3r-|oKm z&o}*bb$8vW>guk#bi5ypWPu)ZsmFlZ26mlp`B?LssS9-(odpCsEi?JRv5rB;_U} zbA?|bB-N#Uq0Ubj`ugh~tdMe*Zz$^djx;S85k6NzfL^YS9%gR(0U=!~>xhsBHK9*c zUh85~VR=Cf$N}UqHw8rSOWqucx#)7l{#p_4AbWk^;~NQcryqeJFxNh)7x7M5ggo;CF0j!oY%Lv?musD zy|JO-Ei+TTBqRWgo2lgzuCpJsW3{bx<*b#I0F2NyG5{vh4ge2L!9X`6=mr45rF;b- zLHF3uO|lU7zps`T!u_8#%s&gjCk+WXIp|))!p+Lc$=%l3qa!1gF)M&aY=;N&jgBTV@pIRv2Tf2Y|fDgGmihrKYR zu97N+gtMC!1rIBb6-X(9NU*^ywVM<#M4;KM8Hg9ilR&P#LXEz%* zc7A?-HXsKZ2L}r@2aCI}lZTlPi<3Lme-`q8%8|5kw{Wv_@vw7tqWD*?nYpv4hcG4O zzl#3*_n+;w^0E7$nw;GK>$adb$oB6F8#^nI?Z3;0nhO0pE1+uUW96VHY3B&-9%vmR z96Ugw|H%LUyYfFZ{x3`2|FLA};rZW||Le;CYpLaKNeIEn#T*r;KlFS{0&1OULD59vf%x|tgF^!3WKiup1Fy*WGJk76`*(g zB>Z;rd+HSUx2yYHxHm7)_wPo>!6fHlyZgCa`g=l^d^oF-&}O!$GFWY1USqej7(DOFPJJr9My3Jeo#v zz1>ksNhuzk&BHg~F}*)DOkon?-3QR$-nZY1SscTY1)^K9u9w63ylri5;FE@49*qiR z?iTAQ4#2WXl{TVnjM{h@91igHelHQcViL?P`g|dgYAI<>Nt3B(O$gca-a3Gv=G_Wd z2!OW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L1NbM9p(8c{ 105extern CLAppCam AppCam;
106
107#endif
-
CLAppCam AppCam
Definition: app_cam.cpp:248
+
CLAppCam AppCam
Definition: app_cam.cpp:247
#define LAMP_DEFAULT
Definition: app_cam.h:11
Camera Manager Manages all interactions with camera.
Definition: app_cam.h:22
-
int savePrefs()
Definition: app_cam.cpp:170
+
int savePrefs()
Definition: app_cam.cpp:169
bool isJPEGinBuffer()
Definition: app_cam.h:54
int loadPrefs()
Definition: app_cam.cpp:109
void setRotation(int val)
Definition: app_cam.h:48
@@ -188,7 +188,7 @@
int getRotation()
Definition: app_cam.h:49
int getFrameRate()
Definition: app_cam.h:42
int getLamp()
Definition: app_cam.h:33
-
int snapToBufer()
Definition: app_cam.cpp:233
+
int snapToBufer()
Definition: app_cam.cpp:232
void setLamp(int newVal=LAMP_DEFAULT)
Definition: app_cam.cpp:96
int getXclk()
Definition: app_cam.h:46
int stop()
Definition: app_cam.cpp:89
@@ -198,7 +198,7 @@
void setAutoLamp(bool val)
Definition: app_cam.h:35
bool isAutoLamp()
Definition: app_cam.h:36
uint8_t * getBuffer()
Definition: app_cam.h:52
-
void releaseBuffer()
Definition: app_cam.cpp:239
+
void releaseBuffer()
Definition: app_cam.cpp:238
int getSensorPID()
Definition: app_cam.h:38
int start()
Definition: app_cam.cpp:8
sensor_t * getSensor()
Definition: app_cam.h:39
diff --git a/Docs/html/app__component_8h_source.html b/Docs/html/app__component_8h_source.html index 86cae78..4c35604 100644 --- a/Docs/html/app__component_8h_source.html +++ b/Docs/html/app__component_8h_source.html @@ -98,44 +98,48 @@
29
30 int getLastErr() {return last_err;};
31
-
32 protected:
-
33 void setTag(const char *t) {tag = t;};
-
34
-
35 void setErr(int err_code) {last_err = err_code;};
+
32 bool isConfigured() {return configured;};
+
33
+
34 protected:
+
35 void setTag(const char *t) {tag = t;};
36
-
41 int readJsonIntVal(jparse_ctx_t *jctx, char* token);
-
42
-
43 int parsePrefs(jparse_ctx_t *jctx);
+
37 void setErr(int err_code) {last_err = err_code;};
+
38
+
43 int readJsonIntVal(jparse_ctx_t *jctx, char* token);
44
-
45
-
46 private:
-
47 // prefix for forming preference file name of this class
-
48 const char * tag;
-
49
-
50 bool debug_mode = false;
-
51
-
52 // error code of the last error
-
53 int last_err = 0;
+
45 int parsePrefs(jparse_ctx_t *jctx);
+
46
+
47
+
48 private:
+
49 // prefix for forming preference file name of this class
+
50 const char * tag;
+
51 bool configured = false;
+
52
+
53 bool debug_mode = false;
54
-
55 char prefs[20] = "prefs.json";
-
56};
+
55 // error code of the last error
+
56 int last_err = 0;
57
-
58#endif
+
58 char prefs[20] = "prefs.json";
+
59};
+
60
+
61#endif
Abstract root class for the appication components.
Definition: app_component.h:14
int getLastErr()
Definition: app_component.h:30
int loadPrefs()
Definition: app_component.h:19
int savePrefs()
Definition: app_component.h:20
bool isDebugMode()
Definition: app_component.h:28
-
void setTag(const char *t)
Definition: app_component.h:33
-
int parsePrefs(jparse_ctx_t *jctx)
Definition: app_component.cpp:50
+
void setTag(const char *t)
Definition: app_component.h:35
+
int parsePrefs(jparse_ctx_t *jctx)
Definition: app_component.cpp:51
int start()
Definition: app_component.h:18
-
void setErr(int err_code)
Definition: app_component.h:35
+
void setErr(int err_code)
Definition: app_component.h:37
void setDebugMode(bool val)
Definition: app_component.h:27
-
int readJsonIntVal(jparse_ctx_t *jctx, char *token)
reads the Int value from JSON context by token.
Definition: app_component.cpp:28
-
void dumpPrefs()
Definition: app_component.cpp:18
+
int readJsonIntVal(jparse_ctx_t *jctx, char *token)
reads the Int value from JSON context by token.
Definition: app_component.cpp:29
+
bool isConfigured()
Definition: app_component.h:32
+
void dumpPrefs()
Definition: app_component.cpp:19
char * getPrefsFileName(bool forsave=false)
Definition: app_component.cpp:3
-
int removePrefs()
Definition: app_component.cpp:36
+
int removePrefs()
Definition: app_component.cpp:37
diff --git a/Docs/html/app__config_8h_source.html b/Docs/html/app__config_8h_source.html index 80a73c6..7e5b63a 100644 --- a/Docs/html/app__config_8h_source.html +++ b/Docs/html/app__config_8h_source.html @@ -92,55 +92,47 @@
19#define WIFI_WATCHDOG 15000
20
21/*
-
22 * Over The Air firmware updates can be disabled by uncommenting the folowing line
-
23 * When enabled the device will advertise itself using the MDNS_NAME defined above
+
22 * Additional Features
+
23 *
24 */
-
25// #define NO_OTA
-
26
-
27/*
-
28 * Additional Features
-
29 *
-
30 */
+
25
+
26// Uncomment to disable the notification LED on the module
+
27// #define LED_DISABLE
+
28
+
29// Uncomment to disable the illumination lamp features
+
30// #define LAMP_DISABLE
31
-
32
-
33
-
34// Uncomment to disable the notification LED on the module
-
35// #define LED_DISABLE
-
36
-
37// Uncomment to disable the illumination lamp features
-
38// #define LAMP_DISABLE
+
32// Uncomment this line to use LittleFS instead of SD.
+
33// NOTE!
+
34// LittleFS is still experimental, not recommended. The 'official' library installed from the Library Manager
+
35// seems to be broken, but fixed in this PR: https://github.com/lorol/LITTLEFS/pull/56
+
36// To install it, please navigate to you /libraries sub-folder of your sketch location and then execute
+
37// git clone https://github.com/Michael2MacDonald/LITTLEFS.
+
38// #define USE_LittleFS
39
-
40// Uncomment this line to use LittleFS instead of SD.
-
41// NOTE!
-
42// LittleFS is still experimental, not recommended. The 'official' library installed from the Library Manager
-
43// seems to be broken, but fixed in this PR: https://github.com/lorol/LITTLEFS/pull/56
-
44// To install it, please navigate to you /libraries sub-folder of your sketch location and then execute
-
45// git clone https://github.com/Michael2MacDonald/LITTLEFS.
-
46// #define USE_LittleFS
-
47
-
48// Define the startup lamp power setting (as a percentage, defaults to 0%)
-
49// Saved user settings will override this
-
50// #define LAMP_DEFAULT 0
-
51
-
52/*
-
53 * Camera Hardware Selectiom
-
54 *
-
55 * You must uncomment one, and only one, of the lines below to select your board model.
-
56 * Remember to also select the board in the Boards Manager
-
57 * This is not optional
-
58 */
-
59#define CAMERA_MODEL_AI_THINKER // default
-
60// #define CAMERA_MODEL_WROVER_KIT
-
61// #define CAMERA_MODEL_ESP_EYE
-
62// #define CAMERA_MODEL_M5STACK_PSRAM
-
63// #define CAMERA_MODEL_M5STACK_V2_PSRAM
-
64// #define CAMERA_MODEL_M5STACK_WIDE
-
65// #define CAMERA_MODEL_M5STACK_ESP32CAM // Originally: CAMERA_MODEL_M5STACK_NO_PSRAM
-
66// #define CAMERA_MODEL_TTGO_T_JOURNAL
-
67// #define CAMERA_MODEL_ARDUCAM_ESP32S_UNO
-
68
-
69
-
70#endif
+
40// Define the startup lamp power setting (as a percentage, defaults to 0%)
+
41// Saved user settings will override this
+
42// #define LAMP_DEFAULT 0
+
43
+
44/*
+
45 * Camera Hardware Selectiom
+
46 *
+
47 * You must uncomment one, and only one, of the lines below to select your board model.
+
48 * Remember to also select the board in the Boards Manager
+
49 * This is not optional
+
50 */
+
51#define CAMERA_MODEL_AI_THINKER // default
+
52// #define CAMERA_MODEL_WROVER_KIT
+
53// #define CAMERA_MODEL_ESP_EYE
+
54// #define CAMERA_MODEL_M5STACK_PSRAM
+
55// #define CAMERA_MODEL_M5STACK_V2_PSRAM
+
56// #define CAMERA_MODEL_M5STACK_WIDE
+
57// #define CAMERA_MODEL_M5STACK_ESP32CAM // Originally: CAMERA_MODEL_M5STACK_NO_PSRAM
+
58// #define CAMERA_MODEL_TTGO_T_JOURNAL
+
59// #define CAMERA_MODEL_ARDUCAM_ESP32S_UNO
+
60
+
61
+
62#endif