Servers by jDrones

Dynamic gyro notch filter based on esc rpm telemetry


(oz ozzy) #1

Been trying to get my 250mm quad to fly good in acro, the problem is I have lots of experience with BF, so the bar is pretty high. I did not build this quad in hopes it would outperform BF acro, but it should fly somewhat better than it is now, the response is just slow comparatively (I have removed many delays and tried many things and its better, but not even close), also my roll rates are about half of what I would like (1000dps is max on AC i think).

Another large step forward for BF this week, BF/Skaug just came up with a dynamic notch based on esc rpm telemetry, the few that have flown it says its magic. Here is some words from the dev: https://www.rcgroups.com/forums/show…postcount=5567

Joe came up with the yaw drift fix code that works brilliantly too.

It seems quite far behind as AC is just getting to esc passthrough mode and dshot. Qudos for the autonomous modes of AC!


(vosair ) #2

To be fair I don’t think the AP devs have ever been focused on acro, as most of the user base never uses it in their mostly stabilized/autonomous builds. That said the possibilities of implementing filtering based on ESC telemetry is super cool!


(andypiper) #3

I’m pretty pleased with my 250mm quad (QAV250) in acro, but have only tuned for 3s. My settings look like this (on AC 3.5.5):

One of the things that made the biggest difference was the ATC_ACCEL params:

Not flown my 180mm/4s quad in acro yet, but it’s pretty responsive. I’m not a great pilot so your bar may be considerably higher than mine :slight_smile:


(S) #4

Andy,
How did you come up w/ that tune? Specifically why did you lower the I term? I’ve been playing w/ manual tuning lately, and on my little 120mm copter I’ve been finding higher I term (higher than P) is giving me more betaflght like performance… But… I’m still learning (5 years of tuning sub 250mm size copters and still don’t quite have it…heh…)

It’s never as good as betaflight, but as others have said, manual flight is not a major design consideration for Arducopter. I had what felt like a GREAT tune the other day… My P and I were up around .1, and D up to about .003 (or was it .03). It finally felt really locked in and under control. But then when I looked at my HD video recording, it was oscillating a little. Did an auto-tune, and it’s back to feeling like it’s ice skating.
I can get it good enough, and fly it well. But then I pull out my betaflight copter and that one is just a dream to fly. It’s like it’s part of me… does exactly what I want. I’m always fighting arducopter a little.

-Worth mentioning… I’m usually flying down narrow trails, or weaving my way through branches in a forest canopy, or flying down halls in abandoned buildings… Always tight spaces. If I were just cruising around up in the air, the tune wouldn’t matter quite as much.


(vosair ) #5

What does features does AC have that you wish you had on BeF?


(S) #6

For me, on these small copters,
GPS, flight path displayed in Mission Planner, RTL, and sometimes Auto missions.
For these small copters it’s mostly the recoverability the GPS offers. I don’t fly auto all that often. But, I do like that I can… It’s a cool novelty on the small copters.

On my big copters, I only fly auto, so definitely only use Arducopter on them.


(Andyp1per) #7

Autotune with some manual tweaking. My 180mm on 4s feels much more locked in so I was putting any sloppiness down to weight and lower power. Maybe I should try BF :slight_smile:


(oz ozzy) #8

There is a good chance you wont have to tune PIDs on BF. Rates/Expo, season to taste. :slight_smile:


(oz ozzy) #9

Quick response in acro mode, minimal delay, Air-Mode, much higher roll/pitch rates (1950d/s), zero bounce back, bb logging compatible, minimal yaw drift on long spins to name a few. Or atleast good acro preformance.


(S) #10

We have basically ‘air mode’. Enable the “motor interlock”. It keeps the props spinning and levels if you’re in stab, at minimum throttle.
We have extensive logging, and I doubt we’ll see it made compatible w/ Betaflight’s system… The parameters are all different.

Keep us updated if you start to get a tune you like. I don’t think a lot of us are flying Ardu manually (or at least not those of us who make posts), so any new info is welcome.
There are a lot of settings you can dig in to, besides just the PID’s. Filters, angle limits, roll/pitch rates, etc. Read through the full parameter list if you haven’t, to get an idea of all the different things you can try.
I always get stuck between slow performance or oscillations… By the time I get the tuning ‘tight’ or fast enough, it’s prone to oscillate… I autotune or manually decrease PID’s and it’s smooth, but too loose like ice skating.

The differences are subtle and the engineer in me can’t quite figure out the technical things to look in to… I just know betaflight ‘feels’ more in control. But I can’t say arducopter is in any way out of control. I’ll eventually get it…


(andypiper) #11

This is my current tune on 4s for my 180mm quad. I was flying acro today and it was a lot of fun. I’m sure it can be better but I felt very in control:

You can see on this one my ATC params are outside norms :slight_smile:


(S) #12

Thanks!
Mine is a 130mm quad, 3" props, 2s, I don’t remember the exact weight, but about 120grams I think. 8200kv motors.

Right now my settings are…
Stab R,P,Y 10,10,4
Roll P,I,D, .05,.075,.0012 Filt,40
Pitch P,I,D .1,.15,.0031 Filt,40
Yaw P,I .19,.019 Filt 4
(These are just slightly modified from my last auto-tune… I don’t know why it made my ptich and roll so different, but I left it that way for now)
I increased my wpnav speeds, but everything else is the same as yours.

Acro_Yaw_P, 9
ATT Accel P,R,Y 284603,399964,65599
Gyro Filter 80
Sched_loop_rate:800

I think I’ve changed some other filter parameters, and did change the loit_ and PSC_ settings to get better performance in auto modes, but that’s a different conversation…

Anyway, it is flying well w/ this. But it has some odd movements… It wiggles at high throttle… It’s subtle, but it will yaw a couple degrees, roll a couple of degrees, sort of randomly.


(vosair ) #13

Try a higher I value and see if it gets rid of the wiggles at high throttle.


(S) #14

Thanks, I will. I’ve been playing w/ higher I (than you get w/ autotune) already and like the results, but I’ll try even higher. I’ve never explored the limits of I to see what it does at very high and low settings, and I guess I should.


(vosair ) #15

Depending on the speed of the “wiggles” you might need higher D as well.


(oz ozzy) #16

fast osc is usually to high P gain, slow osc is usually too high I gain. Osc in high thro is too high p gain but TPA can lower the p gain at higher thro. I would be surprised if higher I gain fixed high thro osc, but with the many loops AC is using, I it might work.

Question: Stabilize roll/pitch is just P gain for the stabilize loop? So this parameter should not effect acro flight? Or?


(S) #17

What do people mean by fast and slow oscillations?
I’ve had some that were up in the audio range that I’d consider fast…
Then I’ve had some around 5hz or so, that I’d consider slow…
But can they be as slow as 1hz? If the strange things I’m seeing are related to oscillations, it would have to be very slow… 1hz or slower. They seem like random movements, but if it’s possible to oscillate over a 2 second period or something, maybe that’s happening.


(oz ozzy) #18

Fast osc is like shaking your hand fast, somewhere around 5~10Hz, slow probably under 3Hz.

P and D can cause fast, but it’s mostly P. D causes very fast and most time is only herd and hot motors. I term is long term corrections, so these are slow osc.

What gets confusing is all the loops in AC, the main loop is acro mode (I would hope, like all other flight controllers), this main loop is the most inside loop and first and foremost needs to be stable, as the other loops (stability, alt hold, lioter, gps, etc) run much slower and on the outside of the acro loop.

Here is the problem I have with tuning AC acro mode, I want pure acro mode, but there is so many parameters that are added to make AC a smooth camera platform, like slow return to center stick (yes in acro mode???), speed, etc, these all mess with a good acro tune. I understand why they did it, they are all about smooth, where BF is all about minimal delay control that exactly follows your stick inputs, AC dont want this for the majority of pilots as it makes for bad video. But I would think acro should be acro w/o all the delays and smoothing added, and that is what I am fighting to make ac feel good. I think I should just cut my losses as ac was never designed for it.


(oz ozzy) #19

Anyone answer this one?


(Bill Geyer) #20

yes, the stabilize roll/pitch P gains are used for acro mode. this is due to the control system tracking the pilots inputs and translating them to a target rate and subsequently an attitude. the controller then drives the actual attitudes and rates to the target values. it uses both the stabiilize gains and rate gains to do this.