Sounds interesting, thank you Blacky! I would also be keen to follow this. My setup looks similar to that of vaclavIII where the original wall switches still control the fan and light through the ZB T2 dual relay module, but Iâm currently unsure how to use that in your blueprint and have not yet started to experiment with that whilst i was dialing in the fan / humidity part.
Happy to be a tester if you need one
Hello Blacky (and Vicusj),
I look forward to seeing your new version of the blueprint. I still tried to work around the independent triggering problem by introducing a âhelperâ so that the automation thinks that the manual triggering is a different switch, but I failed (I honestly didnât have much hopeâŚ). I think the problem I described is fairly general - itâs nice to be able to control switches both by automation and manually - relatively independently.
Thanks to both of you for your comments!
Just to add into this to show there is demand, I can also operate my fan via the original wall switch but also control itâs status via a smart relay.
I have looked into it again. It is a little bit tricky in the one automation but I have come up with a solution that could work. Below this post I am going to post a FAQ on how to make your actual fan switch control the fan manually in âManual Fan Switchâ or the âBypassâ. Try it out and let me know how you go.
Stay tuned as I will do the FAQ now.
Blacky
Thatâs great! Iâll definitely check it out, Iâll let you know. Thanks!
FAQ - How to use the same âFan Switchâ also in âManual Triggerâ or âManual Fan Switchâ
If your wall-mounted physical switch controls the fan and you want to use this same switch to control the âManual Triggerâ or âManual Fan Switchâ functionality while ensuring your automations continue to work, you must create a trigger-based template binary sensor.
Please follow these steps
Step 1: Create a template binary sensor by adding the code below into your âconfiguration.yamlâ file.
The things you will need to change are:
- switch.your_fan_switch_id_here = Replace this with the entity ID of your fan switch used in âFan Switchâ.
The things you can change to your liking are:
- Manual Fan Switch = This is the name you would like to call your new binary sensor.
- fan-clock = The icon used. You can change it to your preference or remove the line icon: mdi:fan-clock if you donât want an icon. To see what icons you can use click here.
template:
- trigger:
- platform: state
entity_id: switch.your_fan_switch_id_here
to: "on"
id: "t1"
- platform: state
entity_id: switch.your_fan_switch_id_here
to: "off"
binary_sensor:
- name: "Manual Fan Switch"
icon: mdi:fan-clock
state: >
{% if trigger.id == 't1' and trigger.to_state.context.parent_id is none %}
on
{% else %}
off
{% endif %}
Step 2: Once you have added it into your âconfiguration.yamlâ file, for it to take effect you have 2 options.
- Go into developer tools / under âYAML configuration reloadingâ, click âTemplate Entitiesâ (recommended).
- OR
- Restart Home Assistant.
Step 3: You can only add it into either the âManual Triggerâ or âManual Fan Switchâ. You can not add it into both choose only one.
- Add the new binary sensor into âManual Triggerâ
OR
- Add the new binary sensor into âManual Fan Switchâ
Step 4: Your done test it out.
Enjoy
Blacky
Back to FAQ: Click Here
Thank you, Iâve now added this and will test over the next few days.
How will this work if the fan Is manually switched on and then the humidity spikes after being turned on manually. Will the automation run or will the manual switch auto off time be used?
In the âManual Fan Switchâ it should take over and the automation should run.
In the âBypassâ it will not run until you turn it OFF.
When you test it can you let us know how you go.
Blacky
Awesome! I have done it all and using the Manual Fan Switch option; I can confirm that the auto-off delay works fine. Will give it a shot along with a shower tonight. (i have no doubts though )
Also, thank you for the guidance on doing my first configuration.yaml edit
Nice one thanks for letting us know.
Now you got the bug and it is why we love Home Assistant⌠you can do what you want
Blacky
Hey, Blacky,
manually turning on the fan as per your modification above works great, thanks for your modification.
P.S. P.S. My fear of a similar problem with the combination of manual switch and wifi controller when controlling the lights did not materialize: I used your blueprint âSwitch - Turn ON & OFF Entitiesâ to associate 3 switches (one switch is master, the other 2 slaves) - everything works fine, mechanical on/off and control by automation.
Thanks a lot for your help!
Thanks for letting us know. It is always good if someone tests it out on a different setup.
It is also good to know it working on my other blueprint. A lot of people have been asking for it. I going to post it up on the other blueprints as a FAQ soon. I am just going through the final testing of the next release for this blueprint.
Blacky
Hi Blacky,
Same here, I tested it all last night and worked like a well oiled machine!!. Much appreciated for your kindness sharing all this with the HA community!
I did a bit of analysis for my own understanding, and came up with this fwiw:
Thank you for this, sadly I got an error while importing the blue print. All I needed was the idea of the derivative anyway. So I got a simplified version running now (just turning up the ventilation and lowering it back down). I have a heat recovery system in house, so Iâm going to do some stuff with multiple sensors. My idea was to use some helpers which will say high humidity, or high CO2 and if anyone of them is high the ventilation will change. Maybe even add people are home or not in the future. Could save significant amounts of energy.
Anyway, Thanks for this! Its a really nice showcase.
Manual Switch seems to be working ok for me as well.
Iâm running on at 1.5% and off at -2.5% seems to be working quite well at the moment.
The fun will start in winter
You need to be on the latest version of HA.
For all the rest, I donât know why you are posting it here. Please stay on topic as this post is for this blueprint. If you would like talk to others about what you are doing then please create another topic.
Blacky
Nice one 2 out of 3, we are going well so far
Your welcome, and thanks for your kind words.
It is a whole lot of fun once you get into it. Good to see your getting the hang of it and thanks for sharing your graph.
Blacky
3 out of 3 YES!
Nice one glad it is all working for you.
You do have another winter mode but the next release will help in the winter months as they can be tricky. It is all done and ready to go, just doing final UI checks.
Blacky
New Feature
-
Manual Trigger - This feature allows you to manually trigger the automation. It replaces the humidity derivative settings in either âDefault - Summer Modeâ or âWinter Mode,â configurations. Turning it ON initiates the automation process, and turning it OFF starts the time delay. Note that auto triggers can and will override the manual trigger option if triggered.
This feature can operate with or without a humidity sensor, which is particularly useful if the humidity sensor malfunctions, allowing time for repairs and reducing stress levels. Additionally, it can initiate the fan to turn ON before a shower, aiding in humidity removal before the auto triggers take over. It is designed with good spouse approval in mind.
Maintenance
- Update deprecated code for light control in kelvin.
Bugs Fixed
- Fixed bypass - It would turn fan OFF if bypass was disabled but bypass entity was entered in and you turned bypass entity OFF.
- Fixed HA restart when using manual switch. It will now wait for the set time delay when HA restarts.
If you like this blueprint? Consider hitting the button in the top post
If you like my blueprints, and would like to show your support or just say thank you? Click Here
Enjoy
Blacky
Looking great! I upgraded to this version, most of the old settings carried over no problem, and everything is working fine for me, thanks Blacky!