Skip to content

Temperature sensors

Up to four DS18B20 sensors share one data cable. Sentinel tells them apart by ROM ID (16 hex digits starting with 28), so plug order does not matter and replacing or adding a sensor does not swap slots.

  1. Plug the sensor into the bus (VDD, GND, and DQ in parallel with existing sensors).
  2. Wait up to 60 seconds, or run rescan (serial, the Scan button in the web Control tab, or cmd rescan).
  3. The new sensor is automatically bound to the lowest empty slot. Serial log: [sensors] t2 terikat ke <ROM> (baru).

The bus is scanned at boot, every 60 seconds, and on the rescan command. Every new binding is immediately re-sent in config/reported.

If all slots are full or temp_autobind is off, the sensor is listed in discovered in config/reported and on the LCD (the Device menu, 2nd screen: baru 1, then ROM <16 hex>). Bind manually:

{"cfg_ver":2,"t3_rom":"28d6237b2ed91eea"}

From the server without opening serial: python3 Tools/celestianctl.py cmd <mac> rescan. The result is in cmd/result: the discovered list and the bound map (slot → ROM).

{"cfg_ver":3,
"t1_name":"rack_top","t1_label":"Atas",
"t2_name":"rack_bottom","t2_label":"Bawah","t2_offset_c":-0.5,
"t2_warn_c":27,"t2_alarm_c":30}
Key Function
tN_en false turns the slot off: not read, not sent, no alarm, not on the LCD. The ROM binding remains stored
tN_name metric name in the data (rack_top). Empty = slot ID (t1). Lowercase letters, digits, _; starts with a letter; max. 24 characters; unique; must not start with alarm_, rule_, flag_ or be a fixed metric name. Renaming starts a new data series in Celestian
tN_label name for humans and the LCD, max. 12 characters
tN_offset_c calibration −10 … 10 °C, added to the reading. Compare with a reference thermometer before setting it
tN_warn_c, tN_alarm_c per-slot limits. -1 = follow temp_warn_c / temp_alarm_c; 0 = disabled

The effective warning must be lower than the effective alarm for each slot.

A sensor that is unplugged or broken makes its slot missing: its value is -- on the LCD, its metric is not sent, but the alarm status does not change and the ROM remains stored. If the sensor comes back, the binding recovers by itself. In Celestian, the vanished metric is the sign.

  1. Unplug the faulty sensor, plug in the new one.
  2. If the new sensor should take over the old slot (t2), set t2_rom to its ROM (see discovered or rescan):
    {"cfg_ver":4,"t2_rom":"28bb1d6d132cde16"}
  3. One ROM may only be in one slot. If that ROM was already auto-bound to another slot, clear that slot first in the same message: {"t3_rom":"","t2_rom":"<ROM>"}. Swapping the ROMs of two slots in one message is allowed.

Without setting t2_rom, the new sensor goes into the lowest empty slot, which is not necessarily t2.

Room temperature and humidity, metrics temp_ambient and humidity. Enable with sht41 = true (reboot). Details: Power and SHT41.