-
Notifications
You must be signed in to change notification settings - Fork 23
New issue
Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? # to your account
KNXD USB auto select device #62
Comments
there is no default device defined. The "optional" feature seems to be broken for device options in UI mode (has been the case since I created the add-on) |
There is a default value defined: options: |
but the value is empty, and at least back in the days when I created the add-on HA complained about a broken config file if I did not add the empty string |
…as optional option (fixes #62) Back in the days HomeAssistant complained if an option did not have any value assigned, so the default value of `""` (empty string) for `devices` had been used. It appears as if this changed now.
if I do that, the setting vanishes entirely from the UI. So I suspect this is then still a bug which needs to be reported to HA |
ah wait, it is there but hidden unless you switch the toggle to show unused settings. Likely not the most user friendly thing then |
but I still consider this to be a bug in HA |
once my local version updated so that I can test the latest change to the config, I will push it to github, but I won't make a new release just for this (as nothing inside the container changes). But once the commit is on github you should be able to "update" by simply uninstalling and reinstalling the add-on (maybe do a "check for updates" after uninstalling so that HA is updating the repo). After that you should have the latest config version as well |
Now the container starts but knxd fails to start:
|
the reason is this check in the config script: https://github.com/da-anda/hass-io-addons/blob/main/knxd/rootfs/etc/s6-overlay/s6-rc.d/init-knxd-config/run#L30 |
sorry, pasted the wrong line earlier (fixed now). Actually, USB should not require a value according to the script, but I suspect the condition for this check is wrong (the check for USB would have to be negated as well, but can't think straight yet, too early) |
Thanks, I'll take a look into the script. In the meantime I just configure /dev/null as the device, so the script can't get the USB bus id and is left empty. Auto select works. |
KNXD can automatically select the appropriate USB device.
The add-on configuration currently requires selecting a USB device manually.
It seems this setting was intended to be optional, as the config.yaml file includes:
device: "device?"
According to the Add-on Development Guide, you should not provide a default option if the setting is intended to be optional.
I'm happy to assist in testing a solution if you can provide guidance.
The text was updated successfully, but these errors were encountered: