Board index FlightGear Development Aircraft Autopilot and route manager

Generic Autopilot Rework Proposal

Designing a stable autopilot is one of the hardest things. Need help?

Generic Autopilot Rework Proposal

Postby Octal450 » Sun Jan 09, 2022 7:55 pm

Hi,
CC'd from the mailing list, as I'd like to reach out for opinions from those who are not there aswell.

Josh wrote:For years the generic AP has irritated me as it just flies very poorly. In my view a generic AP should be able to fly most aircraft with plausible FDM, but the generic AP can barely do that. (No offense intended to the original creator)

I created some prototype of a reworked generic AP last year but forgot about it, it was designed to be able to fly any aircraft with a plausible FDM.

To be clear - this is not anything like IT-AUTOFLIGHT. IT-AUTOFLIGHT is designed to facilitate development of realistic airliners autopilots, which is totally different goal then a default generic AP.

This generic AP I wrote last year was designed to be a drop-in replacement of the existing - no aircraft side edits required. It uses the existing properties to maintain compatibility and is designed to fly as many types as possible. The control system design is very specifically made so that different FDMs and feeling aircraft can still be flown with some stability.

The primary issues with the current generic:
- Unstable response in all heading/route manager, altitude, and speed on pitch control
- Overshoots/undershoots due to bad integrator use/cascade design
- Oscillation/vibration on sensitive aircraft
- Oscillation/overshoots on heavier flying aircraft
- Bad pitch control handling
- A few more I can't remember now

I made a quick demo showing the heading, altitude, and trim issues: https://youtu.be/9b1e9aVzT7Q
Did not have time to film/demo all the other issues, this is just a small subset of the issues. If weather comes into play, it just gets much more unstable

I also think some configurability can be added, for example, whether to use the baro altimeter or the standard altitude shown in the HUD and /position. This would not require any aircraft side changes for the default behavior. Meaning, when the setting is not there, the file falls back on the default behavior (ex, standard altitude prop), and when the setting is there, it uses the defined behavior. That way any airplanes use the default behavior, and also there is some minimal configurability possible by the developer.

Appreciate your thoughts and feedback, and if there is interest, I will put together a demo using the prototype file I created, and you can tell me what you think! I really think this would improve alot of the "unfinished" planes that are borderline un-autopilotable with the current generic AP.


Kind Regards,
Josh
Skillset: JSBsim Flight Dynamics, Systems, Canvas, Autoflight/Control, Instrumentation, Animations
Aircraft: A320-family, MD-11, MD-80, Contribs in a few others

Octal450's GitHub|Launcher Catalog
|Airbus Dev Discord|Octal450 Hangar Dev Discord
User avatar
Octal450
 
Posts: 5601
Joined: Tue Oct 06, 2015 1:51 pm
Location: Huntsville, AL
Callsign: WTF411
Version: next
OS: Windows 11

Re: Generic Autopilot Rework Proposal

Postby MariuszXC » Sun Jan 09, 2022 8:00 pm

I will be interested for sure.
INOP
MariuszXC
 
Posts: 1062
Joined: Tue May 18, 2021 5:38 pm
Location: Europe
Callsign: SP-MRM
Version: 2020.4
OS: Ubuntu 16.04

Re: Generic Autopilot Rework Proposal

Postby wlbragg » Sun Jan 09, 2022 8:45 pm

Yeah, I think it is a good idea to improve what we have now. After all it is ancient!
Kansas and Ohio/Midwest scenery development.
KEQA, 3AU, KRCP Airport Layout
Intel i7/GeForce RTX 2070/Max-Q
User avatar
wlbragg
 
Posts: 7609
Joined: Sun Aug 26, 2012 12:31 am
Location: Kansas (Tornado Alley), USA
Callsign: WC2020
Version: next
OS: Win10/Linux/RTX 2070

Re: Generic Autopilot Rework Proposal

Postby S&J » Sun Jan 09, 2022 10:06 pm

Wtg octal ..... Involve the whole community
"Stay away from negative people.They have a problem for every solution." - Albert Einstein
S&J
 
Posts: 797
Joined: Wed Aug 26, 2020 7:31 pm

Re: Generic Autopilot Rework Proposal

Postby S&J » Sun Jan 09, 2022 10:11 pm

Ok my tuppence worth.

Have you considered the Auto pilot might be correct and it's the flight model that's.......... How to say this without offence .......mmmmmmm ..........











Poor

Incase you didn't see it

viewtopic.php?f=4&t=27894&p=396643#p396643
"Stay away from negative people.They have a problem for every solution." - Albert Einstein
S&J
 
Posts: 797
Joined: Wed Aug 26, 2020 7:31 pm

Re: Generic Autopilot Rework Proposal

Postby Octal450 » Mon Jan 10, 2022 1:14 am

Thanks for the notes!

@S&J, No that's not it. From a control engineering perspective alone, the autopilot is wrong. And then ignoring that and looking at the behavior, its still wrong. And then if I go further and test tons of different FDMs from FG's most realistic to more "toy" planes, it can barely fly any of them without multiple of the above listed issues... and I'm not talking about a crazy FDM (like a dynamically unstable FDM with FBW off).

Plus - my autopilot can fly the same planes far better without adjusting the values specific to each aircraft. :mrgreen:

Kind Regards,
Josh
Skillset: JSBsim Flight Dynamics, Systems, Canvas, Autoflight/Control, Instrumentation, Animations
Aircraft: A320-family, MD-11, MD-80, Contribs in a few others

Octal450's GitHub|Launcher Catalog
|Airbus Dev Discord|Octal450 Hangar Dev Discord
User avatar
Octal450
 
Posts: 5601
Joined: Tue Oct 06, 2015 1:51 pm
Location: Huntsville, AL
Callsign: WTF411
Version: next
OS: Windows 11

Re: Generic Autopilot Rework Proposal

Postby S&J » Mon Jan 10, 2022 9:14 pm

Well if your proposal is an improvement of the Auto pilot and I'm sure whatever you propose will be an improvement. I can't see any reason for not implementing improvements.

I always think that to call it an auto pilot is misleading in that it's more a co-pilot or even a means of flying the plane whilst giving instructions.

Anyway good look with it
"Stay away from negative people.They have a problem for every solution." - Albert Einstein
S&J
 
Posts: 797
Joined: Wed Aug 26, 2020 7:31 pm

Re: Generic Autopilot Rework Proposal

Postby Thorsten » Tue Jan 11, 2022 7:21 am

FWIW, I don't think there's anything sacred about the existing generic AP - any serious model should come with its own AP anyway (if it has one) and won't be affected, so the measure for how good the generic AP is is simple - what percentage of planes that do not have their own AP can it fly decently?

If the new version has a higher percentage, the old can go as far as I am concerned.
Thorsten
 
Posts: 12490
Joined: Mon Nov 02, 2009 9:33 am

Re: Generic Autopilot Rework Proposal

Postby Octal450 » Tue Jan 11, 2022 3:58 pm

Thanks for the feedback.

Yes the old one can't really fly many planes well. Especially since many developers use the generic to start their own system, there are many poor custom systems made from it.

Fun fact, the first version of ITAF was also based on the generic before I got sick of it and rewrote it.

Kind Regards,
Josh
Skillset: JSBsim Flight Dynamics, Systems, Canvas, Autoflight/Control, Instrumentation, Animations
Aircraft: A320-family, MD-11, MD-80, Contribs in a few others

Octal450's GitHub|Launcher Catalog
|Airbus Dev Discord|Octal450 Hangar Dev Discord
User avatar
Octal450
 
Posts: 5601
Joined: Tue Oct 06, 2015 1:51 pm
Location: Huntsville, AL
Callsign: WTF411
Version: next
OS: Windows 11

Re: Generic Autopilot Rework Proposal

Postby Octal450 » Thu Jan 20, 2022 4:02 am

Made good progress on this, its now scalable to different classes of airplanes from heavies to GA. Pitch axis needs the most work, Roll is working well as from my prototype and thrust is easily completed. I've also added a mach function.

Kind Regards,
Josh
Skillset: JSBsim Flight Dynamics, Systems, Canvas, Autoflight/Control, Instrumentation, Animations
Aircraft: A320-family, MD-11, MD-80, Contribs in a few others

Octal450's GitHub|Launcher Catalog
|Airbus Dev Discord|Octal450 Hangar Dev Discord
User avatar
Octal450
 
Posts: 5601
Joined: Tue Oct 06, 2015 1:51 pm
Location: Huntsville, AL
Callsign: WTF411
Version: next
OS: Windows 11

Re: Generic Autopilot Rework Proposal

Postby Octal450 » Tue Feb 08, 2022 2:27 am

Hi


Here is the proposal of the rework.

Kind Regards,
Josh
Skillset: JSBsim Flight Dynamics, Systems, Canvas, Autoflight/Control, Instrumentation, Animations
Aircraft: A320-family, MD-11, MD-80, Contribs in a few others

Octal450's GitHub|Launcher Catalog
|Airbus Dev Discord|Octal450 Hangar Dev Discord
User avatar
Octal450
 
Posts: 5601
Joined: Tue Oct 06, 2015 1:51 pm
Location: Huntsville, AL
Callsign: WTF411
Version: next
OS: Windows 11

Re: Generic Autopilot Rework Proposal

Postby benih » Tue Feb 08, 2022 8:55 am

Nice job!
User avatar
benih
 
Posts: 1711
Joined: Tue Aug 15, 2017 10:34 am
Callsign: D-EBHX
Version: next
OS: Debian Linux 64bit

Re: Generic Autopilot Rework Proposal

Postby S&J » Tue Feb 08, 2022 11:02 am

Looks good
"Stay away from negative people.They have a problem for every solution." - Albert Einstein
S&J
 
Posts: 797
Joined: Wed Aug 26, 2020 7:31 pm

Re: Generic Autopilot Rework Proposal

Postby MariuszXC » Tue Feb 08, 2022 11:12 am

Was there an autothrottle in action during C182 climb demonstration?
I think I also noticed small oscillation in pitch just prior to commencing roll and at the roll exit with MD-11.

Impressive nonetheless.
INOP
MariuszXC
 
Posts: 1062
Joined: Tue May 18, 2021 5:38 pm
Location: Europe
Callsign: SP-MRM
Version: 2020.4
OS: Ubuntu 16.04

Re: Generic Autopilot Rework Proposal

Postby wlbragg » Tue Feb 08, 2022 5:33 pm

Hi Josh;

I haven't been following this closely, so if you've already explained this, forgive me. how is this expected to work with helicopters? If it was considered, any chance we could get some form of "basic" AFCS or even SAS for them?

I'm not sure how many of the helicopters out there would even have either of these systems in real life, although I would expect the newest ones would.

I couldn't pass up the opportunity to ask :)
Kansas and Ohio/Midwest scenery development.
KEQA, 3AU, KRCP Airport Layout
Intel i7/GeForce RTX 2070/Max-Q
User avatar
wlbragg
 
Posts: 7609
Joined: Sun Aug 26, 2012 12:31 am
Location: Kansas (Tornado Alley), USA
Callsign: WC2020
Version: next
OS: Win10/Linux/RTX 2070

Next

Return to Autopilot and route manager

Who is online

Users browsing this forum: No registered users and 1 guest