raehDocs
Guides

Register a Device

Register a device model and understand the device_model_id lifecycle.

Before any frame can flow, Raeh needs to know what kind of hardware is sending it: which sensors, at what sample rate, at what bit depth. That's what a device model describes.

You register a device model once per hardware type, not per physical unit.

Register in the dashboard

  1. Go to Devices in the sidebar.
  2. Click Register Device Type.
  3. Fill in:
    • Name: anything unique to your account (e.g. xyz_watch_v1).
    • Description and Firmware Version: optional, for your own records.
    • Sensors: one row per modality channel. Pick the modality (PPG Green, 3-axis accelerometer, …), set the sample rate. Bit depth and channel count come from sensible defaults.
  4. Save.

Copy the Device Model ID

Open the device detail page. At the top you'll see the Device Model ID, a UUID like 573fdc48-b7a8-40bb-81b7-e96df24fab6d. Click the copy icon.

You'll pass this ID every time you open /stream/ingest. Bake it into your firmware / SDK build config; every physical unit of this hardware type carries the same ID.

// firmware.c
#define RAEH_DEVICE_MODEL_ID "573fdc48-b7a8-40bb-81b7-e96df24fab6d"

Multiple sensors

A device model can declare several modality channels. For example, an XYZ watch with PPG and accelerometer:

SensorSample rateNotes
PPG Green100 HzRequired for HR, SpO₂, RR
Accelerometer 3-axis50 HzOptional; used for motion-artifact rejection

When you connect, the server's handshake returns one slot per channel:

{
  "session_id": "…",
  "slots": [
    { "slot_id": 0, "modality": "ppg_green" },
    { "slot_id": 1, "modality": "acc_3axis" }
  ]
}

You send each modality's samples on its own slot.

Editing a device model

You can change the name, description, firmware version, and add new modality channels on the detail page. The Device Model ID stays the same.

Removing a modality channel is allowed, but any firmware still sending on that slot will get an error; plan rollouts accordingly.

Versioning

A device model represents one hardware profile. If you ship new hardware with different sensors (e.g. a v2 with added SpO₂ red/IR), register a new device model (xyz_watch_v2) with its own ID. Don't reuse the v1 ID.

Keeping each hardware version as a separate model makes it easy to:

  • Route sessions from v1 devices through v1-appropriate algorithms
  • Report per-hardware analytics in the dashboard
  • Deprecate old hardware cleanly

Physical units (devices)

You don't pre-register individual watches or patches. The first time a unit connects, pass its serial number / MAC address / UUID as device_id; the server creates a Device row for it automatically. Subsequent connections with the same device_id reuse that row.

On this page