ROSSMA IIOT-AMS 1-WIRE/
OPERATION MANUAL
1
st
revision 04.09.2019
9
4.
COMMUNICATIONS PROTOCOL
DATA PACKAGE FORMAT
Data package format for ROSSMA IIOT-AMS 1-WIRE:
cc010c0e0c16
- 6 byte
Cc - package type (0xCC - status)
010c - temperature of external temperature sensor (0x010C = 16.75 degrees)
0e0c - battery voltage (0x0E0C = 3596mV = 3.596V)
16 - internal sensor temperature (0x16 = 22 degrees)
Example of external sensor temperature conversion algorithm implemented in python 3.x
(
https://www.python.org/
)
:
Data = 0x010c # data on external temperature sensor
Sign = -1 if ((data > > 11) & 0x01) else 1 # get sign (higher bit of 12)
Value = float ((data & 0x7FF) > > 4) # as whole part of 4 - 10 bits inclusive
Value = (data & 0x0F)/16.0 # least significant 4 bits are fractional, resolution 0.0625
Value * = sign # use sign
Print ('% .4f'% value) # output with 4 decimal places
SWITCHING DEVICE CONTROLLING AND PROGRAMMING
The switching device receives the following control commands on port 1 or port 2::
0x01001E where 0x001E is the new call-out interval in seconds (not saved when power is reset)
0x02001E, where 0x001E - time in seconds when the switching device communicates next time
0xBB - Query the switch version. The answer with version numbers ̆, for example
0xBB010402000301 where will be at once sent to this team:
0xBB - Package type
0x0104 - Switching device type
0x0200 - Software version
0x0301 - Device version
The switching device is supplied with built-in firmware that enables the switching device to
operate with the characteristics specified in this document. The switching device is
programmed using a special input for the programmer.
The switching device is configured using special control commands that are sent to the
switching device in LoRaWAN network.