OnMeters Documentation

Everything you need to set up, connect and integrate your Metron optical reader.

Quick start

1. Place the magnetic optical head over the round IR port on your meter's front panel. It self-aligns and holds.

2. Power: the device runs wire-free on its coin cell battery. For permanent installation (or WiFi mode, which uses more power), connect any USB-C supply — a phone charger works.

3. The status LED blinks while reading. Within 60 seconds the first full readout completes.

4. Connect: the device starts in Bluetooth mode — open the web app in Chrome/Edge and tap Connect. Or switch to WiFi mode (below) for the dashboard.

Switching between BLE and WiFi

Only one radio runs at a time. The active mode is stored and survives power cycles. Three ways to switch:

MethodHow
ButtonHold the mode (BOOT) button for 3 seconds — the LED flashes and the device reboots into the other mode.
BluetoothSend the command MODE=WIFI from the web app or any BLE terminal.
HTTPIn WiFi mode, call GET /api/mode?set=ble to go back to Bluetooth.
Battery vs WiFi: Bluetooth mode is designed for battery operation. WiFi mode draws considerably more power — use USB-C when running in WiFi mode.
First WiFi setup: send SSID=YourNetwork and PASS=YourPassword over Bluetooth, then MODE=WIFI. If the network can't be joined, the device opens its own hotspot OnMeters-Setup (password onmeters123) — connect to it and open 192.168.4.1.

BLE commands

OnMeters exposes a Nordic UART Service (NUS). Write commands to the RX characteristic; responses arrive as notifications on TX, terminated by a newline.

CommandAction
READTrigger a fresh meter readout, then return full JSON.
DATAReturn the latest cached readout as JSON.
INFODevice, firmware, detected protocol and meter ID.
SSID=name / PASS=secretStore WiFi credentials.
MQTT=host[:port]Store MQTT broker (default port 1883).
MQTTUSER=u / MQTTPASS=pStore MQTT credentials (if your broker needs them).
INTERVAL=secondsSet the read interval, e.g. INTERVAL=900 = every 15 min.
RATE=n/hour|day|monthSet rate by count, e.g. RATE=48/day, RATE=100/month.
SLEEP=ON / SLEEP=OFFEnable battery deep-sleep mode (see below).
BATTERYReturn battery voltage (mV) and low-battery flag.
MESHList all other Metrons heard over the mesh: module ID, meter ID, kWh, power, battery, hops.
NEIGHBORSInstallation survey: 3-second listen, then reports which Metrons this unit hears directly, with signal strength (dBm), approximate distance and link quality — plus which are reachable only via relay.
PRICE=0.30Set your electricity tariff per kWh — enables cost calculation.
CURRENCY=USDCurrency label for cost values (USD, EUR, SAR, EGP...).
MODE=WIFISwitch to WiFi mode (reboots).

Battery & deep sleep

OnMeters runs wire-free on a CR2450 coin cell. To maximise battery life, enable deep-sleep mode: SLEEP=ON over BLE (or sleep=on via /api/config). The device then wakes on a timer, reads the meter, publishes the data, stays connectable over Bluetooth for 60 seconds, and goes back to deep sleep (a few µA).

Choose how often it reads with INTERVAL= (seconds) or RATE= — for example RATE=24/day for hourly readings or RATE=30/month for a daily reading. Fewer reads = longer battery life.

WiFi needs USB power. WiFi and MQTT draw far more current than a coin cell can deliver continuously — connect USB-C when using WiFi mode.

RGB status LED

ColourMeaning
⚪ WhiteBooting / switching mode
🔵 Blue pulseBluetooth pairing — advertising, waiting for a phone
🔵 Blue blipBluetooth connected
🟡 YellowConnecting to WiFi
🩵 CyanReading the meter
🟢 Green flashRead successful / WiFi connected
🔴 Red flashRead failed — check probe alignment
🟠 Orange pulseLow battery — replace the coin cell

HTTP API (WiFi mode)

Base URL: http://onmeters.local (or the device IP).

EndpointMethodDescription
/GETBuilt-in live dashboard.
/api/dataGETLatest readout as JSON.
/api/readGETForce a fresh readout, return JSON.
/api/mode?set=bleGETSwitch to Bluetooth mode.
/api/configPOSTSet ssid, pass, mqtt_host, mqtt_port, mqtt_user, mqtt_pass, interval, rate, sleep, price, currency (form fields).
/api/meshGETJSON table of all Metrons heard over the BLE mesh (collected while in Bluetooth mode).
/api/historyGETFull reading history as CSV (epoch,kwh,power_w,vbat_mv). Add ?clear=1 to erase.
/updateGET/POSTOver-the-air firmware update — open in a browser and upload the compiled .bin.

History log

Every successful read is appended to flash storage (~64 KB ring, oldest entries trimmed automatically). Timestamps come from NTP when the device is in WiFi mode; in battery/BLE mode the epoch is 0 and rows are still ordered. Pull the CSV into Excel, Grafana or a script via /api/history.

Cost calculation

Set your tariff once (PRICE=0.30 + CURRENCY=USD) and OnMeters reports the total energy cost in the JSON (cost_total), and publishes a Home Assistant "monetary" sensor at onmeters/cost.

Mesh relay (beta)

Every Metron embeds its latest reading in its Bluetooth advertisement — like Apple's Find My network. Nearby Metrons overhear it and re-broadcast it (up to 3 hops), with no pairing, router or internet. Connect to any unit and send MESH to see every meter in range of the chain. Each entry carries two identities: the module ID (unique per device, from its radio chip — shown as OM-XXXXXX) and the meter ID (the serial read from the meter itself), so readings stay tracked per meter even if a module is moved.

Power tip: relaying requires periodic listening (2 s every 20 s). Battery units in deep-sleep mode relay only during their wake window — use USB-powered units as the always-on backbone of the mesh.

Installation survey

When installing multiple units, connect to each one and send NEIGHBORS. It listens for 3 seconds and reports every Metron it hears directly, with signal strength and a rough distance estimate:

{ "module_id": "OM-4B22F1",
  "neighbors": [
    { "module_id": "OM-A3F210", "direct": true,  "rssi_dbm": -62,
      "approx_m": 3.2, "link": "strong" },
    { "module_id": "OM-77B4C1", "direct": true,  "rssi_dbm": -84,
      "approx_m": 14.8, "link": "weak" },
    { "module_id": "OM-99D2E0", "direct": false, "via": "relay", "hops": 2 } ],
  "direct_count": 2, "relay_only_count": 1,
  "hint": "some nodes reachable only via relay - links are working" }

If a far unit shows "link": "weak" or doesn't appear at all, place an extra Metron (or any USB-powered unit) roughly halfway between them and run NEIGHBORS again. Distance estimates assume open air — walls and metal meter cabinets shorten real range considerably.

OTA firmware updates

In WiFi mode, open http://onmeters.local/update, choose the official update file downloaded from onmeters.com and click Flash. The device reboots into the new firmware in seconds — no cables, and all settings are kept.

Response format

{
  "device": "OnMeters", "fw": "1.5.0",
  "vbat_mv": 2980, "battery_low": false,
  "interval_s": 1800, "sleep": true,
  "price": 0.30, "currency": "USD", "cost_total": 3854.20,
  "meter": "ISK5MT174-0001", "protocol": "IEC",
  "reads": 42, "age_s": 12, "mode": "wifi",
  "obis": [
    { "code": "1.8.0", "name": "Energy import total",
      "value": "012847.335", "unit": "kWh" },
    { "code": "16.7.0", "name": "Active power",
      "value": "1240", "unit": "W" }
  ]
}

MQTT & Home Assistant

Set a broker once and OnMeters publishes every register plus Home Assistant auto-discovery — sensors appear in HA automatically with correct units and device classes. No YAML needed.

# configure over HTTP (or use BLE: MQTT=192.168.1.10)
curl -X POST http://onmeters.local/api/config \
  -d "mqtt_host=192.168.1.10" -d "mqtt_port=1883" \
  -d "mqtt_user=ha" -d "mqtt_pass=secret"
TopicPayload
onmeters/<obis>Plain value per register, e.g. onmeters/1.8.0012847.335
onmeters/jsonFull readout JSON.
onmeters/availabilityonline / offline (LWT, retained).
homeassistant/sensor/onmeters_*/configRetained discovery messages.
In Home Assistant, just make sure the MQTT integration is configured with the same broker — the "OnMeters" device with all its sensors appears under Settings → Devices after the first readout.

OBIS reference

Common registers OnMeters decodes (availability depends on your meter):

OBISMeaningUnit
0.0.0Meter serial number
1.8.0Active energy import, totalkWh
1.8.1 / 1.8.2Energy import tariff 1 / 2kWh
2.8.0Active energy export, totalkWh
3.8.0 / 4.8.0Reactive energy import / exportkvarh
16.7.0 / 1.7.0Instantaneous active powerW
32.7.0 / 52.7.0 / 72.7.0Voltage L1 / L2 / L3V
31.7.0 / 51.7.0 / 71.7.0Current L1 / L2 / L3A
14.7.0Grid frequencyHz
13.7.0Power factor
0.9.1 / 0.9.2Meter time / date

Firmware updates

Metron updates itself over the air — no cables, no tools. When a new firmware version is released, put one device in WiFi mode, open http://onmeters.local/update, select the update file from onmeters.com and click Flash. The device reboots into the new version in seconds; all your settings are kept.

The rest of your Metrons update themselves. Once one unit runs the new version, it announces it over the mesh — nearby units download it directly from that unit, verify its cryptographic signature, flash, reboot, and pass it onward. A whole building updates from a single flash, with no internet.

Battery protection: a battery-powered Metron refuses any firmware update (mesh or manual) while its battery is below a safe level — the status shows waiting_battery and the update resumes automatically after charging. Updates that fail verification are rejected and the current firmware keeps running.
New firmware releases are announced on our LinkedIn page.

Troubleshooting

SymptomFix
No readings, LED blinks continuouslyCheck head alignment on the IR port; rotate slightly. Some meters need PIN activation via the utility to enable extended data.
Garbage charactersContact support — your meter's optical port may use an inverted signal, which we fix with a firmware update.
onmeters.local not foundUse the device IP (check your router's client list). Some Android devices don't resolve mDNS.
Web Bluetooth won't connectUse Chrome or Edge over HTTPS; Bluetooth must be on. iOS Safari doesn't support Web Bluetooth — use WiFi mode there.
Sensors missing in Home AssistantVerify broker host/credentials, and that HA's MQTT integration uses the same broker. Check onmeters/availability is online.

© 2026 OnMeters · onmeters.com · info@onmeters.com