Developer

Arducopter 2.1.1 alpha

This is a work in progress. I've tried to address some fine tuning and performance issues.

Denny R. had made a comment about the inertia of bigger props causing issues. I've added a low pass filter to smooth the positive acceleration of the props to see if we can get at this issue. It may require tuning up Rate_P for a few folks, but I saw little issue in multiple flights.

Crosstrack had a small math error that decreased the resolution of it. I've fixed that and upped the default gains to get better tracking. 

Made WP hit radius 1 by default. even 3m is too much for quads. (If you pass a WP you will move on to the next)

The Loiter method is tuned a little better by default, and now uses GPS offsets when flying less than 1.5m/s. Code experimentation will continue on this front. Thanks to Emile and afernan for their help!

A fix in the Z Accel startup was added to get an averaged result.

Added the ability to enter Loiter with Optflow enabled. - still a work in progress, not for everyday use just yet.

This alpha is on GIT now and is for user's who want to test code. As always, you need to use the "relaxpatch" version of Arduino you can find in the downloads section

Update: We've found and patched some small type bugs in the latest and updated some GPS drivers in the Library. Be sure to pull the latest code and check http://apm.tridgell.net/ for the status of each build run against the SIL sim server.

Update r3:

I pushed a version on to GIT that addresses a number of issues.

- the low speed GPS XY calculations were incorrect and have been fixed

- Nav_Rate I term has been removed in loiter control - it's too easy to get two iterms working out of phase

- A second derivative has been added to Roll and Pitch. I found it removed wobbles nicely - Can be adjusted in the planner as STAB_D with a default of .25 (just enough)

- Smoothing has been applied to the motor commands in a way that really quiets down the alt hold pulsing without much effect on latency

- Yaw now has a dynamic constraint and I've upped the yaw gain.

- The motors output now have an LP filter on them so that the accelerate just a tad slower than the deceleration. This is a test to see if it helps big Octo's and Hexa's

- The Rate_I term is now zero'd for first five seconds after takeoff to keep balance.

- Loiter gains are lightened up a bit

- Nav_Rate_P is lower to remove back and forth sped related hunting in loiter

- Compass is enabled by default

- New I2C Library now included which should solve I2C related lockouts

- optflow is still a work in progress.

Update R4:

This update is based on flights today in a very windy environment.

It occurred to me that we're handling the WP nav I terms incorrectly and I reworked the WP navigation to share the same I terms from the Loiter. Even though they use different error input, etc, they turn out to both deal with wind in the same way. I have not Flown WPs with this new code, but heavily tested it in the sim and It's really rocking in hard wind. Transitions from Loiter flight and Nav flight are very smooth. Please let me know if you have luck.

Update R5:

This is a quick patch based on a bad crash Marco had. My theory was an I term that built up during wind that needed to be reset, but wasn't. It's a corner case but It bit Marco pretty bad. Please re-pull if you have R4 running to go to R5. And please, please be careful. This is alpha code not for general testing, but for development. Don't fly it on anything you would feel bad about crashing. 

Jason

Update R6:

Includes fix for Acro mode reset bug.
I went through all of the global variables and gave them lengthy descriptions. It's worth a read if you want to learn more how the internals work. I'll be doing some more organization like this as we move forward with an architectural redesign for 3.0 \
This version is mostly clean-up, but does include 1 interesting performance enhancement. It's disabled by default because It's fairly untested. The idea is that the wind compensation created by the Iterms for lat and lon in Loiter and Navigation are carried over into Stabilize. This unifies all of the modes so that when you switch modes, you don't get a small, but fast change in pitch or roll. This is only noticeable in high wind environment. 
To get this to work, I look for near zero velocity and start moving the pitch and roll into the wind control items. This takes a  transformation from copter frame to world frame, but the result is the copter will hold the position against the wind with the sticks in the center of the controller. If you fly around the wind compensation will bleed off slowly - about 30 seconds.
Again, this is off by default and needs significant testing, preferably in the HIL sim first.JNL has already started and flown this version for real.
The feature may be off by default for another version or two, but just letting you know it's there.
I think it will go a long way to making the mode changes feel seamless.

Update R7:

Added an auto-land timer for RTL. If you don't change modes for 20s after the copter arrives at home, it will begin to auto-land. If you have failsafe and no GPS, you will immediately begin auto-landing.
Failsafe RTL now goes 10M up as it RTLs to avoid obstructions.
Added SIL test for failsafe. 

Update R8:

Minor tweaks and cleanup

Update R9:

Made climb rate controller for landing universal for all altitude changes

Update R10:

Updated Loiter controller - Works great in the sim, thanks Afernan.

Thanks,

Jason

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

Join diydrones

Email me when people reply –

Replies

  • 100KM

    I've just spend quite some time setting up HIL with flightgear and testing loiter.  For the life of me, I couldn't get it to do circles in loiter with the current mission planner hil version.

    So I'm very curious as to what has changed now and where the culprit was.

    Saturday evening (newyears eve) I'll be using the hexa with showleds and fireworks again to brighten the skies at midnight.  Will it be flying the good old and trusted 2.0.49 or will it fly the new firmware ?

  • Developer
    I would say it's time to say: we finally! :-)
    I'm currently testing a latest "very alpha" version, not released from Jason to the community because still being tested, we want to try in really fly it before you claim victory, but from this tlog that I just tested on the simulator you can see how the loiter work now, and in strong winds!!! This is evident because the drone is almost always tilted at an angle of 10/15 degrees.
    In the tlog the loiter start around 20%, the drift are not more than 2 meters in the worst case, less than one meter in the best, and notice when I turn the drone as a continuous tail still holds the position!
    And 'soon to declare victory, but finally I would say that Jason hit the nail! :-)
    Tomorrow i put on my youtube channel the video of this simulated flight with AeroSim, and not believe your eyes ... : P

    Nice work Jason! :-)))


    Bests

    Marco

    2011-12-29 11-53-01.tlog

  • I wonder what the accelerometer does. Does this have some important features?

  • Watch that

    https://www.youtube.com/watch?v=6hC2nPcFpbM

    Dammmm

  • I can´t upload the 2.1.1r2 from the download site (tryed many times). Once installed (no errors aparently) APM remains dead beeping constantly, No connect, no CLI. Going back to 2.1.0 alpha, all comes to life.

    ?¿

  • Now , I want edit about lagging control. Because , It can't some control.

  • Just downloaded this from the downloads section and loaded it on with Arduino. When I try to access the CLI through serial monitor all i get is "Init A" scrolling over and over. What have I done wrong?

  • In 2.1.1 , I have bug about some lagging and lock control there're hold angle pitch and roll when i will move stick about more than 30 %. Which i think have some crash or some out of control. 

    I download from http://code.google.com/p/arducopter/downloads/detail?name=ArduCopte...  and GIT. 

  • I have a suspect in why to some of us the new code doest´t work at all in LOITER.

    I´ve discover that using HIL with several code versions (I´ve tested from 2.0.49 to now) in all cases GPS is read correctly by the MP, taking the coordenates from the simulator (AeroSIM-RC, in this case).

    In all, except in the 2.1.1. (I see in the MP "gps no fix"), so maybe this could explain that LOITER is not working since there is not GPS refference.

    Could anyother check that (mainly the folks that 2.1.1 doesn´t work)?

    Angel

  • Is it possible to reverse the Yaw output (APM not RC) from the MP? 

    RC 4= -1 reverse only the RC not the correction.

     

This reply was deleted.

Activity

DIY Robocars via Twitter
Sep 9
DIY Robocars via Twitter
RT @chr1sa: We've got another virtual @DIYRobocars race tomorrow at 9:00am PT. Two dozen autonomous cars will compete, four at a time. Ther…
Sep 4
DIY Robocars via Twitter
Sep 1
DIY Robocars via Twitter
Aug 31
DIY Robocars via Twitter
Aug 31
DIY Robocars via Twitter
RT @ExplorerRobocar: Sometimes, I am really a big kid!! Having fun with my virtual RC car on the @diyrobocars track 😜😉, by using the « AR R…
Aug 24
DIY Robocars via Twitter
RT @grepLeigh: @donkey_car @unity3d @TensorFlow ~1050 episodes into training, my agent learned to erratically drive in the left lane. 🤖😆 ht…
Aug 24
DIY Robocars via Twitter
RT @EclipseCyclone: Sweet! http://Robotec.ai high performance #ROS 2 @unity3d #CycloneDDS bridge for @AutowareFdn @SVLSimulator now…
Aug 24
DIY Robocars via Twitter
RT @a1k0n: My car had a lot of trouble getting around the track at the last @diyrobocars event -- only one actual finished lap during the r…
Aug 24
DIY Robocars via Twitter
RT @SmallpixelCar: This is the run time map https://t.co/VzykOkUt2G
Aug 24
DIY Robocars via Twitter
RT @SmallpixelCar: Made a lot progress on Warm Spring Raceways track. Almost finished one lap. https://t.co/nUVpufZQyP
Aug 24
DIY Robocars via Twitter
RT @AntonioRobotics: Super fun time seeing these autonomous cars race at @circuitlaunch for the @diyrobocars quarterly meet up! The demolit…
Aug 15
DIY Robocars via Twitter
RT @a1k0n: I thought my dumb localization code was still working at the new @circuitlaunch track, but it was just *barely* working. I shoul…
Aug 14
DIY Robocars via Twitter
RT @DAVGtech: Recording of entire in person @diyrobocars race today @circuitlaunch. Fast forward a couple hours to go straight to the racin…
Aug 14
DIY Robocars via Twitter
RT @SmallpixelCar: This is the run time map. Very noisy Lidar signal https://t.co/bAbeVUMi10
Aug 14
DIY Robocars via Twitter
RT @SmallpixelCar: Today’s race with @a1k0n at @diyrobocars We both decided jumping over the wall was the way to break the 11s lap time. Th…
Aug 14
More…