i got a python script to collect data from a few connected sensors. This script runs in background from starting the PI. The script is working fine but irregular it fells in 'Sl' state. If i restart the PI it works again for a few days, but then it happens again.
Is there a way to monitor the state of the script (kill it and start it again if this happens) or any idea why this happen?