Skip to content

1. Sensor Overview

Model catalog

Search for these models in ThinkLink by name or ID.

Model typeNameid_namePlatform model ID
RPC[RS-O2WS-N01 GET] parars_o2ws_n01_get_2210292200172653645829
RPC[RS-O2WS-N01 SET] parars_o2ws_n01_set_2210292199641528930309
TemplateRS-O2WS-N0192202072736272389
Thing Model[RS-O2WS-N01]rs_o2ws_n01_22210292198338690027525
Thing Model[RS-22102-RS-O2WS-N01资产] 区域聚合rs_o2ws_n01_asset_22102119677174411063311
Parameter Thing Model[RS-O2WS-N01-PARA]rs_o2ws_n01_para_2210292198902907801605

The RS-O2WS-N01 is an oxygen, temperature, and humidity sensor from RenKe. It is a 3-in-1 RS485 transmitter supporting RS485 output and standard Modbus-RTU communication. It is suitable for warehouses, workshops, chemical plants, agricultural greenhouses, livestock farms, enclosed living spaces, and other scenarios where real-time monitoring of oxygen concentration, temperature, and humidity is required. The device supports a wide input power supply of 10–30 V DC and allows device address and baud rate configuration.

2. Product Features

  • Measurement range: 0–30% VOL, supporting oxygen, temperature, and humidity monitoring.
  • Oxygen measurement accuracy: within ±2% FS, with repeatability within 1%.
  • Temperature measurement range: -40°C to +80°C, accuracy ±0.5°C.
  • Humidity measurement range: 0–100% RH, accuracy ±3% RH.
  • Supports RS485 communication interface and standard Modbus-RTU protocol, with a communication distance of up to 2000 meters.
  • Supports 10–30 V DC wide-range power supply.
  • Uses a wall-mounted waterproof enclosure, suitable for harsh on-site environments.
  • Some single-gas models support an optional OLED display, but the 3-in-1 model does not include OLED.

3. Application Scope

This device is suitable for warehouses, workshops, chemical plants, greenhouses, livestock farms, enclosed living spaces, and other scenarios requiring real-time oxygen concentration monitoring.

Since this model is a 3-in-1 oxygen, temperature, and humidity device, it is also suitable for applications requiring simultaneous collection of environmental temperature, humidity, and oxygen concentration.

4. Integration Information

4.1 Hardware Information

  • Device Model: RS-O2WS-N01
  • Manufacturer: RenKe
  • Business Code: 22102
  • Template: RS-O2WS-N01
  • Power Supply: 10–30 V DC
  • Output Signal: RS485
  • Communication Protocol: Modbus-RTU
  • Default Address: 0x01
  • Default Baud Rate: 4800 bit/s (manual default); set to 9600 in the EB configuration (actual integration shall follow the flashed configuration)
  • Operating Temperature: -20 to 50°C
  • Operating Humidity: 5–95% RH, non-condensing
  • Device Dimensions: 110 × 85 × 42 mm

4.2 Wiring Information

Power and Communication Interface

  • Power Positive: Brown, 10–30 V DC
  • Power Negative: Black
  • 485-A: Yellow
  • 485-B: Blue

Note:
When wiring RS485, A/B must not be reversed. Device addresses on the same bus must not conflict.

Sensor Interface

This model is an integrated oxygen, temperature, and humidity sensor. The sensing probe is built into the device, so no separate sensor interface definition is required.

For versions with an external probe, the probe is connected to the main unit using the factory-supplied cable.

5. Data Acquisition

In this solution, the following registers are read via Modbus:

For the RS-O2WS-N01 3-in-1 device, the acquisition registers are:

  • 0000H: Humidity
  • 0001H: Temperature
  • 0002H: Oxygen concentration

In the EB configuration, they correspond to:

  • 0x0000 → Humidity
  • 0x0001 → Temperature
  • 0x0002 → Oxygen concentration

5.1 Register Definition

Register AddressPLC / SCADA AddressContentFunction CodeDescription
0000H40001Humidity0x03 / 0x040–1000, scaled by 10
0001H40002Temperature0x03 / 0x04-400–800, scaled by 10
0002H40003Oxygen concentration0x03 / 0x040–300, scaled by 10
0032H40051Temperature calibration0x03 / 0x04 / 0x06 / 0x10Write value after scaling by 10
0035H40054Humidity calibration0x03 / 0x04 / 0x06 / 0x10Write value after scaling by 10
0038H40057Oxygen calibration0x03 / 0x04 / 0x06 / 0x10Write value after scaling by 10
07D0H42001Device address0x03 / 0x04 / 0x06 / 0x101–254, default 1
07D1H42002Device baud rate0x03 / 0x04 / 0x06 / 0x100=2400, 1=4800, 2=9600, 3=19200, 4=38400, 5=57600, 6=115200, 7=1200

Data is 16-bit, high byte first. When the temperature is below 0°C, it is uploaded in two’s complement format.

5.2 Status Bit Definition

The device manual does not provide an independent status bit register definition, so no status bit definition is included in this integration.

No additional status word or alarm bit is defined in the EB configuration.

6. EdgeBus Model

6.1 EB Configuration Parameters

The key parameters defined in EB are as follows:

  • Device Name: o2ws
  • LoRaWAN Port: 22
  • Protocol Type: modbus
  • Modbus Address: 0x01
  • Function Code: 0x03
  • Version: 0x86
  • Data Type: 0x02
  • Uplink Period Index: 70
  • Collection Period Index: 74

Register mapping:

  • 0x0000~0x0000 → covAppIndex 110, Int16BE
  • 0x0001~0x0001 → covAppIndex 112, Int16BE
  • 0x0002~0x0002 → covAppIndex 114, Uint16BE

OTA configuration:

  • BaudRate: 9600
  • StopBits: 1
  • DataBits: 8
  • Checkbit: NONE
  • Battery: true
  • ConfirmDuty: 60
  • BzType: 22102
  • BzVersion: 11

6.2 EB Code

typescript
import { Buffer } from "buffer";
import { buildOtaFile } from "@EBSDK/run";
import {
    ActionAfertExpr, CalcData,
    CrcMode,
    CvtRule,
    EBBuffer,
    EBModel,
    ExprCondition,
    LoraUpEvent,
    QueryEvent, SetUpCovDataType,
    UserConfUPItem, EventInfoItem, QuItemModBus, TypeVal, ValItem, EventConfig, Utils, UserConfQueryItem
} from "@EBSDK/EBCompiler/all_variable";
import { CheckbitEnum, getOtaConfig, HwTypeEnum, UpgrdTypeEnum } from "@EBSDK/otaConfig";
////////////////////////////////////////////////////////////////////////////////////////

const eventInfo:UserConfUPItem[]=[
    {
        name:"o2ws", port:22, version:"0x86",dataType:"0x02",upPeriodIndex:70,
        quInfo:[{
            protocol:"modbus",addr:"0x01",code:"0x03", periodIndex:74,//addr:"0x01",
            indexAPP:150, indexCMD:0, copySize:1,isLast:false,//period:"900s",payIndex:3,ackAddrIndex:0,
            listVal:[
                { start: "0x0000", end: "0x0000" ,covType:"Int16BE",covAppIndex:110},
                { start: "0x0001", end: "0x0001" ,covType:"Int16BE",covAppIndex:112},
                { start: "0x0002", end: "0x0002" ,covType:"Uint16BE",covAppIndex:114},
            ]
            }
        ]
    }
]
let otaConfig = getOtaConfig({
    BaudRate: 9600,
    StopBits: 1,
    DataBits: 8,
    Checkbit: CheckbitEnum.NONE,
    Battery: true,
    ConfirmDuty: 60,
    BzType: 22102,
    BzVersion: 11
})
const MODBUS_TT = (ebModel: EBModel) => {
    for (let i=0; i<eventInfo.length; i++){
        let event=new EventInfoItem(eventInfo[i]);
        event.upEventSetup()
        event.eventInstall()
    }
    return JSON.stringify(ebModel, null, 2)
}
buildOtaFile(import.meta.url, otaConfig, MODBUS_TT)

6.3 Description

Current EB logic description:

This solution uses EdgeBus to periodically initiate Modbus reads, collect the three registers for temperature, humidity, and oxygen concentration, map the collected values to application-layer indexes, and then report them through LoRaWAN port 22.

Among them:

  • upPeriodIndex:70 is used to control the overall uplink period.
  • periodIndex:74 is used to control the Modbus acquisition period.
  • app_110, app_112 are used for temperature and humidity threshold or change-value configuration.
  • app_150 is used for Modbus address configuration.
  • index 6 → humidity
  • index 8 → temperature
  • index 10 → o2

7. Thing Model

7.1 Basic Information

  • Data Thing Model Name: [RS-O2WS-N01]
  • id Name: rs_o2ws_n01_222102
  • Parameter Thing Model Name: [RS-O2WS-N01-PARA]
  • id Name: rs_o2ws_n01_para_22102

The current uplink frame structure is as follows:

javascript
let frameInfo={
  port:22, dataLen:-1,rssi:true,battery:true,
  subDevice:{index:5,type:"uint8"},
  tagList:[{index:0, tag:0x86}, {index:1, tag:0x02}]
}

7.3 Thing Model Script

javascript
let frameInfo = {
  port: 22,
  dataLen: -1,
  rssi: true,
  battery: true,
  tagList: [
    { index: 0, tag: 0x86 },
    { index: 1, tag: 0x02 }
  ]
}

let appInfo = [
  { name: "humidity", field_name: "humidity", unit: "%RH", index: 6, type: "int16be", coefficient: 0.1, decimal: 1 },
  { name: "temperature", field_name: "temperature", unit: "℃", index: 8, type: "int16be", coefficient: 0.1, decimal: 1 },
  { name: "o2", field_name: "o2", unit: "%VOL", index: 10, type: "int16be", coefficient: 0.1, decimal: 1 }
]

let payParser = new PayloadParser({
  device: device,
  msg: msg,
  frameInfo: frameInfo,
  appInfo: appInfo,
})
let tdata = payParser.telemetry();
return {
  telemetry_data: tdata,
  server_attrs: null,
  shared_attrs: null,
};

8. Third-Party Platform Data Subscription

8.1 MQTT Topic

javascript
/v32/{Organization Account}/tkl/up/telemetry/{eui}

8.2 Example Reported Data

The following example has been adjusted based on the device fields.

thingModelId and eui should be replaced with the actual platform device values.
thingModelIdName uses the current thing model name:

json
{
    "eui": "your_device_eui",
    "active_time": "2026-04-02T08:00:00.000Z",
    "thingModelId": "your_thing_model_id",
    "thingModelIdName": "rs_o2ws_n01_22102",
    "telemetry_data": {
        "snr": 13.5,
        "rssi": -51,
        "battery": 3.37,
        "humidity": 35.9,
        "temperature": -7.5,
        "o2": 10.0
    }
}

The sample values above are based on the Modbus response example from the manual: humidity 35.9%RH, temperature -7.5°C, oxygen 10%VOL.

9. RPC

9.1 RPC Names

  • Parameter Configuration RPC: rs_o2ws_n01_set_22102
  • Parameter Read RPC: rs_o2ws_n01_get_22102

9.2 Parameter Definition

The current RPC / parameter model is defined as follows:

ParameterNameField NameUnitTypeDescription
app_70period_upperiod_upsuint32LEUplink period
app_74period_readperiod_readsuint32LECollection period
app_110cov_temperaturecov_temperatureint16BETemperature change threshold
app_112cov_humiditycov_humidity%int16BEHumidity change threshold
app_114cov_o2cov_o2%%int16BEHumidity change threshold
app_150addr_modbusaddr_modbusuint8Modbus address

9.3 RPC Code

javascript
let classMode = (device && device.shared_attrs && device.shared_attrs.class_mode) || "ClassA";
let intervalms = classMode === "ClassA" ? 0 : 2000;
const rpcName="rs_o2ws_n01_set_22102"
let paraDef= {
  app_70:  {name: "period_up", field_name: "period_up", unit: "s",  type: "uint32LE"},
  app_74:  {name: "period_read", field_name: "period_read", unit: "s", type: "uint32LE"},
  app_110: {name: "cov_temperature", field_name: "cov_temperature", unit: "℃", type: "int16BE",coefficient:0.1,decimal:1},
  app_112: {name: "cov_humidity", field_name: "cov_humidity", unit: "%", type: "int16BE",coefficient:0.1,decimal:1},
  app_114: {name: "cov_o2", field_name: "cov_o2", unit: "%", type: "int16BE",coefficient:0.1,decimal:1},
  app_150: {name: "addr_modbus", field_name: "addr_modbus", unit: "", type: "uint8"}
}
let frames=RPCHelper.buildFrame({
  paraDef:paraDef,
  params:params});
let redoBuffer=RPCHelper.redo()
let dnBuffer=Buffer.alloc(frames.writeBuffer.length+frames.readBuffer.length);
frames.writeBuffer.copy(dnBuffer,0)
frames.readBuffer.copy(dnBuffer,frames.writeBuffer.length)
logger.info("set para")
let msgQue=Utils.makeParaSetMSG({
  device:device,
  classMode:classMode,
  rpcName:rpcName,
  params:params,
  paraDownBuffer:dnBuffer,
  extraAppBuffer:redoBuffer
})
if (msgQue.length==0)  return null
return msgQue

10. Template Selection

In the ThinkLink platform, search for the template:

  • RS-O2WS-N01

Or search by business type:

  • 22102