The single-shot connect_wifi aborted boot on any transient association or DHCP miss — common right after a reset, when the AP still holds the stale pre-reset association. Add a bounded retry (5 attempts, 500ms→4s backoff, disconnect between tries) so those transient failures recover instead of failing the boot. Extract the logic into firmware::net (new lib target) and rewire the wifi_tls / git_push / git_sync spikes to it, removing three duplicated copies. main.rs reuses this when Wi-Fi lands there instead of adding a fourth copy.
11 lines
513 B
Rust
11 lines
513 B
Rust
//! Shared library surface for the Typoena firmware crate.
|
|
//!
|
|
//! The editor binary (`src/main.rs`) and the spike binaries under `src/bin/`
|
|
//! are each separate crate roots; anything they need to share lives here and is
|
|
//! reached as `firmware::…`. Currently that is just the resilient Wi-Fi
|
|
//! bring-up, extracted from three duplicated `connect_wifi` copies so the retry
|
|
//! logic lives in exactly one place and the eventual editor integration reuses
|
|
//! it instead of growing a fourth copy.
|
|
|
|
pub mod net;
|