On Mon, 2012-10-22 at 19:27 -0600, Jon S. Berndt wrote: > John, > > > > Yes, there were some changes. I’ll try to help out soon, but am > limited on time at the moment. You might search the JSBSim mailing > list for the “tank priority” terms. > > > > Briefly, as I recall, there is now a “priority” element, with priority > “1” being the highest. I forget if “0” means anything. Any tank with > the same priority provides fuel until all tanks of the same priority > are empty. Then, the next priority tanks are used (1, then 2, then …). > > > > The “new” tank system was introduced by one of our developers who is > also an airline pilot. Unfortunately, I don’t think that the features > is widely used, yet – at least in models in the JSBSim repository. I’m > using it in one vehicle model now, but can’t share that. > >
If you are looking for an example in FG, the A380 has used this new system for some time. It uses a <feed> element on the <engine> element, and <priority> on the <tank> element. You can see https://www.gitorious.org/airbus-aircraft/a380/blobs/master/A380.xml for details. Hope that helps. S. > > I hope this helps. You might try cross-posting to the JSBSim developer > list, too. Let me know if you need more help. > > > > Jon > > > > > > From: castle...@comcast.net [mailto:castle...@comcast.net] > Sent: Monday, October 22, 2012 10:41 AM > To: FlightGear developers discussions > Subject: [Flightgear-devel] Fg Fuel System Changes > > > > > HI, > > Had been running with fg-2.4 for some time and finally getting around > to upgrading to 2.8. Seems there where some changes to the fuel and > tanking system in JSBSiim starting with 2.6. It "breaks" the mods > made to the code to support the 737/747 full scale cockpits tanking > models in 2.4 and prior. > > In large aircraft such as the 7x7 types the fuel is NOT drawn equally > from all tanks. Rather, in terms of graph theory, you should think of > the tanking system as a fully connected graph for the tanks, engines, > and crossfeed valves. Such that any feed tank can feed any engine or > all engines can draw from one feed tank. The case where all tanks > feed to a manifold that supplies all engines is just one special case. > > At any rate, is there a writeup on the changes? Or might the author > find some time to describe what was changed? > > Having trouble understanding how to the "FuelExpended" variable to a > specific tank and how to pass the tank contents onto the flightgear > side. > Here is how it works in my 2.4: > > this was the mod to the FGEngine::ConsumeFuel(void) in 2.4 > > if ( Active_Tank >= 0 ) { > Tank = Propulsion->GetTank(Active_Tank); > if (Tank->GetType() == FGTank::ttFUEL) { > //Fshortage += Tank->Drain(CalcFuelNeed()/TanksWithFuel); // > SEE NOTE ABOVE > Fshortage += Tank->Drain(CalcFuelNeed() ); > } > } else Starved = true; > > where "Active_Tank" was a value passed from the cockpit fuel control > panel (via network controls) to fg and the fg/jsbsim interface in > jsbsim.cpp. > > and this was the code to transfer fuel in the 737 model to the center > feed tank > > // Remove equal amount of fuel from each feed tank. > // FuelNeeded = FuelToBurn/TanksWithFuel; > // for (i=0; i<FeedList.size(); i++) { > // Tank = Propulsion->GetTank(FeedList[i]); > // Tank->Drain(FuelNeeded); > // } > > Tank_0 = Propulsion->GetTank(0); > double center_fuel = Tank_0->GetContents(); > if ( center_fuel < 6000.0 ) transfer = true; > else if ( center_fuel > 9000.0 ) transfer = false; > if ( transfer ) { > Tank_1 = Propulsion->GetTank(1); > if ( Tank_1->GetContents() > 100.0 ) { > Tank_0->Fill( 0.040 ); > Tank_1->Drain( 0.040 ); > } > Tank_2 = Propulsion->GetTank(2); > if ( Tank_2->GetContents() > 100.0 ) { > Tank_0->Fill( 0.0401 ); > Tank_2->Drain( 0.0401 ); > } > } > > So setting Active_Tank=0 has both engines drawing from the center tank > and when it drops below 6000# the fuel transfer system fills until it > reaches 9000# or the pilot can select, via the fuel control panel, to > feed each engine directly or crossfeed as desired. Setting > Active_Tank=-1 starves the engine. > > The 747 is much more complex and, in the interest of brevity, is not > discussed. > > The entire function "ConsumeFuel" is removed and having some > difficulty undestanding how "FuelExpended" is interfaced to draw down > the tanks. > > Any help would be apprecuated. > > John > > > ______________________________________________________________________ > > > > ------------------------------------------------------------------------------ > Everyone hates slow websites. So do we. > Make your web apps faster with AppDynamics > Download AppDynamics Lite for free today: > http://p.sf.net/sfu/appdyn_sfd2d_oct > _______________________________________________ Flightgear-devel mailing list > Flightgear-devel@lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/flightgear-devel ------------------------------------------------------------------------------ Everyone hates slow websites. So do we. Make your web apps faster with AppDynamics Download AppDynamics Lite for free today: http://p.sf.net/sfu/appdyn_sfd2d_oct _______________________________________________ Flightgear-devel mailing list Flightgear-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/flightgear-devel