Board index FlightGear Development Aircraft

CRJ700 family goes canvas

Questions and discussion about creating aircraft. Flight dynamics, 3d models, cockpits, systems, animation, textures.

Re: CRJ700 family goes canvas

Postby Octal450 » Fri Aug 11, 2017 4:01 am

Hi JSB
I got some request to fix this autopilot from D-SVEN, and a few others.

I tried to tune the current AP for a while -- the logic just isn't realistic. Perhaps I should just write a new autopilot for the CRJ700 while I'm overhauling the PIDs anyways?

But I retuned Roll, Pitch smoothly, and fixed/enabled the Yaw Damper again :)

Let me know what I should do with these changes please!

Kind Regards,
Josh
Octal450

Lead Programmer, IDG (Join our Discord!)
Download High Quality Aircraft from Octal450 Hangar
User avatar
Octal450
 
Posts: 4306
Joined: Tue Oct 06, 2015 12:51 pm

Re: CRJ700 family goes canvas

Postby danielHL » Mon Aug 14, 2017 7:44 pm

Hej,

jsb is currently on vacation and taking some time off FG.

What about the logic isn't realistic? Most of the buttons do exactly as specified in the FOM. I know of some glitches in the ILS LOC and GS arming logic and a nasty bug in the pitch controller. But button logic should be mostly OK. I know this behaves differently than Airbus and Boeing and also as your IT-Autoflight-implementation of both.

That being said, I think this way is the future. I really don't get my head around all this nested logic elements and conditions to implement simple logic behaviour. It should really be done in nasal and just do the controllers in the xml files.

Could you post your issues here and maybe fixes, too?

CU
Daniel
danielHL / GVA0387 / D-FMPW / (UA83DAN)
danielHL
 
Posts: 66
Joined: Fri May 02, 2014 6:23 pm
Callsign: UA83DAN, GVA0387
Version: git
OS: Linux

Re: CRJ700 family goes canvas

Postby Octal450 » Mon Aug 14, 2017 11:37 pm

Hi Daniel

The issue is with ILS arming, and altitude capture logic. I'm offering to fix this.

IT-AUTOFLIGHT is very modular. See my A320 implementation works total different to the 737-800 implementation. But what I would do, is take the basic functions and customize it for the CRJ (like I did with the A320). The logic is all Nasal, and the controllers are all XML.

I made a fixed file for the current autopilot logic, I was simply proposing a logic rewrite. I can send you the new autopilot.XML, but it also requires 2 files changed also.

Kind Regards,
Josh
Octal450

Lead Programmer, IDG (Join our Discord!)
Download High Quality Aircraft from Octal450 Hangar
User avatar
Octal450
 
Posts: 4306
Joined: Tue Oct 06, 2015 12:51 pm

Re: CRJ700 family goes canvas

Postby wkitty42 » Tue Aug 15, 2017 2:33 am

danielHL wrote in Mon Aug 14, 2017 7:44 pm:That being said, I think this way is the future. I really don't get my head around all this nested logic elements and conditions to implement simple logic behaviour. It should really be done in nasal and just do the controllers in the xml files.

my understanding is that doing it in nasal puts additional load on the system... load that is mitigated by using the xml system and doing it all there... you'd still have nested logic in nasal anyway ;)
"You get more air close to the ground," said Angalo. "I read that in a book. You get lots of air low down, and not much when you go up."
"Why not?" said Gurder.
"Dunno. It's frightened of heights, I guess."
User avatar
wkitty42
 
Posts: 5577
Joined: Fri Feb 20, 2015 3:46 pm
Location: central NC, USA
Callsign: wk42
Version: git next
OS: Kubuntu 14.04.5

Re: CRJ700 family goes canvas

Postby Octal450 » Tue Aug 15, 2017 4:57 am

But XML logic sucks for autopilots... A complex AP is much easier to do via nasal. I test all my work on a old PC from 2009, and that machine runs everything great. So I don't see this point. I guess if your AP refreshes the entire script several times per frame, maybe. But ITAF was designed against that.

Kind Regards,
Josh
Octal450

Lead Programmer, IDG (Join our Discord!)
Download High Quality Aircraft from Octal450 Hangar
User avatar
Octal450
 
Posts: 4306
Joined: Tue Oct 06, 2015 12:51 pm

Re: CRJ700 family goes canvas

Postby Thorsten » Tue Aug 15, 2017 5:50 am

But XML logic sucks for autopilots... A complex AP is much easier to do via nasal.


To me it least it seems reasonable to let Nasal do guidance and AP/JSBSim elements control.

Guidance tasks (like 'pitch to +10 degrees' or 'hold -30 fps vertical speed') don't need to be computed or updated at a high frequence (every few seconds is usually sufficient) and the can be fairly complex as they might involve optimization processes over fairly tough problems ('assuming I hold current pitch and thrust, where will I be within the next 30 seconds given gravity, current wind and the fact that I descent into more dense air ')

Control tasks (like 'how to move the airfoils to pitch to +10 degrees') need to be done at a high rate to avoid instability - you basically need them to run at FDM rate of 120 Hz or you will get nasty oscillations.

So the division of labor along those lines will give you a lean and stable AP, and anyone who believes that you can code optimization over trajectory prediction scenarios in JSBSim as well as in Nasal has likely never tried either.
Thorsten
 
Posts: 10844
Joined: Mon Nov 02, 2009 8:33 am

Re: CRJ700 family goes canvas

Postby Octal450 » Tue Aug 15, 2017 12:10 pm

I agree @Thorsten.

Some inputs like VS can go directly to the PID, so not all need to go through nasal, but mode selection definitely.

Kind Regards,
Josh
Octal450

Lead Programmer, IDG (Join our Discord!)
Download High Quality Aircraft from Octal450 Hangar
User avatar
Octal450
 
Posts: 4306
Joined: Tue Oct 06, 2015 12:51 pm

Re: CRJ700 family goes canvas

Postby wkitty42 » Tue Aug 15, 2017 9:09 pm

Thorsten wrote in Tue Aug 15, 2017 5:50 am:anyone who believes that you can code optimization over trajectory prediction scenarios in JSBSim as well as in Nasal has likely never tried either.

i wasn't looking at any specific type of scenario... i was only looking at what i've seen...

eg: fuel stuff in the c172p used to be controlled by a script... there had to be a special test in for when running with --enable-fuel-freeze (for example)... onox (IIRC) rewrote the fuel stuff in xml and remove that nasal code and suddenly everything was much better in the craft... i'm not positive about that nasal only doing fuel, though, but fuel flow was definitely one part of it... since the c172p doesn't have all that much of an AP, well... you know ;)
"You get more air close to the ground," said Angalo. "I read that in a book. You get lots of air low down, and not much when you go up."
"Why not?" said Gurder.
"Dunno. It's frightened of heights, I guess."
User avatar
wkitty42
 
Posts: 5577
Joined: Fri Feb 20, 2015 3:46 pm
Location: central NC, USA
Callsign: wk42
Version: git next
OS: Kubuntu 14.04.5

Re: CRJ700 family goes canvas

Postby Octal450 » Thu Aug 17, 2017 2:40 pm

So... what do you want me to do with these changed files?

You want I push to my git, that you can look my changes?

Kind Regards,
Josh
Octal450

Lead Programmer, IDG (Join our Discord!)
Download High Quality Aircraft from Octal450 Hangar
User avatar
Octal450
 
Posts: 4306
Joined: Tue Oct 06, 2015 12:51 pm

Re: CRJ700 family goes canvas

Postby wkitty42 » Thu Aug 17, 2017 8:20 pm

i guess you're talking to danielHL and/or JSB?? selective quoting is a GoodThing<tm> ;)
"You get more air close to the ground," said Angalo. "I read that in a book. You get lots of air low down, and not much when you go up."
"Why not?" said Gurder.
"Dunno. It's frightened of heights, I guess."
User avatar
wkitty42
 
Posts: 5577
Joined: Fri Feb 20, 2015 3:46 pm
Location: central NC, USA
Callsign: wk42
Version: git next
OS: Kubuntu 14.04.5

Re: CRJ700 family goes canvas

Postby Octal450 » Thu Aug 17, 2017 10:04 pm

Yes.

Kind Regards,
Josh
Octal450

Lead Programmer, IDG (Join our Discord!)
Download High Quality Aircraft from Octal450 Hangar
User avatar
Octal450
 
Posts: 4306
Joined: Tue Oct 06, 2015 12:51 pm

Re: CRJ700 family goes canvas

Postby jsb » Sun Aug 20, 2017 1:39 pm

it0uchpods wrote in Fri Aug 11, 2017 4:01 am:Hi JSB
I got some request to fix this autopilot from D-SVEN, and a few others.

I tried to tune the current AP for a while -- the logic just isn't realistic. Perhaps I should just write a new autopilot for the CRJ700 while I'm overhauling the PIDs anyways?

But I retuned Roll, Pitch smoothly, and fixed/enabled the Yaw Damper again :)

Let me know what I should do with these changes please!

Kind Regards,
Josh


Hi Josh,
sorry for the delay. As said by Daniel, the logic follows the CRJ700 manual, and yes, some parts may be not intuitive. Also, as allways, there may be bugs.
The PID controllers def. need some overhaul so I am more than happy to read you could improve/fix those. I would like to give it a try and then we can push it into the repos :)

best regards
Henning
jsb
 
Posts: 219
Joined: Sat Oct 25, 2014 8:17 pm
Location: Hamburg, Germany
Callsign: D-JSB
Version: next
OS: Win7/Linux

Re: CRJ700 family goes canvas

Postby Octal450 » Sun Aug 20, 2017 2:21 pm

Hi JSB,

No problem, I'll make a fork and paste a link here soon. If you like my work, I'd be happy to fix the logic (alt capture, local/GS capture)

For now, I've rewritten the entire autopilot PIDs etc. It flies a lot better now.

Josh
Octal450

Lead Programmer, IDG (Join our Discord!)
Download High Quality Aircraft from Octal450 Hangar
User avatar
Octal450
 
Posts: 4306
Joined: Tue Oct 06, 2015 12:51 pm

Re: CRJ700 family goes canvas

Postby Octal450 » Sun Aug 20, 2017 3:32 pm

Also, if you'd like to look at my A320, I have the multi-page MFD type Canvas system working for the ECAM display. Maybe you can adapt this to your CRJ Canvas?

Josh
Octal450

Lead Programmer, IDG (Join our Discord!)
Download High Quality Aircraft from Octal450 Hangar
User avatar
Octal450
 
Posts: 4306
Joined: Tue Oct 06, 2015 12:51 pm

Re: CRJ700 family goes canvas

Postby D-ECHO » Sun Aug 20, 2017 4:12 pm

And fyi I already started Implementing a canvas eicas into the crj2 if you like to have a Look
User avatar
D-ECHO
 
Posts: 1507
Joined: Sat May 09, 2015 12:31 pm

PreviousNext

Return to Aircraft

Who is online

Users browsing this forum: YandexBot [Bot] and 3 guests