Flight modes

The Ardupilot allows you to have multiple flight modes of which I would actually only need 2 and downsizing has already been discussed but downsizing irrelevant code is not what I want/need.

 

Could I have two sets of autopilot code one setup for fast servo control, the other setup for slow servo control? (Space permitting or if not remove another mode for space)

Could I add altitude based servo variables? the higher she goes the slower the servos react

 

I will be using a glider first off (because I dont care if it breaks) so motor control is not needed. Is there a variable for this or do I delete/adjust a section of code

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

Join diydrones

Email me when people reply –

Replies

  • I would also like to increase my mode options. to use the mixing option to get 6 modes, will this require reprogramming of the Atiny?

    Thanks for all your help
  • Does anyone know if it is possible to add more than three modes to the control modes? I have a proportional dial on channel 7 on my hitec eclipse 7 and I would love to be able to do manual, stabilize, waypoints and RTL on the same flight.
  • Developer
    I do this when testing....
    void read_control_switch(){
    byte switchPosition = readSwitch();
    if (oldSwitchPosition != switchPosition){

    switch(switchPosition)
    {
    case 1: //
    set_mode(POSITION_1);
    break;

    case 2: //
    set_mode(POSITION_2);
    // set a variable here such as a PID value
    break;

    case 3: //
    set_mode(POSITION_3);
    // set a variable here such as a PID value
    break;
    }

    oldSwitchPosition = switchPosition;

    // reset navigation integrators
    // -------------------------
    reset_I();
    }
    }
  • Developer
    You can certainly implement this in your code. Look at the roll slew rate limiter. If you set up a similar pitch slew rate limiter and then set up modes which change the limiter parameters that would do what you want.

    If you are not using a motor then use the airspeed sensor. Elevator will be based on airspeed hold. You can just ignore the throttle parameters.
This reply was deleted.

Activity