Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Proposed fan support #12

Open
wants to merge 5 commits into
base: master
Choose a base branch
from

Conversation

allengray
Copy link

In particular to @jdhorne and @rapamatic - Pls check these for sanity. I haven't checked to see whether I can merge them in on my own.

These changes create a new action to set the fan hold and rely on the existing 'resume' action to return to normal.

Works well for Ecobee3, I don't have an earlier 'Smart' unit to test on.

This was only impacting the below log message but it fixes some confusion.
Only obvious way in Ecobee API to do this, needs to submit current hot and cold setpoints as a hold but with fan=on
Added action for fan support plus an explicit log message when unimplemented calls are made instead of quietly swallowing these.
Enum used for mode translation and capture the MinOnTime published to device state
Publish the fanMinOnTime as device state, this should be made writable.
@jdhorne
Copy link
Collaborator

jdhorne commented Dec 4, 2017

I'll have to defer to @rapamatic for testing with an Ecobee Smart.

@rapamatic
Copy link
Contributor

I can try to take a look at it this week with my smart... I don't do a lot of control of the fan settings - I just leave them in X minutes per hour mode, but I can test this

@rapamatic
Copy link
Contributor

Just doing some quick remote testing, it correctly shows fan status (is this new? I don't know) but I'm not able to change fan status, either on my older Smart or my newer 3....

I can do more detailed testing tonight - somewhat limited in what I can do from work.

@rapamatic
Copy link
Contributor

Scratch the above comments - I hadn't downloaded the correct version of the plugin!

One suggestion would be to add the fanMinOnTime custom state to ecobee smart devices also - they have that capability.

Fan status was correctly reported for my ecobee 3 and my smarts.

However, I had issues changing fan status... specifically, going from auto (my default state) to fan on also set a hold temperature. I was able to go from a forced fan on state back to auto (essentially sending the resume schedule command).

Here's my log entries:

Dec 8, 2017, 9:39:32 AM
   Enabling plugin "Ecobee 1.1.1"
   Starting plugin "Ecobee 1.1.1" (pid 68915)
   Started plugin "Ecobee 1.1.1"
   Ecobee                          added remote sensor G5PH
   Ecobee                          added smart thermostat 173448830954
   Ecobee                          added smart thermostat 150992022817
   SQL Logger                      adding column "fanminontime" to table device_history_44612195 ("Ecobee: Office")
   Ecobee                          added thermostat 314784831377

Dec 8, 2017, 9:40:02 AM
   Ecobee                          resume normal program to set fan to OFF
   Ecobee                          sent resume_program to 150992022817
   Ecobee                          sent "Ecobee: Master" set fan hold to auto
   SQL Logger                      adding column "hvacfanison_ui" to table device_history_882197752 ("Ecobee: Master")

Dec 8, 2017, 9:40:56 AM
   Ecobee                          resume normal program to set fan to OFF
   Ecobee                          sent resume_program to 314784831377
   Ecobee                          sent "Ecobee: Office" set fan hold to auto
   SQL Logger                      adding column "hvacfanison_ui" to table device_history_44612195 ("Ecobee: Office")

Dec 8, 2017, 9:41:17 AM
   Automatic OBD-II                FYI - Exception caught getting vehicle info: 'latest_location'
   Ecobee                          leave cool at: 74.0F and leave heat at: 68.0F and set fan to ON
   Ecobee                          sent "Ecobee: Master" set fan hold to on

Dec 8, 2017, 9:42:10 AM
   Ecobee                          leave cool at: 75.0F and leave heat at: 69.0F and set fan to ON
   Ecobee                          sent "Ecobee: Office" set fan hold to on
   Automatic OBD-II                2014 Honda Odyssey Touring Elite:ignition:off @ 2017-12-08 09:42:20
   Automatic OBD-II                Location unknown, geocode failed: list index out of range

@rapamatic
Copy link
Contributor

Looking through the API specs, I think we can send a fan only hold:

The two properties Event.isTemperatureAbsolute and Event.isTemperatureRelative indicate what type of temperature hold is being used. If both of these are false then the event is not using any temperature control, and thus it is a fan hold. This same logic applies when reading the running event off of a thermostat object.

The link here has info on how to structure the query with those parameters, something like this:

{ 
selection: { 
selectionType: 'thermostats', 
selectionMatch: deviceId 
}, 
"functions": [{ 
"type": "setHold", 
"params": { 
"isTemperatureRelative": false, 
"isTemperatureAbsolute": false, 
"fan": "on" 
} 
}] 
}

But you do need to send at least some dummy value for the hold temps...

@allengray
Copy link
Author

That does look more promising, I wonder if that will have the desired simple 'Fan is on' indication on the thermostat display as well instead of the current hold with fan and temps.

I'll be anxious to try that approach, can check it this weekend.

@allengray
Copy link
Author

That works, adding the 'isTemperatureRelative' and 'isTemperatureAbsolute' params gives it the preferred behavior of just turning the fan on without the setpoint hold. I'll update the method call to just use that.

I'll commit that change plus adding the MinOnTime to the smart series t-stat.

Not incidentally - Using the 'web inspector' debugger in my web browser while using Ecobee's web app shows that same syntax. I should have thought of that sooner but it does give an additional validation that we're not making an unsupported API call .. it's just a badly documented one.

@rapamatic
Copy link
Contributor

Looks like someone else on the indigo forums is interested in this feature too, so good timing to be working on it. I'd be happy to test any changes you may have made, so we can get this update pushed out.

FlyingDiver referenced this pull request in IndigoDomotics/indigo-ecobee-plugin Jul 19, 2018
From the original project - Fan hold support
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants