Metrics Client
Discover nearby Metrics Servers and view live device metrics streamed over Bluetooth LE.
Overview
Metrics Client connects to a Metrics Server running on another device and displays the server's live metrics in real time. It receives CPU usage, per-core CPU activity, device identity (server name, device model, device name), and timestamps — all streamed over Bluetooth Low Energy.
Table Of Contents
- Tabs
- Discovery Tab
- Metrics Tab
- How To Use With Metrics Server
- Permissions
- Technical Details
- Notes And Limitations
Tabs
Metrics Client has two tabs. You can swipe between them or tap the tab titles.
- Discovery — scan for and connect to nearby servers.
- Metrics — view live data from the connected server.
Discovery Tab
The Discovery tab is the landing screen. It scans for nearby Metrics Server peripherals and lets you connect to one.
Discovery Status Card
The status card shows:
- A scanning indicator — a colored dot with a label:
- Scanning (blue, with loading animation) — actively scanning for peripherals.
- Idle (gray) — scanning is paused.
- Discovered Servers — the count of Metrics Server peripherals currently visible.
- A Refresh button — stops and restarts the BLE scan to pick up new servers.
Scanning starts automatically when the tool is opened.
Available Servers List
Below the status card, discovered servers are listed. Only peripherals that advertise the Metrics Server BLE service UUID are shown — other Bluetooth devices are filtered out.
When no servers are found, a troubleshooting checklist is displayed:
- A device is running the Metrics Server tool
- Local Network permission is granted in Settings
- Both devices are on the same network / within BLE range
Servers that disappear from BLE advertisements are kept in the list for a short grace period (3 seconds) to avoid flickering.
Server Row
Each discovered server is displayed as a row containing:
- Server name — the name configured in Metrics Server (e.g. "iPhone 16 Pro Max (iPhone17,2)"). Display names are debounced for 1.5 seconds to avoid rapid flickering when the BLE advertisement name changes.
- RSSI — the signal strength in dBm, with a color-coded 3-bar signal indicator:
- Green (3 bars) — strong signal (>= -60 dBm)
- Orange (2 bars) — moderate signal (>= -75 dBm)
- Red (1 bar) — weak signal (< -75 dBm)
- Service availability — a green or gray dot indicating whether the server is advertising the Metrics service UUID.
- A Connect / Disconnect button:
- Connect (blue) — initiates a BLE connection to this server.
- Connecting (gray, with loading spinner) — connection in progress.
- Disconnect (red) — disconnects from the current server.
Only one server connection is supported at a time. While connecting to one server, other server rows are disabled.
Metrics Tab
When connected, the Metrics tab displays live data streamed from the server. The client automatically switches to this tab upon successful connection.
Connection Status Card
The top card shows:
- Connection state — a colored dot with a label:
- Connected (green)
- Disconnected (red)
When connected, additional details appear:
-
Signal Strength — a 5-bar indicator with a quality label (Excellent, Good, Fair, Poor, Very Poor) and the raw RSSI value in dBm:
RSSI Range Quality Bars >= -50 dBm Excellent 5 -51 to -65 dBm Good 4 -66 to -75 dBm Fair 3 -76 to -85 dBm Poor 2 Below -85 dBm Very Poor 1 -
RSSI History — a rolling line graph of signal strength readings (up to 120 samples), providing a visual sense of connection stability.
-
Server identity — three key-value rows showing the data transmitted by the server:
Field Description Server Name The name configured in Metrics Server (e.g. "iPhone 16 Pro Max (iPhone17,2)"). Device Model The server device's marketing name (e.g. "iPhone 16 Pro Max"). Device The user-assigned device name from iOS Settings (e.g. "Rogerio's iPhone 16ProMax"). -
Error messages — if any BLE errors occur (connection failure, disconnection, etc.), they appear as a red warning.
-
A Disconnect button (red, full-width) to terminate the connection.
Real-Time Metrics Card
When metrics are being received, this card displays:
| Field | Description |
|---|---|
| CPU Usage | The server device's current overall CPU usage percentage (e.g. 30.0%), displayed as a large number. |
| Core Count | The number of CPU cores on the server device (e.g. 6). |
| Last Update | The timestamp of the most recent metrics packet, shown as a time string. |
CPU Usage History
A rolling line graph showing the server's CPU usage over time. The graph holds up to 100 data points, providing roughly 100 seconds of history at the 1-second update rate.
Per-Core Usage
When the server provides per-core CPU data, a Per-Core Usage view is shown below the history graph. This displays the current usage percentage for each individual CPU core, matching the same per-core visualization used in the CPU Monitor tool.
No Metrics State
When not connected or when no metrics have arrived yet, the Metrics tab shows a placeholder with a chart icon and a prompt to connect to a server using the Discovery tab.
How To Use With Metrics Server
- On the device you want to observe, open Tools > Metrics Server and tap Start Server.
- On the device running Metrics Client, open Tools > Metrics Client.
- In the Discovery tab, find the server and tap Connect.
- The client automatically switches to the Metrics tab to display live readings.
Permissions
- Bluetooth permission — required for BLE scanning and connection. If permission is denied, enable Bluetooth access for Lirum in iOS Settings.
- Bluetooth permission is handled automatically by CoreBluetooth. The system prompt appears the first time the tool initializes.
Technical Details
- The client acts as a BLE Central using
CBCentralManager. It scans for all nearby peripherals and filters the list to show only those advertising the Metrics Server service UUID. - Upon connection, the client discovers the Metrics Server GATT service and subscribes to both the summary and per-core notify characteristics.
- Metrics arrive as binary payloads approximately once per second. The client decodes:
- Summary: server name, device model, device name, overall CPU usage (Float), core count (UInt16), timestamp (UInt64 milliseconds).
- Per-core: core count, per-core usage array (Float per core), timestamp (UInt64 milliseconds).
- The client supports both v1 (legacy) and v2 (current) payload formats for backward compatibility with older Metrics Server versions. v2 adds device model, server name as separate fields, and millisecond-precision timestamps.
- RSSI for the connected server is polled every 2 seconds via
readRSSI(). An RSSI history of up to 120 samples is maintained for the signal graph. - Signal smoothing — in the discovery list, RSSI values are exponentially smoothed (alpha = 0.15) to reduce visual jitter in the signal bars.
- Name stabilization — server display names in the discovery list are debounced for 1.5 seconds to prevent flickering when BLE advertisement names change rapidly.
- Vanish grace period — servers that disappear from BLE advertisements are retained in the list for 3 seconds before being removed, preventing the list from flickering.
- CoreBluetooth state restoration is enabled, allowing the client to recover an existing connection if the app is relaunched by the system.
- Metrics history is capped at 100 entries, corresponding to roughly 100 seconds of data at the default 1-second update interval.
Notes And Limitations
- This tool uses Bluetooth LE, not Wi-Fi networking. Both devices must be within BLE range.
- Only one server connection is supported at a time.
- RSSI is an approximate indicator of signal strength and can fluctuate due to environmental factors.
- The metrics stream includes CPU usage, per-core usage, core count, and device identity. Other device metrics (memory, storage, thermals) are not currently transmitted.
- On visionOS, Metrics Client is unavailable because the BLE central role is not supported on that platform.