diff options
| author | Your Name <you@example.com> | 2026-05-19 13:21:25 +0530 |
|---|---|---|
| committer | Your Name <you@example.com> | 2026-05-19 13:31:08 +0530 |
| commit | eeba74a4a1c011e85e33dea4252b381e35a64ea4 (patch) | |
| tree | 14862e7d300511e28e214c743fd2f699bc54c5b8 /main/config.h | |
| parent | b0d9d494f00ee77f9efc22d1ef2ea3c94b23ddbd (diff) | |
feat: multi-mint wallet with health tracking, WPA auto-detect, display gating
Squash merge of feature/multi-mint-support (21 commits):
Multi-mint wallet:
- Accept payments from 4 mints: minibits, coinos, 21mint, lnvoltz
- Periodic health probing (300s interval, 3 recovery threshold)
- Multi-wallet init with nucula_wallet_init_multi()
- /mints and /wallet API endpoints
WPA auto-detect:
- wifi_auth_mode config field (default WPA2, supports WPA3)
- Runtime mapping to wifi_auth_mode_t in STA config
Display gating:
- display_enabled config field (default true)
- Guards display_init/display_update per-board
Bug fixes:
- 3s delay before service start prevents lwip mem_free assertion
- Real npub in discovery (identity_get()->npub_hex)
- Health probe interval 300s (production value)
- Duplicate services_start_task call removed
- UTF-8 arrow replaced with ASCII in log message
Tests: 61+14 unit tests passing, firmware builds clean
Diffstat (limited to 'main/config.h')
| -rw-r--r-- | main/config.h | 11 |
1 files changed, 8 insertions, 3 deletions
diff --git a/main/config.h b/main/config.h index af372af..370e6cc 100644 --- a/main/config.h +++ b/main/config.h | |||
| @@ -9,7 +9,7 @@ | |||
| 9 | #include "lightning_payout.h" | 9 | #include "lightning_payout.h" |
| 10 | 10 | ||
| 11 | #define TOLLGATE_MAX_WIFI_NETWORKS 5 | 11 | #define TOLLGATE_MAX_WIFI_NETWORKS 5 |
| 12 | #define TOLLGATE_MAX_MINT_URLS 3 | 12 | #define TOLLGATE_MAX_MINT_URLS 8 |
| 13 | #define TOLLGATE_MAX_AP_SSID_LEN 32 | 13 | #define TOLLGATE_MAX_AP_SSID_LEN 32 |
| 14 | #define TOLLGATE_MAX_AP_PASS_LEN 64 | 14 | #define TOLLGATE_MAX_AP_PASS_LEN 64 |
| 15 | #define TOLLGATE_MAX_RELAYS 4 | 15 | #define TOLLGATE_MAX_RELAYS 4 |
| @@ -41,6 +41,8 @@ typedef struct { | |||
| 41 | char ap_ip_str[16]; | 41 | char ap_ip_str[16]; |
| 42 | 42 | ||
| 43 | char mint_url[256]; | 43 | char mint_url[256]; |
| 44 | char accepted_mints[TOLLGATE_MAX_MINT_URLS][256]; | ||
| 45 | int accepted_mint_count; | ||
| 44 | char lnurl_url[256]; | 46 | char lnurl_url[256]; |
| 45 | int price_per_step; | 47 | int price_per_step; |
| 46 | int step_size_ms; | 48 | int step_size_ms; |
| @@ -52,6 +54,8 @@ typedef struct { | |||
| 52 | char nostr_relays[TOLLGATE_MAX_RELAYS][128]; | 54 | char nostr_relays[TOLLGATE_MAX_RELAYS][128]; |
| 53 | int nostr_relay_count; | 55 | int nostr_relay_count; |
| 54 | int nostr_publish_interval_s; | 56 | int nostr_publish_interval_s; |
| 57 | int nostr_sync_interval_s; | ||
| 58 | int nostr_fallback_sync_interval_s; | ||
| 55 | 59 | ||
| 56 | bool identity_initialized; | 60 | bool identity_initialized; |
| 57 | 61 | ||
| @@ -65,10 +69,11 @@ typedef struct { | |||
| 65 | bool cvm_enabled; | 69 | bool cvm_enabled; |
| 66 | char cvm_relays[256]; | 70 | char cvm_relays[256]; |
| 67 | 71 | ||
| 72 | char wifi_auth_mode[16]; | ||
| 73 | bool display_enabled; | ||
| 74 | |||
| 68 | char nostr_seed_relays[TOLLGATE_MAX_SEED_RELAYS][128]; | 75 | char nostr_seed_relays[TOLLGATE_MAX_SEED_RELAYS][128]; |
| 69 | int nostr_seed_relay_count; | 76 | int nostr_seed_relay_count; |
| 70 | int nostr_sync_interval_s; | ||
| 71 | int nostr_fallback_sync_interval_s; | ||
| 72 | 77 | ||
| 73 | bool market_enabled; | 78 | bool market_enabled; |
| 74 | int market_scan_interval_s; | 79 | int market_scan_interval_s; |