Expand description
Host-side client for the UMSH Local Control Protocol (ULCP).
UlcpDevice drives a device over a frame-oriented FrameLink, and
exposes the link as a [umsh_hal::Radio] so the host can run the
full MAC/node stack with the device acting purely as the PHY.
The wire format lives in [umsh_ulcp] (re-exported as
[crate::ulcp_wire]); this module owns the host-side session
behavior: the reset/configure handshake, request/response
transactions, and queueing of frames that arrive while a command is
in flight.
See docs/protocol/src/ulcp.md and the chapters under it for the
protocol.
Structs§
- Advert
Policy - What a device announces without being asked.
- BleFrame
Link - GATT/SAR frame transport backed by
btleplug. - BleFrame
Link Config - BLE-specific link configuration.
- BleScan
Result - One ULCP GATT Service peripheral seen during a
BleFrameLink::scan. - Device
Sync - Device state gathered by
UlcpDevice::sync: the spec’s post-attach synchronization procedure. Fields whose capability the device does not advertise areNone; multi-value properties are the digest forms and never contain key material. - Device
Time - The wall clock of a
CAP_TIMEdevice. - Gnss
Status - Everything a
CAP_GNSSdevice reports about positioning: the switch, the current fix, and the policy that governs what is done with it. - Host
Provisioning - The host-domain state
UlcpDevice::provisionestablishes on the device. - Provision
Report - What
UlcpDevice::provisionwrote. - RawRx
Frame - One inbound
STR_PHY_RAWframe with its trailing metadata exactly as the device sent it. - Repeater
Policy - The repeater forwarding policy of a
CAP_REPEATERdevice. - Serial
Frame Link - HDLC-Lite framing over a reliable asynchronous byte stream.
- Ulcp
Device - Companion radio attached over a frame link, usable as a
[
umsh_hal::Radio]. - Ulcp
Device Config - RF and session configuration applied during initialization.
Enums§
- Attach
Mode - The two relationships a host can have with a device.
- Host
Ownership - Verdict of comparing
PROP_HOST_KEYagainst this host’s identity (spec §Attach, Detach, and Synchronization, step 2). - Prop
Event - An unsolicited property notification (TID zero) retained for the caller: device state can change for reasons the host did not initiate, and publication of the new authoritative value is how the protocol reports that. Multi-value payloads are in digest form and never contain key material.
- Restore
Completion - How the device reported a successful
CMD_RESTORE. Both forms leave the device in the same configuration; they differ only in reporting and session-state handling. - Saved
Snapshot PROP_SAVED: what the device reports about its stored snapshot.- Trace
Direction - Direction of a traced ULCP frame.
- Ulcp
Error
Traits§
- Frame
Link - A cancel-safe, frame-oriented ULCP transport.
Functions§
- describe_
frame - Render one ULCP frame as a one-line human-readable summary:
command, TID, property mnemonic, and the decoded status where the
payload is a
PROP_LAST_STATUSvalue. Values are summarized by length — never dumped — so traces cannot leak key material.
Type Aliases§
- Frame
Trace - Sink for per-frame trace lines (see
UlcpDevice::set_frame_trace).