chamberlain2007 / aprilaire-ha

A custom component for Home Assistant to interact with Aprilaire thermostats.
MIT License
12 stars 5 forks source link

Humidifier & Fresh Air Intake Control #14

Closed ShinobiAlchemist closed 1 year ago

ShinobiAlchemist commented 1 year ago

First I just want to say...THANK YOU. Once I got this installed and setup I was able to implement a lot of automation ideas I had in my head just around heating and A/C alone.

My 8920W is also connected to my fresh air intake and humidifier.

Are there currently any plans to implement control of these components? Is there anything I could do to assist in development of the feature?

chamberlain2007 commented 1 year ago

Hi, glad I can help! Nice to hear you're getting good use out of it.

Can you tell me what you are looking to do with the humidifier and fresh air? Are you looking to set the humidifier/dehumidifier setpoints? And for fresh air, is it the 3/24 hour event that you're looking to trigger?

If those are the items, I should be able to add them, the problem is just that I don't have those components, so I can't really test. The more detail you provide the better, so that I can cross-reference with the protocol docs.

ShinobiAlchemist commented 1 year ago

Sure - so I have an Airthings Air Quality Unit and I want to build automations using certain values.

Examples:

If CO² exceeds X value, turn on fresh air to lower levels. If humidity exceeds X inside, and air is x drier outside, turn on fresh air. If outdoor temp exceeds indoor temp by X, turn off fresh air.

(In either case, since there's no permanent on option for fresh air, I'd use the 24-hour mode as a proxy and then have the automation set it to Off after reaching whatever set point.)

As I'm typing this, I realize that more of my ideas revolve around fresh air than humidity, which I usually leave on and set at a specific value anyway. It would still be nice to control though.

chamberlain2007 commented 1 year ago

Gotcha, I should be able to get those functions added. Just working on some code quality items currently, but that shouldn't be a big lift.

For humidity, if your Aprilaire system has the humidity sensor installed, you should see it listed as a sensor. Controlling, I should be able to do that with the climate entity, but interestingly it only supports humidity, not dehumidifier in the climate entity. So it might end up as a different entity. I'll think that through.

ShinobiAlchemist commented 1 year ago

Yes, I do see it as a sensor. (Also my model is 8840. They look so similar haha.)

Screenshot for reference!

Screenshot_20230329-121115

SensehacK commented 1 year ago

It seems that 8920W is not your home model. It is 8840 which has the option for Home Automation.

I have 8920W which doesn't have the home automation option. Spoke with Aprilaire customer representative.

ShinobiAlchemist commented 1 year ago

It seems that 8920W is not your home model. It is 8840 which has the option for Home Automation.

I have 8920W which doesn't have the home automation option. Spoke with Aprilaire customer representative.

Thanks love. I did address that in my previous comment 🙂

SensehacK commented 1 year ago

Just pointing it out for someone who has similar setup and spent about 1 hour figuring out why some option isn't present for their Thermostat.

Make it index friendly as well :)

ShinobiAlchemist commented 1 year ago

Just pointing it out for someone who has similar setup and spent about 1 hour figuring out why some option isn't present for their Thermostat.

Make it index friendly as well :)

Good point!

chamberlain2007 commented 1 year ago

Thanks for the input y'all. I did ask Aprilaire if they could provide a list of the thermostat models and their corresponding model number from the protocol, but they did not have that information. If you (or anyone) is able to get a thermostat added but the model doesn't show up on the device page, let me know with the number that is shown and I can get it added to the table.

chamberlain2007 commented 1 year ago

@ShinobiAlchemist I have completed the humidity/dehumidity, fresh air and air cleaning.

Please test this if possible with your devices by enabling Beta mode for the integration and installing the latest. https://hacs.xyz/docs/faq/beta/

I don't have humidity or air cleaning on my physical system, so while I tested against a mock server, I don't have a physical device to test those against.

Please let me know if you have a chance to test and if there are any issues. Ideally I would like to release this 1-2 weeks from now.

SensehacK commented 1 year ago

I wish I could test this out but the model I have doesn't support Automation but it has Humidity and air cleaning. Cheers though. Excellent progress.

I also was able to connect Google Assistant SDK + Home Assistant (Automation + Scripts) + Generic thermostat. I'll create a config in the future and maybe you could include that as an extra link for folks having 8920W Aprilaire.

ShinobiAlchemist commented 1 year ago

I've been running the beta since the evening I got the message:

Humidifier

I moved the humidifier slider to 35 and it changed on the unit but the app went back to reflecting 45. After that sliding it didn't produce any changes at all on the unit.

Fresh Air

I'm still not able to control that one.

A/C

Normal

Is there anything special you'd like me to do to help you troubleshoot?

On Tue, Apr 25, 2023, 7:30 PM Matthew FitzGerald-Chamberlain < @.***> wrote:

@ShinobiAlchemist https://github.com/ShinobiAlchemist I have completed the humidity/dehumidity, fresh air and air cleaning.

  • Humidity will appear on the climate entity detail if supported
  • Dehumidity is a new service as home assistant does not yet support humidity ranges in the UI like it does with temperatures
  • There is a service for triggering and canceling fresh air ventilation and air cleaning

Please test this if possible with your devices by enabling Beta mode for the integration and installing the latest. https://hacs.xyz/docs/faq/beta/

I don't have humidity or air cleaning on my physical system, so while I tested against a mock server, I don't have a physical device to test those against.

Please let me know if you have a chance to test and if there are any issues. Ideally I would like to release this 1-2 weeks from now.

— Reply to this email directly, view it on GitHub https://github.com/chamberlain2007/aprilaire-ha/issues/14#issuecomment-1522674371, or unsubscribe https://github.com/notifications/unsubscribe-auth/AR54WAVD6JKP3GIHBA76GO3XDCCDTANCNFSM6AAAAAAWLJLRJQ . You are receiving this because you were assigned.Message ID: @.***>

chamberlain2007 commented 1 year ago

Thanks for testing it out!

ShinobiAlchemist commented 1 year ago

Absolutely!

In the app meaning via Home Assistant on my phone.

Yes, where I'm looking says target humidity. The thermostat appears to respond immediately to me moving the slider the 1st time just fine but there seems to be a delay in HA reporting back the new status, and allowing me to pick a different value.

The only error that I've seen happens shortly after restarting HA:

This error originated from a custom integration.

Logger: custom_components.aprilaire Source: runner.py:179 Integration: Aprilaire (documentation, issues) First occurred: 8:17:40 PM (1 occurrences) Last logged: 8:17:40 PM

Received NACK for attribute 7

The humidity service works fine. The fresh air service works fine. Supported_features: 4125

On Sat, Apr 29, 2023, 3:44 PM Matthew FitzGerald-Chamberlain < @.***> wrote:

Thanks for testing it out!

  • When you say "in the app" do you mean in the Aprilaire app? Are you sure that you are looking at the current humidity setpoint, and not the current humidity? Can you try using the Climate: Set humidity service directly? Are there any errors in the HA log when you do this?
  • For fresh air, do you see the new services in the HA developer tools? Should say Aprilaire: Trigger fresh air event and Aprilaire: Cancel fresh air event. What happens when you try to use the services? Can you go to the climate entity in the developer tools and tell me what the climate entity shows for supported_features?

— Reply to this email directly, view it on GitHub https://github.com/chamberlain2007/aprilaire-ha/issues/14#issuecomment-1528888671, or unsubscribe https://github.com/notifications/unsubscribe-auth/AR54WAQ4QXJ5KSNWCSS4ACTXDWKTTANCNFSM6AAAAAAWLJLRJQ . You are receiving this because you were mentioned.Message ID: @.***>

chamberlain2007 commented 1 year ago

Ah, thanks for that info. A close reading of their docs revealed that setting the humidifier/dehumidifier setpoints doesn't trigger the COS for those attributes, which is strange. I will add an explicit read when they are changed which should work fine. Keep an eye out for a new version in HACS in the next day or two.

ShinobiAlchemist commented 1 year ago

Will do!

On Mon, May 1, 2023, 8:57 AM Matthew FitzGerald-Chamberlain < @.***> wrote:

Ah, thanks for that info. A close reading of their docs revealed that setting the humidifier/dehumidifier setpoints doesn't trigger the COS for those attributes, which is strange. I will add an explicit read when they are changed which should work fine. Keep an eye out for a new version in HACS in the next day or two.

— Reply to this email directly, view it on GitHub https://github.com/chamberlain2007/aprilaire-ha/issues/14#issuecomment-1529865621, or unsubscribe https://github.com/notifications/unsubscribe-auth/AR54WAQG6HKNB37PGND6BG3XD7MNVANCNFSM6AAAAAAWLJLRJQ . You are receiving this because you were mentioned.Message ID: @.***>

chamberlain2007 commented 1 year ago

@ShinobiAlchemist I've pushed a new beta release which you should be able to update to in HACS. Let me know if this resolves the humidity issue.

Apart from the humidity issue, is there anything else outstanding regarding this issue?

ShinobiAlchemist commented 1 year ago

Yes the humidity issue is resolved.

The temperature output is behaving oddly though. I changed it down to 69° and the thermostat responded correctly. However, when I changed it back up to 75° the thermostat set at 74 and when I changed it to 76, the thermostat set at 75.

On Mon, May 1, 2023, 5:32 PM Matthew FitzGerald-Chamberlain < @.***> wrote:

@ShinobiAlchemist https://github.com/ShinobiAlchemist I've pushed a new beta release which you should be able to update to in HACS. Let me know if this resolves the humidity issue.

Apart from the humidity issue, is there anything else outstanding regarding this issue?

— Reply to this email directly, view it on GitHub https://github.com/chamberlain2007/aprilaire-ha/issues/14#issuecomment-1530679164, or unsubscribe https://github.com/notifications/unsubscribe-auth/AR54WASUKF3BUS65IDAT5GLXEBIYBANCNFSM6AAAAAAWLJLRJQ . You are receiving this because you were mentioned.Message ID: @.***>

ShinobiAlchemist commented 1 year ago

I also noticed this morning that the target temperature section lost it's current value and arrow buttons:

unnamed

On Wed, May 3, 2023 at 7:22 AM Kadeem Hinton @.***> wrote:

Yes the humidity issue is resolved.

The temperature output is behaving oddly though. I changed it down to 69° and the thermostat responded correctly. However, when I changed it back up to 75° the thermostat set at 74 and when I changed it to 76, the thermostat set at 75.

On Mon, May 1, 2023, 5:32 PM Matthew FitzGerald-Chamberlain < @.***> wrote:

@ShinobiAlchemist https://github.com/ShinobiAlchemist I've pushed a new beta release which you should be able to update to in HACS. Let me know if this resolves the humidity issue.

Apart from the humidity issue, is there anything else outstanding regarding this issue?

— Reply to this email directly, view it on GitHub https://github.com/chamberlain2007/aprilaire-ha/issues/14#issuecomment-1530679164, or unsubscribe https://github.com/notifications/unsubscribe-auth/AR54WASUKF3BUS65IDAT5GLXEBIYBANCNFSM6AAAAAAWLJLRJQ . You are receiving this because you were mentioned.Message ID: @.***>

-- Kadeem F. Hinton

@.***

This electronic message contains information generated solely for the intended recipients. Any unauthorized interception of this message or the use or disclosure of the information it contains may violate the law and subject the violator to civil or criminal penalties. If you believe you have received this message in error, please notify the sender and delete the email immediately.

chamberlain2007 commented 1 year ago

I'll check to make sure, but this is most likely due to the way that the Aprilaire protocol works with Celcius vs Fahrenheit. The protocol only accepts Celcius values with a resoluton of 0.5C, so there are values that are possible in the UI that are not possible to represent correctly. Additionally, the thermostat can modify the requested temperature to enforce deadband limitations.

chamberlain2007 commented 1 year ago

@ShinobiAlchemist Good catch, that was actually a long-standing rounding error. Should be fixed in the latest beta.

Could you share the screenshot in Github? It won't come through when you email a comment. If it's not related to the humidification/fresh air work, could you please open a new issue? I'd like to get this release out the door.

ShinobiAlchemist commented 1 year ago

It's related. I've updated the pic in the previous comment just.

chamberlain2007 commented 1 year ago

Looks like in your screenshot that it is in Off mode, in which case it is correct to not show the temperature controls.

ShinobiAlchemist commented 1 year ago

HA! Rookie mistake. In that case I think we are good to go!

chamberlain2007 commented 1 year ago

Excellent! Bit more testing on my end, but expect the new version to be released in the next few days.

Thanks a ton for your help with this!

chamberlain2007 commented 1 year ago

This has been deployed as version 0.6.0. Thanks again for your help!