Quantcast
Channel: Configuration - Home Assistant Community
Viewing all articles
Browse latest Browse all 102976

Using an input_select to change a target sensor?

$
0
0

I have a generic hygrostat set up to control my dehumidifier, it currently looks like this:

  - name: Hygrostat
    humidifier: switch.dehumidifier
    target_sensor: sensor.room_humidity
    min_humidity: 0
    max_humidity: 100
    target_humidity: 60
    device_class: dehumidifier
    min_cycle_duration: 00:05:00
    dry_tolerance: 3
    wet_tolerance: 3
    away_humidity: 55
    away_fixed: true
    sensor_stale_duration: 00:15:00

The sensor “room_humidity” is a helper sensor that takes the average of the (unreliable) dehumidifier’s current humidity and the sensor in the room it’s in, which I try to change when I move it.

I do have an input_select setup to choose which room it is in so was wondering if there’s any way for the input_select to change which sensor is used? Either by (1) changing the target sensor in the generic hygrostat OR (2) changing the sensor used in calculating the “room_humidity” helper.

I.e. (1) When I set the select to “Bathroom” change the hygrostats target to “sensor.bathroom_humidity”. When changed to “Kitchen” change the hygrostats target to “sensor.kitchen_humidity”.
(2) When I set the select to “Bathroom” change the helper sensor to take the average of “sensor.dehumidifier_humidity” and “sensor.bathroom_humidity”. When changed to “Kitchen” change to “sensor.dehumidifier_humidity” and “sensor.kitchen_humidity” etc.

Hope I’ve explained this clearly enough!?

1 post - 1 participant

Read full topic


Viewing all articles
Browse latest Browse all 102976

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>