Running mavproxy script automatically on startup

I have been trying to run the mavproxy script mavoproxy.py --master=/dev/serial0 --baudrate 921600 --out IPaddress:port --aircraft Mycopter from /etc/rc.local but it doesn’t work. I previously used to run it ok when mavproxy was only Python2, after upgrading to python3, it doesn’t work anymore. I have tried “cronjob” and all other auto script running methods to no avail. My application is such that the copter has to connect to the ground station right after the raspberrypi and pixhawk have booted.

Did you install the latest mavproxy using pip3?

Yes , I only use pip3 for all installs on my raspberry pi

What do the system logs say about what happened?

That’s going to be browsing files in /var/log or using journalctl
(depending on distribution)

@peterbarker I didn’t attach the logging functionality to the script