HDL Smartbus via NodeRed and MQTT

Have updated my first post to include latest NodeRed Flow. The new version supports the new sensors mentioned by @AKRANO above.

Also supported is the Heating module MFH06. For this to work correctly on the heating module you need to change the file commands.js due to an indexing fault new file can be found here.

Steps to install the new file:

  1. First you need to find your commands.js file. (For me it is in \IP.adress\config\node-red\node_modules\smart-bus-mrgadget\lib)
  2. Replace the file with the new file
  3. In HA go to Configuration ā†’ Add-ons, backups & Supervisor ā†’ Node-RED and press RESTART
  4. When nodered is restarted it should be decoding the heatmodule messages correct.

Special thanks to @Tarvo for helping making the new commands.js file.

@Lexsus2020 You will also have to change the file for the flow to work.

2 Likes

Great job to all involved in bringing HDL BusPro integration to Home AssistantšŸ‘

Have anyone tried this method for controlling DALI lighting through the HDL gateway (HDL-MC64-DALI.431)?

Maybe there is a solution for the 2ch curtain controllers as well? (HDL-MW02.431)

Thanks :smiley:

Welcome to the forum @Cregeland.

I dont have a DALI module but should already work as described in the first post under lights as the hdl messages are the same for dimmers, DMX and DALI. Did you try this?

Not implemented atm. as i use normal relay module for my blinds but should not be to hard to implement as the codes are already supported in nodered.

Can put it together for you if you send me nodered debug screenshots of the codes: 58336, 58337, 58338 and 58339. Would also be interesting to get 58340 but not required. (If you do not know how to get the screenshots send me the subnet and device id for the curtain controller and i can make a flow for you)

Thank you @Linax!

IĀ“ll try controlling DALI once I get my DALI gateway up and running.

IĀ“m quite new to NodeRed so I would really appreciate the flow if itĀ“s not too much of an inconvenience. Subnet 1 device 5.

Regarding control of the AC and Floorheating Module. I get an error saying some of the options are deprecated. See attached screenshot. I have replaced the lines in commands.js with the new version as mentioned in your post on March 10. Still I get the error - and I am not able to read the status or command the AC/Floorheating module. Any idea what could be causing this?

Onge again thank you for your help, time and effort :smiley:

No problem. Import this flow and add your HDL gateway to the HDL in and out node. You should get the messages to and from the curtain controler in the debug window when it is triggered from other items like a DLP or even the buspro programing software.

[{"id":"3a3d48083fb04932","type":"tab","label":"Cregeland curtain debug","disabled":false,"info":"","env":[]},{"id":"c885a1ed834c58fe","type":"hdl-raw-in","z":"3a3d48083fb04932","controller":"","name":"","x":90,"y":160,"wires":[["b00ce7a280aae8b7","ded39737b0165cc1"]]},{"id":"b00ce7a280aae8b7","type":"switch","z":"3a3d48083fb04932","name":"sender","property":"sender","propertyType":"msg","rules":[{"t":"eq","v":"1.5","vt":"str"}],"checkall":"true","repair":false,"outputs":1,"x":350,"y":260,"wires":[["8a7a1b9ec676db0b"]]},{"id":"77175d9bb6c8da23","type":"switch","z":"3a3d48083fb04932","name":"code","property":"code","propertyType":"msg","rules":[{"t":"eq","v":"58336","vt":"str"},{"t":"eq","v":"58338","vt":"str"}],"checkall":"true","repair":false,"outputs":2,"x":470,"y":100,"wires":[["ac2b8e08472a1fe3"],["e3ec9cf255dc670d"]]},{"id":"ac2b8e08472a1fe3","type":"debug","z":"3a3d48083fb04932","name":"58336 Curtain Switch Control","active":true,"tosidebar":true,"console":false,"tostatus":false,"complete":"payload","targetType":"msg","statusVal":"","statusType":"auto","x":680,"y":80,"wires":[]},{"id":"65074da8a605c63d","type":"debug","z":"3a3d48083fb04932","name":"58337 Response Curtain Switch Control","active":true,"tosidebar":true,"console":false,"tostatus":false,"complete":"payload","targetType":"msg","statusVal":"","statusType":"auto","x":720,"y":220,"wires":[]},{"id":"8a7a1b9ec676db0b","type":"switch","z":"3a3d48083fb04932","name":"code","property":"code","propertyType":"msg","rules":[{"t":"eq","v":"58337","vt":"str"},{"t":"eq","v":"58339","vt":"str"},{"t":"eq","v":"58340","vt":"str"}],"checkall":"true","repair":false,"outputs":3,"x":470,"y":260,"wires":[["65074da8a605c63d"],["29213d5322990792"],["7b5d4d97185b40e8"]]},{"id":"ded39737b0165cc1","type":"switch","z":"3a3d48083fb04932","name":"target","property":"target","propertyType":"msg","rules":[{"t":"eq","v":"1.5","vt":"str"}],"checkall":"true","repair":false,"outputs":1,"x":350,"y":100,"wires":[["77175d9bb6c8da23"]]},{"id":"e9c6fc35735d03bf","type":"comment","z":"3a3d48083fb04932","name":"Command to curtain module","info":"","x":380,"y":60,"wires":[]},{"id":"9dcb0699ae35bf80","type":"comment","z":"3a3d48083fb04932","name":"Answers from Curtain module","info":"","x":380,"y":220,"wires":[]},{"id":"e3ec9cf255dc670d","type":"debug","z":"3a3d48083fb04932","name":"58338 Read Status of Curtain Switch","active":true,"tosidebar":true,"console":false,"tostatus":false,"complete":"payload","targetType":"msg","statusVal":"","statusType":"auto","x":710,"y":120,"wires":[]},{"id":"29213d5322990792","type":"debug","z":"3a3d48083fb04932","name":" 58339 Response Read Status of Curtain Switch","active":true,"tosidebar":true,"console":false,"tostatus":false,"complete":"payload","targetType":"msg","statusVal":"","statusType":"auto","x":740,"y":260,"wires":[]},{"id":"7b5d4d97185b40e8","type":"debug","z":"3a3d48083fb04932","name":"58340 Broadcast Status of Status of Curtain Switches","active":true,"tosidebar":true,"console":false,"tostatus":false,"complete":"payload","targetType":"msg","statusVal":"","statusType":"auto","x":760,"y":300,"wires":[]},{"id":"3765e77989f3ca13","type":"comment","z":"3a3d48083fb04932","name":"Test commands","info":"","x":100,"y":400,"wires":[]},{"id":"6461461c9b88d084","type":"inject","z":"3a3d48083fb04932","name":"Read status curtain 1","props":[{"p":"code","v":"58338","vt":"str"},{"p":"target","v":"1.5","vt":"str"},{"p":"curtain","v":"1","vt":"str"}],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"","x":180,"y":460,"wires":[["7baef38eb9b12065"]]},{"id":"7baef38eb9b12065","type":"hdl-raw-out","z":"3a3d48083fb04932","controller":"","name":"","x":470,"y":660,"wires":[]},{"id":"a8a0ea807540fff7","type":"inject","z":"3a3d48083fb04932","name":"Read status curtain 2","props":[{"p":"code","v":"58338","vt":"str"},{"p":"target","v":"1.5","vt":"str"},{"p":"payload.curtain","v":"2","vt":"str"}],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"","x":180,"y":720,"wires":[["7baef38eb9b12065"]]},{"id":"d0db9cf3c0af3c1d","type":"inject","z":"3a3d48083fb04932","name":"Close curtain 1","props":[{"p":"code","v":"58338","vt":"str"},{"p":"target","v":"1.5","vt":"str"},{"p":"curtain","v":"1","vt":"str"},{"p":"status","v":"2","vt":"str"}],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"","x":160,"y":520,"wires":[["7baef38eb9b12065"]]},{"id":"3085b69f73a2e0f6","type":"inject","z":"3a3d48083fb04932","name":"Open curtain 1","props":[{"p":"code","v":"58338","vt":"str"},{"p":"target","v":"1.5","vt":"str"},{"p":"curtain","v":"1","vt":"str"},{"p":"status","v":"1","vt":"str"}],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"","x":160,"y":580,"wires":[["7baef38eb9b12065"]]},{"id":"5483fd27d8442050","type":"inject","z":"3a3d48083fb04932","name":"Open curtain 1","props":[{"p":"code","v":"58338","vt":"str"},{"p":"target","v":"1.5","vt":"str"},{"p":"curtain","v":"1","vt":"str"},{"p":"status","v":"0","vt":"str"}],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"","x":160,"y":640,"wires":[["7baef38eb9b12065"]]},{"id":"de1ad50c1a599ddb","type":"inject","z":"3a3d48083fb04932","name":"Close curtain 2","props":[{"p":"code","v":"58338","vt":"str"},{"p":"target","v":"1.5","vt":"str"},{"p":"payload.curtain","v":"2","vt":"str"},{"p":"payload.status","v":"2","vt":"str"}],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"","x":160,"y":780,"wires":[["7baef38eb9b12065"]]},{"id":"7a99b3ba002e342a","type":"inject","z":"3a3d48083fb04932","name":"Open curtain 2","props":[{"p":"code","v":"58338","vt":"str"},{"p":"target","v":"1.5","vt":"str"},{"p":"payload.curtain","v":"2","vt":"str"},{"p":"payload.status","v":"1","vt":"str"}],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"","x":160,"y":840,"wires":[["7baef38eb9b12065"]]},{"id":"be412e235c4ffe3c","type":"inject","z":"3a3d48083fb04932","name":"Open curtain 2","props":[{"p":"code","v":"58338","vt":"str"},{"p":"target","v":"1.5","vt":"str"},{"p":"payload.curtain","v":"2","vt":"str"},{"p":"payload.status","v":"0","vt":"str"}],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"","x":160,"y":900,"wires":[["7baef38eb9b12065"]]},{"id":"8c657ab601401d4d","type":"comment","z":"3a3d48083fb04932","name":"Debug","info":"","x":70,"y":20,"wires":[]}]

Copy or take screenshots of the results and i will implement it.

Also if you get the code 58340 what is the time interval on that message?

Does any of the test commands work either for curtain 1 or 2?

I was running on 2021.12.5 version of HA with everything working. Have updated to latest version now and get the same error as you.

Apears there have been some breaking changes in recent updates, hate when this happens but must be for a good reason. Atleast the old ā€œholdā€ commands never made any sense to me.

This will recuire a change in the HA config file. Appears to be working with the following changes:

ā€œsend_if_off: trueā€ should be removed, same with ā€œsend_if_off: falseā€ on AC.
ā€œhold_modesā€ needs to be changed with ā€œpreset_modesā€
ā€œholdā€ needs to be changed with ā€œpreset_modeā€.

If you have a lot of zones in the config file already i recomend the ā€œctrl + hā€ Find and replace tool in the editor

To clarify new example config should be like this:

# Floorheat Thermostat
climate:
  - platform: mqtt
    name: Floorheat
    modes:
      - "off"
      - "heat"
    mode_state_topic: "hdl/fh/1.106/01"
    mode_state_template: "{{value_json.status}}"
    mode_command_topic: "hdl/fh/1.106/mode/set"
    #current_temperature_topic: "hdl/fh/1.106/01"
    #current_temperature_template: "{{value_json.temperature.current}}"
    current_temperature_topic: "hdl/temp/1.106/1"
    temperature_state_topic: "hdl/fh/1.106/01"
    temperature_state_template: "{{value_json.temperature.now}}"
    temperature_command_topic: "hdl/fh/1.106/temperature/set"
    preset_modes:
      - "Normal"
      - "Day"
      - "Night"
      - "Away"
      - "Timer"
    preset_mode_state_topic: "hdl/fh/1.106/01"
    preset_mode_value_template: "{{value_json.textmode}}"
    preset_mode_command_topic: "hdl/fh/1.106/textmode/set"
    min_temp: 5
    max_temp: 35
    precision: 0.1

Let me know if this fixes the issues with the floorheat and AC and i will update my first post.

Thanks again @Linax :smiley:

When updating the configuration.yaml file according to your new code there seem to be some issues with a couple of lines. HereĀ“s a screenshot:

I got errors in the editor also, this is i expect due to the code changes are new and the editor has not yet been updated to reflect the new changes.

I can se on your screenshot that the ā€œpreset_mode_modes:ā€ should be ā€œpreset_modes:ā€, this is my error and i fixed it on the post above now.

If you save and go to ā€œserver controlsā€ and press ā€œCheck configurationā€ you should get valid config.

If it is valid press the ā€œManually Configured MQTT Entitiesā€ button on the same page and it should be OK.

PS: The ā€œ#current_temperature_topic:ā€ and ā€œ#current_temperature_template:ā€ is not needed to edit as it is ignored due to the ā€œ#ā€

Now you are pointing to a (temp)temperature message, i am not 100% sure this works on the FH module. I have it working like that on DLP`s and SB-MTS04.20 there i get temp updates every 60s.

If you want to use the temperature from the FH module multi broadcast message instead you can remove the 2x ā€œ#ā€ and put one on the active topic.

Thank you once again for quick reply.

Unfortunately I get an error on the config. Looks like the error is related to Ā«preset_mode_state_templateĀ». That variable does not seem to be listed on the MQTT climate page (MQTT HVAC - Home Assistant) - but maybe IĀ“m looking at the wrong list.

HereĀ“s a screenshot of the debug window. The 58340 shows up 10 seconds after pressing the forward or back button for curtain 1. This is probably a result of the duration for open/close set in HDL BusPro Setup Tool (screenshot below). To verify I set the duration for curtain 2 to 15 sec. Code 58338 and 58339 was not observed. I donĀ“t think the 2ch curtain module reports curtain position - maybe only available on the HDL-MWM65B.20 where you can command the curtains to a predermined position (0-100%).

Unfortunately none of test commands worked.

Curtain/channel 1:

Curtain/channel 2:

BusPro Setup Tool:

Sorry forgot that it was also changed. ā€œpreset_mode_state_template:ā€ should be ā€œpreset_mode_value_templateā€. Updated example again, hopefully for the last time now.

You found the correct list :smiley:

Wish i had all the device myself as it would be quicker to implement.

Updated the flow with complete debug messages (old was only payload) and new commands with curtains and status formated as number and not string. Can you do new test with the updated flow and let me know witch commands work.

[{"id":"3a3d48083fb04932","type":"tab","label":"Cregeland curtain debug","disabled":false,"info":"","env":[]},{"id":"c885a1ed834c58fe","type":"hdl-raw-in","z":"3a3d48083fb04932","controller":"","name":"","x":90,"y":160,"wires":[["b00ce7a280aae8b7","ded39737b0165cc1"]]},{"id":"b00ce7a280aae8b7","type":"switch","z":"3a3d48083fb04932","name":"sender","property":"sender","propertyType":"msg","rules":[{"t":"eq","v":"1.5","vt":"str"}],"checkall":"true","repair":false,"outputs":1,"x":350,"y":260,"wires":[["8a7a1b9ec676db0b"]]},{"id":"77175d9bb6c8da23","type":"switch","z":"3a3d48083fb04932","name":"code","property":"code","propertyType":"msg","rules":[{"t":"eq","v":"58336","vt":"str"},{"t":"eq","v":"58338","vt":"str"}],"checkall":"true","repair":false,"outputs":2,"x":470,"y":100,"wires":[["ac2b8e08472a1fe3"],["e3ec9cf255dc670d"]]},{"id":"ac2b8e08472a1fe3","type":"debug","z":"3a3d48083fb04932","name":"58336 Curtain Switch Control","active":true,"tosidebar":true,"console":false,"tostatus":false,"complete":"true","targetType":"full","statusVal":"","statusType":"auto","x":680,"y":80,"wires":[]},{"id":"65074da8a605c63d","type":"debug","z":"3a3d48083fb04932","name":"58337 Response Curtain Switch Control","active":true,"tosidebar":true,"console":false,"tostatus":false,"complete":"true","targetType":"full","statusVal":"","statusType":"auto","x":720,"y":220,"wires":[]},{"id":"8a7a1b9ec676db0b","type":"switch","z":"3a3d48083fb04932","name":"code","property":"code","propertyType":"msg","rules":[{"t":"eq","v":"58337","vt":"str"},{"t":"eq","v":"58339","vt":"str"},{"t":"eq","v":"58340","vt":"str"}],"checkall":"true","repair":false,"outputs":3,"x":470,"y":260,"wires":[["65074da8a605c63d"],["29213d5322990792"],["7b5d4d97185b40e8"]]},{"id":"ded39737b0165cc1","type":"switch","z":"3a3d48083fb04932","name":"target","property":"target","propertyType":"msg","rules":[{"t":"eq","v":"1.5","vt":"str"}],"checkall":"true","repair":false,"outputs":1,"x":350,"y":100,"wires":[["77175d9bb6c8da23"]]},{"id":"e9c6fc35735d03bf","type":"comment","z":"3a3d48083fb04932","name":"Command to curtain module","info":"","x":380,"y":60,"wires":[]},{"id":"9dcb0699ae35bf80","type":"comment","z":"3a3d48083fb04932","name":"Answers from Curtain module","info":"","x":380,"y":220,"wires":[]},{"id":"e3ec9cf255dc670d","type":"debug","z":"3a3d48083fb04932","name":"58338 Read Status of Curtain Switch","active":true,"tosidebar":true,"console":false,"tostatus":false,"complete":"true","targetType":"full","statusVal":"","statusType":"auto","x":710,"y":120,"wires":[]},{"id":"29213d5322990792","type":"debug","z":"3a3d48083fb04932","name":" 58339 Response Read Status of Curtain Switch","active":true,"tosidebar":true,"console":false,"tostatus":false,"complete":"true","targetType":"full","statusVal":"","statusType":"auto","x":740,"y":260,"wires":[]},{"id":"7b5d4d97185b40e8","type":"debug","z":"3a3d48083fb04932","name":"58340 Broadcast Status of Status of Curtain Switches","active":true,"tosidebar":true,"console":false,"tostatus":false,"complete":"true","targetType":"full","statusVal":"","statusType":"auto","x":760,"y":300,"wires":[]},{"id":"3765e77989f3ca13","type":"comment","z":"3a3d48083fb04932","name":"Test commands","info":"","x":100,"y":400,"wires":[]},{"id":"6461461c9b88d084","type":"inject","z":"3a3d48083fb04932","name":"Read status curtain 1","props":[{"p":"code","v":"58338","vt":"str"},{"p":"target","v":"1.5","vt":"str"},{"p":"payload.curtain","v":"1","vt":"num"}],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"","x":180,"y":460,"wires":[["7baef38eb9b12065"]]},{"id":"7baef38eb9b12065","type":"hdl-raw-out","z":"3a3d48083fb04932","controller":"","name":"","x":470,"y":660,"wires":[]},{"id":"a8a0ea807540fff7","type":"inject","z":"3a3d48083fb04932","name":"Read status curtain 2","props":[{"p":"code","v":"58338","vt":"str"},{"p":"target","v":"1.5","vt":"str"},{"p":"curtain","v":"2","vt":"num"}],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"","x":180,"y":720,"wires":[["7baef38eb9b12065"]]},{"id":"d0db9cf3c0af3c1d","type":"inject","z":"3a3d48083fb04932","name":"Close curtain 1","props":[{"p":"code","v":"58338","vt":"str"},{"p":"target","v":"1.5","vt":"str"},{"p":"payload.curtain","v":"1","vt":"num"},{"p":"payload.status","v":"2","vt":"num"}],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"","x":160,"y":520,"wires":[["7baef38eb9b12065"]]},{"id":"3085b69f73a2e0f6","type":"inject","z":"3a3d48083fb04932","name":"Open curtain 1","props":[{"p":"code","v":"58338","vt":"str"},{"p":"target","v":"1.5","vt":"str"},{"p":"payload.curtain","v":"1","vt":"num"},{"p":"payload.status","v":"1","vt":"num"}],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"","x":160,"y":580,"wires":[["7baef38eb9b12065"]]},{"id":"5483fd27d8442050","type":"inject","z":"3a3d48083fb04932","name":"Open curtain 1","props":[{"p":"code","v":"58338","vt":"str"},{"p":"target","v":"1.5","vt":"str"},{"p":"payload.curtain","v":"1","vt":"num"},{"p":"payload.status","v":"0","vt":"num"}],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"","x":160,"y":640,"wires":[["7baef38eb9b12065"]]},{"id":"de1ad50c1a599ddb","type":"inject","z":"3a3d48083fb04932","name":"Close curtain 2","props":[{"p":"code","v":"58338","vt":"num"},{"p":"target","v":"1.5","vt":"str"},{"p":"payload.curtain","v":"2","vt":"num"},{"p":"payload.status","v":"2","vt":"num"}],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"","x":160,"y":780,"wires":[["7baef38eb9b12065"]]},{"id":"7a99b3ba002e342a","type":"inject","z":"3a3d48083fb04932","name":"Open curtain 2","props":[{"p":"code","v":"58338","vt":"str"},{"p":"target","v":"1.5","vt":"str"},{"p":"payload.curtain","v":"2","vt":"num"},{"p":"payload.status","v":"1","vt":"num"}],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"","x":160,"y":840,"wires":[["7baef38eb9b12065"]]},{"id":"be412e235c4ffe3c","type":"inject","z":"3a3d48083fb04932","name":"Open curtain 2","props":[{"p":"code","v":"58338","vt":"str"},{"p":"target","v":"1.5","vt":"str"},{"p":"payload.curtain","v":"2","vt":"num"},{"p":"payload.status","v":"0","vt":"num"}],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"","x":160,"y":900,"wires":[["7baef38eb9b12065"]]},{"id":"8c657ab601401d4d","type":"comment","z":"3a3d48083fb04932","name":"Debug","info":"","x":70,"y":20,"wires":[]}]

That could be. This should make it easyer to interface against HA.

If you expand the 58340 message array i expect the first one to show initial status and the one 10s behind should show new status. either in 1(Open) or 2(Closed) or in %

Do you mind doing it again and also press the arrow to show the complete messages. Only need 1 of each message and not one per channel. If either of the read status test commands work i do not need the code 58338
arrow

Thank you for your continued effortšŸ˜ƒ

HereĀ“s the debug for channel 1 (forward and back). None of the test commands seem to work in the new flow.




Unfortunately the Floorheating card is still blank. I have updated with the new commands.js as per your post earlier. I was able to validate the config without issues after updating to preset_mode_value_template - but for some reason the Floorheating card is unresponsive/blank:

Thanks, got what i need now,(Think there is a smal bug in the broadcast decoding but will get it working as is) will try to get it working in a few days when i have some free time. (Hopfully working on first try now :crossed_fingers:)

Have modified the commands to match your debug commands now that i have the complete debugs. On this new flow the test commands should work. Can you confirm they are ok and report witch of the 2x read status commands work? (And also send a screenshot of responce code 58339)

Disable or delete the 2x old flows and import this new one:

[{"id":"3a3d48083fb04932","type":"tab","label":"Cregeland curtain debug","disabled":false,"info":"","env":[]},{"id":"c885a1ed834c58fe","type":"hdl-raw-in","z":"3a3d48083fb04932","controller":"","name":"","x":90,"y":160,"wires":[["b00ce7a280aae8b7","ded39737b0165cc1"]]},{"id":"b00ce7a280aae8b7","type":"switch","z":"3a3d48083fb04932","name":"sender","property":"sender","propertyType":"msg","rules":[{"t":"eq","v":"1.5","vt":"str"}],"checkall":"true","repair":false,"outputs":1,"x":350,"y":260,"wires":[["8a7a1b9ec676db0b"]]},{"id":"77175d9bb6c8da23","type":"switch","z":"3a3d48083fb04932","name":"code","property":"code","propertyType":"msg","rules":[{"t":"eq","v":"58336","vt":"str"},{"t":"eq","v":"58338","vt":"str"}],"checkall":"true","repair":false,"outputs":2,"x":470,"y":100,"wires":[["ac2b8e08472a1fe3"],["e3ec9cf255dc670d"]]},{"id":"ac2b8e08472a1fe3","type":"debug","z":"3a3d48083fb04932","name":"58336 Curtain Switch Control","active":true,"tosidebar":true,"console":false,"tostatus":false,"complete":"true","targetType":"full","statusVal":"","statusType":"auto","x":680,"y":80,"wires":[]},{"id":"65074da8a605c63d","type":"debug","z":"3a3d48083fb04932","name":"58337 Response Curtain Switch Control","active":true,"tosidebar":true,"console":false,"tostatus":false,"complete":"true","targetType":"full","statusVal":"","statusType":"auto","x":720,"y":220,"wires":[]},{"id":"8a7a1b9ec676db0b","type":"switch","z":"3a3d48083fb04932","name":"code","property":"code","propertyType":"msg","rules":[{"t":"eq","v":"58337","vt":"str"},{"t":"eq","v":"58339","vt":"str"},{"t":"eq","v":"58340","vt":"str"}],"checkall":"true","repair":false,"outputs":3,"x":470,"y":260,"wires":[["65074da8a605c63d"],["29213d5322990792"],["7b5d4d97185b40e8"]]},{"id":"ded39737b0165cc1","type":"switch","z":"3a3d48083fb04932","name":"target","property":"target","propertyType":"msg","rules":[{"t":"eq","v":"1.5","vt":"str"}],"checkall":"true","repair":false,"outputs":1,"x":350,"y":100,"wires":[["77175d9bb6c8da23"]]},{"id":"e9c6fc35735d03bf","type":"comment","z":"3a3d48083fb04932","name":"Command to curtain module","info":"","x":380,"y":60,"wires":[]},{"id":"9dcb0699ae35bf80","type":"comment","z":"3a3d48083fb04932","name":"Answers from Curtain module","info":"","x":380,"y":220,"wires":[]},{"id":"e3ec9cf255dc670d","type":"debug","z":"3a3d48083fb04932","name":"58338 Read Status of Curtain Switch","active":true,"tosidebar":true,"console":false,"tostatus":false,"complete":"true","targetType":"full","statusVal":"","statusType":"auto","x":710,"y":120,"wires":[]},{"id":"29213d5322990792","type":"debug","z":"3a3d48083fb04932","name":" 58339 Response Read Status of Curtain Switch","active":true,"tosidebar":true,"console":false,"tostatus":false,"complete":"true","targetType":"full","statusVal":"","statusType":"auto","x":740,"y":260,"wires":[]},{"id":"7b5d4d97185b40e8","type":"debug","z":"3a3d48083fb04932","name":"58340 Broadcast Status of Status of Curtain Switches","active":true,"tosidebar":true,"console":false,"tostatus":false,"complete":"true","targetType":"full","statusVal":"","statusType":"auto","x":760,"y":300,"wires":[]},{"id":"3765e77989f3ca13","type":"comment","z":"3a3d48083fb04932","name":"Test commands","info":"","x":100,"y":400,"wires":[]},{"id":"6461461c9b88d084","type":"inject","z":"3a3d48083fb04932","name":"Read status curtain 1","props":[{"p":"code","v":"58338","vt":"num"},{"p":"target","v":"1.5","vt":"str"},{"p":"payload.curtain","v":"1","vt":"num"}],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"","x":180,"y":460,"wires":[["7baef38eb9b12065","1804f4a612932c84"]]},{"id":"7baef38eb9b12065","type":"hdl-raw-out","z":"3a3d48083fb04932","controller":"","name":"","x":610,"y":660,"wires":[]},{"id":"a8a0ea807540fff7","type":"inject","z":"3a3d48083fb04932","name":"Read status curtain 2","props":[{"p":"code","v":"58338","vt":"num"},{"p":"target","v":"1.5","vt":"str"},{"p":"payload.curtain","v":"2","vt":"num"}],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"","x":180,"y":780,"wires":[["7baef38eb9b12065","1804f4a612932c84"]]},{"id":"d0db9cf3c0af3c1d","type":"inject","z":"3a3d48083fb04932","name":"Close curtain 1","props":[{"p":"code","v":"58338","vt":"num"},{"p":"target","v":"1.5","vt":"str"},{"p":"payload.curtain","v":"1","vt":"num"},{"p":"payload.status","v":"2","vt":"num"}],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"","x":160,"y":580,"wires":[["7baef38eb9b12065","1804f4a612932c84"]]},{"id":"3085b69f73a2e0f6","type":"inject","z":"3a3d48083fb04932","name":"Open curtain 1","props":[{"p":"code","v":"58338","vt":"num"},{"p":"target","v":"1.5","vt":"str"},{"p":"payload.curtain","v":"1","vt":"num"},{"p":"payload.status","v":"1","vt":"num"}],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"","x":160,"y":640,"wires":[["7baef38eb9b12065","1804f4a612932c84"]]},{"id":"5483fd27d8442050","type":"inject","z":"3a3d48083fb04932","name":"Open curtain 1","props":[{"p":"code","v":"58338","vt":"num"},{"p":"target","v":"1.5","vt":"str"},{"p":"payload.curtain","v":"1","vt":"num"},{"p":"payload.status","v":"0","vt":"num"}],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"","x":160,"y":700,"wires":[["7baef38eb9b12065","1804f4a612932c84"]]},{"id":"de1ad50c1a599ddb","type":"inject","z":"3a3d48083fb04932","name":"Close curtain 2","props":[{"p":"code","v":"58338","vt":"num"},{"p":"target","v":"1.5","vt":"str"},{"p":"payload.curtain","v":"2","vt":"num"},{"p":"payload.status","v":"2","vt":"num"}],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"","x":160,"y":900,"wires":[["7baef38eb9b12065","1804f4a612932c84"]]},{"id":"7a99b3ba002e342a","type":"inject","z":"3a3d48083fb04932","name":"Open curtain 2","props":[{"p":"code","v":"58338","vt":"num"},{"p":"target","v":"1.5","vt":"str"},{"p":"payload.curtain","v":"2","vt":"num"},{"p":"payload.status","v":"1","vt":"num"}],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"","x":160,"y":960,"wires":[["7baef38eb9b12065","1804f4a612932c84"]]},{"id":"be412e235c4ffe3c","type":"inject","z":"3a3d48083fb04932","name":"Open curtain 2","props":[{"p":"code","v":"58338","vt":"num"},{"p":"target","v":"1.5","vt":"str"},{"p":"payload.curtain","v":"2","vt":"num"},{"p":"payload.status","v":"0","vt":"num"}],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"","x":160,"y":1020,"wires":[["7baef38eb9b12065","1804f4a612932c84"]]},{"id":"8c657ab601401d4d","type":"comment","z":"3a3d48083fb04932","name":"Debug","info":"","x":70,"y":20,"wires":[]},{"id":"1804f4a612932c84","type":"debug","z":"3a3d48083fb04932","name":"CMD to module","active":true,"tosidebar":true,"console":false,"tostatus":false,"complete":"true","targetType":"full","statusVal":"","statusType":"auto","x":640,"y":720,"wires":[]},{"id":"d53dffebe07f93ad","type":"inject","z":"3a3d48083fb04932","name":"Read status curtain 1 v2","props":[{"p":"code","v":"58338","vt":"num"},{"p":"target","v":"1.5","vt":"str"},{"p":"curtain","v":"1","vt":"num"}],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"","x":190,"y":520,"wires":[["7baef38eb9b12065","1804f4a612932c84"]]},{"id":"e834224f7b345554","type":"inject","z":"3a3d48083fb04932","name":"Read status curtain 1 v2","props":[{"p":"code","v":"58338","vt":"num"},{"p":"target","v":"1.5","vt":"str"},{"p":"curtain","v":"1","vt":"num"}],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"","x":190,"y":840,"wires":[["1804f4a612932c84","7baef38eb9b12065"]]}]

Strange. Can you confirm that you have selected a unique device id in the ā€œhdl-controller-nodeā€? It can not be the same as the ip module. See image:

It can also be a problem with nodered not writing to MQTT server or HA not reading from MQTT server. Do you have lights or any other sensors etc. working so we know the interfacing is working. If not i would recomend downloading MQTT explorer and check what data goes to the server from the FH module.

The test commands did not work - but they do work if I change to 58336 instead of 58338. Also the read status v1 triggers an event in the debug - but not v2.

This is the result for 58339:

This is the modified flow where the test commands seem to work.


[{"id":"3a3d48083fb04932","type":"tab","label":"Cregeland curtain debug","disabled":false,"info":"","env":[]},{"id":"c885a1ed834c58fe","type":"hdl-raw-in","z":"3a3d48083fb04932","controller":"746c208aec158bed","name":"","x":90,"y":180,"wires":[["b00ce7a280aae8b7","ded39737b0165cc1"]]},{"id":"b00ce7a280aae8b7","type":"switch","z":"3a3d48083fb04932","name":"sender","property":"sender","propertyType":"msg","rules":[{"t":"eq","v":"1.5","vt":"str"}],"checkall":"true","repair":false,"outputs":1,"x":350,"y":260,"wires":[["8a7a1b9ec676db0b"]]},{"id":"77175d9bb6c8da23","type":"switch","z":"3a3d48083fb04932","name":"code","property":"code","propertyType":"msg","rules":[{"t":"eq","v":"58336","vt":"str"},{"t":"eq","v":"58338","vt":"str"}],"checkall":"true","repair":false,"outputs":2,"x":470,"y":100,"wires":[["ac2b8e08472a1fe3"],["e3ec9cf255dc670d"]]},{"id":"ac2b8e08472a1fe3","type":"debug","z":"3a3d48083fb04932","name":"58336 Curtain Switch Control","active":true,"tosidebar":true,"console":false,"tostatus":false,"complete":"true","targetType":"full","statusVal":"","statusType":"auto","x":680,"y":80,"wires":[]},{"id":"65074da8a605c63d","type":"debug","z":"3a3d48083fb04932","name":"58337 Response Curtain Switch Control","active":true,"tosidebar":true,"console":false,"tostatus":false,"complete":"true","targetType":"full","statusVal":"","statusType":"auto","x":720,"y":220,"wires":[]},{"id":"8a7a1b9ec676db0b","type":"switch","z":"3a3d48083fb04932","name":"code","property":"code","propertyType":"msg","rules":[{"t":"eq","v":"58337","vt":"str"},{"t":"eq","v":"58339","vt":"str"},{"t":"eq","v":"58340","vt":"str"}],"checkall":"true","repair":false,"outputs":3,"x":470,"y":260,"wires":[["65074da8a605c63d"],["29213d5322990792"],["7b5d4d97185b40e8"]]},{"id":"ded39737b0165cc1","type":"switch","z":"3a3d48083fb04932","name":"target","property":"target","propertyType":"msg","rules":[{"t":"eq","v":"1.5","vt":"str"}],"checkall":"true","repair":false,"outputs":1,"x":350,"y":100,"wires":[["77175d9bb6c8da23"]]},{"id":"e9c6fc35735d03bf","type":"comment","z":"3a3d48083fb04932","name":"Command to curtain module","info":"","x":380,"y":60,"wires":[]},{"id":"9dcb0699ae35bf80","type":"comment","z":"3a3d48083fb04932","name":"Answers from Curtain module","info":"","x":380,"y":220,"wires":[]},{"id":"e3ec9cf255dc670d","type":"debug","z":"3a3d48083fb04932","name":"58338 Read Status of Curtain Switch","active":true,"tosidebar":true,"console":false,"tostatus":false,"complete":"true","targetType":"full","statusVal":"","statusType":"auto","x":710,"y":120,"wires":[]},{"id":"29213d5322990792","type":"debug","z":"3a3d48083fb04932","name":" 58339 Response Read Status of Curtain Switch","active":true,"tosidebar":true,"console":false,"tostatus":false,"complete":"true","targetType":"full","statusVal":"","statusType":"auto","x":740,"y":260,"wires":[]},{"id":"7b5d4d97185b40e8","type":"debug","z":"3a3d48083fb04932","name":"58340 Broadcast Status of Status of Curtain Switches","active":true,"tosidebar":true,"console":false,"tostatus":false,"complete":"true","targetType":"full","statusVal":"","statusType":"auto","x":760,"y":300,"wires":[]},{"id":"3765e77989f3ca13","type":"comment","z":"3a3d48083fb04932","name":"Test commands","info":"","x":100,"y":400,"wires":[]},{"id":"6461461c9b88d084","type":"inject","z":"3a3d48083fb04932","name":"Read status curtain 1","props":[{"p":"code","v":"58338","vt":"num"},{"p":"target","v":"1.5","vt":"str"},{"p":"payload.curtain","v":"1","vt":"num"}],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"","x":180,"y":460,"wires":[["7baef38eb9b12065","1804f4a612932c84"]]},{"id":"7baef38eb9b12065","type":"hdl-raw-out","z":"3a3d48083fb04932","controller":"746c208aec158bed","name":"","x":610,"y":660,"wires":[]},{"id":"a8a0ea807540fff7","type":"inject","z":"3a3d48083fb04932","name":"Read status curtain 2","props":[{"p":"code","v":"58338","vt":"num"},{"p":"target","v":"1.5","vt":"str"},{"p":"payload.curtain","v":"2","vt":"num"}],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"","x":180,"y":780,"wires":[["7baef38eb9b12065","1804f4a612932c84"]]},{"id":"d0db9cf3c0af3c1d","type":"inject","z":"3a3d48083fb04932","name":"Close curtain 1","props":[{"p":"code","v":"58336","vt":"num"},{"p":"target","v":"1.5","vt":"str"},{"p":"payload.curtain","v":"1","vt":"num"},{"p":"payload.status","v":"2","vt":"num"}],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"","x":160,"y":580,"wires":[["7baef38eb9b12065","1804f4a612932c84"]]},{"id":"3085b69f73a2e0f6","type":"inject","z":"3a3d48083fb04932","name":"Open curtain 1","props":[{"p":"code","v":"58336","vt":"num"},{"p":"target","v":"1.5","vt":"str"},{"p":"payload.curtain","v":"1","vt":"num"},{"p":"payload.status","v":"1","vt":"num"}],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"","x":160,"y":640,"wires":[["7baef38eb9b12065","1804f4a612932c84"]]},{"id":"5483fd27d8442050","type":"inject","z":"3a3d48083fb04932","name":"Open curtain 1","props":[{"p":"code","v":"58338","vt":"num"},{"p":"target","v":"1.5","vt":"str"},{"p":"payload.curtain","v":"1","vt":"num"},{"p":"payload.status","v":"0","vt":"num"}],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"","x":160,"y":700,"wires":[["7baef38eb9b12065","1804f4a612932c84"]]},{"id":"de1ad50c1a599ddb","type":"inject","z":"3a3d48083fb04932","name":"Close curtain 2","props":[{"p":"code","v":"58336","vt":"num"},{"p":"target","v":"1.5","vt":"str"},{"p":"payload.curtain","v":"2","vt":"num"},{"p":"payload.status","v":"2","vt":"num"}],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"","x":160,"y":900,"wires":[["7baef38eb9b12065","1804f4a612932c84"]]},{"id":"7a99b3ba002e342a","type":"inject","z":"3a3d48083fb04932","name":"Open curtain 2","props":[{"p":"code","v":"58336","vt":"num"},{"p":"target","v":"1.5","vt":"str"},{"p":"payload.curtain","v":"2","vt":"num"},{"p":"payload.status","v":"1","vt":"num"}],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"","x":160,"y":960,"wires":[["7baef38eb9b12065","1804f4a612932c84"]]},{"id":"be412e235c4ffe3c","type":"inject","z":"3a3d48083fb04932","name":"Open curtain 2","props":[{"p":"code","v":"58338","vt":"num"},{"p":"target","v":"1.5","vt":"str"},{"p":"payload.curtain","v":"2","vt":"num"},{"p":"payload.status","v":"0","vt":"num"}],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"","x":160,"y":1020,"wires":[["7baef38eb9b12065","1804f4a612932c84"]]},{"id":"8c657ab601401d4d","type":"comment","z":"3a3d48083fb04932","name":"Debug","info":"","x":70,"y":20,"wires":[]},{"id":"1804f4a612932c84","type":"debug","z":"3a3d48083fb04932","name":"CMD to module","active":true,"tosidebar":true,"console":false,"tostatus":false,"complete":"true","targetType":"full","statusVal":"","statusType":"auto","x":640,"y":720,"wires":[]},{"id":"d53dffebe07f93ad","type":"inject","z":"3a3d48083fb04932","name":"Read status curtain 1 v2","props":[{"p":"code","v":"58338","vt":"num"},{"p":"target","v":"1.5","vt":"str"},{"p":"curtain","v":"1","vt":"num"}],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"","x":190,"y":520,"wires":[["7baef38eb9b12065","1804f4a612932c84"]]},{"id":"e834224f7b345554","type":"inject","z":"3a3d48083fb04932","name":"Read status curtain 1 v2","props":[{"p":"code","v":"58338","vt":"num"},{"p":"target","v":"1.5","vt":"str"},{"p":"curtain","v":"1","vt":"num"}],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"","x":190,"y":840,"wires":[["1804f4a612932c84","7baef38eb9b12065"]]},{"id":"746c208aec158bed","type":"hdl-controller","host":"192.168.1.250","port":"6000","subnetid":"1","deviceid":"199","broadcast":false,"daliId":"0"}]

As for the Floorheating - I now have the HDL controller on a dedicated device ID. The lighting and relay control works - and also the flow for testing curtains - so the HDL controller communication should be ok.

Once again thank you for your help :slight_smile:

Did that fix the issue so that you now can control FH and AC?

Nice catch, to mutch copy paste from my side there.

New config for HA:
Add this line to the configuration.yaml file:

cover: !include cover.yaml

Add a new file in the config folder named cover.yaml and add something like this to it:

# Bedroom blinds
- platform: mqtt
  name: "Blind Bedroom"
  device_class: shade
  command_topic: "hdl/cc/1.5/1/set"
  state_topic: "hdl/cc/1.5/1/state"
#
# Living Room blinds
- platform: mqtt
  name: "Blind Living Room"
  device_class: shade
  command_topic: "hdl/cc/1.5/2/set"
  state_topic: "hdl/cc/1.5/2/state"

Device_class should match what ever you physically have on this page, this is for icons etc.

Example card for ch 1 closed and ch 2 open:
Blinds

Here is a new flow, try disabling your current MQTT - HDL flow and import this instead(Select import to new flow :smiley: ). Update the HDL in and out nodes and the MQTT in and out nodes to match your settings.

The feedbacks are a bit stupid in that it reports only status and not level even though according to the HDL documentation it should report level also. Therefore you will not be able to ask the module for current status on deployment or restart.

This could be issue in the firmware on the module or bug in the commands.js file. To find out and possible fix it one would have to check the byte messages on the bus and decode it from HEX +++. This is quite some work especially as i dont have a module myself, so instead i used the command answerback message and added a manual 10s timer. Now when you click close or it is closed from a sensor, switch etc. it will report status closing for 10s before changing to closed etc. This will be the same time for each blind even if they have different running time. One other option would be to change it straight to closed and ignore the closing and opening status.

Please let me know how it works for you as i have not been able to run a full test.

Fantastic work @Linax ! The relays are now triggered from the cardšŸ‘ There seem to be some issue with the status reporting though.

As you can see from the screenshot one of the blinds are not reporting state Ā«openĀ». The relay ran for 10 seconds - so the blind is open - but seems to be stuck in Ā«openingĀ» state. This happens to both channels in what seems to be random order - both when opening and closing. The state in the entity card is indicating the same state as shown in MQTT explorer. The question is what is causing the state to not update. It seems to happen every time I run both the channels at the same time - but also when running them one at a time (but less frequent).


Unfortunately - No. I still have a blank card on the FH/AC. The FH is also visible in the MQTT explorer as 1.91.

Think the issue is that i used timer instead of delay, a timer will restart on every message in so if you send two messages only last will be retained. Have changed the flow to use a delay node instead, this will delay every message.

For the floorheat i think the problem is you have ā€œhdl/fhā€(fh is short for floorheat this is the DLP thermostats witch is what i have) in your HA config instead of ā€œhdl/hmā€ (hm is short for heatmodule) Sorry i did not spot this earlier.

For the AC i can see that you dont have any data on the MQTT server so this could be an error from HDL to MQTT, and since you need the raw message in nodered ā€œcontext dataā€ to send a new message this will not work. There is two ways to get the initial state:

  1. Run a Read AC Status (6456) on startup. And you should get responce(6457) with current status. Try adding this command to your flow.

  2. Update the AC module from a DLP or something like this and you should get the Response Control AC Status (6459).

I do not have a AC module myself but but run a virtual AC in Node-RED(and forward the command to IR via an arduino) to be able to control my Heatpump from the DLP`s and Home Assistant, so have not done any testing on the actual module myself.

Can see that there have not been added parcer/decoder for the read and responce codes in the commands.js file. Would you be willing to try and get me the debugs of the codes 6456 and 6457? Should be able to use this flow. If there is a refresh button on the ac module in HDL buspro tool i think this should trigger the read command.

[{"id":"c8e5a62fcb5fb706","type":"hdl-raw-in","z":"641980b9a6a75af9","controller":"","name":"","x":90,"y":1040,"wires":[["2f56a10e55062696","ed1e957e136a4d4b"]]},{"id":"2f56a10e55062696","type":"switch","z":"641980b9a6a75af9","name":"code","property":"code","propertyType":"msg","rules":[{"t":"eq","v":"6456","vt":"str"},{"t":"eq","v":"6458","vt":"str"}],"checkall":"true","repair":false,"outputs":2,"x":350,"y":960,"wires":[["dbf0a12520abf499"],["475dbfb3485b2009"]]},{"id":"dbf0a12520abf499","type":"debug","z":"641980b9a6a75af9","name":"6456 Read Status","active":true,"tosidebar":true,"console":false,"tostatus":false,"complete":"true","targetType":"full","statusVal":"","statusType":"auto","x":650,"y":940,"wires":[]},{"id":"ad37da2b41b29aff","type":"debug","z":"641980b9a6a75af9","name":"6457 Read responce","active":true,"tosidebar":true,"console":false,"tostatus":false,"complete":"true","targetType":"full","statusVal":"","statusType":"auto","x":660,"y":1080,"wires":[]},{"id":"ed1e957e136a4d4b","type":"switch","z":"641980b9a6a75af9","name":"code","property":"code","propertyType":"msg","rules":[{"t":"eq","v":"6457","vt":"str"},{"t":"eq","v":"6459","vt":"str"}],"checkall":"true","repair":false,"outputs":2,"x":350,"y":1100,"wires":[["ad37da2b41b29aff"],["3a0134c59eb4da18"]]},{"id":"f776c1b50fea68bc","type":"comment","z":"641980b9a6a75af9","name":"Command to AC module","info":"","x":370,"y":920,"wires":[]},{"id":"29c18d6e22f0c391","type":"comment","z":"641980b9a6a75af9","name":"Answers from AC module","info":"","x":370,"y":1040,"wires":[]},{"id":"475dbfb3485b2009","type":"debug","z":"641980b9a6a75af9","name":"6458 Control AC","active":true,"tosidebar":true,"console":false,"tostatus":false,"complete":"true","targetType":"full","statusVal":"","statusType":"auto","x":640,"y":980,"wires":[]},{"id":"3a0134c59eb4da18","type":"debug","z":"641980b9a6a75af9","name":"6459 Control Responce","active":true,"tosidebar":true,"console":false,"tostatus":false,"complete":"true","targetType":"full","statusVal":"","statusType":"auto","x":670,"y":1120,"wires":[]}]

Great news - the thermostat card is now working. You are correct about the Ā«hdl/hmĀ». Also the addressing of the device/channel had to be changed to 1.91.1 instead of 1.91/1. Once that was changed everything seems to work.

This is my working config for controlling the Floorheating module directly:


# Floorheat Thermostat
climate:
  - platform: mqtt
    name: Floorheat ch1
    modes:
      - "off"
      - "heat"
    mode_state_topic: "hdl/hm/1.91.1"
    mode_state_template: "{{value_json.status}}"
    mode_command_topic: "hdl/hm/1.91.1/mode/set"
    #current_temperature_topic: "hdl/hm/1.91.1"
    #current_temperature_template: "{{value_json.temperature.current}}"
    current_temperature_topic: "hdl/temp/1.91.1"
    temperature_state_topic: "hdl/hm/1.91.1"
    temperature_state_template: "{{value_json.temperature.now}}"
    temperature_command_topic: "hdl/hm/1.91.1/temperature/set"
    preset_modes:
      - "Normal"
      - "Day"
      - "Night"
      - "Away"
      - "Timer"
    preset_mode_state_topic: "hdl/hm/1.91.1"
    preset_mode_value_template: "{{value_json.textmode}}"
    preset_mode_command_topic: "hdl/hm/1.91.1/textmode/set"
    min_temp: 5
    max_temp: 35
    precision: 0.1

The curtain controller is now behaving much better - good jobšŸ‘ The status seems to be more correct. The only issue seems to be related to stopping the curtain between fully open/fully closed position. When I hit down/close the curtain will start to close. If I thereafter hit the stop icon the curtain will stop at the current position. After 10 seconds the state will still update to closed - but the curtain is neither (fully) open or closed.

The close/down button will also be greyed out - so in order to make the curtain continue towards down/closed I first have to click open/up. By doing that the curtain will move up and the down/close button will be reactivated. Since I wanted to continue to close the curtain from where I paused I hit the down/close button. The curtain will reverse direction and head towards down/closed - good. But the sate will report open/up 10 seconds after starting the up command - despite the curtain is actually closed. I see the logic behind that due to the delay function - and maybe there is no easy way to avoid it?

It would be perfect if one could click down - then stop the curtain - and then have the option to continue in either direction (not have the down button disabled/greyed out).

Regarding the AC module. I have an old HDL SB-DN-HVAC module. I found the quoted information below which maybe could explain why there is no MQTT data from the AC. Looks like the SB-DN-HVAC module will only communicate directly with a DLP of Enviro panel. There is a newer AC module available (MAC01.331) that seem to have better functionality. I might have to upgradešŸ˜Ž

Q: Apart from the relay totality is different from that of SB-DN-HVAC, I can see the MAC01.331 has terminal for digital temperature sensor. *

A: Yes, the MAC01.331 has terminal for digital temperature sensor DS18B20, and has built-in control logic, which means once a desired temperature is set (via user panel, e.g., a DLP panel) to it, it can regulate itself and control the room temperature. This is not true for SB-DN-HAVC, the SB-DN-HAVC requires a DLP panel to be online always, because the SB-DN-HVAC has no built-in the control logic, the control logic is in DLP panel.

Thanks, will add this as example to the first post to avoid any confusion in future. Did you also get the current temperature working like that?

I see that there is some issues with the current blinds logic that i did not think of, will try to make a fix for it. Would be intresting to see if there is a bug in the decoding of the codes for curtain controller first tho. Could you run the ā€œcommand testā€(Under tools) function in Buspro software while closing a blind to get me the raw hex value for the commands sendt from clicking close until it is fully closed and also get the debugs from the Nodered test flow at the same time?

I think you can try to add ā€œoptimistic: trueā€ under config for the blind for now and then you should be able to run it all ways.

For the AC can you run the flow bellow and check the debug window when updating status from a DLP? Think you should get some messages atleast and do not think it is needed to upgrade the module.

[{"id":"abe9a13397912ead","type":"tab","label":"AC Test v1","disabled":false,"info":"","env":[]},{"id":"5f6b3ac78f77f3bc","type":"hdl-raw-out","z":"abe9a13397912ead","controller":"","name":"","x":670,"y":580,"wires":[]},{"id":"14bf1182cdd9510c","type":"inject","z":"abe9a13397912ead","name":"Read AC status","props":[{"p":"code","v":"6456","vt":"num"},{"p":"target","v":"1.106","vt":"str"},{"p":"payload.ac","v":"1","vt":"num"}],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"","x":200,"y":620,"wires":[["5f6b3ac78f77f3bc"]]},{"id":"c3bfb169da985d60","type":"hdl-raw-in","z":"abe9a13397912ead","controller":"","name":"","x":130,"y":220,"wires":[["4226e66306f2bb6e","567c80210457e484"]]},{"id":"4226e66306f2bb6e","type":"switch","z":"abe9a13397912ead","name":"code","property":"code","propertyType":"msg","rules":[{"t":"eq","v":"6456","vt":"num"},{"t":"eq","v":"6458","vt":"num"}],"checkall":"true","repair":false,"outputs":2,"x":350,"y":160,"wires":[["f2814864d5123a07"],["7b63dee7c3fa0f45"]]},{"id":"567c80210457e484","type":"switch","z":"abe9a13397912ead","name":"code","property":"code","propertyType":"msg","rules":[{"t":"eq","v":"6457","vt":"num"},{"t":"eq","v":"6459","vt":"num"}],"checkall":"true","repair":false,"outputs":2,"x":350,"y":300,"wires":[["ab75cccd1e6dd1fa"],["3ec86a1575dcaaf7"]]},{"id":"2c156a3804a61641","type":"comment","z":"abe9a13397912ead","name":"Command to AC module","info":"","x":370,"y":120,"wires":[]},{"id":"8851fce670426043","type":"comment","z":"abe9a13397912ead","name":"Answers from AC module","info":"","x":370,"y":240,"wires":[]},{"id":"3ec86a1575dcaaf7","type":"debug","z":"abe9a13397912ead","name":"6459 Control Responce","active":true,"tosidebar":true,"console":false,"tostatus":false,"complete":"true","targetType":"full","statusVal":"","statusType":"auto","x":670,"y":320,"wires":[]},{"id":"ab75cccd1e6dd1fa","type":"debug","z":"abe9a13397912ead","name":"6457 Read responce","active":true,"tosidebar":true,"console":false,"tostatus":false,"complete":"true","targetType":"full","statusVal":"","statusType":"auto","x":660,"y":280,"wires":[]},{"id":"7b63dee7c3fa0f45","type":"debug","z":"abe9a13397912ead","name":"6458 Control AC","active":true,"tosidebar":true,"console":false,"tostatus":false,"complete":"true","targetType":"full","statusVal":"","statusType":"auto","x":640,"y":180,"wires":[]},{"id":"f2814864d5123a07","type":"debug","z":"abe9a13397912ead","name":"6456 Read Status","active":true,"tosidebar":true,"console":false,"tostatus":false,"complete":"true","targetType":"full","statusVal":"","statusType":"auto","x":650,"y":140,"wires":[]},{"id":"1810c2d651082e22","type":"comment","z":"abe9a13397912ead","name":"Need to update commands.js file for read to work","info":"  // 10.1.1 Read AC Status\n  0x1938: {\n    parse: function(buffer) {\n      return { ac: buffer.readUInt8(0) };\n    },\n\n    encode: function(data) {\n      return new Buffer([data.ac]);\n    },\n\n    response: 0x1939\n  },\n  // 10.1.2 Response Read AC Status","x":260,"y":580,"wires":[]},{"id":"f77db578d25054a4","type":"comment","z":"abe9a13397912ead","name":"Debug of AC codes","info":"","x":120,"y":60,"wires":[]},{"id":"70b5c163af262e18","type":"comment","z":"abe9a13397912ead","name":"Test commands for AC","info":"","x":140,"y":460,"wires":[]},{"id":"bbdcae056f8751a8","type":"change","z":"abe9a13397912ead","name":"AC Default parameters","rules":[{"t":"set","p":"sender","pt":"msg","to":"1.106","tot":"str"},{"t":"set","p":"target","pt":"msg","to":"1.99","tot":"str"},{"t":"set","p":"code","pt":"msg","to":"6458","tot":"num"},{"t":"set","p":"payload.acstatus","pt":"msg","to":"true","tot":"bool"},{"t":"set","p":"payload.acno","pt":"msg","to":"1","tot":"num"},{"t":"set","p":"payload.setupmode","pt":"msg","to":"1","tot":"num"},{"t":"set","p":"payload.setupspeed","pt":"msg","to":"2","tot":"num"},{"t":"set","p":"payload.temperature.type","pt":"msg","to":"0","tot":"num"},{"t":"set","p":"payload.temperature.now","pt":"msg","to":"23","tot":"num"},{"t":"set","p":"payload.temperature.cooling","pt":"msg","to":"19","tot":"num"},{"t":"set","p":"payload.temperature.heating","pt":"msg","to":"23","tot":"num"},{"t":"set","p":"payload.temperature.auto","pt":"msg","to":"23","tot":"num"},{"t":"set","p":"payload.temperature.dry","pt":"msg","to":"21","tot":"num"},{"t":"set","p":"payload.modeandfan","pt":"msg","to":"48","tot":"num"},{"t":"set","p":"payload.currentmode","pt":"msg","to":"23","tot":"num"},{"t":"set","p":"payload.sweep","pt":"msg","to":"OFF","tot":"str"}],"action":"","property":"","from":"","to":"","reg":false,"x":400,"y":500,"wires":[["5f6b3ac78f77f3bc"]]},{"id":"0b78e68747fe8af0","type":"inject","z":"abe9a13397912ead","name":"Test AC update","props":[{"p":"test","v":"","vt":"date"},{"p":"topic","vt":"str"}],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"","x":200,"y":500,"wires":[["bbdcae056f8751a8"]]}]

Can you also give me some more info on The AC setup,

  • Subnet and Device id for the AC module?

  • How is it connected from HDL to the AC?

  • How do you control the HDL AC module now?

  • What type of AC is it?

Good catch :slight_smile: I did not - I had to remove # before ā€œcurrent_temperature_topicā€ and the ā€œcurrent temperature_templateā€. Added # in front of ā€œcurrent_temperature_topicā€ with reference to hdl/temp. Requested temperature is shown in big numbers, actual temperature just over ā€œHeat - Normalā€.

To clarify hereā€™s the code:

  - platform: mqtt
    name: Floorheat 1.91.2
    modes:
      - "off"
      - "heat"
    mode_state_topic: "hdl/hm/1.91.2"
    mode_state_template: "{{value_json.status}}"
    mode_command_topic: "hdl/hm/1.91.2/mode/set"
    current_temperature_topic: "hdl/hm/1.91.2"
    current_temperature_template: "{{value_json.temperature.current}}"
    #current_temperature_topic: "hdl/temp/1.91.2"
    temperature_state_topic: "hdl/hm/1.91.2"
    temperature_state_template: "{{value_json.temperature.now}}"
    temperature_command_topic: "hdl/hm/1.91.2/temperature/set"
    preset_modes:
      - "Normal"
      - "Day"
      - "Night"
      - "Away"
      - "Timer"
    preset_mode_state_topic: "hdl/hm/1.91.2"
    preset_mode_value_template: "{{value_json.textmode}}"
    preset_mode_command_topic: "hdl/hm/1.91.2/textmode/set"
    min_temp: 5
    max_temp: 35
    precision: 0.1

Screenshot for running curtain channel 1 down and then up:


Screenshot for running curtain channel 2 down and then up. After it reached the up position the state did not update in HomeAssistant. I pressed the stop button to see if it would trigger an entry in the log:


The status reporting and general control seems to be a bit unstable for some reason.

I will follow up with AC info/logs shortly :slight_smile:

Hey team, good to see some more dev going on with this - I published the node-red module node-red-contrib-hdlbus a couple of years back (forked from node-red-contrib-buspro - that dev and I couldnā€™t agree on directions at the time unfortunately), havenā€™t had a need to update it really to date. I saw a PR pop up a few weeks back - but itā€™s gone now - that one of you?

I use DALI for lighting - hence why thereā€™s a virtual DALI groups device - this is necessary to store/recall levels as theyā€™re not reported correctly on the HDL network. Drop the node on a page and read the info pane if youā€™d like to understand it more - basically just makes the 16 DALI groups function as a virtual 16ch dimmer.

I use the addin slightly differently (I think?) - I have a generic flow for lights that creates a 2-way conduit between HDL and MQTT without knowing about any of the devices - then I create mqtt lights in HA YAML. Iā€™ve recently got into autodiscovery in HA, so would love to look at being able to auto-create entities, just need to find the time.

The YAML for a light/channel - this is in the ā€˜lightā€™ domain:

- platform: mqtt
  name: "Flat Hall"
  command_topic: "lights/20/1/cmd"
  state_topic: "lights/20/1/state"
  state_value_template: "{{value_json.power}}"
  on_command_type: brightness
  brightness_scale: 100
  brightness_command_topic: "lights/20/1/cmd"
  brightness_state_topic: "lights/20/1/state"
  brightness_value_template: "{{value_json.brightness}}"

I do have DLP AC control working for 2-way control also - by this I mean Iā€™m using HA to control my AC, then interfacing with the DLP to facilitate control/display via that interface. 1.95 (in the below image) is the address I gave the aircon control in my DLP.

I did get motor controllers working too for a friend - I can dig into that if people are still looking for that.

Will keep an eye on this topic and happy to answer any questions. :+1:

1 Like

Hi Ben, nice to se you here :smiley:

I created a pull request to implement a buxfix(Current temperature was missing and also had a indexing fault towards the end) for the Heatingmodule MFH06 codes, so if you could implement the PR that would be appreciated. Are you not able to see the PR anymore? I might have deactivated it by accident or something.

I also figured out some of the undocumented codes for DLP`s (Panel Brightness, Eco Mode +++) for some reason that also made its way in to the PR(i am not to familiar with github)

I think it is the same way as i have published here on the forum. I filter the HDL messages by the different answeerback codes for lights, US, sensors thermostats etc. and send it over to the MQTT server.(Thermostats and AC are also saved to the nodered flow context data so that it can be used when changing those messages later from HA as HDL needs the whole config and not only the change for those messages)

The traffic from HA to HDL is also switched by different MQTT topics.

This makes it so that you do not have to do any changes in nodered and all changes are done in the yaml files for the HA interfacing.

That would be cool, where you planning on running only in HA then or still use nodered alongside? I have also looked at those codes slightly and planned to make a addon in HA bypassing nodered stuff but gave it up as i found the nodered route to be more easy as i dont have any HA development skills. Was in the start thinking a auto discovery addon would be great(Names for channels etc could also be taken straight from the channel remarks).

I was also one thime thinking on making a script for nodered that auto created the configuration.yaml file witch would be doable but in the end desided that individual configuration of the yaml files to be quick and good enough.

I dont have DALI but i have DMX for some led strips etc. and they operate same as normal dimmers.
I therfore tought that dali worked on the same codes as a normal dimmer or relay.

Think you forgot to add the flows, would very mutch like to see it if you would be willing to share it?

I think this is the same as i am doing now, you do not have a HDL ac module? I do not own a AC module and my Panasonic heatpump uses extra long IR codes witch is not able to be sendt from HDL. I therfore made a flow in my old openhab setup that listens for the AC command and then sends the answeerback and then forward the message to the Arduino IR sender. It also takes the commands from openhab and update the DLP`s.

When moving to HA i keept my old PI running openhab on the network and only made a flow that works by listening for the HDL answeerback message to update status on the MQTT server. Also commands from MQTT/HA are sendt the same way as a DLP sends the message. (This shold also then work for the persons running an actual HDL AC module)

I was planning on removing my old PI running the Openhab/nodered setup and use the old flow but was not able to. The message on a ā€œHDL raw outā€ does not show up on a ā€œHDL raw inā€ on the same nodered instance. Could you therfore also share the flow on how you use the virtual HVAC nodes so that i might be able to use some of it :smiley:

Would like to see the flows for that if you still have them.(Infact i would like to see all of your HDL flows if you are willing to share :smiley:) Do you remember if you got the % feedback from the module? The way i read the HDL docs it should also report the % status of the blinds on the messages. (Have not yet had time to check the raw Hex messages provided by @Cregeland to check if the % value is reported there but will look into it now.)

1 Like