RGB1602 not starting if I move script
Am new to Raspberrys and Linux and have just got an RGB1602 to go with it.
I have written a python script based on Button.py. I want this script to run everytime the system reboots so have given Anyone access to execute then script. I have changed the script line 2 from sys.path.append('../') to sys.path.append("/home/<username>/DFRobot_RGB1602_RaspberryPi/DFRobot_RGBLCD/python").
The following line has been added to /etc/rc.local:
python3 home/<username>/DFRobot_RGB1602_RaspberryPi/DFRobot_RGBLCD/python/script.py &. This script does what it should.
However, if I move the script to /home/<username>/Documents/script.py, changing the path in /etc/rc.local and keeping the amended sys.path.append nothing happens to the RGB1602. How can I find out what is wrong?
It seems that you have trouble with sys.path.append(), you could check this method on python on the internet.
I guess it is because you didn't include the script after you moved its location, or you didn't include the library field in /DFRobot_RGB1602_RaspberryPi/
Hope it can help you.