Case study · Side project · Connected hardware · 2026

A Bluetooth load-cell gauge I designed end to end.

An inline force gauge that shows tension live on its own display and streams it to an iPhone. I designed every layer myself: the enclosure and load path, the circuit board, the firmware, an open Bluetooth protocol and the iOS app. The method is the one I use with software and agents: measure the inputs, derive everything else, and let automated checks refuse to produce a part that is wrong.

3D render of the assembled 4-layer circuit board: Bluetooth module, 24-bit ADC, three buttons and USB-C
5 layerssteel, board, firmware, protocol, app
One builderfrom caliper readings to app screens
Open protocoldocumented and versioned
87 minutesof constant load behind the accuracy work
The idea

Live tension on the device and on a phone.

The gauge hangs in line with whatever is pulling and reads the tension through it. The display shows the force to one decimal ten times a second, with a session timer beside it. Three buttons: power, zero and timer. The phone app records sessions and graphs them.

  • Honest by default. No stable-lock and no auto-zero: a live instrument shows what is happening now, so the reading is never held or quietly reset.
  • Drift is shown on the display. A sustained negative reading is the only sign the zero has moved, so the gauge flags it.
  • The load never touches the plastic. Steel brackets carry the force through the cell; the housing only protects the electronics.
Render of the gauge face: display showing 12.4 lb and a 03:25 timer above three round buttons
The face: force, unit, timer, three buttons.
MechanicalParametric enclosure and a steel load path
Electronics4-layer board, 24-bit ADC, Bluetooth
FirmwareNon-blocking loop on an nRF52840
ProtocolOpen and versioned, so anyone can build a client
AppNative iOS, live graph and session history
How I built it

Checks that refuse to export a wrong part.

The enclosure, fittings and steel brackets are one parametric OpenSCAD model. Every bought part goes in as measured with calipers, and everything downstream is calculated from those readings, so one changed measurement moves every part that depends on it. The model checks itself, the same way I set up gates for agents.

  • The export refuses a failing model. If any built-in check trips, no printable file is written. A model that renders cleanly and is wrong is the worst outcome.
  • Fit is measured as volume. Every pair of parts that must not touch is intersected, and any overlap is reported in cubic millimetres.
  • Brittle spots are found automatically. A script scans each printed shell for material thinner than about a millimetre.
  • Cut files and their spec come from the same run. The laser shop gets flat patterns and a spec sheet that cannot drift from the model.
Colour-coded load path: load cell in grey, steel brackets in blue, standoff in brass, fasteners in red
The load path, colour coded: in through one steel bracket, through the cell, out through the other. The housing carries no load.

dimensions.scad (excerpt)

// derived, so nothing downstream re-derives it
bracket_proud_potted = standoff + strip;          // 3.2
cell_tallest         = beam_thickness + bracket_proud_potted + strip;
cell_band            = cell_tallest + band_clearance * 2;
bracket_clearance    = standoff - potting_proud;  // 1.0, DERIVED not chosen
Electronics

One small board carries everything.

A 4-layer board designed in KiCad to fit inside the shell, with parts on one side so it is assembled in one pass.

  • nRF52840 for Bluetooth LE and the application. The newest revision moves to a pre-certified radio module, so the finished device can carry an FCC ID.
  • 24-bit ADC (NAU7802) reading a full-bridge load cell.
  • USB-C charging into a LiPo, with protection on the port and the battery level on the display.
  • Easy to assemble: the cell's leads go into a screw terminal and the battery plugs in.
Top-down render of the circuit board
Top side, rendered from the KiCad design (an earlier revision).
Schematic of the main board
The schematic of an earlier revision. Open it on its own to zoom in.
Firmware and protocol

Firmware that never stalls a reading.

The firmware was brought up one step at a time on real hardware: blink, bus scan, raw counts, calibration, display, buttons, then Bluetooth. Nothing in the main loop blocks, because on a live gauge a delayed reading shows a force that is no longer there. Bluetooth writes only queue work; the loop does it.

The wire format is documented so anyone can build a client without reverse engineering. It is versioned: a client that does not recognise the major version refuses to read the data, because a misread packet still produces a plausible number, and a wrong force that looks right is worse than no reading.

CharacteristicAccessPayload
Measurementnotify, 5 times a secondforce in milli-pounds, session time in ms, flags
Controlwrite1 byte: zero, timer start/stop, timer reset
Versionread[major, minor]; absent means 1.0
Batteryread, notifythe standard battery service

The measurement packet (firmware, trimmed)

// 5 Hz, not the display's 10: queueing faster than the radio drains
// only fills buffers and adds latency to every packet.
int32_t  milli_lb = (int32_t) lroundf(lb * 1000.0f);  // fixed point on the wire
uint32_t elapsed  = timerElapsed();

uint8_t buf[9];
memcpy(&buf[0], &milli_lb, 4);              // little-endian
memcpy(&buf[4], &elapsed,  4);
buf[8] = (timerRunning ? 0x01 : 0)             // bit 0: timer running
       | (zeroHintActive(lb) ? 0x02 : 0);      // bit 1: zero has drifted
measurement.notify(buf, sizeof(buf));
Measured, not assumed

87 minutes under a constant load.

I characterised the first prototype with a Web Bluetooth bench dashboard that logged every sample. Under a constant 6.2 lb hold, 23,258 samples showed that creep is a start-up effect, not a steady drift: it settles to almost nothing after the first few minutes. A mechanical slip would have kept a constant slope, which is why the run was 87 minutes and not 30.

5.905.956.006.056.106.150153045607590 minutes under constant load pounds

15-second averages of 23,258 samples. The spike near minute 13 is in the raw log and is left in.

σ ≈ 0.0013 lbreading noise
0.02 to 0.03 lbdrift over 30 min once settled
0.062 lbre-seating repeatability
1 to 20 lbthe range it is built for

Noise is about eighty times smaller than the creep, so filtering would not improve accuracy. Accuracy comes from a written error budget where calibration is the biggest term, and it is stated as an absolute figure, never a percentage. The target is within half a pound, and it stays a target until a weight near the top of the range confirms it.

The app

A native iOS app that follows the device.

Built with SwiftUI and Core Bluetooth. It connects, streams, records and controls the gauge.

  • The device owns the timer. Pressing start on the phone asks the gauge to start, so a session started from the gauge's own button is recorded too.
  • Figures are derived from the stored series, never frozen, so changing a threshold re-reads the whole history.
  • The protocol layer is plain value types with no Bluetooth import, so the packet format is unit tested on any machine.

Decoding a measurement, Swift (trimmed)

// Read through withUnsafeBytes, not by subscript: Data from Core
// Bluetooth may be a slice of a larger buffer, so packet[0] can trap.
let (milli, elapsed, flags) = packet.withUnsafeBytes { raw in (
    Int32(littleEndian: raw.loadUnaligned(fromByteOffset: 0, as: Int32.self)),
    UInt32(littleEndian: raw.loadUnaligned(fromByteOffset: 4, as: UInt32.self)),
    raw.loadUnaligned(fromByteOffset: 8, as: UInt8.self)
)}
// Unknown flag bits are ignored, not rejected:
// that is a newer device, not a corrupt one.
Live session screen: elapsed time, time under tension and at rest, current force, and a live step graph
A live session, graphed as it happens.
Session summary: time under tension and at rest, median, mean and highest force, and the force graph
The summary, recomputed from the stored series.

Captured in the iOS simulator, which has no Bluetooth radio, so these values were entered by hand. Connected to the gauge, the same screens fill from the device.

Want to talk about it?

I'm based in Los Angeles and open to product and engineering roles.

therevoltingx@gmail.com