WB-MSW v.4 TH
Wall-mounted temperature and humidity sensor with RS-485 Modbus RTU
Covered order codes (1)
WB-MSW v.4 TH— Temperature and humidity
WB-MSW v.4 is a wall-mounted RS-485 Modbus RTU sensor family for homes and offices. The WB-MSW v.4 TH order code contains the temperature and relative-humidity channels; the same hardware platform is also available with optional CO₂, VOC, illuminance, motion, sound-level, indicator and infrared-transceiver modules. This manual describes the complete family and clearly identifies functions that depend on the ordered configuration.

Models and enclosure options
CO₂ and VOC sensors are optional and must be selected when ordering. If an optional sensor is not fitted, the corresponding value is reported as zero or unavailable. The standard enclosure is white; black and mixed-colour enclosures are also available.




A black lens reduces the illuminance reading by approximately five to seven times and shortens the useful infrared range by about 2.5 to 3 times, typically to 3–4 m. Indicator LEDs are also much dimmer through the black lens. A flat cover can be ordered where motion detection, infrared control, LEDs and illuminance measurement are not required. The enclosure may be repainted; keep all sensor openings and the lens clear.

Technical specifications
| Measurement | Range | Accuracy or response | Notes |
|---|---|---|---|
| CO₂ | 400–10,000 ppm | ±100 ppm + 5% of reading | Ready in about 3 minutes; automatic baseline calibration every 7 days |
| Temperature | −40 to +80 °C | ±0.3 °C from 0 to +70 °C; ±0.5 °C outside this range | 1 s sensor time constant; enclosure reaches equilibrium in about 4 minutes |
| Relative humidity | 5–95% RH | ±3% RH at ambient temperature ≥0 °C | 1 s sensor time constant |
| Sound level | 39–90 dBA | ±2 dB; 5 s response | A-weighted level |
| Illuminance | 0–145,000 lx | ±10%; up to 1.5 s response | Spectral response approximates the human eye |
| VOC | 0–60,000 ppb ethanol equivalent | ±15% typical, ±40% maximum | Initial readiness depends on the fitted sensor; see the VOC section |
| Motion | Up to 8 m, 120° | Ready about 8 s after power-up | Passive infrared detector |
| IR transceiver | Up to 10 m with clear lens | Ready about 1 s after power-up | Stores up to 80 commands; maximum 1,000 pulse symbols per command |
| Supply voltage | 9–28 V DC |
|---|---|
| Power consumption | 0.5 W typical; up to 1.6 W with CO₂ measurement; up to 4 W during simultaneous CO₂ measurement and IR transmission |
| Interfaces | Zigbee; RS-485 with Modbus RTU |
| Controls and indicators | Red and green user LEDs, status LED and buzzer |
| Start-up time | Approximately 2 s, excluding individual sensor warm-up |
| Operating conditions | −40 to +80 °C, up to 95% RH without condensation. With a CO₂ sensor fitted: −10 to +50 °C |
| Dimensions | 80 × 80 × 23.6 mm with lens; 60 mm mounting-hole spacing; compatible with a 68 mm round European wall box |
| Packaged weight | Approximately 90 g |
| Service life / warranty | 8 years / 2 years |
For screw terminals, use single insulated wire-end ferrules for 0.35–1 mm² conductors or twin ferrules for 0.35–0.5 mm² conductors. The recommended sleeve length is 8 mm and the tightening torque is 0.2 N·m. Size the cable and power supply for voltage drop and peak consumption.
Sensor operation
Temperature and humidity
The SHT40 sensor includes automatic compensation for heat generated inside the enclosure. The standard corrections are 0.30 °C for the main electronics, 0.31 °C for the CO₂ module and 0.14 °C for the VOC module. Raw uncompensated temperature and humidity are available in Modbus registers 284 and 285; a user temperature offset is available in register 245.
At relative humidity above 95%, the anti-condensation heater switches on automatically for one second. It can be controlled manually with coil register 2. A separate cleaning mode heats the sensing element to about 110 °C for one hour and temporarily suspends normal measurements other than raw temperature and humidity. Run cleaning only at an ambient temperature of 15–40 °C, never above 50 °C, and only when necessary because heater life is limited. Start cleaning from the controller interface or with coil register 8; input register 365 reports the remaining time in seconds.
In the controller web interface, TH Sensor Heater Enabled switches on the heater, and TH Sensor Heater Cleaning Mode Enabled activates cleaning mode. Both channels are hidden by default. Enable them in the channel list in the device settings to display their switches on the Devices page.
Motion detection
Current Motion is a short moving average and is suitable for fast polling. Max Motion keeps the maximum value over a configurable period, 10 seconds by default in register 282, and is suitable for slower polling. The sensitivity threshold can be raised to reduce triggers from pets. Firmware 4.37 and later also allows the input RC-filter time constant to be adjusted. Fast Modbus events can be used for immediate wired notifications.

Indicators and buzzer
The red and green user LEDs can be flashed under automation control; the buzzer is available in every configuration. User LEDs require the lens board used by the illuminance and IR options. A separate green status LED indicates data exchange and can be disabled.
To disable the green status indicator through Modbus, write 1 to holding register 130; write 0 to enable it (the default). For a device at address 202 on /dev/ttyRS485-1 using 38400 bit/s, 8N2, stop the driver with systemctl stop wb-mqtt-serial, run the required command, then restart it with systemctl start wb-mqtt-serial:
modbus_client -mrtu -b38400 -pnone -s2 /dev/ttyRS485-1 -a202 -t6 -r130 1 # disable
modbus_client -mrtu -b38400 -pnone -s2 /dev/ttyRS485-1 -a202 -t6 -r130 0 # enable
Infrared transceiver
The receiver and eight infrared emitters are located behind the lens. Learn a remote-control command once, store it in a numbered cell, then replay it from Zigbee or Modbus. A command may contain up to 1,000 high/low pulse pairs whose durations are represented in microseconds. The transmitter is intentionally wide-angle and can control equipment visible from the sensor. For individual control of several nearby air conditioners, use dedicated directional IR transmitters.
Illuminance and sound
The illuminance channel uses an optical filter shaped to the sensitivity of the human eye and responds within about 1.5 seconds. The sound channel reports an A-weighted sound-pressure level in dBA and provides a configurable noise-detected state.
VOC and indoor-air quality
Units made before August 2023 can contain an SGPC3 VOC module. It takes about six minutes to become ready, returns 0xFFFF during warm-up and adjusts its baseline every 12 hours. Later units use an ENS160 VOC module and firmware 1.5 or later. It reports VOC and an air-quality index immediately, but its initial self-calibration takes about 24 hours. Keep the sensor powered continuously during calibration.
| AQI | VOC, ppb | Assessment | Recommended action |
|---|---|---|---|
| 1 | 0–65 | Excellent | Target condition; unlimited exposure |
| 2 | 65–220 | Good | Ventilation recommended |
| 3 | 220–660 | Acceptable | Ventilate and identify the source |
| 4 | 660–2,200 | Poor | Ventilate intensively and remove the source |
| 5 | 2,200–5,500 | Hazardous | Intensive ventilation; limit exposure to hours |
Carbon dioxide
The optional CO₂ module uses the non-dispersive infrared (NDIR) principle.

Automatic baseline calibration treats the lowest reading observed over seven days as approximately 400 ppm. For reliable calibration, the room must be unoccupied or well ventilated for part of each week. If this cannot be guaranteed, calibrate the module manually in fresh air using the wired interface.
| CO₂ concentration | Typical interpretation |
|---|---|
| 400–450 ppm | Normal outdoor air |
| Below 600 ppm | Good indoor air |
| 600–1,000 ppm | Stale-air complaints may begin |
| 1,000–2,500 ppm | Drowsiness and reduced concentration are possible |
| 2,500–5,000 ppm | Adverse effects become more likely |
| 5,000 ppm | Common maximum eight-hour occupational exposure level |
Installation and wiring
Connect 9–28 V DC to V+ and GND. The green status LED flashes during normal communication unless it has been disabled. Long cables require adequate conductor size to keep the voltage at the sensor within specification during CO₂ measurement and IR transmission.
When calculating voltage drop on a long supply cable, use the peak consumption of up to 4 W per sensor, including simultaneous CO₂ measurement and IR transmission.

Mount the sensor on an interior wall, typically 1–1.6 m above the floor, away from sunlight, radiators, doors, drafts and local heat sources. Exterior walls can bias temperature readings. A 68 mm round European wall box can be used; the wall box is only for the cable and does not provide spare space behind the electronics. For surface mounting, use screws with heads approximately 7 mm in diameter and the 60 mm hole spacing.

To open the enclosure, hold it with both hands, press the two halves gently and lift the front cover.
Controller setup and configuration
On a Wiren Board controller, open the serial-device configuration and either scan the RS-485 bus or add the WB-MSW v.4 template manually. The device then appears on the Devices page, where measured values, optional outputs and configuration parameters are available. Disable unused channels in the wb-mqtt-serial driver settings so the interface matches the installed sensor options.
- Connect the powered sensor to an RS-485 port and verify the A/B polarity and common ground.
- Add the WB-MSW v.4 template automatically by bus scan or manually in the serial-device settings.
- Enter the factory Modbus address from the enclosure label and keep the default serial settings unless the bus uses another supported speed.
- Save the configuration, open the Devices page and confirm that temperature and humidity update without communication errors.
Without a Wiren Board controller, configure the module with the Wiren Board web configurator or any Modbus RTU master through a USB-to-RS-485 adapter. Update the device firmware before troubleshooting a parameter that is missing from an older template.
Modbus RTU operation
WB-MSW v.4 supports the standard Modbus RTU functions for reading and writing one or multiple registers. The default serial parameters are shown below. Current firmware accepts either one or two stop bits even when the master setting does not exactly match. For lower latency on a busy bus, a rate of 115,200 bit/s is recommended after every device on the segment has been configured for it.
| Parameter | Default |
|---|---|
| Baud rate | 9,600 bit/s |
| Data bits | 8 |
| Parity | None |
| Stop bits | 2 |
Modbus address
Each device uses a unique address from 1 to 247. The factory address is printed on the enclosure. Address 0 is reserved for broadcast requests. Change the address only while the target device can be identified unambiguously, then update the master configuration to the new value.

Fast Modbus extension
Fast Modbus adds rapid discovery and event polling while remaining compatible with ordinary Modbus masters. Event-capable registers are marked with a lightning symbol in the register map. The feature is enabled by a master command; no special wiring is required.
Essential register map
The table lists the registers most often used for commissioning. Unsupported optional channels return their documented error value. Signed values must be decoded as signed integers before applying scale.
| Address | Type | Purpose | Format / values |
|---|---|---|---|
| 0 | Input | Temperature | ×0.01 °C |
| 1 | Input | Relative humidity | ×0.01 %RH |
| 2 | Coil | Temperature/humidity heater | 0 off; 1 on |
| 8 | Coil | One-hour TH cleaning mode | 0 off; 1 start |
| 9–10 | Input | Illuminance | 32-bit value, ×0.01 lx |
| 11 | Input | VOC concentration | ppb; 0xFFFF means unavailable |
| 83 | Input | Installed CO₂ sensor type | Model code |
| 88 | Holding | Manual CO₂ reference value | ppm |
| 95 | Holding | CO₂ automatic baseline calibration | 0 disabled; 1 enabled |
| 245 | Holding | User temperature compensation | Signed ×0.01 °C |
| 280 | Input | Max Motion | Event-capable optional channel |
| 283 | Input | Current Motion | Event-capable optional channel |
| 284 | Input | Raw temperature before compensation | Signed ×0.01 °C |
| 285 | Input | Raw relative humidity before compensation | Signed ×0.01 %RH |
| 365 | Input | TH cleaning time remaining | Seconds |
| 955 | Holding | Communication-loss timeout | Seconds; default 10 |
| 956 | Holding | Fail-safe action | 0 none; 1 replay IR command |
| 957 | Holding | Fail-safe IR command number | 1–80 |
| 130 | Holding | Status indicator | 1 disables; 0 enables (default) |
Infrared command storage
Configurations fitted with the infrared option provide 80 persistent command cells. Learn a remote control command once, store it in a numbered cell, and replay it from the controller or by writing the documented IR registers. Use holding registers 5500, 5501 and 5502 for reliable integration with third-party Modbus masters. The WB-MSW v.4 TH order code does not include the infrared module.
{"learn_start":0}
{"learn_stop":0}
{"play_store":0}
{"clear_store":0}
Replace 0 with the required cell number. For temporary RAM learning and playback use:
{"learn_ram_start":"ON"}
{"learn_ram_stop":"ON"}
{"play_ram":"ON"}

Fail-safe action
A fail-safe action can replay one stored IR command if controller communication is lost. The timer restarts after every successfully processed Modbus packet; the default timeout is 10 seconds. Normal operation resumes automatically when communication returns. By default, no IR command is assigned. Configure the timeout, playback action and stored command number before enabling this function.

Firmware update and reset
The main controller firmware is updated over RS-485. On a Wiren Board controller, use the device firmware updater; on another system, use the supported Modbus firmware-update service. Stored configuration is preserved during a normal update. Do not disconnect power or the RS-485 line while an update is in progress. The optional NS8 CO₂ module is updated automatically together with the WB-MSW v.4 firmware.
A factory reset restores device settings but retains the connection settings required to reach the module. After a reset or address change, verify the master configuration before returning the sensor to service.
Dimensions and internal layout
Illustration gallery
















