Quantcast
Viewing all articles
Browse latest Browse all 3780

Troubleshooting • Build HAT script not loading on/after startup

Hi,

I have a Raspberry Pi 4 with the Build HAT

I have gone through https://github.com/thagrol/Guides/tree/main and attempted multiple methods to load my script.
I have tried at startup, after startup 30 seconds, after startup 60 seconds, with and without sudo however my script does not load still.
I have the script writing to a log and if I run the script in the IDE it logs fine, but if I load it via the crontab nothing just a blank log.

My latest command was

Code:

@reboot sleep 60; python3 /home/admin/Spike/ForceSensor.py &
My goal is to load a script that detects user input on a Lego ForceSensor and runs a motor for 5 seconds if detected. I am trying to use the Raspberry Pi as an alternative to the Lego Hub which loads when it starts up whatever script was pushed to it.

The script works perfectly when run manually.

Thank you

Statistics: Posted by mrpatrick — Wed Jan 24, 2024 3:48 pm



Viewing all articles
Browse latest Browse all 3780

Trending Articles