Hi,

I have only seen time-based WP missions, or just individual WP commands using the python scripting. I would would like to send a whole mission using a python script.

Just to quickly explain what I am trying to do: I am using a program to identify points of interest using a downward facing camera feed, from which I can create a waypoint mission file (in the right formatting and protocol). I am using Matlab to do some image processing, and I am using the TCP mavlink feed (ctrl-f in Mission Planner and using mavlink) to get the real time GPS information to attach the position to the image. Then I can pick out points on the image and give an estimate of the Lon and Lat. I create a WP file with these points at a predefined altitude. Then, with the press of a button, I would like my copter to follow those waypoints.

What I would like to do is run a python script (within Matlab) to upload and run that mission. I wanted to take advantage of the existing WP scripting of the autopilot. In other words, I am trying to avoid adapting the time-based method (that JoeM made) to use telemetry info and essentially do the same thing that the autopilot has already been programmed to do. I thought that this method would be easier, but I have not found a way to run a 'load WP file' command.

So the two main things that I am stuck on are:

- Can I run a python script from outside of the Mission Planner application? (I haven't found an answer to this question online, so I am making a simple motor test script to see if I can run it from Matlab)

- How can I upload and run a full waypoint mission file with the python scripting?

Thanks,

Michael

You need to be a member of diydrones to add comments!

Join diydrones

Email me when people reply –

Replies

  • Hello michael i am trying to do the same thing but with the help of MATLAB can u help or advice on what i should do
  • Use mavproxy.
    • Thanks. I looked into it a little and saw that it had exactly what I needed to upload the waypoint file. But I haven't found out yet if I can run a command in mavproxy using a script in matlab. What I saw was that the commands needed to be entered in mavproxy "via the command line or the menu bar of the GUI console." Do you know anything about that?

This reply was deleted.

Activity

DIY Robocars via Twitter
RT @_JonMyer: 🚨Our 1st AWS DeepRacer Community Race is Underway on http://twitch.tv/aws 🚨 Join us to find out which member of your commu…
3 hours ago
Ben Sinnock left a comment on New Zealand DIY Drones Group
"Hi all, glad to be in the group. Apologies in advance but I have a great many questions."
9 hours ago
DIY Robocars via Twitter
20 hours ago
DIY Robocars via Twitter
RT @BackyardRobotcs: After an admittedly long wait, the new Tinymovr R3.3 motor controller is now available https://tinymovr.com 🥳
22 hours ago
DIY Robocars via Twitter
RT @_JonMyer: 🏎 1 hr left before the #AWS #DeepRacer Community 🏎 Top 5 Race tomorrow LIVE on Twitch 1st Place = $50 Amazon GC or AWS Credit…
23 hours ago
DIY Robocars via Twitter
Friday
DIY Robocars via Twitter
Thursday
DIY Robocars via Twitter
Oct 14
DIY Robocars via Twitter
RT @davidfsmith: Race virtually with The AWS DeepRacer Community Race and then join us on the track to see how your times compare on the ph…
Oct 14
DIY Robocars via Twitter
Oct 14
Hiroki Tanaka liked Hiroki Tanaka's profile
Oct 13
DIY Robocars via Twitter
RT @breadcentric: It's now!
Oct 13
DIY Robocars via Twitter
RT @SahikaGenc: Happy Prime Day! AWS DeepRacer is available at a 30% discount today! @sunilmallya #AWSDeepRacer https://www.amazon.com/AWS-DeepRacer-Fully-autonomous-developers/dp/B07JMHRKQG/ref=sr_1_5?dchild=1&keywords=deepracer&qid=1602609599&sr=8-5
Oct 13
DIY Robocars via Twitter
RT @chr1sa: Printing all the parts for @DIYRobocars https://t.co/ygRxBBBQbi
Oct 11
DIY Robocars via Twitter
RT @chr1sa: Cool new @donkey_car controller app (iOS or Android). Can even do training in-app. Impressive! cc @DIYRobocars https://t.co/XD…
Oct 11
DIY Robocars via Twitter
RT @chr1sa: Drifting with @donkey_car! This is an example of the fully autonomous @DIYRobocars we race monthly now (virtually, in the shar…
Oct 10
More…