Hello everyone,

I've got a little problem here which I'm sure must have been solved hundreds of times. I think I understand how I'm meant to fix it but I'd like to confirm before taking the plane out again.

The scenario:

  • Platform is a PX4 + 3DR GPS/compass mounted on a Bixler 2.
  • Our runway runs east-west, with the pits area on the north side and the flying area on the south. Aircraft are not allowed to fly on the north side of the runway under any circumstances.
  • Manual mode works fine, stabilised mode works fine. I want to get auto (waypoint following) working so I can do autonomous circuits, but I want the circuits to be a fair way south of the runway (mostly to avoid other planes that are doing circuits on the runway).



This is how I did it last time:

  • Set up five waypoints (home about 10m south of the runway, then four to make a circuit pattern further south of the runway)
  • Take the plane to the field, arm it in the pits area, fly
  • Turn on automatic mode and watch as the plane makes a beeline for the north side of the runway and the clubhouse
  • Check on the computer afterwards and note that the home location is now on the north side of the runway


I've done a bit of searching and it appears that setting the home position in APM Planner is a bit pointless, because the autopilot moves the home position to its current location when it's armed (ie in the pits area). Then when I turn on automatic mode it heads straight for that waypoint. Therefore what I need to do is first get the home position away from the restricted side of the runway, and then set up the autopilot so that it doesn't actually include the home position in its waypoint following.

The new plan is this:

  • Set up five waypoints (home about 10m south of the runway, then four to make a circuit pattern further south of the runway)
  • After the last waypoint add a "DO JUMP 2" so it skips going home and goes on to the second waypoint.
  • Take the plane to the field, arm it while standing in the middle of the runway, fly



So now the home will be somewhere that the plane is actually allowed to go (definitely a good start) and it should only go there on the first circuit (after that it'll skip home and just follow waypoints 2 - 5). All correct? Is there a better/preferable way to achieve the same result?

Thanks,
Evan

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

Join diydrones

Email me when people reply –

Replies

  • Apologies for the slow reply on this. Here's a screenshot:

    http://i.imgur.com/d49SnZe.png

    It appears that in APM Planner v2.0.0 RC3 I can't set the number of jumps to -1 (it won't accept any negative value), so I've just set it to 10000 instead.

  • Great, thanks for the reply. That certainly cleared up a lot. What you said about going home after the flight plan is complete now makes a lot of sense. The initial waypoints were set up with a very large radius, so it didn't really need to fly far to 'hit' all of them. Then it'd head north to the home point. Hopefully adding the jump will fix it.

    I'll post a screenshot either tomorrow or Monday (left the laptop at work, and that's what I run APM Planner on).
  • This is a longstanding open issue. There is a thread on it at github and a guy was working on the solution, but he seems to have vanished.
    Unfortunately for Plane, Home is not where it is Armed like Copter, but rather where GPS lock is achieved.
    It should not fly to this home position when you switch to Auto, it should go to Waypoint 1, home is actually WP0, but you can't see that in MP. It will only go to Home after the flight plan is complete (or RTL is activated).
    I use the do_set_jump command followed by a dummy waypoint to get multiple laps. Make sure you never leave the number of jump reps at 0, unlimited is -1.

    If you are still confused, post a screenshot of you flight plan and map.
This reply was deleted.

Activity