Dear All,
I currently have a script that automatically runs after startup. It basically sleeps for 12 hours and then reboots. The problem I am having is that my PI is restarting while media is playing in Kodi. Is there any shell/terminal command that can check if Kodi is currently playing media?
*Before you ask I need this script because for some reason I am having SMB issues. I have an external 2-bay HDD enclosure connected via USB and after startup I am able to access the drives from other PCs. Unfortunately, after some time the SMBs seem to slow down soooo badly, that is not even possible to read-write to the drives from another PC. The solution I am using is just rebooting my PI. This is a separate problem, and I am aware that there might be million different causes so for the time being, I am happy by rebooting (IF media is NOT playing)