Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

starting Kodi using triggers #4

Open
sgonauer opened this issue Apr 22, 2023 · 1 comment
Open

starting Kodi using triggers #4

sgonauer opened this issue Apr 22, 2023 · 1 comment

Comments

@sgonauer
Copy link

Hi,

I'm using a raspberrypi4 to use Kodi.
I'd like to use the cecdaemon to start Kodi at will to avoid having it run 24/7 (and hence saving power)

If I start cecdaemon and Kodi manually Kodi gets input from cecdaemon (and not from the pulseeightdevice)

However once I try to start Kodi using trigger (a press on red key for example) Kodi doesn't receive events anymore.

I tried starting Kodi using the following script :

stgo@raspberrypi:~ $ cat /usr/bin/start-k.sh
#/bin/bash
sleep 1
echo "after sleep"
if pgrep -f kodi; then
echo "kodi present exiting"
exit
fi

su stgo /usr/bin/kodi &
echo "after fork of kodi" | logger

with the config :

[cmd_start_kodi]

Red

key = 114
holdtime = 1
command = bash /usr/bin/start-k.sh

I'm wondering if the issue is the fork from cecdaemon context.

Maybe using a systemd service would help ?

Any ideas ?

@sgonauer
Copy link
Author

Indeed using a systemd service fixes the issue !

I'm not sure of the underlying issue but it works

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant