Framework for upcoming variant-specific PRs that add LED feedback during boot. The hook gives users visual cues that the device is busy and
shouldn't be interacted with until startup completes.
Introduces a fourth ACL role (value 4) that can manage the region map
without full admin privileges. The role is intended for trusted users
who curate regions on a repeater but should not have access to general
admin commands.
ClientACL:
- Widen PERM_ACL_ROLE_MASK from 2 to 3 bits so the new value fits.
- Add PERM_ACL_REGION_MGR and ClientInfo::isRegionMgr().
- Exempt region_mgr entries from least-recently-active eviction in
putClient(), same as admins.
simple_repeater:
- Phones may still gate UI on the legacy is_admin byte (reply_data[6]),
so report region_mgr as admin there. Without this, the phone CLI
falls back to guest view.
- Allow region_mgr to send TXT_MSG CLI commands. handleCommand()
gates non-whitelisted commands with "Err - not permitted". The
whitelist covers region.* (read+write) plus a small set of
read-only queries (get, ver, board, neighbors, clock, sensor
get/list).
- Pass the ClientInfo* through to handleCommand and drop the
redundant sender_timestamp parameter (derived from
sender->last_timestamp; NULL means Serial CLI).
- Use ~PERM_ACL_ROLE_MASK instead of ~0x03 when clearing role bits
on login, so the wider mask is honored.
This commit refactors the serial bridge functionality out of the `simple_repeater` example and into a more reusable, object-oriented structure.
An `AbstractBridge` interface has been introduced, along with a concrete `SerialBridge` implementation. This encapsulates all the logic for packet framing, checksum calculation, and serial communication, cleaning up the main example file significantly.
The `simple_repeater` example now instantiates and uses the `SerialBridge` class, resulting in better separation of concerns and improved code organization.
* Sensor, anon_req now just for admin login (guest password now unused)
* special CLI command, "setperm {pubkey-hex} {permissions-int16}" for admin(s) to manage user access (permissions 0 = remove)