I am new to ardupilot so please forgive me for the potential dumb question.
I am trying to perform some specific patterns around a moving boat. (That boat is not at the same location as the GCS but I am able to get its updates position via AIS every 1 minutes or so).
I was able to generate a LUA code running on the autopilot to perfrom circle or whatever pattern around a given fixed location (using set_target_location).
However, i don’t know :
- how to send the updated boat location (transmitted as a NMEA message to a port COM on the GCS) to the onboard autopilot
- How to import this updated boat location as a variable into my lua script.
- How the LUA code performing a cricle around a fixed location will behave once the “fixed location” becomes a moving boat with its position updated every minute…
For point 1 & 2 :
I have tried to upload my boat location as a moving base and send its updated location to the onboard autopilot using the “rally point 0” but :
- Then if a failsafe occurs, the helicopter may fly to the rally point and stay there. Therfore it will be stuck at sea far away from the GCS.
- I cannot find a way to get the rally point location via the LUA script
Thank you in advance if you have any advice on those 3 points.