So I did remove the system wide autostart changes and went to the user autostart here
- You should really be using your user's autostart file not the systemwide one. in /etc.
- Your autostart line doesn't run your code with sudo yet your manual command does. This may be a factor but it may also be an unnecessary use of sudo
- Assuming your command is correctly passed to lxterminal, the echo won't run until your python script exits.
- I've no idea whether the quoting around your -e argument will be enough. It may not be being interpreted correctly. Put those three command into a shell script and call the shell script from autostart instead.
Code:
cd /home/pi/.config/lxsession/LXDE-pi/
Now I have put the same call (and also moved the grott directory from Desktop to /home/pi/grott therefore a different code right now) into the user autostart and rebooted the pi.
Code:
lxterminal --geometry=120x40 --title=Updating -e bash -c '/home/pi/grott/autostartgrott.sh'
Code:
python3 /home/pi/Desktop/grott/grott.py -v
Code:
Traceback (most recent call last): File "/home/pi/grott/grott.py", line 33, in <module> proxy = Proxy(conf) File "/home/pi/grott/grottproxy.py", line 112, in __init__ self.server.bind((conf.grottip, conf.grottport))OSError: [Errno 98] Address already in use
It is a phyton script that runs 247 until you press ctrl & c
And my main goal was a visible terminal where the pyhton code is already running.
Everything else was working already except the terminal window had disappeared.
Statistics: Posted by typxxi — Tue Mar 19, 2024 7:20 pm