I have some automations running with sensors involved. for example: a sensor if the window is closed or open (turn of heating when window is open) . I also use a sensor from a mobile phone for an automation (stop loading at 97%).
Both don’t update fast enough. I can’t determine when they update but they are not updating when I want to.
For the mobile sensor, I adjusted the settings in the companion app but with no result.
For the window sensor I don’t know how to make the update happen for, lets say, every 30 seconds.
Any help would be appreciated. I have searched this community but can’t find a solution for this. I’ve read something about templates but the explanation was above my knowlegde level.
It’s much easier to help you if you tell us what they are. Make and model, and ideally how you’ve integrated them into HA. Leaving us to guess makes things needlessly hard
They are tuya based sensors which I have integrated with the cloudsolution (not local tuya). I made an automation to perform an action when the state goes to “open”.
alias: "raamsenor luna open: tado en AC uit"
description: ""
trigger:
- type: opened
platform: device
device_id: 89f76a2beb79dbd009ff75894e622ee4
entity_id: binary_sensor.raamsensor_luna
domain: binary_sensor
condition: []
action:
- device_id: 10eb8f42ed062141b7868c3cc7e1ba08
domain: climate
entity_id: climate.tado_slaapkamer_luna
type: set_hvac_mode
hvac_mode: "off"
- service: media_player.play_media
target:
entity_id: media_player.luna
data:
media_content_id: >-
media-source://tts/cloud?message=Je+raam+staat+open+dus+je+verwarming+en+airconditioning+gaan+uit&language=nl-NL&gender=female
media_content_type: provider
metadata:
title: Je raam staat open dus je verwarming en airconditioning gaan uit
thumbnail: https://brands.home-assistant.io/_/cloud/logo.png
media_class: app
children_media_class: null
navigateIds:
- {}
- media_content_type: app
media_content_id: media-source://tts
- media_content_type: provider
media_content_id: >-
media-source://tts/cloud?message=Je+raam+staat+open+dus+je+verwarming+en+airconditioning+gaan+uit&language=nl-NL&gender=female
mode: single
Does this give you more information to help me out?
Ah… so, you’ve got all the latency of a cloud platform involved.
WiFi isn’t a great choice for sensors anyway, due to the power drain, and cloud services are just a pain. You have a problem somewhere between your sensors, your Internet service, the Tuya cloud service, and HA…
I’d take those sensors and recycle them. Invest in some Zigbee kit instead (not Tuya or Sonoff Zigbee though). You’ll find it much more responsive, and as a bonus the battery life is a lot better.
I invested a lot to have wifi all arround the house and surroudings. Does a change to zigbee imply that I have to invest in a dual system with also a certain amount of accespoints?
I think I am going to check my wifi first. Sometimes some bulbs won’t respond either. If that is fixed, I can rule out wifi problems and concentrate on the sensors. .
Also check if this is an issue related to home assistant or tuya itself via validating sensor state in tuya app, you can use official tuya integration together with tuya app, it won’t break.