Airplane/APM flies RTL regardless of mode setting in AUTO or RTL

Guys:  

As many of you have seen from my postings I am struggling to get my aircraft to fly in auto mode.  Many of you have helped me chase down suspected problems with compass and various other suspected problems. I have yet to get the aircraft / APM to actually fly successfully in automatic.  It has flown well inManual,  FBW-A, Loiter, RTL, Circle etc.  

Today I discovered a problem with my APM / Mission controller that may help us identify the real problem.  I have three modes on the channel that I switch between Manual, RTL and AUTO.  I confirmed on the "Flight Data Screen" of the Mission Planner that when switch the mode switch that the display on the HUD display changes when I changed the switch.  HOWEVER - I learned today that there is no difference in the APM's actions between RTL and AUTO, even though the HUD display changes.  Please see the attached Tlogs and waypoints for verification.  I am sure there is something that I don't have set correctly, but this has been a challenge.  I frankly found this by accident today when I was switching between RTL and AUTO and noticed the airplane continued to circle above the RTL site.

  • I am using APM 2.5
  • Today I upgraded the APM firmware to V.2.7 in the APM, but the same thing happened in V 2.69
  • I am using a Hitec Aurora 9 with an Optma reciver
  • After discovering the fact that the APM did not change even though the mode was changed, I re-calibrated the radio a couple times with no joy.

Below is a narration of the actives today that I sent to a friend who has been trying to help me it may contain a clue:

I learned something very interesting.  I had changed one of the three remote actions to RTL (return to launch).  In addition I still had manual and automatic where it is to fly the way points.    I flew it out manually a ways and switched to RTL.  It came back over the launch site and perfectly held altitude and circled above me 400 feet.  It was so solid that I walked over to the truck and messed with the computer while it was flying!  Then, flew back out a ways and switched it to "automatic".  Instead of heading out  to the way point it turned and headed back toward me.  So a couple times I switched it back to manual and flew it back out but each time it came back to me, holing a nice altitude.  So I just let it go to see where and what it was going to do.  It circled around me and held a perfect altitude and around and around it went - just like the RTL.  So, while it was flying over me I switched it back and forth between automatic and RTL, but it kept circling above me.  I walked back over to the computer to verify that the HUD data on flight data on the mission planner displayed "RTL" when I had the switch in that position and "Auto" when I had the switch in that position.  Sure enough, the switch had no effect.

If any of you can can give me some direction, I would greatly appreciate it.

Bret C

Views: 3939

Attachments:

Reply to This

Replies to This Discussion

Bret, 

Sorry to hear about your problems. In general, "restart" mission in the Mission Planner should always do just that (if you're getting RTL instead of Auto, it's because it thinks it's finished the previous mission).  

If it's heading to a waypoint on the ground, check to see that you haven't accidentally set the altitude of that waypoint to 0 or checked "absolute altitude" rather than relative. 

If you're still having trouble, we can put you on a Skype call with one of our flight operations guys to diagnose. Your problems do not sound typical, so we should be able to zero in on the issue pretty quickly

Chris:

Thank you for your note.  I look forward to a skype call.  Monday anytime will work.  Just let me know a couple hours prior so that I can be back to my office.

Thanks

Bret C

Hi Bret,

I've had a look at your logs, and what is happening is that the mission is not being reset after finishing the AUTO mission. That is actually normal behaviour, although it certainly could be better documented!

Internally APM keeps a counter which records what waypoint it is up to. As it passes each waypoint it increments that counter. If the counter goes past the total number of commands in the mission it will RTL.

In your case when you enter AUTO the 2nd time the counter is still set to the end of the mission, so it immediately does an RTL.

There are two ways to reset the counter:

  • you can set the parameter RST_MISSION_CH to a RC input channel that will be watched by APM. If this channel goes above 1750 PWM then the mission will be reset to start at the beginning. On my transmitted I setup channel 7 on a spring loaded switch and use that switch to reset the mission. I set RST_MISSION_CH to 7
  • you can ask the APM to change to waypoint number 0. You can do that in Mission Planner with the menus in the flight data view. The APM recognises a change to waypoint number 0 as a request to reset the auto mission

I'd suggest you use the first method if you have a spare channel on your transmitter. It is very handy being able to restart the mission at any time by using a switch on your transmitter.

If you are still stuck then contact me on Skype as AndrewTridgell. Note that I am in Australia, so US afternoon is my morning.

Cheers, Tridge

Another suggestion ...

I often find it useful for this sort of testing to make the mission loop forever, so when it reaches the last waypoint it goes back to the first one. If you exit and re-enter AUTO it will continue where it left off.

To do that add two more waypoints to your mission. The first will be a JUMP to waypoint 1, then after that add a dummy navigation waypoint which will be ignored.

Cheers, Tridge

I remember Doug and I went back and forth on that decision to continue or restart missions. Perhaps you should restart the mission index when the mission is complete and the copter has reached home or landed. I know you don't have an arming procedure like AC, but something similar like a landed state could reset the mission.

For many reasons specific to helis and early testing it made more sense to have Arducopter restart its mission whenever we entered AUTO mode. This lead to less confusion for me during testing if things went poorly. Repeating the mission from the start was simply more practical. 

Jason

Andrew:

Thank you for your explanation and time on Skype tonight.  You were are huge help!  I suspected that the solution was simple, and it was.  Just press the "restart mission" button! 

Thank you!

Bret C

Andrew and all people who helped my.  

Thank you!

As I suspected, the fix was very simple and something that I did not understand, overlooked or did not read.  I did not realize that the "Restart Mission" needed to be done after the mission.  I thought that the "Restart Mission" was connected with recording the telemetry logs.

As Andrew suggested, I assigned a channel to reset the mission from the radio transmitter.

Today everything worked as intended and I was very pleased by the results.  The aircraft performed flawlessly on each mission.

So others can learn from this, be sure to RESET MISSION either from the mission controller action tab or preferably from a spare switch on the radio transmitter.  If you try to fly a mission and all it does it RTL (Return To Launch) you need to RESET MISSION.

Thank you.

Bret C

Tridge,

Or anyone else who knows the answer! Would it be possible (or acceptable) in ArduPlane to use the same Channel as both the 'Reset Mission' and the 'Reset after Breach switch for GeoFence' to the same channel? I am currently using all 8 input channels as follows:

1) Aileron

2) Elevator

3) Throttle

4) Rudder

5) GeoFence Enable

6) Reset GeoFence after Breach (RTL)

7) MinimOSD panel select

8) Flight Mode

So what would happen if I set CH6 as both the Mission Reset Switch and as the Reset GeoFence after Breach channel to monitor if say I had GeoFence enabled (CH5 above 1750 us) and CH8 mode set to AUTO? What might I expext to see happen in this case? Would this be possible?

 

Regards,

Nathaniel ~KD2DEY

Should work, I have already read about a RTL triggered when CH7 was reassigned to the camera gimbal and this parameter was not changed http://code.google.com/p/ardupilot-mega/wiki/APM_Parameters#Channel...(_ArduCopter_:CH7_OPT)
It arduCopter but the principal is the same.

Hi Andrew, Can you be a bit more explisit by what you mean by a dummy navigation way point, and where in the mission are these way points added, 76yr old brain is a bit slow, Regards Geoff, (in Victoria)

Brilliant thread Bret,

It may the answer my issue too, except mine is with the arducopter.

Thanks to all!

Cheers,

Choppy

Reply to Discussion

RSS

Groups

Season Two of the Trust Time Trial (T3) Contest 
A list of all T3 contests is here. The current round, the Vertical Horizontal one, is here

© 2019   Created by Chris Anderson.   Powered by

Badges  |  Report an Issue  |  Terms of Service