Quantcast
Channel: Configuration - Home Assistant Community
Viewing all 105566 articles
Browse latest View live

Issue with Custom Domain CNAME validation & freedns.afraid.org

$
0
0

I am using freedns to manage my domain, and I am trying to add CNAME entries for my custom domain. The CNAME entries appear when I test the domains on dnschecker.com, but the homeassistant cloud webpage is still unable to validate. Any tips?

1 post - 1 participant

Read full topic


Prevent modification of a lock entity while the door is moving

$
0
0

I have a garage door I can control via zigbee2mqtt but I am having some issues to make it work smoothly.
TLDR after a button press I need to prevent any further button press while the door is moving, I can only use a timer after a button press to know if it’s moving.
Best option would actually be while the door is moving, toggling the lock entity should trigger the push button twice with 1sec interval, first will stop the movement second will reverse the movement.

I did see the Lock Template entity and using it without the optimistic setting I do have a reliable on/off status, but still, any attempt to mistakenly open it twice results in the garage door stopping.

I’m not fixed on one or the other, but for me stopping the garage door mid-way is useless, so I would really like to either prevent any press of the button while the door is moving, or double any press with 0.5 sec interval inbetween to allow the motor to stop then reverse…

My garage exposes a single contact as a binary sensor (closed is closed, but “open” might be opening or fully open) as well as a trigger exposed as a switch, but this switch is let’s say… complex in it’s behaviour, it remains on or of and depending on what the door is doing it triggers either a stop or a close or an open of the door.

I found a reliable way to sue the switch regardless of it’s position on or off : doing 2 toggles in quick sucession will always make the door register an action, and it will either ropen or close or stop depending on the position.

So what I’m now trying to achieve is to prevent stopping the door mid-way…
I tried relying on the on/off state of the trigger button but no luck here, I’m still able to stop the door in the middle…

I’m imagining many ways of doing this, with mqtt I could create a fake position, and automations to increment/decrement the position, I could create a simple input_boolean “door is moving” instead and try to set/unset it in the template lock/unlock actions and in automations with complex conditions depending on the actual contact of the door and when the movement has started and such…

I see many complicated solution but I can’t wrap my head around anything simple that would make the actual lock entity just “work” with no stopping in the middle…

I thought it’s not so hard :

  • any action on the door means switch.toggle+wait0.5s+switch.toggle again
  • if door is in movement, the first action will only stop the door, so double the action.

This is because on the template lock entity if it directly manipulates the switch entity, you can end up, by mistake, with the door stuck in the middle while given the number of lock/unlock I thought the door should be closing…

As of today my only solution is to have my CCTV camera pointed at my garage door on the same dashboard as the lock button, this way I can see that I’m waiting for something to happen while the door is simply stopped in the middle unmoving… This happens to me regularly… Trying to solve that frustration, I saw many people offering many templates and stuff none of them would seem to solve my current gripe.

I’m also taking other advices f you have, I mean if buying a vibration sensor to stick on my garage motor is the best way to get a “door is moving” thing that I can actually rely upon then this is what I’d do…

2 posts - 2 participants

Read full topic

Smartwings Roller Blinds Zwave - How to Sync?

$
0
0

I’ve installed 11 smartwings zwave blinds and hooked them up to HA. They work great and extremely easy to setup.

Now i’d like for the blinds in the same room to sync up when they roll up/down. I’ve tried zwave multicast… but it doesnt’ seem to have much of an impact on their sync.

They open up almost sequentially… even when hit by the multicast.

Does anyone have any ideas on another approach?

1 post - 1 participant

Read full topic

SMTP with picture attachement not working

$
0
0

Hi,
I’m really going crazy with this topic. Spend a lot of time with paths, / and no /, ‘’ and no ‘’ etc - lot of different configs but nothing working.

I’m using Home Assistant OS in a virtual machine and try to send a pic (taken by cctv cam) as email attachement.

First of all, picture is taken with this automation:

action: camera.snapshot
metadata: {}
data:
  filename: /config/www/tmp/reolink.jpg
target:
  device_id: 123

delay:
  hours: 0
  minutes: 0
  seconds: 10
  milliseconds: 0

and then the part where the email is sent:

action: notify.gmail_info
metadata: {}
data:
  title: test
  target: abc@mail.com
  message: "123"
  data:
    images:
      - /local/tmp/reolink.jpg
    html: >
      <html> <img src="cid:reolink.jpg"> </html>

Email is arriving, but w/o a pic in it. Same when I change the path from /local/tmp/ to /config/www/tmp

And log file is telling me

Logger: homeassistant.components.smtp.notify
Source: components/smtp/notify.py:279
integration: smtp
First occurred: 7:23:32 AM (1 occurrences)
Last logged: 7:23:32 AM
Attachment /local/tmp/reolink.jpg not found. Skipping

This automation for sending the pic via HA mobile app is working

action: notify.mobile_app_iphonejos
metadata: {}
data:
  message: test
  data:
    attachment:
      content-type: jpeg
      url: /local/tmp/reolink.jpg

There the pic is attached

In configuration.yaml i have

homeassistant:
  allowlist_external_dirs:
    - '/config/www/tmp'

I’m really out of clues and going crazy, where the problem could be

edit:
additional info: pic is visible as it should be in
http://HAIP:8123/local/tmp/reolink.jpg

1 post - 1 participant

Read full topic

OneDrive integration - backup other files

$
0
0

Is it possible to use the OneDrive integration to backup other files? For example, motion detections from a camera? Where is the “graph” folder located on internal storage?

1 post - 1 participant

Read full topic

Blueprint SENSOR Template with trigger_variables

$
0
0

Greetings,
I’m trying to add a new Template BinarySensor Blueprint that has a “trigger: template”.
Unfortunately it seems that neither “variables” and “trigger_variables” keys can be used to pass BP’s input variables to it. The second one returns an error that says something like “trigger_variables keyword is not_valid/unknown for BP”.

This trigger has to do something like (but more complex) “value_template: {{ states(xxxxxxxxx) >= 18 }}” where “xxxxxxxx” is the value stored in the INPUT section of the blueprint that neither “variables” and “trigger_variables” can’t works.

It is possible? :thinking:
Thx

1 post - 1 participant

Read full topic

Remove entity by automation

$
0
0

Hey,
I’d like to know if it’s possible to automate the removal of entities.
I have an app with which I manage my work schedule, with that I can add this schedule to my Google calendar which will be added as separate work calendar.
When I do changes to this and upload them to my Google Cal, it removes the old calendar and adds the new one.
In HA, the sync doesn’t work as flawless, the old work calendar entity becomes unavailable and a new one will be added as calendar.work_2.
Naturally that messes with automations and I’d like to remove the old entity automatically when it becomes unavailable and refresh the Google calendar service/rename the new entity.

Is that possible?

1 post - 1 participant

Read full topic

Database corrupts every few hours, reboot shows no error and a working database

$
0
0

Hello,

2 days ago I upgraded my Raspberry Pi 4 (with SSD) to a Raspberry Pi 5 with NVME SSD and transferred it using a backup. Everything went smoothly.

Now I’m getting a corrupt database for the third time in 36 hours and Home Assistant is still online but no longer responsive.

Logs say that the database got corrupted and renamed so Home Assistant can boot up again.

But if I restart the Home Assistant (the only thing that helps is unplugging the plug and plugging it back in), I can’t find any renamed database - only the original one - and all historical the data is still there.

I even read up a bit on SQL and installed the SQLLite Web Addon and checked it using “pragma integrity_check;”. No errors are displayed here.

So after I rebooted the Home Assistant, it works perfectly again as if nothing had happened and all my data is still there.

Does anyone have an idea what I can do here?

Can this be a Hardware related Error (since new Pi5 + new SSD)?

Thanks

Michael

1 post - 1 participant

Read full topic


Error while processing template renders=2

$
0
0

Hi,

Recently I’m getting multiple errors on diferentes templates while processing the template. Below you can find the log:

> Logger: homeassistant.helpers.event
> Source: helpers/template.py:645
> First occurred: 2:04:12 AM (4 occurrences)
> Last logged: 2:04:12 AM
> 
> Error while processing template: Template<template=({% set T1 = states.climate.termostato_salon.attributes.temperature | float %} {% if T1|is_number %} {{ (T1 ) | round(1) }} {% else %} {{ this.state }} {% endif %}) renders=2>
> Traceback (most recent call last):
>   File "/usr/src/homeassistant/homeassistant/helpers/template.py", line 643, in async_render
>     render_result = _render_with_context(self.template, compiled, **kwargs)
>   File "/usr/src/homeassistant/homeassistant/helpers/template.py", line 2756, in _render_with_context
>     return template.render(**kwargs)
>            ~~~~~~~~~~~~~~~^^^^^^^^^^
>   File "/usr/local/lib/python3.13/site-packages/jinja2/environment.py", line 1295, in render
>     self.environment.handle_exception()
>     ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^^
>   File "/usr/local/lib/python3.13/site-packages/jinja2/environment.py", line 942, in handle_exception
>     raise rewrite_traceback_stack(source=source)
>   File "<template>", line 1, in top-level template code
>   File "/usr/src/homeassistant/homeassistant/helpers/template.py", line 2375, in forgiving_float_filter
>     return float(value)
> jinja2.exceptions.UndefinedError: 'homeassistant.util.read_only_dict.ReadOnlyDict object' has no attribute 'temperature'
> 
> The above exception was the direct cause of the following exception:
> 
> Traceback (most recent call last):
>   File "/usr/src/homeassistant/homeassistant/helpers/template.py", line 760, in async_render_to_info
>     render_info._result = self.async_render(  # noqa: SLF001
>                           ~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^
>         variables, strict=strict, log_fn=log_fn, **kwargs
>         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
>     )
>     ^
>   File "/usr/src/homeassistant/homeassistant/helpers/template.py", line 645, in async_render
>     raise TemplateError(err) from err
> homeassistant.exceptions.TemplateError: UndefinedError: 'homeassistant.util.read_only_dict.ReadOnlyDict object' has no attribute 'temperature'

And this is my template sensor:

{% set T1 = states.climate.termostato_salon.attributes.temperature | float %}

{% if T1|is_number %}
  {{ (T1 )  | round(1) }}
{% else %}       
  {{ this.state }}
{% endif %}

Is there any thing wrong with the template? It’s working perfectly most of the time.

2 posts - 2 participants

Read full topic

Logbook shows same value as changed when datetime

$
0
0

A sensor value is returned as a datetime object for when a battery was last fully charged.

Updates are every 10 seconds and this value may stay the same for a day, or longer when overcast, until the battery is next fully charged.

Another sensor that returns a string value, correctly updates only when that value changes:

Many posts describe blocking datetime values from being recorded, which I do block a number of them, not this one.

This particular value is interesting to know when the battery was last fully charged, but logbook does not work properly for this type of value.

Has anyone had success with a datetime logbook value? Any clues as to what can be done?

I’m thinking next clue will be to look at code to see how a change is determined for logging.

Related to this, some other posts also discuss when a new logbook is created it does not show the initial value when the logbook was created. The initial value should be the next update when the sensor value changes from ‘undefined’ to ‘defined’, with that defined value being the first value logged.
Current behaviour results in the sensor value when the logbook is created is never logged.
There is a battery sensor that may not change for weeks or months, meaning the predominant value for a long period is never logged. /
This leaves a blank logbook that looks like it’s not working properly by not showing the current long-lived value of the sensor.

2 posts - 2 participants

Read full topic

Help with Scrape for mp3 news file

$
0
0

Hi all;

I am trying to murder my google-home speaker and replace it with my VoicePE.

The only two things we use google speaker is in the morning “Play ABC News” and “play radio station”. I have resolved radio station.

I finally found the mp3 url, but the url itself changes daily, but it’s position on the website does not.

However my attempts to follow scrape tutorials have no produced anything (mostly jsoup etc).

Can anyone assist?

Target website;

https://www.abc.net.au/news/2025-02-19/top-stories-from-abc-news/104954222

From that website, a url similar to this will appear (the last letters change every few hours); the src one;

<video class="jw-video jw-reset" tabindex="-1" disableremoteplayback="" webkit-playsinline="" playsinline="" src="https://mediacore-live-production.akamaized.net/audio/02/6r/Z/br.mp3"></video>

I don’t know anything about CSS or HTML things to zero in on this.

Can someone please assist?

Thanks

1 post - 1 participant

Read full topic

HAOS on VM, PiHole on Unraid -- PiHole integration not working

$
0
0

Hey all!

Was wondering if anyone with a similar configuration has this working.

My HA runs in a VM on one machine, with my PiHole running in a docker on another (Unraid).

PiHole works great, but the HA integration can’t find the PiHole instance. Have already tried all sorts of port combinations (looking at the settings in Unraid) when installing the integration to no avail. Basically trial and error cause I have no real idea what I’m doing .

Any tips?

1 post - 1 participant

Read full topic

Reverse proxy with changing internal IP addresses in Docker

$
0
0

Hi!

I have HA and a reverse proxy (tsdproxy in my case, but this should not matter) both installed at the same host with Docker. Proxy requests to HA seem to have their origin from the Docker internal IP address. Therefore, I use this address as trusted IP:

http:
  use_x_forwarded_for: true
  trusted_proxies:
    - 172.18.0.2

This does work. But after a reboot of the host, Docker does change IP addresses, that’s why it fails after a reboot. In my opinion, there are three possible solutions for this problem:

  1. Add the proxy to the Docker host network (I do not want this).
  2. Add all private networks to trusted proxies (ugly and security concerns).
http:
  use_x_forwarded_for: true
  trusted_proxies:
    - 10.0.0.0/8
    - 172.16.0.0/12
    - 192.168.0.0/16
  1. Use the name of the Docker network (preferred way).
http:
  use_x_forwarded_for: true
  trusted_proxies:
    - tsdproxy

Unfortunately, the latter version does not work. So my question is, what is the best way to solve this problem? I am happy about your opinion! :slight_smile:

Have a nice day,

Tom

1 post - 1 participant

Read full topic

Scripting: string manipulation

HAOS Add-on container can't access /dev/tty0

$
0
0

I am trying to write an add-on to let HAOS users view dashboards using the native HDMI port of their RPi device.
I do this by creating a docker container with Xorg window system, Openbox window manager, and Luakit browser.

I now have it all working perfectly in a manually-built and run docker container.

When I convert that to a HAOS add-on, it builds fine but it is unable to launch Xorg since X requires access to /dev/tty0 and HAOS won’t allow it.

I tried changing various combinations of options to Xorg to hopefully avoid the need for a tty device (e.g., -retro, -nobackground, -noreset, -nolisten, -novtswitch, -keeptty, etc.).

Similarly, I tried adding the “NoTrapSignals”, “DontVTSwitch” and “DontZap” options to xorg.conf.
But none of that helped.

I tried adding /dev/tty0 to the devices section in config.yaml to no avail.
I tried opening up security by adding apparmour:unconstrained to security_opt – but again that failed.

So I am stuck between a rock and a hard place:

  • Xorg stubbornly requires terminal access
  • HAOS stubbornly refuses such access

I need one of them to relent :slight_smile:
Any suggestions?

AND YES - I know that there are people who believe that the HAOS server should not be used to display dashboards but others of us don’t want to add additional PCs/tablets/RPis to our network and like the idea of seeing dashboards right on the HA server.

1 post - 1 participant

Read full topic


Script description string to dictionary?

$
0
0

I’m reading a ToDo list that contains a dictionary in the description entry, how do I in script convert the string to a useable dictionary and conversely back to a string in another script.

Effectively I’m using the ToDo list as a keyed store with a data block attached, I just need to decipher the data block.

Update: Issue resolved… simply implement dict() around string.

1 post - 1 participant

Read full topic

Dynamically fill entity picture?

$
0
0

This is something I have done nothing of, and need to learn.

I simply want to dynamically fill this image, with the sensor data.

lpg

I have tried to create a simple SVG overlay but it didn’t seem to work. Is the only way to do this using SVG overlays?

Thanks

type: picture-elements
image: /local/images/lpg.svg
elements:
  - type: image
    entity: sensor.weigh_test_hx711_value
    image: local/images/lpg.png
    style:
      top: 210%
      left: 50%
      width: 100%
      height: |
        [[[
          return (states['sensor.weigh_test_hx711_value'].state / 100) * 100 + '%';
        ]]]

1 post - 1 participant

Read full topic

Entities to Areas

$
0
0

Hi, I really hope someone can help, this is driving me mad. Fairly new HA user but have configured a lot. However, I cannot, whatever I do, get entities to show under an area. If I list all the entities in settings I can see them all assigned to areas. The devices are assigned to areas. But, if I go to an Area setting it says “There are no entities linked to this area.”. I absolutely cannot fix it, tried everything I can think of (apart from start adding manual config in the file which seems not required really). Also I noticed that if I try and switch the ‘use device area’ to disabled and hit update, it doesnt save. It is just shown as enabled again. Driving me mad now as I cannot use Area cards to show controls. Thanks, Paul.

1 post - 1 participant

Read full topic

Two helpers aren't link together

$
0
0

I’ve created two helpers, one is an input, second is a template.


Second:

When I open the switch template in UI and toggle the state, I can see that the input state changes, but when I change the input state, the template doesn’t update.

I can’t use input_boolean in the thermostat helper, so I imagined I could use a switch template for it.

How can I bind those two together, so that when the input state changes the template updates

3 posts - 2 participants

Read full topic

Rinmitra Loan App Customer" Care Helpline Number©️))+91-7470981581 @! 9890743382-™️Call Call

$
0
0

Rinmitra Loan App Customer" Care Helpline Number©️))+91-7470981581 @! 9890743382-™️Call Call.

1 post - 1 participant

Read full topic

Viewing all 105566 articles
Browse latest View live


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