MEGAsquirt A place to collectively sort out this megasquirt gizmo

What does your MAT Air Density Table look like?

Old 05-17-2016, 09:33 AM
  #1  
Newb
Thread Starter
 
compuw22c's Avatar
 
Join Date: Mar 2012
Posts: 42
Total Cats: 0
Default What does your MAT Air Density Table look like?

Hey Guys,

Trying to get this thing tuned perfectly. Finally got some ID1000 injectors, their data for megasquirt with regards to dead time and small pulse widths helped me get closer to perfect for sure. But I recently started tuning my MAT air density table and am curious to see what other people are running. I basically ditched my old table which looked like this:


Because I seemed to be having issues with changing temperatures, I found one I think Braineak said he was running (or one of the "great Oracle users"), plugged that in and modified it just a bit:


But now after autotuning with this table when it was a bit cold (45-50F maybe) I noticed after it warmed up a little bit I seemed to be going a bit lean in places (target of 15.2, was hitting 16).

What does everyone else's tables look like? Should it look more like my first table that I found from...somewhere or should it be flatter like the second picture? This is on firmware 1.4.1. I feel like it should be relatively flat as it mentions it takes into account the ideal gas law, so I'm assuming this table is just adjusting based on that table already? Any help would be great. I enjoy this whole tuning thing, but trying to track down every little variable that might be throwing everything off for you is a bit daunting... Also any tuning advice for tuning the MAT air density table would be appreciated. I understand what it does (accounts for varying density based on temperature) but would be interesting to see how others go about tuning it in terms of procedure (looking at logs and adding fuel when it's running a bit lean? or maybe try and do it based on idle?). Thanks!
Attached Thumbnails What does your MAT Air Density Table look like?-80-mat_air_density_before_397a31869d781c02bbfb8d3a2c117916b62e0c7a.jpg   What does your MAT Air Density Table look like?-80-mat_air_density_after_5425704dac3c83079531a890c1cb94af0547152a.jpg  
compuw22c is offline  
Old 05-17-2016, 10:17 AM
  #2  
Elite Member
iTrader: (17)
 
pdexta's Avatar
 
Join Date: Aug 2007
Location: Knoxville, TN
Posts: 2,949
Total Cats: 182
Default

Interested in this too as I've realized mine needed to be tweaked a bit. I'll post mine when I get home. I seem to have gotten the 85-140 range working pretty well for me.

We don't get to use the left side of the graph in South FL so I guess I'll have to steal that from someone.
pdexta is offline  
Old 05-17-2016, 10:25 AM
  #3  
VladiTuned
iTrader: (76)
 
18psi's Avatar
 
Join Date: Apr 2008
Posts: 35,821
Total Cats: 3,481
Default

not sure why people use values like -40 and 240 for temps, I've yet to see anyone go outside 30-180F

if I remember correctly, mine are about 105-99, almost linear but not quite.

it all depends on your specific location/temp/weather, and the rest of your tune. if the car is tuned properly, you will need very little correction
18psi is offline  
Old 05-17-2016, 10:42 AM
  #4  
Boost Czar
iTrader: (62)
 
Braineack's Avatar
 
Join Date: May 2005
Location: Chantilly, VA
Posts: 79,483
Total Cats: 4,076
Default

yeah mine had a ~105-95 swing. I actually tuned it so when it was like 10°F or 90°F outside, my enrichment (ego) weren't compensating.

you want to complete 100% it across until your fuel map is completely tuned. THEN you can start applying the MAT corrections when you notice your EGO sitting off 100% when it's very warm or very cold out. (don't use it to combat heatsoak).
Braineack is offline  
Old 05-17-2016, 10:45 AM
  #5  
Newb
Thread Starter
 
compuw22c's Avatar
 
Join Date: Mar 2012
Posts: 42
Total Cats: 0
Default

Originally Posted by Braineack
yeah mine had a ~105-95 swing. I actually tuned it so when it was like 10°F or 90°F outside, my enrichment (ego) weren't compensating.
​^^ I want my car to run like this guy's. Seriously almost wanna hop in the car with some beer, a mail order bride and a bunch of mystery pills and drive over to VA and offer them up for you to tune my car. Sure, we'd both make some bad decisions, but think of how much I could learn...while the walls were breathing and I was puking on your new bride who may or may not have been a male before chernobyl
compuw22c is offline  
Old 05-17-2016, 10:50 AM
  #6  
Boost Czar
iTrader: (62)
 
Braineack's Avatar
 
Join Date: May 2005
Location: Chantilly, VA
Posts: 79,483
Total Cats: 4,076
Default

lol. i invested a great deal of time tuning and learning. so then i can stand up here on my ivory tower and laugh at you mere mortals.
Braineack is offline  
Old 05-17-2016, 10:52 AM
  #7  
VladiTuned
iTrader: (76)
 
18psi's Avatar
 
Join Date: Apr 2008
Posts: 35,821
Total Cats: 3,481
Default

learning? aint nobody got time fo dat
18psi is offline  
Old 05-17-2016, 10:58 AM
  #8  
Newb
Thread Starter
 
compuw22c's Avatar
 
Join Date: Mar 2012
Posts: 42
Total Cats: 0
Default

Oh don't get me wrong, I do want to learn. And I have learned quite a bit, and still am. And still want to continue. But at a certain point it is very helpful to know a) what others are using so you have some kind of ballpark to look in (or know if your settings are horribly off) and b) procedure. It's one thing to understand what a variable does (in this case, adds/subtracts PW based on MAT), but it's another to understand methodology, which things to tune first, best practices. I'm sure people much more experienced than I am have a set of "procedures", a pattern, an order if you will of things they tune first so that they're not chasing their tails. I'd love to watch one of you guys tune a car so I can watch you guys fly through what would take me months of trial and error.

Also, learning is easy when documentation is awesome. Megasquirt documentation is usually not very good (though I notice the MS Pro manual is much better than the MS3 manual, so that's helpful for tuning, but wtf, copy and paste that **** into the MS3 manual). In fact, because I have a coding background I've had better luck understanding things like how exactly the EBC calculates duty cycle by just reading the source code itself. I love learning, it's part of the reason I undertook this project. But I'm also not going to try building an Ikea bookshelf while absolutely refusing to look at the directions. If there's a way to learn better, quicker, and from someone who knows what they're doing, I'm going to take advantage of that. What I DON'T want to do is drop my car off at a tuner and say "I'll see ya thursday"
compuw22c is offline  
Old 05-17-2016, 10:59 AM
  #9  
Boost Czar
iTrader: (62)
 
Braineack's Avatar
 
Join Date: May 2005
Location: Chantilly, VA
Posts: 79,483
Total Cats: 4,076
Default

yeah luckily i have one of the ms-extra developers as a contact, and just bothered him until he'd either change the code for me, build it in, or explain how it worked. :P
Braineack is offline  
Old 05-17-2016, 11:05 AM
  #10  
VladiTuned
iTrader: (76)
 
18psi's Avatar
 
Join Date: Apr 2008
Posts: 35,821
Total Cats: 3,481
Default

zero out the table (or "100 out" in this case), tune the car, then adjust it in varying climates. ve table has to be completed before you tune mat correction or you're just fighting yourself
18psi is offline  
Old 05-17-2016, 11:06 AM
  #11  
Senior Member
iTrader: (8)
 
cyotani's Avatar
 
Join Date: Jan 2012
Location: Azusa, CA
Posts: 1,407
Total Cats: 116
Default

Does this correction stack on some type of densiy calc in the speed density equation? Like a fudge factor to correct for misc errors and variations that aren't compensated for.

This is what theoretical should be if there is absolutely no temperature variable in the speed density fueling calc... This is only looking at 14.6 psia ambient pressure (sea level ish) which would be at WOT for a NA car. This table can be comparable to a weather correction factor for a dyno which compare the current ambient density to standard day (SAE J1349 etc.) I assumed 86 deg F standard day to match the tuner studio table (everything is normalized to the air density at 86 deg F).

It looks like they assumed a lower ambient pressure to get their theoretical calibration... But really you need a separate temperature compensation curve for each pressure and interpolate between them like a 3D map...

So I'm confused. I just want to learn more about what's going on as well. Has anyone looked at the firmware code and the speed density calc to see how temperature in handled in their equations? This seems to just be a fudge factor to account for misc errors and uncountable variables. if you guys are getting well tuned values between 95 and 105% then that must be the case?



EDIT: theoretical density calculation does not change with different ambient pressures. A 1D cal table like megaqsuirt uses is sufficient for temp compensation, a 3D map is not needed).



Attached Thumbnails What does your MAT Air Density Table look like?-80-capture_3dca4fa8bc5184be21535658d5c06211274a6e25.jpg   What does your MAT Air Density Table look like?-80-capture2_9f4c44ec324c986e248878aff5a31373738498a3.jpg  

Last edited by cyotani; 05-17-2016 at 12:13 PM.
cyotani is offline  
Old 05-17-2016, 11:16 AM
  #12  
Senior Member
iTrader: (8)
 
cyotani's Avatar
 
Join Date: Jan 2012
Location: Azusa, CA
Posts: 1,407
Total Cats: 116
Default

To tune it by trial and error you can set all to 100% the day you tune your vehicle. The ambient temperature (or your IAT temp) the day you tune is your 100% value and should never change. Then when you drive in hotter summer days and colder winter days you can datalog and average your short term fuel trims over a long run in mixed driving situations. Apply that averaged STFT to the temp compensation table and repeat to see if the average STFT is close to zeroed out. Repeat this for as many ambient temperature conditions that you can. I'd zero out and disable and long term fuel trims if you have that enabled.
cyotani is offline  
Old 05-17-2016, 11:19 AM
  #13  
Boost Czar
iTrader: (62)
 
Braineack's Avatar
 
Join Date: May 2005
Location: Chantilly, VA
Posts: 79,483
Total Cats: 4,076
Default

the default curve actually matches that theo:



the problem is, the ideal gas law itself doesn't account for all the other variables with a running engine... it was hella-aggressive and posed many problems and why they changed the way the table works; we were implementing anti-corrections tables just to zero out the built in ideal-gaw law code.

this table is how temp is handled in the fuel equations.
Braineack is offline  
Old 05-17-2016, 11:27 AM
  #14  
VladiTuned
iTrader: (76)
 
18psi's Avatar
 
Join Date: Apr 2008
Posts: 35,821
Total Cats: 3,481
Default

one of the big things that affects it is injectors/fuel heatsoaking

not the intake. not the sensor.
18psi is offline  
Old 05-17-2016, 11:38 AM
  #15  
Senior Member
iTrader: (8)
 
cyotani's Avatar
 
Join Date: Jan 2012
Location: Azusa, CA
Posts: 1,407
Total Cats: 116
Default

Originally Posted by Braineack
the default curve actually matches that theo:



the problem is, the ideal gas law itself doesn't account for all the other variables with a running engine... it was hella-aggressive and posed many problems and why they changed the way the table works; we were implementing anti-corrections tables just to zero out the built in ideal-gaw law code.

this table is how temp is handled in the fuel equations.
ahh, good to know that science still works...

So temperature must be in the fueling calc, ( i think you put a pic with that info but I can't see it at the moment) and this MAT compensation table is a fudge factor table, then it should not be calibrated as default as the theoretical Wheather correction factor compensation curve...
cyotani is offline  
Old 05-17-2016, 11:43 AM
  #16  
Boost Czar
iTrader: (62)
 
Braineack's Avatar
 
Join Date: May 2005
Location: Chantilly, VA
Posts: 79,483
Total Cats: 4,076
Default

MegaSquirt Fuel Equation

What MegaSquirt® does is take this downloaded REQ_FUEL number and then multiply (or adds) values that scale this number, to come up with the injected pulse width [PW]. Therefore, pulse width is:
PW = REQ_FUEL * VE * MAP * E + accel + Injector_open_time


The "E" above is the multiplied result of all enrichments, like warm-up, after-start, barometer and air temperature correction, closed-loop, etc:



E = gamma_Enrich = (Warmup/100) * (O2_Closed Loop/100) * (AirCorr/100) * (BaroCorr/100)and

  • Warmup is the warm-up enrichment value from the table the user enters in MegaTune,
  • O2_Closed Loop is the EGO adjustment based on the EGO sensor feedback and the EGO settings the user enters in MegaTune,
  • AirCorr is the adjustment for air density (based on the intake air temperature), and
  • BaroCorr is the barometric correction based on the ambient air pressure (usually taken at start-up, but a second baro pressure sensor can be added to MegaSquirt-II for continuous updates to the BaroCorr).
info dump.
Braineack is offline  
Old 05-17-2016, 11:57 AM
  #17  
Junior Member
iTrader: (1)
 
dr_boone's Avatar
 
Join Date: Dec 2015
Location: Tulsa
Posts: 189
Total Cats: 17
Default

A little bit of a thread jack....
Is there a list of things that should be zeroed out of turned off to tune fuel map? My fuel tuning seems to be a little inconsistent and I'm sure some setting(s) are fighting against me.
dr_boone is offline  
Old 05-17-2016, 11:59 AM
  #18  
Junior Member
iTrader: (1)
 
dr_boone's Avatar
 
Join Date: Dec 2015
Location: Tulsa
Posts: 189
Total Cats: 17
Default

I think you mostly answered my question while I was typing
dr_boone is offline  
Old 05-17-2016, 12:08 PM
  #19  
Senior Member
iTrader: (8)
 
cyotani's Avatar
 
Join Date: Jan 2012
Location: Azusa, CA
Posts: 1,407
Total Cats: 116
Default

Originally Posted by Braineack
info dump.
Thanks for the info.


So it looks like all of the temperature density compensation is handled solely by that MAT density table. So it is not a fudge factor table, it is how the Speed Density equation compensates for changes mass of oxygen available due to changes in air charge temperature. If that is the case I would not expect the calibration of that curve to change much from the default calibration (ideal gas law equation).

But if you're getting 95-105% as it's range and that's pretty well dialed then the speed density engine fueling model must not account for a lot of misc errors.

Oh well, good to know what's going on behind the scenes there at least

PS: I ran the density values for 12 and 8 psi and it matched 14.6 psi so the MAT density equation is not dependent on pressure (I was wrong in an early post, 1 1D calibration is sufficient, not a 2D MAP),
cyotani is offline  
Old 05-17-2016, 12:11 PM
  #20  
VladiTuned
iTrader: (76)
 
18psi's Avatar
 
Join Date: Apr 2008
Posts: 35,821
Total Cats: 3,481
Default

I already posted the other factors. You ignore them. Oh well
18psi is offline  

Thread Tools
Search this Thread
Quick Reply: What does your MAT Air Density Table look like?



All times are GMT -4. The time now is 09:12 AM.