Milesight AM308: 8-in-1 LoRaWAN Indoor Air Quality Sensor

Milesight AM308 8-in-1 LoRaWAN IAQ sensor: own ChirpStack/ThingsBoard decoder, decoded example, CO2, PM2.5, TVOC and smart-office integration.

Milesight AM308
AM308Sensor
LoRaWAN
Class A, OTAA
Band / port
EU868 / port 85
Display
4.2 inch E-Ink, dark/light theme
CO2 sensor
NDIR, 400 to 5000 ppm
Particulate
PM2.5 and PM10 (laser)
Battery
Replaceable, up to 1 year
Configuration
NFC (Milesight ToolBox)
Measurements

What the AM308 measures

CO2

NDIR sensor, 400 to 5000 ppm, the lead indicator for ventilation.

PM2.5 and PM10

Laser particulate sensor for fine dust in micrograms per cubic metre.

TVOC

Total volatile organic compounds, as an IAQ index or in micrograms per cubic metre.

Temperature and humidity

Comfort baseline alongside barometric pressure.

PIR and light

Occupancy and ambient light level for demand-based ventilation.

Data into your dashboard

Integration

Sensor / controller

Measures or controls in the field and sends LoRaWAN uplinks.

LoRaWAN gateway

Receives the radio packets and forwards them to the server.

ChirpStack

Network server: manages sessions and decodes the payload.

ThingsBoard / Grafana

Dashboards, alarms, rules and reports.

ChirpStack v4 · decodeUplink
function decodeUplink(input) {
  var bytes = input.bytes;
  var data = {};

  for (var i = 0; i < bytes.length; ) {
    var channel = bytes[i++];
    var type = bytes[i++];

    if (channel === 0x01 && type === 0x75) {          // battery (%)
      data.battery = bytes[i]; i += 1;
    } else if (channel === 0x03 && type === 0x67) {   // temperature (°C)
      data.temperature = readInt16LE(bytes, i) / 10; i += 2;
    } else if (channel === 0x04 && type === 0x68) {   // humidity (%RH)
      data.humidity = bytes[i] / 2; i += 1;
    } else if (channel === 0x05 && type === 0x00) {   // PIR occupancy
      data.pir = bytes[i] === 1 ? "trigger" : "idle"; i += 1;
    } else if (channel === 0x06 && type === 0xcb) {   // light level (raw)
      data.light_level = bytes[i]; i += 1;
    } else if (channel === 0x07 && type === 0x7d) {   // CO2 (ppm)
      data.co2 = readUInt16LE(bytes, i); i += 2;
    } else if (channel === 0x08 && type === 0x7d) {   // TVOC (IAQ index)
      data.tvoc = readUInt16LE(bytes, i) / 100; i += 2;
    } else if (channel === 0x08 && type === 0xe6) {   // TVOC (µg/m³)
      data.tvoc = readUInt16LE(bytes, i); i += 2;
    } else if (channel === 0x09 && type === 0x73) {   // pressure (hPa)
      data.pressure = readUInt16LE(bytes, i) / 10; i += 2;
    } else if (channel === 0x0b && type === 0x7d) {   // PM2.5 (µg/m³)
      data.pm2_5 = readUInt16LE(bytes, i); i += 2;
    } else if (channel === 0x0c && type === 0x7d) {   // PM10 (µg/m³)
      data.pm10 = readUInt16LE(bytes, i); i += 2;
    } else {
      break;
    }
  }
  return { data: data };
}

function readInt16LE(b, i) {
  var v = (b[i + 1] << 8) | b[i];
  return v > 0x7fff ? v - 0x10000 : v;
}
function readUInt16LE(b, i) {
  return ((b[i + 1] << 8) | b[i]) & 0xffff;
}

Implemented from the published Milesight byte specification (Communication Protocol / User Guide).

Channel format: 01 75 battery (%), 03 67 temperature (INT16 LE, /10), 04 68 humidity (/2), 05 00 PIR, 06 cb light level, 07 7d CO2 (ppm), 08 7d TVOC as IAQ index (/100) or 08 e6 TVOC in µg/m³, 09 73 pressure (/10), 0b 7d PM2.5, 0c 7d PM10. The TVOC channel type depends on the unit configured over NFC. History uplinks (channel 0x20/0x21) bundle a timestamp plus all values, the loop above breaks on them and they can be added per deployment. For ThingsBoard the same logic goes into an uplink converter.

Uplink (hex)

0367E40004685B077DF401087D2C01097377270B7D0F000C7D1400

Decoded JSON

{ "temperature": 22.8, "humidity": 45.5, "co2": 500, "tvoc": 3, "pressure": 1010.3, "pm2_5": 15, "pm10": 20 }
From the field

Configuration & pitfalls

NFC setup

Keys, reporting interval, TVOC unit and threshold alarms are set over NFC with the Milesight ToolBox before rollout.

CO2 calibration (ABC)

The NDIR sensor uses automatic baseline calibration that assumes regular exposure to fresh air. In rooms that are never ventilated, switch to manual calibration so readings stay accurate.

TVOC unit

TVOC is reported either as an IAQ index (channel type 0x7d, /100) or in µg/m³ (type 0xe6). Pick one in ToolBox and keep the decoder branch aligned so the dashboard label matches.

Mounting and PM intake

Wall mount at breathing height and keep the particulate intake clear. Direct draughts or heat sources distort PM and temperature readings.

Your partner

How merkaio supports your AM308

From sourcing to day-to-day operation, all from one partner on our own European infrastructure.

Pre-staging & provisioning

We configure the AM308, set keys, intervals and alarms, and ship it ready to deploy.

Own decoder

Payload codec for ChirpStack v4 and ThingsBoard, implemented from the Milesight specification.

Dashboard integration

Data lands in your ThingsBoard or Grafana, with alarms and reports.

Operations & monitoring

We run the LoRaWAN stack and dashboards on European infrastructure, you just use the data.

Frequently asked questions

Yes. It is a standard LoRaWAN Class A device, no Milesight gateway or cloud required. You add the codec to the device profile and provision it via OTAA.
Yes, for both ChirpStack and ThingsBoard, implemented from the published Milesight byte specification. The same channel logic goes into a ThingsBoard uplink converter.
Temperature, humidity, CO2, TVOC, barometric pressure, PM2.5, PM10 and light, plus PIR occupancy. The eight air-quality values are also shown on the built-in E-Ink display.
Either as an IAQ index or directly in micrograms per cubic metre, depending on the unit you select over NFC. The two formats use different channel types, so the decoder branch must match the configured unit.
The AM308 runs up to about one year on its replaceable battery, depending on the reporting interval. It can also be powered continuously over USB for high-frequency reporting.
Yes. Thresholds, for example a CO2 ceiling, are set over NFC with the Milesight ToolBox and trigger an immediate uplink outside the regular interval, so dashboard rules should treat alarm uplinks as priority events.
From the same series

Related devices

Let's discuss your infrastructure. Digital and on-site.

Whether it's IoT platform development, hardware selection, managed hosting for ChirpStack, ThingsBoard, Grafana or NetBird VPN, or migration from a self-hosted setup - we'll find the right solution for your use case. Book a free 30-minute consultation, no commitment required.

Timo Wevelsiep

Your contact

Timo Wevelsiep

Founder, merkaio

15 minutes, no commitment, directly with Timo.

By submitting, you agree to our Privacy Policy.

Decoder for ChirpStack v4. merkaio is an independent integrator and is not affiliated with Milesight.