I’m developing a drone platform for surveillance and am encountering issues with my software setup using MAVSDK as a ground control station. I based my work on the rtk-sender-example
from github, adding to it telemetry subscriptions and mission controls with multiple threads and async operations and also web page integration for control. However, this setup often leads to segmentation faults in c++.
To mitigate this, I want to organize my project into multiple scripts. However, I’m facing difficulties because I’m using a serial port, which cannot be accessed from different scripts simultaneously.
I seek advice on structuring MAVSDK as a server that connects to the drone, allowing other scripts to handle specific tasks, like reading battery status or sending mission commands, to create more organized, scalable, and reusable code.