Plane doesn't fly on track

I'm trying to get my plane to fly the centerline of my neighbor's 1200ft (400m) runway.

So far, I've done all I can to tweak crosstrack, nav pid, etc., but it still gets way too far off for me to consider attempting an autonomous landing.

I've been reading the code and it appears that it sets a track from the airplane's current location when it hits the current waypoint (up to 30m off the centerline!) to the next waypoint, instead of tracking from the current waypoint to the next waypoint.

It's a nitpicky distinction, but I'm wondering how it can be fixed, keeping in mind the potential for DO_JUMP loops in the flight plan.

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

Join diydrones

Email me when people reply –

Replies

  • Developer

    Jonathan,

     

    It is not really a nitpicky distinction.  It just was a choice made at some point in the past.  Why was it made?  Well, I can tell you it was made to optimize the performance for the Sparkfun AVC competition ;)  It is not optimal for auto landing.  

     

    I would suggest you do one of two things.  (1) If your mission allows just string 2-3 waypoints along the final approach leg so that you will not be far off the desired course line when you hit the next to last waypoint.  This way the point used to compute crosstrack will be close to the courseline.  If that is not desireable then (2) Change the code to use the waypoint rather than the "hit point" to compute the crosstrack course line.

     

    Seriously, this is just one of a myriad of little choices we made because of what was perceived as desirable performance at some point.  If you use the waypoint instead of the the "hit point" you get more of a jug-handle shaped turn.  Is that bad?  Well for one application it was, but maybe it is actually the better alternative.  Stuff like that I am happy to change one way or the other if I hear from enough people about it.

  • Hi jonathon,

    How many waypoints are you setting?

    Have you tried increasing the number of waypoints?

    Regards

    D
This reply was deleted.

Activity

Neville Rodrigues liked Neville Rodrigues's profile
Jun 30
Santiago Perez liked Santiago Perez's profile
Jun 21
More…