# Protocol Description

Thermolog sends data using the Modbus proto protocol. Below is a description of the protocol.

<table border="1" id="bkmrk-readable-registers-0" style="border-collapse: collapse; width: 100%; height: 362.4px;"><colgroup><col style="width: 10.1305%;"></col><col style="width: 12.395%;"></col><col style="width: 22.0487%;"></col><col style="width: 12.1566%;"></col><col style="width: 13.8252%;"></col><col style="width: 15.2553%;"></col><col style="width: 14.3019%;"></col></colgroup><thead><tr style="height: 29.8px;"><td class="align-center" colspan="7" style="height: 29.8px;">Readable registers 0x04 – 30000</td></tr><tr style="height: 29.8px;"><td style="height: 29.8px;">Address</td><td style="height: 29.8px;">Hex Address</td><td style="height: 29.8px;">Parameter</td><td style="height: 29.8px;">Organization</td><td style="height: 29.8px;">Example Value</td><td style="height: 29.8px;">Accuracy</td><td style="height: 29.8px;">Example</td></tr></thead><tbody><tr style="height: 29.8px;"><td style="height: 29.8px;">30000</td><td style="height: 29.8px;">0x00</td><td style="height: 29.8px;">Temperature</td><td style="height: 29.8px;">int32</td><td style="height: 29.8px;">152</td><td style="height: 29.8px;">%0.1f</td><td style="height: 29.8px;">15.2 °C</td></tr><tr style="height: 29.8px;"><td style="height: 29.8px;">30002</td><td style="height: 29.8px;">0x02</td><td style="height: 29.8px;">Humidity</td><td style="height: 29.8px;">int32</td><td style="height: 29.8px;">457</td><td style="height: 29.8px;">%0.1f</td><td style="height: 29.8px;">45.7 %</td></tr><tr style="height: 46.6px;"><td style="height: 46.6px;">30004</td><td style="height: 46.6px;">0x04</td><td style="height: 46.6px;">Version</td><td style="height: 46.6px;">uint32</td><td style="height: 46.6px;">20201</td><td style="height: 46.6px;">%d.%02d.%02d</td><td style="height: 46.6px;">2.02.01</td></tr><tr style="height: 29.8px;"><td style="height: 29.8px;">30006</td><td style="height: 29.8px;">0x06</td><td style="height: 29.8px;">Serial</td><td style="height: 29.8px;">uint32</td><td style="height: 29.8px;">7EF8E955</td><td style="height: 29.8px;">%08X</td><td style="height: 29.8px;">0x7EF8E955</td></tr><tr style="height: 29.8px;"><td style="height: 29.8px;">30008</td><td style="height: 29.8px;">0x08</td><td style="height: 29.8px;">ID 1</td><td style="height: 29.8px;">uint32</td><td style="height: 29.8px;">05D3FF31</td><td style="height: 29.8px;">%08X</td><td rowspan="3" style="height: 89.4px;">05D3FF313838553443134350  
</td></tr><tr style="height: 29.8px;"><td style="height: 29.8px;">30010</td><td style="height: 29.8px;">0x0A</td><td style="height: 29.8px;">ID 2  
</td><td style="height: 29.8px;">uint32</td><td style="height: 29.8px;">38385534</td><td style="height: 29.8px;">%08X</td></tr><tr style="height: 29.8px;"><td style="height: 29.8px;">30012</td><td style="height: 29.8px;">0x0C</td><td style="height: 29.8px;">ID 3  
</td><td style="height: 29.8px;">uint32</td><td style="height: 29.8px;">43134350</td><td style="height: 29.8px;">%08X</td></tr><tr style="height: 29.8px;"><td style="height: 29.8px;">30014</td><td style="height: 29.8px;">0x0E</td><td style="height: 29.8px;">Position Record Memory</td><td style="height: 29.8px;">uint32</td><td style="height: 29.8px;">34897</td><td style="height: 29.8px;">%d</td><td style="height: 29.8px;">34897</td></tr></tbody></table>

<table border="1" id="bkmrk-readable%2Fwritable-re" style="border-collapse: collapse; width: 100%; height: 344.6px;"><colgroup><col style="width: 9.29623%;"></col><col style="width: 10.1305%;"></col><col style="width: 13.2292%;"></col><col style="width: 7.38931%;"></col><col style="width: 10.0113%;"></col><col style="width: 10.0113%;"></col><col style="width: 10.0113%;"></col><col style="width: 10.0113%;"></col><col style="width: 10.0113%;"></col><col style="width: 10.0113%;"></col></colgroup><thead><tr><th colspan="10">Readable/Writable registers 0x03 – 40000</th></tr><tr><th>Address</th><th>Hex Address</th><th>Parameter</th><th>Organization</th><th>Example Value</th><th>Accuracy</th><th>Example</th><th>Val. Min</th><th>Val.Max</th><th>Default</th></tr></thead><tbody><tr><td>40000</td><td>0x00</td><td>Correct Temperature</td><td>int32</td><td>-12</td><td>%0.1f</td><td>-1.2</td><td>-100</td><td>100</td><td>0</td></tr><tr><td>40002</td><td>0x02</td><td>Correct Humidity</td><td>int32</td><td>25</td><td>%0.1f</td><td>2.5</td><td>-100</td><td>100</td><td>0</td></tr><tr><td>40004</td><td>0x04</td><td>Low Temp. Alarm</td><td>int32</td><td>-25</td><td>%0.1f</td><td>-2.5</td><td>-1200</td><td>1200</td><td>-1.5</td></tr><tr><td>40006</td><td>0x06</td><td>High Temp. Alarm</td><td>int32</td><td>20</td><td>%0.1f</td><td>3.0</td><td>-1200</td><td>1200</td><td>3.6</td></tr><tr><td>40008</td><td>0x08</td><td>State Alarm</td><td>int32</td><td>0</td><td>%d</td><td>0</td><td>0</td><td>2</td><td>0</td></tr><tr><td>40010</td><td>0x0A</td><td>Modbus Address</td><td>uint32</td><td>1</td><td>%d</td><td>1</td><td>1</td><td>247</td><td>1</td></tr><tr><td>40012</td><td>0x0C</td><td>RS485 Baudrate</td><td>uint32</td><td>9600</td><td>%d</td><td>9600</td><td>1200</td><td>921600</td><td>9600</td></tr><tr><td>40014</td><td>0x0E</td><td>RS485 Parity</td><td>uint32</td><td>0</td><td>%d</td><td>0</td><td>0</td><td>2</td><td>0</td></tr><tr><td>40016</td><td>0x10</td><td>RS485 Length Bit</td><td>uint32</td><td>8</td><td>%d</td><td>8</td><td>8</td><td>9</td><td>8</td></tr><tr><td>40018</td><td>0x12</td><td>RS485 Stop bit</td><td>uint32</td><td>1</td><td>%d</td><td>1</td><td>0</td><td>3</td><td>1</td></tr><tr><td>40020</td><td>0x14</td><td>Show Type</td><td>uint32</td><td>1</td><td>%d</td><td>1</td><td>1</td><td>6</td><td>1</td></tr><tr><td>40022</td><td>0x16</td><td>Correct Time</td><td>int32</td><td>-13</td><td>%0.1f</td><td>-13</td><td>-120</td><td>120</td><td>-11</td></tr><tr><td>40024</td><td>0x18</td><td>Light</td><td>uint32</td><td>-</td><td>%d</td><td>-</td><td>0</td><td>15</td><td>0</td></tr><tr><td>40026</td><td>0x1A</td><td>Year</td><td>uint32</td><td>1022</td><td>%d</td><td>1022</td><td>2022</td><td>2099</td><td>-</td></tr><tr><td>40028</td><td>0x1C</td><td>Month</td><td>uint32</td><td>9</td><td>%d</td><td>9</td><td>1</td><td>12</td><td>-</td></tr><tr><td>40030</td><td>0x1E</td><td>Day</td><td>uint32</td><td>3</td><td>%d</td><td>3</td><td>1</td><td>29/30/31</td><td>-</td></tr><tr><td>40032</td><td>0x20</td><td>Hour</td><td>uint32</td><td>15</td><td>%d</td><td>15</td><td>0</td><td>23</td><td>-</td></tr><tr><td>40034</td><td>0x22</td><td>Minute</td><td>uint32</td><td>12</td><td>%d</td><td>12</td><td>0</td><td>59</td><td>-</td></tr><tr><td>40036</td><td>0x24</td><td>Second</td><td>uint32</td><td>33</td><td>%d</td><td>33</td><td>0</td><td>59</td><td>-</td></tr></tbody></table>

<table id="bkmrk-correct-temperature-"><tbody><tr><td colspan="2">Correct temperature - each temperature reading is corrected by this value  
</td></tr><tr><td colspan="2">Correct Humidity - each humidity reading is corrected for this value  
</td></tr><tr><td colspan="2">Low Temp. Alarm - when the temperature is lower than this value, the alarm will be triggered  
</td></tr><tr><td colspan="2">High Temp. Alarm - when the temperature is higher than this value, the alarm will be triggered  
</td></tr><tr><td colspan="2">State Alarm - there are three alarm states  
</td></tr><tr><td>ALARM\_NONE</td><td>0</td></tr><tr><td>ALARMYELLOW</td><td>1</td></tr><tr><td>ALARMRED</td><td>2</td></tr><tr><td colspan="2">Show type - determines how the temperature, humidity and time are shown on the LED display  
</td></tr><tr><td colspan="2">Correct time - after the end of the day, the time was adjusted by this value  
</td></tr><tr><td colspan="2">Light - brightness level of the LED display. For value 0 - the automatic brightness function is enabled.  
</td></tr><tr><td colspan="2"> Identification Device – ID1+ID2+ID3 - unique value for each device  
</td></tr><tr><td colspan="2">Position Record Memory - position in the internal memory organization of the device for archiving the measured temperatures  
</td></tr></tbody></table>

#### Communication over Modbus

<table id="bkmrk-name-function-value-" style="border-color: hsl(0, 0%, 90%); border-style: solid;"><thead><tr><th>Name</th><th>Function</th><th>Value</th></tr></thead><tbody><tr><td>RS485 Baudrate</td><td>From 1200 to 921600</td><td>9600</td></tr><tr><td rowspan="3">RS485 Parity</td><td>None</td><td>0</td></tr><tr><td>Odd</td><td>1</td></tr><tr><td>Even</td><td>2</td></tr><tr><td rowspan="2">RS485 Length Bit</td><td>Normal</td><td>8</td></tr><tr><td>Extend</td><td>9</td></tr><tr><td rowspan="4">RS485 Stop bit</td><td>0.5</td><td>0</td></tr><tr><td>0</td><td>1</td></tr><tr><td>1.5</td><td>2</td></tr><tr><td>2</td><td>3</td></tr></tbody></table>