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

[Feature request] Add capability to switch between heating and cooling modes from UI #86

Closed
GoNzCiD opened this issue Sep 14, 2022 · 19 comments

Comments

@GoNzCiD
Copy link

GoNzCiD commented Sep 14, 2022

This virtual thermostat with PID looks quite brilliant, thanks for your work!

I have a question: Is it also valid for cooling, or it only fits for a heater system?

@T81
Copy link

T81 commented Nov 29, 2022

This can be done by setting ac_mode parameter to True
Read about it in Parameters

@GoNzCiD
Copy link
Author

GoNzCiD commented Nov 29, 2022

Thanks @T81! I suppose it's needed to edit the yaml and restart HA, I mean, there is no interactive switch to change it from the UI, right?
If yes, it should be great to include this as a new FR...

@ScratMan
Copy link
Owner

Yes, you need to restart HA after editing the Yaml. I change the issue to feature request to add a service to switch the mode.

@ScratMan ScratMan changed the title [Question] Is it also valid for cooling? [Feature request] Add capability to switch between heating and cooling modes from UI Nov 29, 2022
@ScratMan
Copy link
Owner

I had a look to this FR, but it's more complex that what it seems.
When setting the ac_mode to true, PID is set to work between -100% and 0% ; but I'm not sure it's compatible with standard AC equipments.
The way it should work strongly depends on the controlled equipment: Is it using a single switch to be on or off with another control to select between heating or cooling ? Or is it using a -100%/100% control range on a unique entity to cool or heat ?

Could someone please provide some examples of AC controlling in HA ?

@ScratMan
Copy link
Owner

I could at least switch on/off AC mode changing the value in the YAML and reloading the integration through the service.

service: smart_thermostat.reload
data: {}

@GoNzCiD
Copy link
Author

GoNzCiD commented Jan 31, 2023

Hi @ScratMan, at least for my case, with heating/cooling floor (with water circuits) it's completely the same output control than for heat mode. Just operate in the opposite way.
So a relay is open/close to manage the valve & pump that flows water. Previously, you have changed the mode in the 'boiler' between heat/cool mode. I don't know if it's the same for the AC systems.

Just for this FR, I understood that the behaivour is the same as when ac_mode is set to true.

@fisiomacao
Copy link

Another one interested on this.
I'm trying to use pid to control my buffer tank temperature with heat pump.
The way it was functioning was with a radio thermostat in my living room, measuring room emperature and turning heat pump on and off.
Problem was my fancoils still work while heat pump is off and buffer tank is cold, and temperature drops a lot.
Now I eliminated that thermostat and have a thermometer reading buffer tank water temperature and a Shelly 2.5 turning heat pump on and off.
And now I have two smart thermostats, one for heating and other for cooling. Why not having only one doing both?

@ScratMan
Copy link
Owner

Could you please provide your configurations for both thermostats so I can look for a way to merge them ?

@fisiomacao
Copy link

fisiomacao commented Mar 31, 2023

- platform: smart_thermostat
  name: Inércia Inverno
  unique_id: inercia_inverno
  heater: switch.shellyswitch25_c45bbe77520f_channel_1
  target_sensor: sensor.inercia_temperature
  min_temp: 20
  max_temp: 65
  ac_mode: False
  keep_alive:
    seconds: 300
  kp: 100
  ki: 0
  kd: 0
  ke: 0
  pwm: 00:10:00
  min_cycle_duration: 120
  sampling_period: 0
  target_temp_step: 0.5
  precision: 0.1
  preset_sync_mode: sync
  boost_pid_off: true
  away_temp: 40
  eco_temp: 45
  boost_temp: 55
  debug: true

- platform: smart_thermostat
  name: Inércia Verão
  unique_id: inercia_verao
  heater: switch.shellyswitch25_c45bbe77520f_channel_2
  target_sensor: sensor.inercia_temperature
  min_temp: 0
  max_temp: 25
  ac_mode: true 
  keep_alive:
    seconds: 300
  kp: 100
  ki: 0
  kd: 0
  ke: 0
  pwm: 00:10:00
  min_cycle_duration: 120
  sampling_period: 0
  target_temp_step: 0.5
  precision: 0.1
  preset_sync_mode: sync
  boost_pid_off: true
  away_temp: 12
  eco_temp: 10
  boost_temp: 5
  debug: true

@fisiomacao
Copy link

Could you please provide your configurations for both thermostats so I can look for a way to merge them ?

Any news?

@AnduriI
Copy link

AnduriI commented Jun 22, 2023

what is the status of that FR? Is it now possible to switch heating/cooling in UI?
I also have a underfloor water circuit with simple on/off-valves. The mode would be selected depending on the temperature coming from the heatpump, but the valves to a room should be opened or closed depending on heating/cooling needed for that room.

@fisiomacao
Copy link

For what I know, nothing changed. I'm using dual smart termostat https://github.com/swingerman/ha-dual-smart-thermostat

@AnduriI
Copy link

AnduriI commented Jun 27, 2023

For what I know, nothing changed. I'm using dual smart termostat https://github.com/swingerman/ha-dual-smart-thermostat

could you please update the link to the correct url as shown in the text? The actual link is from this repo.
The dual smart thermostat is not able to use a single switch to operate heating and cooling. Therefor I can not use it.

@ScratMan
Copy link
Owner

One option would be to add a service to switch AC mode to True or False. I understand that the driving of the boiler (control_output, own and on/off switch) should remain the same (no more -100/0 range for control output as of today with AC mode on); am I correct ?
Switching to AC mode should be done by the service on Smart Thermostat and physically switching the boiler to cooling mode. Right?

@AnduriI
Copy link

AnduriI commented Jun 28, 2023

well I can only specify that for my heating setup: In case it is in heating mode, the sensor for supply temperature is >25°C and in cooling mode it is <22°. That's the criteria I used at the moment to differentiate those to close some valves during cooling where not needed.

@ScratMan
Copy link
Owner

Hi, v2023.7.0-beta1 is available.
It changes the way the AC mode is managed.
When set to ac_mode: true in YAML configuration, the thermostat card will now get both HEAT and COOL modes displayed, allowing to switch between them directly from the HA interface or using core service 'climate.set_hvac_mode. You can also specify a dedicated cooling entity (switch or valve) using the cooler parameter in YAML if your system uses two different devices for heating and cooling.

You can switch to this pre-release by enabling "beta versions" in HACS download screen.
I will make the final release if the pre-release is confirmed to work well. Thanks.

@GoNzCiD
Copy link
Author

GoNzCiD commented Jul 14, 2023

Thanks @ScratMan, I'll try it... but today looks cloudy ^_^.

Edit: I've installed beta1 as you said, but I've noticed there's a beta2. It's ok to try the b1?

@ScratMan
Copy link
Owner

Yes, beta2 adds capability to drive input_number helpers as heater entity, there will be no difference regarding AC mode.

@AnduriI
Copy link

AnduriI commented Aug 30, 2023

@ScratMan I did test yor pre-release quite some time. For me it is working absolutly fine.
The weather here in germany was only few weeks hot enough to make my heating system cool, so it took a little time to test everything. I still have to tune the pid correctly, but I think that is best done during the realy cold period to actually see the changes.

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

No branches or pull requests

5 participants