Setting up and testing your failsafe NEWBIES LISTEN UP

Post Reply
Posts: 451
Joined: Mon Aug 17, 2015 5:56 pm

Setting up and testing your failsafe NEWBIES LISTEN UP

Post by Kbev5709 »

Multiwii firmware comes with the FAILSAFE DISABLED BY DEFAULT.
Not a good idea to leave it this way and fly at all. One of the first things you need to do before flying is to set that puppy up.

In your config.h sketch is a little section called Failsafe settings

Code: Select all

  /********                          Failsafe settings                 ********************/
    /* Failsafe check pulses on four main control channels CH1-CH4. If the pulse is missing or bellow 985us (on any of these four channels)
       the failsafe procedure is initiated. After FAILSAFE_DELAY time from failsafe detection, the level mode is on (if ACC is avaliable),
       PITCH, ROLL and YAW is centered and THROTTLE is set to FAILSAFE_THROTTLE value. You must set this value to descending about 1m/s or so
       for best results. This value is depended from your configuration, AUW and some other params.  Next, after FAILSAFE_OFF_DELAY the copter is disarmed, 
       and motors is stopped. If RC pulse coming back before reached FAILSAFE_OFF_DELAY time, after the small quard time the RC control is returned to normal. */
    #define FAILSAFE                                // uncomment  to activate the failsafe function
    #define FAILSAFE_DELAY     10                     // Guard time for failsafe activation after signal lost. 1 step = 0.1sec - 1sec in example
    #define FAILSAFE_OFF_DELAY 200                    // Time for Landing before motors stop in 0.1sec. 1 step = 0.1sec - 20sec in example
    #define FAILSAFE_THROTTLE  (MINTHROTTLE + 200)    // (*) Throttle level used for landing - may be relative to MINTHROTTLE - as in this case

The secret to making it work is to simply change this: //#define FAILSAFE to this: #define FAILSAFE
That turns it on at least with the default settings. To fine tune what your craft does in a failsafe landing you can change the number (variable) in the FAILSAFE DELAY, FAILSAFE OFF, and FAILSAFE THROTTLE phrases.

FAILSAFE DELAY is set to somewhere between 0 and lets say 15. This is how long it takes the failsafe to activate after losing TX signal. More than 15 is just stupid.

FAILSAFE OFF DELAY is how long those motors will run after the signal is lost. You want to give it enough time to land under power. Time is set in .1 of a second. 200 = 20 seconds etc. Time depends on your descent speed which is determined by:

FAILSAFE THROTTLE: Give this enough RPM to prevent a damagingly hard failsafe landing. Should be set in the area of RPM where quad descends quickly enough to reach the ground before FAILSAFE OFF DELAY kicks in and slowly enough to prevent crash damage upon failsafe landing.

Best to just leave this one: #define FAILSAFE_DETECT_TRESHOLD  985
alone and enabled. This is what determines how far it can wander from where it was armed before the failsafe kicks in.

Testing the failsafe for functionality:
Arm the craft. Step away from it. Turn off the TX. Motors should start turning at a speed that is slow enough to not fly but still exhibits a tiny bit of resistance to a fast descent. To get it right, find the speed your craft hovers at and drop it down a couple hundred RPM in the FAILSAFE THROTTLE settings.

EASY PEASY?? Yep. Now go turn on your failsafe before you fly that thing anymore.

Post Reply