home  /  projects  /  gsm + gps
experimental

GSM + GPS Probes

Command-line diagnostics for the Surface's cellular modem and GPS hardware. A dashboard for live diag events. An unbuffered wrapper around QCSuper for modem logging. Feeds the gpslog pipeline that the notebook's MCP tools rely on.

diag_dash.py terminal: timestamp, event type, band, signal, status columns with live-updating rows and color-coded status cells.
what's in tree
  • cell_scan.pycellular band probe — ModemManager-backed scan, dumps signal, operator, bands
  • gps_test.pyGPS probe — queries the modem's GNSS, reports fix state, sats, HDOP
  • diag_dash.pyterminal dashboard for live diag events
  • qcsuper_unbuf.pyline-unbuffered wrapper around qcsuper so its output streams cleanly
  • diag_events.csvgrowing corpus of captured events, useful for regression tests against modem firmware quirks
where this fits

The Surface Pro 9 has a cellular modem that ModemManager sees but that doesn't quite behave like a textbook 3GPP device. Some commands stall. Some diag pipes emit partial events. Some sequences crash the modem stack if you ask the wrong question during lock.

These probes exist to write down what actually happens. Before any feature is built on top of the modem, a probe confirms the behaviour on the device in front of me. That's the only way to keep the LLM honest when it's reasoning about the hardware.

Terminal running gps_test.py: fix state transitions from NO FIX to 2D FIX to 3D FIX with sat count and HDOP updating.
cell_scan.py output: operator, band list and per-band signal strength.

Feed for the notebook

The GPS probe lineage is what made gpslog viable: by the time the daemon was written, we already knew which gpsd messages were garbage (status pings with mode < 2, the pre-lock (0.0, 0.0) zero-island) and which were real. See the MCP server page for how that feeds the notebook's location tools.

Probes first, features second

Every hardware integration in this workspace starts with a probe. You can't design around a device you haven't interrogated. The HackRF dashboard did it with the PortaPack's ChibiOS shell. The camera did it with a libcamera rating jig. This project does it for the modem. Pattern pays off every time.