1
0
mirror of https://github.com/home-assistant/operating-system.git synced 2026-02-21 10:17:33 +00:00
Files
Stefan Agner 93a2d8a19b Do not start hciuart.service/bthelper@hci0.service if krnbt is used (#2947)
* Do not start hciuart.service if krnbt is used

Avoid starting (and failing to start) hciuart.service if krnbt is used.
This avoid unnecessary failed services showing up.

* Update buildroot-external/package/pi-bluetooth/hciuart.service

Co-authored-by: Jan Čermák <sairon@users.noreply.github.com>

* Drop duplicate bluetooth in path

* Avoid bthelper@hci0.service failing

* Revert "Avoid bthelper@hci0.service failing"

This reverts commit f79777e63e.

* Add ExecConditiono to bthelper@.service as well

---------

Co-authored-by: Jan Čermák <sairon@users.noreply.github.com>
2023-11-28 17:18:50 +01:00

12 lines
332 B
Desktop File

[Unit]
Description=Raspberry Pi bluetooth helper
Requires=hciuart.service bluetooth.service
After=hciuart.service
Before=bluetooth.service
[Service]
Type=oneshot
ExecCondition=/bin/sh -c '[ "$(cat /proc/device-tree/$(cat /proc/device-tree/aliases/bluetooth)/status)" != "okay" ]'
ExecStart=/usr/bin/bthelper %I
RemainAfterExit=yes