How do I encode a Configuration Downlink for an Air Temperature and Humidity Sensor?

            A downlink message is one that is sent to the sensor from the cloud and is used to configure the sensor itself.
            Messages cannot be initiated from the cloud since the sensor is typically sleeping and the radio is turned off, so the sensor itself must initiate a downlink message.
            The supervisory, reset, and tamper-open (not tamper close) messages all request a downlink message as a response, and the response must be received within 30 seconds of the request.

            This article describes how to create a downlink configuration specific to Air Temperature and Humidity Sensors.
            Follow this link for help with creating General Configuration Downlink Messages.

            Air Temperature and Humidity Configuration Message: 0x0D 
                  Byte            Description
                  0   Reporting Mode (0x00 for Threshold, or 0x01 for Report on Change)
                  1-6   Defined by Mode (See Mode sections)

            Threshold Mode Configuration: 0x0D00...
                  Byte            Description
                  1   Periodic reporting in 1 minute or 1 hour intervals. Default is 0 (disabled)
                  2   Restoral margin (bits 7:4 for humidity, bits 3:0 for temperature). Default 5 degrees C for temperature and 5% for humidity.
                  3   Lower temperature threshold. Default 10 degrees C.
                  4   Upper temperature threshold. Default 40 degrees C.
                  5   Lower humidity threshold. Default 40% relative humidity.
                  6   Upper humidity threshold. Default 60% relative humidity.

            Report on Change Configuration: 0x0D01...
                  Byte            Description
                  1                   Periodic reporting in 1 minute or 1 hour intervals. Default is 0 (disabled)
                  2                  Not used
                  3                  Temperature increase (increments of 1 degree C)
                  4                  Temperature decrease (increments of 1 degree C)
                  5                  Humidity increase (increments of 1%)
                  6                  Humidity decrease (increments of 1%)

            Periodic Reporting Configuration: 
                  Bit 7            Bits 6:0
                  0                  Period defined in hours (1-127 hours)
                  1           Period defined in minutes (1-127 minutes)
                  Note that prior to firmware version 1.3, only hourly reporting is available. 
                  The firmware version can be found in the reset message and is logged on the Radio Bridge console.

            Threshold Mode Configuration Example:

                  0D 00 18 A5 8A 1E 0F 3C

                  0D                  Downlink Message Type (Air Temp & Humidity = 0x0D)
                  00                  Reporting Mode (Threshold = 0x00)
                  18                   Periodic Reporting (24 hours = 0x18)
                  A5                  Restoral Margin (10% Humidity, 5 degrees C Temperature)
                  8A                  Lower Temperature Threshold ( -10 degrees C = 0x8A)
                  1E                   Upper Temperature Threshold ( 30 degrees C = 0x1E)
                  0F                  Lower Humidity Threshold ( 15% = 0x0F)
                  3C                  Upper Humidity Threshold ( 60% = 0x3C)

            Report on Change Configuration Example:

                  0D 01 8F 00 0A 0F 05 14

                  0D                  Downlink Message Type (Air Temp & Humidity = 0x0D)
                  01                   Reporting Mode (Report On Change = 0x01)
                  8F                  Periodic Reporting (15 minutes = 0x8F)
                  00                  Not Used
                  0A                  Temperature Increase (10 degrees C = 0x0A)
                  0F                  Temperature Decrease (15 degrees C = 0x0F)
                  05                  Humidity Increase (5% = 0x05)
                  14                   Humidity Decrease (20% = 0x14)

                  If the configuration is successful the sensor will respond with a Downlink Acknowledge message:

                  1 0 FF 02

                  1                    Protocol Version (currently always 0x1)
                  0                   Packet Counter, increments by 1 each message and wraps from 0xF to 0x0
                  FF                 Message Type (Downlink ACK = 0xFF)
                  02                 Downlink Message Valid (Invalid/Undefined = 0x01, Valid = 0x02)

            See Also:

            Updated: 28 Jan 2019 09:19 AM
            Helpful?  
            Help us to make this article better
            0 0