upleb.uk

Public git repos — served from a NIP-34 GRASP relay at git.upleb.uk

summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorYour Name <you@example.com>2026-05-19 19:43:25 +0530
committerYour Name <you@example.com>2026-05-19 19:43:25 +0530
commit402f4f2c63f2621f4e7e587288bc106bea37857a (patch)
tree04565c7071b76f7fd7c281ebfccd4e98df0408e8
parentcf4ac1bc04a19110bca26f969245dcc9ef265890 (diff)
docs: update web WiFi setup plan checklist with progress
-rw-r--r--WEB_WIFI_SETUP_PLAN.md20
1 files changed, 17 insertions, 3 deletions
diff --git a/WEB_WIFI_SETUP_PLAN.md b/WEB_WIFI_SETUP_PLAN.md
index 1a3f742..b80ec3a 100644
--- a/WEB_WIFI_SETUP_PLAN.md
+++ b/WEB_WIFI_SETUP_PLAN.md
@@ -13,11 +13,11 @@ WiFi setup.
13 13
14| State | When | Content | 14| State | When | Content |
15|-------|------|---------| 15|-------|------|---------|
16| BOOT | Startup | "TollGate" title + "starting..." | 16| BOOT | Startup | WiFi QR + "TollGate" title + SSID + status |
17| READY (unconfigured) | No STA network | AP WiFi QR + SSID + "http://AP_IP/setup" | 17| READY (unconfigured) | No STA network | AP WiFi QR + SSID + "http://AP_IP/setup" |
18| READY (configured) | STA connected | QR cycling (WiFi↔Portal) + balance/clients/price | 18| READY (configured) | STA connected | QR cycling (WiFi↔Portal) + balance/clients/price |
19| PAYMENT_RECEIVED | After payment | "ACCESS GRANTED" + amount + time (3s then→READY) | 19| PAYMENT_RECEIVED | After payment | "ACCESS GRANTED" + amount + time (3s then→READY) |
20| ERROR | No upstream | "NO UPSTREAM" + "http://AP_IP/setup" | 20| ERROR | No upstream | WiFi QR + "NO UPSTREAM" + SSID + setup URL |
21 21
22### Captive Portal (new endpoints) 22### Captive Portal (new endpoints)
23 23
@@ -53,6 +53,8 @@ WiFi setup.
53- [x] Update `display.h` — remove `DISPLAY_WIFI_SETUP`, `display_enter_wifi_setup()` 53- [x] Update `display.h` — remove `DISPLAY_WIFI_SETUP`, `display_enter_wifi_setup()`
54- [x] Add setup URL text to READY (unconfigured) and ERROR screens 54- [x] Add setup URL text to READY (unconfigured) and ERROR screens
55- [x] Remove WiFi setup auto-enter from `tollgate_main.c` 55- [x] Remove WiFi setup auto-enter from `tollgate_main.c`
56- [x] Add WiFi QR code to BOOT screen (scan to connect)
57- [x] Add WiFi QR code to ERROR screen
56 58
57### Phase 2: Add web WiFi setup 59### Phase 2: Add web WiFi setup
58- [x] Add `/wifi/scan` endpoint to `captive_portal.c` 60- [x] Add `/wifi/scan` endpoint to `captive_portal.c`
@@ -64,9 +66,21 @@ WiFi setup.
64### Phase 3: Build configuration 66### Phase 3: Build configuration
65- [x] Remove touch.c, keyboard.c, wifi_setup.c from `main/CMakeLists.txt` 67- [x] Remove touch.c, keyboard.c, wifi_setup.c from `main/CMakeLists.txt`
66 68
67### Phase 4: Testing 69### Phase 4: Testing and fixes
68- [x] `make test-unit` passes 70- [x] `make test-unit` passes
69- [x] Build succeeds (`idf.py build`) 71- [x] Build succeeds (`idf.py build`)
70- [x] Flash to Board C, verify portrait display shows setup URL 72- [x] Flash to Board C, verify portrait display shows setup URL
73- [x] Fix: display stuck at BOOT when WiFi configured but unreachable
74 - Added `s_total_retries` counter (MAX_TOTAL_RETRIES=10)
75 - Transitions to DISPLAY_ERROR after all retries exhausted
76- [x] WiFi QR code visible on BOOT and ERROR screens (hardware verified)
71- [ ] Test `/setup` page from phone browser 77- [ ] Test `/setup` page from phone browser
72- [x] Write integration test `tests/integration/wifi_setup.mjs` 78- [x] Write integration test `tests/integration/wifi_setup.mjs`
79
80## Commits
81
82| Hash | Message |
83|------|---------|
84| `aa58b47` | feat: web-based WiFi setup via captive portal, portrait-only display |
85| `2e65cdf` | fix: transition display to ERROR after WiFi retries exhausted |
86| `cf4ac1b` | feat: add WiFi QR code to BOOT and ERROR screens |