🌟 Elevate Your Monitoring Game!
The XY-MD02 Temperature Humidity Sensor Module is a high-precision device featuring the SHT40 sensor for accurate temperature and humidity readings. With a robust RS485 interface, it supports communication distances of up to 1000 meters and is compatible with both MODBUS and ordinary protocols. Its compact design allows for easy installation on standard DIN35 rails, and it operates on a versatile DC power supply range of 5-30V.
D**B
Works, but No Documentation
The lack of documentation is a trend for these sort of devices, but fortunately, with a little google-fu, I was able to fill in the blanks.There are only 2 data registers to read, each 2 bytes long. I used libmodbus C library (at libmodbus dot org or github) and the relevant function to use is modbus_read_input_registers(). Note: there is also the python library pymodbus if that's more your speed (for pymodbus, there's an excellent youtube by 'Chipsee' that was published on Aug 31, 2023- he walks through everything in detail). Start at register 1 and read 2 bytes (the library actually reads words, so '2-bytes' is 2 words- each parameter is stored as 16-bit 2's complement). Register 0x0001 is the temperature and 0x0002 is the humidity. The measurement value are stored in 10ths, so 273d is 27.3°C.There are some other registers (keep registers) which are read with modbus_read_registers(), such as 0x0103 and 0x0104 that hold calibration offsets, but according to what little is described in this product listing, it does say 'no calibration'. And 0x0101, 0x0102 for changing the device address and baud rate from the defaults.I included some pix of the innards for those who are interested. In my hunt for details on this device, I found some people complaining that they did not get the sensor chip as advertise. So I was curious and mine has the SH40- which is not the SH20 as stated in the product listing.
J**H
Accurate
Tested out accurate with my other monitors and now I can expand their range
Trustpilot
1 month ago
3 weeks ago