You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Rachel edited this page Aug 24, 2016
·
2 revisions
Running a script from boot on the Pi is pretty straightforward. We're going to use a service called crontab:
sudo crontab -e
Pick your favorite text editor (I like nano) and at the bottom of the file (under all of the comments), add @reboot nohup sudo /usr/bin/python /home/pi/presence.py &. If you named your script something else or put it in a different directory, replace /home/pi/presence.py with the correct path. The path in my example is just the main Pi directory.
Save the file! You need to reboot for it to take effect, but we are going to add another task to our crontab in this next step.