I have been working on improving the TradHeli slowly but surely over the past few months.  One major aspect I've been working on is the ability to use full Pitch and Roll I-term.  Currently in 2.9.1 these are "Leaky" which limits their build-up to avoid tip-overs on the ground.  I have created a robust Take-off detection scheme that allows us to switch over to full I-term (as the multirotors use) for much better dynamic flight.  However, the system must switch back over to "Leaky" I-term once it touches the ground again to avoid tipping over.

I have managed to accomplish this, based largely on the work of Leonard and Randy who provided such a great Alt_Hold controller that if can also quite accurately detect a touch-down.

Another minor part of this is that while the heli is on the ground, I limit the negative collective pitch to less than full negative, so that we do not push the heli hard into the ground.

Here is the video from today using my 450 testbed.  I'm not working on this with my large 600.  Back to the field!

This code exists only in my branch which is based on 2.9.1.  I have not pushed these latest changes yet but will later tonight.

E-mail me when people leave their comments –

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

Join diydrones

Comments

  • Well, there's no guarantee I can do it at 30 m/s.  I can barely fly it that fast manually.  There's some control problems that crop up at those speeds.  

    Yeah, the water thing... I just don't know.  Do I want to risk a $1000 heli for a *chance* at a $1000 prize?  I dunno. I'm afraid that even if I put floats on it, they could get ripped off if it goes in hard.

    I have started taking it apart looking for the cause of the possible "leans", and I haven't found any bad bearings yet.  Weird...

     

  • I'll see you there.  30 m/s on a non-fixed wing that's going to have little trouble with the ball drop is going to be hard to beat.  I'm going with the simple router of a little 450 running light and hot, but hopefully do reliable 3 runs in a row, and hopefully those with super fast octos will have a problem on at least one of their runs.


    I still don't understand why they're doing it over water.

  • Yup, I'll be there.  That's partially why there was a big push to get this working.  I'll be working to speed up performance.  My 600 can fly waypoints at 20 m/s almost reliably.  I'd like to go faster, maybe up to 30.  We'll see.  But I also want to speed up the landing.  It's quite slow right now.

    I also have to work on cornering at the high speeds.  Because right now it corners like a runaway truck.

    And then obviously a ball-drop mechanism.

    But I'm EXTREMELY intimidated by the location.  Flying near people, and over water has be quite scared.

  • Amazing work as always.  Do you know if you're going to the Sparkfun AVC or not?   I could see where this would be useful.

  • Greg, yeah, in a hover, it's completely motionless, so I can't do it on motion.  Mind you, I'm not shutting down the motors when I do the ground detection.  It just switches back over to the Leaky I for Rate control, and constrains the collective pitch so that it doesn't push down on the ground too hard (helis can push down, unlike quads).

  • Moderator

    ahrs.xyz would be a good check to run though, Greg.

  • Moderator

    Nice

  • Looked at you code. Had an idea. Look at the differential if the ahrs.xyz and if it's close to zero then the vehicle is not moving. Or there's no wind and it's hovering very steady, dang! Landed 2 meters above the ground :(  It's much easier to know if a plane is flying(moving) than a copter.

  • It's deceptively simple, but took a bit of trial and error to get something that works and doesn't false.  I think if I just change 

    g.rc_3.control_in for g.rc_3.servo_out, and likewise the g.rc_2.control_in for g.rc_2.servo_out, it'll kick into full I-term in Auto modes.

  • Looking at the logs, I'm quite certain I had "leans" is what was causing the tip-over.  I probably blew the tail shaft bearings again.  The belt is a bit tight. 

    Yeah Greg, what's nice about the Leaky I term is that when you switch modes, it's much softer than a hard Reset_I.  Here's the code I'm using, it works very well in manual, but I realize looking at it now, it's probably not working in auto modes because it relies on the incoming stick signals.  I'll have to keep working on it.  But it definitely works in manual mode.  You can feel the difference in flight.  And see it on the bench if you fake a takeoff.  And it's surprisingly simple.  One key thing is routing the ESC signal through the APM so it can know if the motor is running or not.  If the motor is running, and we are at high throttle, we must be off the ground.  It could still go wrong, say a really heavy payload, but it's working OK like this.

    #if FRAME_CONFIG == HELI_FRAME
    static void check_ground_contact(void){

    if (!motors.armed()){
    set_takeoff_complete(false);
    return;
    }
    if (!ap.takeoff_complete){ // check if we've taken off yet
    if (motors.motor_runup_complete == true) {
    if (g.rc_3.control_in > 800 || g.rc_2.control_in > 2500) {
    set_takeoff_complete(true); // we must be in the air by now
    }
    }
    }
    if (ap.takeoff_complete && (throttle_mode != THROTTLE_LAND)){
    if ( (abs(climb_rate) < 20) && (motors.coll_out <= motors.throttle_mid) && (labs(ahrs.roll_sensor) < 2500) && (labs(ahrs.pitch_sensor) < 2500) ) {
    if( land_detector < LAND_DETECTOR_TRIGGER ) {
    land_detector++;
    }else{
    set_takeoff_complete(false);
    }
    }else{
    // we've sensed movement up or down so decrease land_detector
    if (land_detector > 0 ) {
    land_detector--;
    }
    }
    }

    }
    #endif // HELI_FRAME

This reply was deleted.