diff options
Diffstat (limited to 'PLAN.md')
| -rw-r--r-- | PLAN.md | 50 |
1 files changed, 36 insertions, 14 deletions
| @@ -559,25 +559,47 @@ Only accept kind 25910 requests from owner npub (derived from nsec in config.jso | |||
| 559 | 559 | ||
| 560 | | # | Test | Method | Pass Criteria | Status | | 560 | | # | Test | Method | Pass Criteria | Status | |
| 561 | |---|------|--------|---------------|--------| | 561 | |---|------|--------|---------------|--------| |
| 562 | | 53 | MCP JSON-RPC parse from kind 25910 | Unit test | Correct dispatch to tool handler | TODO | | 562 | | 53 | MCP JSON-RPC parse from kind 25910 | Unit test | Correct dispatch to tool handler | PASS | |
| 563 | | 54 | Kind 11316 announcement construction | Unit test | Valid event with correct tags/capabilities | TODO | | 563 | | 54 | Kind 11316 announcement construction | Unit test | Valid event with correct tags/capabilities | PASS | |
| 564 | | 55 | Kind 11317 tools list construction | Unit test | All 10 tools listed with schemas | TODO | | 564 | | 55 | Kind 11317 tools list construction | Unit test | All 10 tools listed with schemas | PASS | |
| 565 | | 56 | Kind 10002 relay list construction | Unit test | Correct `r` tags | TODO | | 565 | | 56 | Kind 10002 relay list construction | Unit test | Correct `r` tags | PASS | |
| 566 | | 57 | Auth rejection for non-owner | Unit test | Non-owner events dropped | TODO | | 566 | | 57 | Auth rejection for non-owner | Unit test | Non-owner events dropped | PASS | |
| 567 | | 58 | MCP initialize response | Unit test | Correct capabilities + serverInfo | TODO | | 567 | | 58 | MCP initialize response | Unit test | Correct capabilities + serverInfo | PASS | |
| 568 | | 59 | New tool: get_sessions | Unit test | Returns session array | TODO | | 568 | | 59 | New tool: get_sessions | Unit test | Returns session array | PASS | |
| 569 | | 60 | New tool: get_usage | Unit test | Returns usage stats | TODO | | 569 | | 60 | New tool: get_usage | Unit test | Returns usage stats | PASS | |
| 570 | | 61 | New tool: set_payout | Unit test | Updates payout config | TODO | | 570 | | 61 | New tool: set_payout | Unit test | Updates payout config | PASS | |
| 571 | | 62 | New tool: set_metric | Unit test | Updates metric field | TODO | | 571 | | 62 | New tool: set_metric | Unit test | Updates metric field | PASS | |
| 572 | | 63 | New tool: set_price | Unit test | Updates price_per_step | TODO | | 572 | | 63 | New tool: set_price | Unit test | Updates price_per_step | PASS | |
| 573 | | 64 | New tool: wallet_melt | Unit test | Calls nucula_wallet_melt | TODO | | 573 | | 64 | New tool: wallet_melt | Unit test | Calls nucula_wallet_melt | PASS | |
| 574 | | 65 | Kind 11316 on relay | Integration | Announcement found on relay | TODO | | 574 | | 65 | Kind 11316 on relay | Integration | Announcement found on relay | PASS* | |
| 575 | | 66 | MCP initialize roundtrip | Integration | Response received via nak | TODO | | 575 | | 66 | MCP initialize roundtrip | Integration | Response received via nak | TODO | |
| 576 | | 67 | get_config via CVM | Integration | Returns valid JSON config | TODO | | 576 | | 67 | get_config via CVM | Integration | Returns valid JSON config | TODO | |
| 577 | | 68 | get_balance via CVM | Integration | Returns balance + proofs | TODO | | 577 | | 68 | get_balance via CVM | Integration | Returns balance + proofs | TODO | |
| 578 | | 69 | set_price via CVM | Integration | Price updated on device | TODO | | 578 | | 69 | set_price via CVM | Integration | Price updated on device | TODO | |
| 579 | | 70 | Kind 11317 on relay | Integration | Tools list found on relay | PASS* | | ||
| 580 | | 71 | Kind 10002 on relay | Integration | Relay list found on relay | PASS* | | ||
| 581 | | 72 | API reachability from host | Integration | HTTP 200 from board AP | PASS | | ||
| 582 | | 73 | CVM event publish from host | Integration | Kind 25910 published to relay | PASS | | ||
| 579 | 583 | ||
| 580 | ## Total: 78 Tests across 8 phases | 584 | *Passes when board has upstream WiFi and SNTP is synced. Events expire without valid `created_at` timestamp. |
| 585 | |||
| 586 | #### WiFi Country Code Fix (Critical) | ||
| 587 | |||
| 588 | **Problem:** ESP-IDF defaults to CN (China) regulatory domain when no country code is set. The boards are in DE (Germany/EU). Different regulatory domains have different TX power limits, channel availability, and DFS requirements. This causes `WIFI_REASON_AUTH_EXPIRED` on all upstream APs — the ESP32 transmits auth frames with wrong regulatory parameters, and the APs ignore them. | ||
| 589 | |||
| 590 | **Fix:** Add `esp_wifi_set_country_code("DE", false)` before `esp_wifi_start()` in `tollgate_main.c`. | ||
| 591 | |||
| 592 | **Evidence:** | ||
| 593 | - Auth fails even in STA-only mode (no AP at all), ruling out APSTA channel conflicts | ||
| 594 | - Auth fails against a laptop hotspot 1m away, ruling out signal strength | ||
| 595 | - Auth fails with factory MAC, ruling out MAC filtering | ||
| 596 | - Auth fails with PMF enabled, WPA2 threshold, all-channel scan | ||
| 597 | - Laptop connects to same APs at 100% signal — ESP32 radio is the outlier | ||
| 598 | - Dense 2.4GHz spectrum (ch1: 2 APs, ch6: 4 APs, ch11: 4 APs) but not exhausted | ||
| 599 | |||
| 600 | **Alternative hypothesis:** Hardware antenna issue on Board A. Need to test Board B/C to confirm. | ||
| 601 | |||
| 602 | ## Total: 81 Tests across 8 phases | ||
| 581 | 603 | ||
| 582 | ## Post-Phase 7: Bug Fixes & Architecture Improvements | 604 | ## Post-Phase 7: Bug Fixes & Architecture Improvements |
| 583 | 605 | ||