HDL Smartbus via NodeRed and MQTT

Go in HDL buspro and see on that sensor if broadcast temperature is enabled.

I have checked now and as far as I can see all dlps has broadcast sensor enabled.

@Linax Do you have any ideas here?

I agree with kentwin if broadcast is active it should update. But have seen some sensors not able to send broadcasts before or it might be sending temperature messages with a different code. If you use this flow and open the debug window for 5 minutes you will see if it is broadcasting with a different message code than the normal code 58341.

[{"id":"f374919fab2bfe3c","type":"hdl-raw-in","z":"b999661087cf6e7d","controller":"","name":"","x":210,"y":500,"wires":[["c7b05830e48fe26a"]]},{"id":"c7b05830e48fe26a","type":"switch","z":"b999661087cf6e7d","name":"sender","property":"sender","propertyType":"msg","rules":[{"t":"eq","v":"200.12","vt":"str"}],"checkall":"true","repair":false,"outputs":1,"x":350,"y":500,"wires":[["78b5115e674d04f9"]]},{"id":"78b5115e674d04f9","type":"debug","z":"b999661087cf6e7d","name":"From WL DLP","active":true,"tosidebar":true,"console":false,"tostatus":false,"complete":"true","targetType":"full","statusVal":"","statusType":"auto","x":540,"y":500,"wires":[]}]

If not you will have to read the temperature manually at fixed intervals with the code 58343, this will however generate more messages on the wireless network.
Not tested this but should work:

[{"id":"84d5fedcd8ee3a7e","type":"hdl-raw-out","z":"b999661087cf6e7d","controller":"","name":"","x":550,"y":300,"wires":[]},{"id":"4fda5a0cb16b6340","type":"function","z":"b999661087cf6e7d","name":"Read temp","func":"msg.target = \"200.12\"\nmsg.payload.channel = 1\nmsg.code = 58343;\nreturn msg;\n","outputs":1,"noerr":0,"initialize":"","finalize":"","libs":[],"x":350,"y":300,"wires":[["84d5fedcd8ee3a7e"]]},{"id":"c3c879b14efe65bb","type":"inject","z":"b999661087cf6e7d","name":"","props":[{"p":"payload"},{"p":"topic","vt":"str"}],"repeat":"60","crontab":"","once":true,"onceDelay":"3","topic":"","payload":"Started!","payloadType":"str","x":160,"y":300,"wires":[["4fda5a0cb16b6340"]]}]

Tested now, I can`t see any feedback from the DLP in the debug window.
Maybe I have configured it wrong. What adress are you using on the temperature broadcast setting?

My debug window when i raised the temparature on the thermostat manually from home assistant:

Works now, found out that the address for broadcast temperature should be 255 and 255. Perfect!


image
image
After several days of trying, I finally found out today that the code you provided has an extra d at the beginning. Now it can be used. The first picture is the feedback of nodered button in the process. There is no feedback for 7000 color temperature. The last two pictures are the feedback I got when I controlled it on the HDL APP.

Sorry about the extra “d” not sure how that made it in there.

This was also my error as the “7000” sends code 6627 instead of 6626.

Have what we need to get it working now then but was not able to add color temperature to the MQTT light config as expected. This was something i tought should be easy when looking at the MQTT light documentation.

Have made a new post on the forum and hopefully someone will be able to assist.

Thank you very much. I also follow this post

Ok, have schetched a new setup thats ready for test.

First back up your files as i have not tested since i dont have the right hardware :smiley:

New config for the light:

# - Test light
#1 - Temperature light
- schema: template
  name: "Test Temperature Light"
  state_topic: "hdl/sc/2.11/1"
  command_topic: "hdl/sc/2.11/1/set"
  command_on_template: >
    {"state": "on"
    {%- if brightness is defined -%}
    , "level": {{ brightness }}
    {%- else -%}
    , "level": 255
    {%- endif -%}
    {%- if color_temp is defined -%}
      , "colortemp": {{ color_temp }}
      {%- endif -%}
    }
  command_off_template: '{"state": "off", "level": 0}'
  state_template: "{{ 'on' if value_json.level | int > 0 else 'off' }}"
  brightness_template: "{{ value_json.level }}"
  color_temp_template: "{{ value_json.colortemp }}"
  max_mireds: 7000
  min_mireds: 2100

new nodered flow

Will need new commands.js file with parcer and encoder for the read responce command if you want to read the initial startup status of the color temp. Let me know if you want this.

Let me know if it works ok?

Thank you very much for your help. Now it can work normally, and the effect is very good.

Hi
Problems getting temp sensor value on Floor Heating Module (MFH06.432)
I`m trying to find a way to read temperature, and export the data into a table with timestamp (example excel)?

Edit: The problem Im experiencing with the MFH06.432 (Floor Heat Module) is missing updates from all but one temp-sensor. I only get feedback on temperature from sensor 1. (All sensors are set to broadcast).
I get update from sensor 1 every two minutes, but nothing from sensors 2 to 6.
Strange thing is that when I disable broadcast on sensor 1, then I get update from sensor 2 every two minutes.
Seems like the floor module only broadcast one sensor no matter what I do.
I there any way to “force” a broadcast from the floor heat module?

Hello Linax

I have a question regarding presence detection. We are five persons in our family an we have a unifi network logging detecting when our phones connect to the wifi.
I want the lights to not turn on in the morning when all is away/out of the house.
How can I add that to the flow? I could also need some help to add a flow detecting when the first person arrives, and then fire the lights on flow. Do you have an example for this?

I also get an error message on the HDL ch get - node


image

I don`t understand where it is wrong and what is wrong

Dont have a Floor heating module so not sure if it will respond to a read temperature code.

See this example flow for how to read and save the value for sensor 1.56 ch 4. You will have to change the change and switch node to match your module.

[{"id":"d52b8a2380fd971e","type":"tab","label":"Exel","disabled":false,"info":""},{"id":"9eebef7ae486ae54","type":"file","z":"d52b8a2380fd971e","name":"","filename":"/share/nodered/temperatures/1.56.xls","filenameType":"str","appendNewline":true,"createDir":true,"overwriteFile":"false","encoding":"none","x":970,"y":420,"wires":[[]]},{"id":"541e6d06823d1fed","type":"inject","z":"d52b8a2380fd971e","name":"Read Request","props":[],"repeat":"10","crontab":"","once":true,"onceDelay":"1","topic":"","x":320,"y":300,"wires":[["ae7ffa7bb3a856f0"]]},{"id":"721b0c379d242807","type":"hdl-raw-out","z":"d52b8a2380fd971e","controller":"","name":"","x":750,"y":300,"wires":[]},{"id":"ef48e6e315d2edc9","type":"hdl-raw-in","z":"d52b8a2380fd971e","controller":"","name":"","x":270,"y":420,"wires":[["547a5324e77ef3e3"]]},{"id":"547a5324e77ef3e3","type":"switch","z":"d52b8a2380fd971e","name":"sender","property":"sender","propertyType":"msg","rules":[{"t":"eq","v":"1.56","vt":"str"}],"checkall":"false","repair":false,"outputs":1,"x":390,"y":420,"wires":[["90247025a7065a8e"]]},{"id":"90247025a7065a8e","type":"switch","z":"d52b8a2380fd971e","name":"code","property":"code","propertyType":"msg","rules":[{"t":"eq","v":"0xE3E8","vt":"str"}],"checkall":"false","repair":false,"outputs":1,"x":530,"y":420,"wires":[["aad10a572df83844"]]},{"id":"ae7ffa7bb3a856f0","type":"change","z":"d52b8a2380fd971e","name":"Read Temp 1.56 Ch 4","rules":[{"t":"set","p":"msg.target","pt":"msg","to":"1.56","tot":"str"},{"t":"set","p":"code","pt":"msg","to":"58343","tot":"num"},{"t":"set","p":"payload.channel","pt":"msg","to":"4","tot":"str"}],"action":"","property":"","from":"","to":"","reg":false,"x":520,"y":300,"wires":[["721b0c379d242807"]]},{"id":"aad10a572df83844","type":"function","z":"d52b8a2380fd971e","name":"Add Date and Time","func":"var time = new Date()\nvar sender = msg.sender\nvar channel = msg.payload.channel\nvar temperature = msg.payload.temperature\nmsg.payload = time + \",\" + sender + \",\" + channel + \",\" + temperature;\nreturn msg;","outputs":1,"noerr":0,"initialize":"","finalize":"","libs":[],"x":710,"y":420,"wires":[["9eebef7ae486ae54","673313ce3dfb8dc1"]]},{"id":"e117bcb699382b57","type":"comment","z":"d52b8a2380fd971e","name":"Read temperature once per minute","info":"","x":300,"y":240,"wires":[]},{"id":"77c3ddba0f172387","type":"comment","z":"d52b8a2380fd971e","name":"Save temperature to file when recived","info":"","x":310,"y":380,"wires":[]},{"id":"673313ce3dfb8dc1","type":"debug","z":"d52b8a2380fd971e","name":"debug 1","active":true,"tosidebar":true,"console":false,"tostatus":false,"complete":"false","statusVal":"","statusType":"auto","x":900,"y":520,"wires":[]}]

It can be a bug in the firmware of the module. But it might already be sending all the channels in one message, i do not have the module so can you add the nodes below and change sender to your module and check the debug window if the messsages contains more than one channel?

[{"id":"bea4b925661697a7","type":"hdl-raw-in","z":"d52b8a2380fd971e","controller":"","name":"","x":330,"y":620,"wires":[["29261dc96a37dbba"]]},{"id":"29261dc96a37dbba","type":"switch","z":"d52b8a2380fd971e","name":"sender","property":"sender","propertyType":"msg","rules":[{"t":"eq","v":"1.56","vt":"str"}],"checkall":"false","repair":false,"outputs":1,"x":490,"y":620,"wires":[["cc20381f8cdab476"]]},{"id":"cc20381f8cdab476","type":"debug","z":"d52b8a2380fd971e","name":"Test ","active":true,"tosidebar":true,"console":false,"tostatus":false,"complete":"true","targetType":"full","statusVal":"","statusType":"auto","x":650,"y":620,"wires":[]}]

I have not gotten in to precence detection yet but this is on my todo list. I do not have unifi equipment so do not have the possibility to help mutch on that.
Do you have “input booleans” for each person stating if they are home or away? It should not be to hard if you have this in place.

I dont know what causes this but it did not give an error before the latest update. Does the flow still work?
I would recomend creating an issue on the github page for the node, Or reach out to the creator @bnutt here on the forum for some insight?

I have an event node tracking a group (familie) from home assistant. It shows like this:


It sets the temperature to the heatpump and oven with a call service node, but it doesn’t activate the lights or turns off the lights when all is away. What node do I have to use to activate the light functions?

Would you mind also sharing how to get the event node triggered? As i also look to implement something like this.

From the picture you are 99% there, i am not able to see what you have in the function node but have added example for what works for me, both with change and function node (I like using the change node when posible as this is a bit more “forgiving” on the formating)

[{"id":"640066474e07eaf5","type":"inject","z":"bb746fca8a7efb1f","name":"Light on","props":[{"p":"test","v":"","vt":"date"}],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"","x":170,"y":180,"wires":[["9f2e99b8f07e362c"]]},{"id":"52a9b7d9f6617763","type":"hdl-raw-out","z":"bb746fca8a7efb1f","controller":"","name":"","x":570,"y":180,"wires":[]},{"id":"9f2e99b8f07e362c","type":"change","z":"bb746fca8a7efb1f","name":"1.61.2 - 100%","rules":[{"t":"set","p":"target","pt":"msg","to":"1.61","tot":"str"},{"t":"set","p":"code","pt":"msg","to":"49","tot":"num"},{"t":"set","p":"payload.channel","pt":"msg","to":"2","tot":"num"},{"t":"set","p":"payload.level","pt":"msg","to":"100","tot":"num"}],"action":"","property":"","from":"","to":"","reg":false,"x":340,"y":180,"wires":[["52a9b7d9f6617763"]]},{"id":"0f2d6ad5abd86944","type":"inject","z":"bb746fca8a7efb1f","name":"Light Off","props":[{"p":"test","v":"","vt":"date"}],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"","x":180,"y":300,"wires":[["37ae54f5821f7789"]]},{"id":"37ae54f5821f7789","type":"change","z":"bb746fca8a7efb1f","name":"1.61.2 - 0%","rules":[{"t":"set","p":"target","pt":"msg","to":"1.61","tot":"str"},{"t":"set","p":"code","pt":"msg","to":"49","tot":"num"},{"t":"set","p":"payload.channel","pt":"msg","to":"2","tot":"num"},{"t":"set","p":"payload.level","pt":"msg","to":"0","tot":"num"}],"action":"","property":"","from":"","to":"","reg":false,"x":330,"y":300,"wires":[["52a9b7d9f6617763"]]},{"id":"7e1cf5380891d098","type":"inject","z":"bb746fca8a7efb1f","name":"Light 50%","props":[{"p":"test","v":"","vt":"date"}],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"","x":180,"y":240,"wires":[["1ae8f3ecd1cc1573"]]},{"id":"1ae8f3ecd1cc1573","type":"change","z":"bb746fca8a7efb1f","name":"1.61.2 - 50%","rules":[{"t":"set","p":"target","pt":"msg","to":"1.61","tot":"str"},{"t":"set","p":"code","pt":"msg","to":"49","tot":"num"},{"t":"set","p":"payload.channel","pt":"msg","to":"2","tot":"num"},{"t":"set","p":"payload.level","pt":"msg","to":"50","tot":"num"}],"action":"","property":"","from":"","to":"","reg":false,"x":330,"y":240,"wires":[["52a9b7d9f6617763"]]}]

I got it working with a restart of the system. I made a group in HA where I have placed all persons in the family. Their mobile phones are detected by a device tracker from Unifi when they enters the wlan in the house. When one family member arrives home the state of the group “familie” is changed to “home”, lights turns on and heating temp is increased.

I don`t know how to paste the code here, so I could need a little help

Hello Linax.
Regarding the messages I have been running the debug for quite a while now. The module doesn`t seem to send all channel status in one message sadly. However, I think I discovered something else:
I receive two different “types” of messages from the module.
Type 1 is code: “7261”. This seems to be channel status with various information (see full message below):

As seen above (this is message 7261 for channel 1 & 2. However I receive channel status from all 6ch. It varies from 15 to 30min between every recurring message for all channel (which is OK)…
The message actually contains the data that I am looking for, but it is a bit “hidden”, because as you see above there is a lot of “unnecessary” information. I have pasted a full expanded snag of the message below:
*****(see attachment in reply post as I couldnt paste more than one img pr message)

You may think that the value under “Temperature” - “Now” is the data I am looking for, but this is actually the current SET temperature, and not the current “IS” temperature.
However, under “Watering” - “Time” there is a value which is actually the current IS temperature.
So in conclusion, the data-value is “hidden behind a wrong description” but it is there.

Now for the next message code →

Type 2 is code: 5834* (*is a channel identifier number, so for ch1 the code is 58341):
As you see in the message below this message gives me exactly what I need, only channel and temperature. *****(See next post)

However, my problem is that I receive this message only for channel 1 (which is recurring every 2minutes). AND now and then I get a single update from channel 4 through message “58344”. Do not understand why its not sending on the other channels (as you mention I also suspect a firmware bug causing this error).

To sum up, I guess my best option will be to make use of the “Time” value in the 7261 message code?
If you dont have a better suggestion against the missing “5834*” messages?

Thanks in advance, and sorry about the long report