# Checksum UDP ? read value from HVAC controller

**URL:** https://discourse.nodered.org/t/checksum-udp-read-value-from-hvac-controller/35040
**Category:** General
**Created:** [29 October 2020 20:41 UTC](https://discourse.nodered.org/t/checksum-udp-read-value-from-hvac-controller/35040 "2020-10-29T20:41:44Z")
**Posts on this page:** 3
**Page:** 1

<div class="post-metadata">

### Author: ![rogier](https://avatars.discourse-cdn.com/v4/letter/r/ecc23a/32.png) [@rogier](https://discourse.nodered.org/u/rogier)
#### Post date: [29 October 2020 20:41 UTC](https://discourse.nodered.org/t/checksum-udp-read-value-from-hvac-controller/35040/1 "2020-10-29T20:41:44Z")

</div>

Hello,

i have a HVAC controller. want to read values via a UDP port. In the program software of the controller i can monitor a input value and grap with Wireshark the HEX send to the controller. to do this is a lot of work when you want to read a lot of values.. i like to auto create a working string.  
this is the string a grap:  
0251fc209a000002b5095d55  
what i know is the first 2 is the adres of the controller. the point i want to read is 2b509  
here is another HEX grap of the same value:  
0251fc289a000002b509cef8  
is it possible to create an HEX string if you know the adres (02) and the point (2b509)??

![image](https://us1.discourse-cdn.com/flex026/uploads/nodered/original/3X/3/8/38cdffa204a71b043084c86be34499ac7b4c6043.png)

---

<div class="post-metadata">

### Author: ![Steve-Mcl](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/steve-mcl/32/4826_2.png) [@Steve-Mcl](https://discourse.nodered.org/u/Steve-Mcl)
#### Post date: [30 October 2020 23:32 UTC](https://discourse.nodered.org/t/checksum-udp-read-value-from-hvac-controller/35040/2 "2020-10-30T23:32:15Z")

</div>

hi, I doubt `2b509` is the full value as it is an odd number of bytes, starting at offset of 7.5th byte in the data `0251fc289a000002b509cef8`

It is more likely to be the 7th + 8th bytes (16 bit) e.g. 02b5 (as is circled in your picture)

Anyhow, that's the finer details - for starters, I will show you how you can pick & select any value you want using the [buffer parser](https://flows.nodered.org/node/node-red-contrib-buffer-parser) node...

 ![image](https://us1.discourse-cdn.com/flex026/uploads/nodered/original/3X/4/7/47140af9e7c77bff660515d1c142d5ce3ed1395d.png)

Now i realise that ^ value is potentially not what you expect, but without a specification / manual for your HVAC (e.g. byte swapping?, int?, uint? etc) - I randomly chose 16 bit UINT (big endian)

**example flow...**

```auto
[{"id":"58bdc980.c562e8","type":"inject","z":"c9ca6ac7.25b568","name":"0251fc209a000002b5095d55","props":[{"p":"payload"},{"p":"topic","vt":"str"}],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"","payload":"0251fc289a000002b509cef8","payloadType":"str","x":1220,"y":100,"wires":[["7544a660.fcb0e8"]]},{"id":"816105c6.6e6208","type":"inject","z":"c9ca6ac7.25b568","name":"0251fc289a000002b509cef8","props":[{"p":"payload"},{"p":"topic","vt":"str"}],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"","payload":"0251fc289a000002b509cef8","payloadType":"str","x":1220,"y":140,"wires":[["7544a660.fcb0e8"]]},{"id":"7544a660.fcb0e8","type":"buffer-parser","z":"c9ca6ac7.25b568","name":"","data":"payload","dataType":"msg","specification":"spec","specificationType":"ui","items":[{"type":"int8","name":"address","offset":0,"length":1,"offsetbit":0,"scale":1,"mask":""},{"type":"uint16be","name":"data","offset":7,"length":1,"offsetbit":0,"scale":1,"mask":""}],"swap1":"","swap2":"","swap3":"","swap1Type":"swap","swap2Type":"swap","swap3Type":"swap","msgProperty":"payload","msgPropertyType":"str","resultType":"keyvalue","resultTypeType":"output","multipleResult":false,"setTopic":true,"x":1450,"y":120,"wires":[["309f9087.49213"]]},{"id":"309f9087.49213","type":"debug","z":"c9ca6ac7.25b568","name":"","active":true,"tosidebar":true,"console":false,"tostatus":false,"complete":"false","statusVal":"","statusType":"auto","x":1470,"y":160,"wires":[]}]

```

---

<div class="post-metadata">

### Author: ![system](https://us1.discourse-cdn.com/flex026/uploads/nodered/original/1X/d073cd938eafa2e558d7c2cd59003b3ef4963033.png) [@system](https://discourse.nodered.org/u/system)
#### Post date: [29 December 2020 23:32 UTC](https://discourse.nodered.org/t/checksum-udp-read-value-from-hvac-controller/35040/3 "2020-12-29T23:32:16Z")

</div>

This topic was automatically closed 60 days after the last reply. New replies are no longer allowed.
