Hello this time I created a small program written in c that I intend to run in a raspberry the same one already works correctly, but now I need to run it when I start the system (and it works without logging in), the idea would be that when starting the device the program works directly without the need to login. It should be noted that it reads information through the gpio ports.
Try adding the scrip in the following way
#! /bin/sh
# /etc/init.d/prototip
### BEGIN INIT INFO
# Provides: casero
# Required-Start: $remote_fs $syslog
# Required-Stop: $remote_fs $syslog
# Default-Start: 2 3 4 5
# Default-Stop: 0 1 6
# Short-Description: Simple script to start a program at boot
# Description: iniciar servicio autana system.
### END INIT INFO
# If you want a command to always run, put it here
# Carry out specific functions when asked to by the system
case "$1" in
start)
echo "Starting prototip"
# run application you want to start
/bin/prototip
;;
stop)
echo "Stopping noip"
# kill application you want to stop
killall prototip
;;
*)
echo "Usage: /etc/init.d/prototip {start|stop}"
exit 1
;;
esac
exit 0
the same when I try it in the following way - sos /etc/init.d/prototip start executes the program correctly, but when I turn the computer off and on the program never starts. Any ideas?. Thanks