kodi autostart

how is it possible to start after 2 minutes kodi when is in autostart after the system restart? thankyou

someone that could help me?

create a bash script that waits for the desired time, and then launches kodi.
You could use the following command, for example:

sleep 2m

This would make the system wait for 2 minutes before going on with the rest of the script (just add the command to launch kodi).
Give executable rights to this script and add it to the autostart.

yes my kodi go to autostart in dietpi…
where i put the script and how?
thank you

kodi va in autostart
dove devo mettere lo script e come ? grazie

The delay of the Kodi opening is because DiedPi first needs to initialize mySQL, and some minutes subsequently Kodi will start.


Go to dietpi-config → Autostart Options and select option number 14 (Custom).
Then you edit the file:

nano /etc/dietpi/autostart.sh

at the end of the file add the commands to wait 2 minutes and then launch kodi:

# let's wait two minutes
sleep 2m

# then launch kodi

Save: (Ctrl-X, then Y) and reboot.


Allora, vai in dietpi-config → Autostart e seleziona l’opzione 14 “Custom”
Poi editi il file:

nano /etc/dietpi/autostart.sh

e aggiungi i comandi per aspettare 2 minuti e per lanciare kodi:

# prima facciamo aspettare due minuti
sleep 2m

# poi lanciamo kodi

Salva (Ctrl-X, poi Y) e riavvia.

non funziona il comando startkodi

Eh, cerca tu il comando giusto, non uso kodi quindi non so quale sia il comando corretto.