ME7Tuner is software that provides tools to help calibrate the MAF, primary fueling and torque/load requests. It is somewhat specific to an ME7 M-box ECU.
There are vast number of binary formats for ME7. TunerPro is equipped to handle most of them and supports MSB<->LSB, and other complex definitions, but ME7Tuner is not. ME7Tuner is designed to work with a specific binary format, specifically the B5 S4 2.7T M-box. If you have a different binary format, there is a possibility that ME7Tuner will not work.
I have no intention of modifying ME7Tuner to work with other binary formats, but you can certainly do so yourself.
See the example binary format and xdf in the example
directory to see the supported binary format.
ME7Tuner is free software written by some guy on the internet. ME7Tuner comes with no warranty. Use at your own risk!
It is a certainty that ME7Tuner will produce garbage outputs at some point you will damage your engine if you do not know what you are doing. ME7Tuner is software that helps you calibrate your engine. It does not calibrate your engine for you. It is not a replacement for knowledge of how to calibrate an engine.
ME7Tuner is packaged as a JAR file. You will need to have Java installed on your system to run it. You can download Java from here.
Note that ME7Tuner built against Java 17, so you will need to have Java 17 installed on your system to run it. Once you have Java 17 installed and the JAR file, simply double click the JAR file to run it.
- Tuning Philosophy
- KRKTE(Primary Fueling)
- MLHFM (MAF Scaling)
- MLHFM - Closed Loop
- MLHFM - Open Loop
- PLSOL (Pressure -> Load)
- KFMIRL (Load)
- KFMIOP (Torque)
- KFZWOP (Optimal Ignition Timing)
- KFZW/2 (Ignition Timing)
- KFVPDKSD (Throttle Transition)
- WDKUGDN (Alpha-N Fueling)
- LDRPID (Feed-Forward PID)
Everything in ME7 revolves around requested load (or cylinder fill).
- Read Engine load
The simplified description of how ME7 works is as follows:
In ME7, the driver uses the accelerator pedal position to make a torque request. Pedal positions are mapped to a torque request (which is effectively a normalized load request). That torque request is then mapped to a load request. ME7 calculates how much pressure (boost) is required to achieve the load request which is highly dependent on hardware (the engine, turbo, etc...) and also the weather (cold, dry air is denser than hot, moist air). When tuning ME7 the goal is to calibrate the various maps to model the hardware and the weather accurately. If modeled incorrectly, ME7 will determine something is wrong and will protect the engine by reducing the capacity to produce power at various levels of intervention.
Note that no amount of modifications (intake, exhaust, turbo, boost controllers, etc...) will increase the power of the engine if actual load is already equal to or greater than requested load. ME7 will use interventions to decrease actual load (power) to get it equal requested load. You must calibrate the tune to request more load to increase power.
ME7Tuner can provide calculations that allow ME7 to be tuned with accurate airflow, pressure and load measurements which can simplify calibrations.
You probably don't need to use ME7Tuner. For most applications, the stock M-box is sufficient to support the power you want to make.
In general ME7Tuner is only useful if you need to request more than 191% load on an M-Box. This means that K03 and most K04 configurations do not need the level of calibrations provided by ME7Tuner.
The following information should give you a good estimate of what hardware you need to achieve a given power goal, how much calibration you will need to do to support that power and if ME7Tuner is useful to you.
Refer to the following tables to determine if ME7Tuner is useful to you:
The stock MAP limit is the primary limitation to calibration. A stock M-box has just enough overhead to support K04's within their optimal efficiency range.
- 2.5bar absolute (~22.45 psi relative)
Read MAP Sensor
Read 5120 Hack
Unless you are planning on making more than 2.5 bar absolute (~22.45 psi relative) of pressure, you don't need to use ME7Tuner.
- K03 16 lbs/min (120 g/sec) (~160hp)
- K04 22 lbs/min (166 g/sec) (~225hp)
- RS6 25 lbs/min (196 g/sec) (~265hp)
- 650R 37 lbs/min (287 g/sec) (~370hp)
- 770R 48 lbs/min (370 g/sec) ((~490hp)
Note: Remember to multiply by the number of turbo. The 2.7T has two turbos.
Unless you are planning on maxing your K04's, or have a larger turbo frame, you don't need to use ME7Tuner.
- Stock Bosch/Hitachi 73mm (337 g/sec)
- Stock RS4 83mm (498 g/sec)
- Stock Hitachi 85mm (493 g/sec)
- HPX 89mm (800 g/sec)
Read MAF Sensor
Unless you are planning on maxing the stock MAF, or have a larger MAF, you don't need to use ME7Tuner.
- K03 16 lbs/min air -> ~1000 cc/min fuel
- K04 22 lbs/min air -> ~1400 cc/min fuel
- RS6 25 lbs/min air -> ~1600 cc/min fuel
- 650R 37 lbs/min air -> ~2200 cc/min fuel
- 770R 48 lbs/min air -> ~3024 cc/min fuel
Note: Remember to multiply air by the number of turbos and divide fuel by the number of fuel injectors. The 2.7T has 6 fuel injectors.
- K03 16 lbs/min air -> ~340 cc/min
- K04 22 lbs/min air -> ~470 cc/min
- RS6 25 lbs/min air -> ~540 cc/min
- 650R 37 lbs/min air -> ~740 cc/min
- 770R 48 lbs/min air -> ~1000 cc/min
Read Fuel Injectors
- K03 16 lbs/min air -> ~155% load -> ~320hp
- K04 22 lbs/min air -> ~210% load -> ~440hp
- RS6 25 lbs/min air -> ~240% load -> ~500hp
- 650R 37 lbs/min air -> ~354% load -> ~740hp
- 770R 48 lbs/min air -> ~460% load -> ~960hp
Note that a stock M-box has a maximum load request of 191%, but can be increased with the stock MAP sensor to ~215%.
ME7Tuner works from a binary file and an XDF definition file. You will need to load these using the ME7Toolbar.
- File -> Open Bin
- XDF -> Select XDF
You will need to tell ME7Tuner what definition you want to use for all fields. This is necessary because many XDF files have multiple definitions for the same map using different units. Pay attention to the units!
ME7Tuner makes the following assumptions about units:
- KRKTE - ms/%
- MLHFM - kg/h
- KFMIOP - %
- KFMIRL - %
- KFZWOP - grad KW
- KFZW - grad KW
- KFVPDKSD - unitless
- WDKUGDN - %
- KFWDKMSN - %
- KFLDRL - %
- KFLDIMX - %
ME7Tuner automatically filters map definitions base on what is in the editable text box.
In some cases ME7Tuner can parse logs automatically to suggest calibrations. There are often many names of the same logged parameter.
You must define the headers for the parameters that the log parser uses here.
In general, you should start with a stock binary and follow order provided by this document.
It is critical that you calibrate primary fueling first.
Fueling is the one and only known constant to calibrate the MAF. It is highly recommended that you calibrate your fueling with an accurate specification of the fuel injectors.
When the fueling has been calibrated, you can take logs to have ME7Tuner suggest a MAF scaling.
Once the fueling and MAF are calibrated load request, ignition advance and pressure (boost) requested can be calibrated.
- Read Primary Fueling first
The first step is to calculate a reasonable value for KRKTE (primary fueling). This is the value that allows the ECU to determine how much fuel is required to achieve a given AFR (air fuel ratio) based on a requested load/cylinder filling. It is critical that KRKTE is close to the calculated value. If your KRKTE deviates significantly from the calculated value, your MAF is likely over/under scaled.
Pay attention to the density of gasoline (Gasoline Grams per Cubic Centimeter). The stock M-box assumes a value of 0.71 g/cc^3, although the generally accepted density of gasoline is 0.75 g/cc^3. Also consider that ethanol has a density of 0.7893 g/cc^3 so high ethanol blends can be even denser.
Note that the decision to use a fuel density of 0.71 g/cc^3 (versus ~0.75 g/cc^3) will have the effect of under-scaling the MAF ( more fuel will be injected per duty cycle so less airflow will need to be reported from the MAF to compensate). As a result, the measured engine load (rl_w) will be under-scaled which is key to keeping estimated manifold pressure (ps_w) slightly below actual pressure (pvdks_w) without making irrational changes to the VE model (KFURL) which converts pressure to load and load to pressure.
The KRKTE tab of ME7Tuner will help you calculate a value for KRKTE. Simply fill in the constants with the appropriate values.
When you are satisfied with KRKTE, you will need to get your MAF scaled to the fuel injectors.
Read MAF
In any MAFed application it may be necessary to increase the diameter of the MAF housing to extend the range of the sensor (while also reducing resolution) or to change MAF sensors entirely.
In general, a MAF sensor can be moved to a larger housing to extend the range of the sensor with a constant correction to the linearization curve (MLHFM) that defines the conversion between the MAF sensors voltage output to an estimation of airflow. This constant correction is usually based on the change in diameter from the current MAF housing to the new MAF housing.
If the MAF diameter can not be increased enough to achieve the desired range a new sensor (accompanied by a corresponding linearized curve) can be used to increase the range of the MAF housing.
Read Diameter Effect on Airflow
Significantly increasing the diameter of the MAF housing can change the airflow through the MAF housing enough that it results in a non-linear change to the original linearization curve (MLHFM). Since the injector scaling (KRKTE) is fixed (and linear) this means making changes in KFKHFM and/or FKKVS to get the fuel trims close to 0% corrections. This is difficult and tedious work. It is more simple to scale the MAF accurately and leave KFKHFM and FKKVS more or less alone.
Changing to a MAF sensor with an increased range may be a better option than reusing your stock sensor in a larger diameter housing. Even if a transfer function is provided, you may find that the new sensor and housing in your specific configuration doesn't flow exactly as expected due to non-linearities in airflow at specific (or all) air velocities or other unknown irregularities. The original curve is inaccurate enough that KFKHFM and/or FKKVS would have to be significantly modified to get the engine to idle and WOT fueling safe. Again, it is more simple to scale the MAF accurately and leave KFKHFM and FKKVS more or less alone.
Presumably, incorrect MAF linearization will lead to irrational changes in the following places at a minimum:
- Fueling -> KFKHFM/FKKVS/LAMFA/WDKUGDN
- VE model -> KFURL
- Load request -> LDRXN/KFMIRL
Having to make irrational changes in these places makes tuning considerably more difficult overall compared to just having an accurate MAF.
To scale a MAF we need a source of truth to make changes against we can do that in two ways based on fueling. Since we know the size of the injectors, the injector duty cycle and the air-fuel ratio... actual airflow can be calculated and compared against the MAF to make corrections.
- Closed loop fueling uses the narrowband O2 sensors and fuel trims to make corrections
- Open loop fueling uses a wideband 02 sensor to make corrections
This algorithm is roughly based on mafscaling.
The average of your LTFT and STFT corrections at each voltage for MLHFM are calculated and then applied to the transformation.
The Correction Error is calculated as LTFT STFT at each measured voltage for MLHFM.
The Total Correction is the average of the mean and mode of the Correction Errors at each measured voltage for MLHFM.
The corrected kg/hr transformation for MLHFM is calculated as current_kg/hr * ((tot_corr% / 100) 1).
The key is to get as much data as possible. Narrow band O2 sensors are noisy and slow, so the algorithm depends on lots of data and averaging to estimate corrections. The Closed Loop parser is designed to parse multiple log files at one time so you can compile logs over a period of time. The tune/hardware cannot change between logs. Also, it is advisable to log in consistent weather.
- Get ME7Logger
Log the following parameters:
- RPM - 'nmot'
- STFT - 'fr_w'
- LTFT - 'fra_w'
- MAF Voltage - 'uhfm_w'
- Throttle Plate Angle - 'wdkba'
- Lambda Control Active - 'B_lr'
- Engine Load - rl_w'
Logging Instructions:
- Log long periods of consistent throttle plate angles and boost. We are trying to capture data where the MAF's rate of change (delta) is as small as possible. You don't have to stop/start logging between peroids of being consistent since ME7Tuner will filter the data for you, but you still want as much of this data as possible.
- Stay out of open-loop fueling. We don't care about it (right now). Like inconsistent MAF deltas, ME7Tuner will filter out open-loop data.
- Get at least 30 minutes of driving on a highway. Vary gears and throttle positions often to get measurements at as many throttle angles and RPM combinations as possible. Finding a highway with a long, consistent incline is ideal since you can 'load' the engine resulting in higher MAF voltages without going into open-loop fueling. Remember to slowly roll on and off the throttle. Sudden changes will result in less usuable data.
- Get at least 30 minutes of typical 'city' driving. Stop lights, slower city speeds, lots of gears and throttle positions. Remember to be as consistent as possible rolling on and off of the throttle.
- Get at least 15 minutes of parking lot data. Drive slowly around the parking lot in 1st and 2nd gear. Stop and start often. Vary the throttle plate and RPM as much as possible.
- Save your log and put it into a directory (along with other closed-loop logs from the same tune if desired).
- Open ME7Tuner and click on the "Close Loop Fueling" tab at the top
- Click the "ME7 Logs" tab on the left side of the screen and click the "Load Logs" button at the bottom. Select the directory that contains your closed loop logs from ME7Logger. The derivative (dMAFv/dt) of the logged MAF voltages should plot on the screen. The vertical lines represent clusters of data at different derivative (rates of change, delta, etc...) for a given MAF voltage. You want to select the data under the smallest derivative possible while also including the largest voltage range as possible. I find 1 to be a good derivative to start with.
- Green samples are included by the filter.
- Red samples are excluded by the filter.
-
Click "Configure Filter" in the bottom left corner of the screen. This is where you can configure the filter for the incoming data. You can filter data by a minimum throttle angle, a minimum RPM, a maximum derivative (1 is usually a good start).
-
Click the "Correction" tab on the left side of the screen. You will see the current MLHFM plotted in blue and the corrected MLHFM plotted in red. The corrected MLHFM is also displayed in a table on the right hand side of the screen and can be copied directly into TunerPro. Clicking "Save MLFHM" will allow you to save MLFHM to a .csv file which can be loaded for the next set of corrections.
- Click the "dMAFv/dt" tab at the bottom of the screen. This displays the derivative of the filtered data used to calculate the corrections. Remember that a smaller derivative is better because the MAF's rate of change smaller (more stable).
- Click the "AFR Correction %" tab at the bottom of the screen. This displays the raw point cloud of Correction Errors with the Mean, Mode and Final AFR correction plotted on-top of the point cloud. Note how noisy the Correction Errors are.
-
Load the corrected MLHFM into a tune, take another set of logs and repeat the process until you are satisfied with your STFT/LTFT at idle and part throttle.
-
You may notice MLHFM starting to become 'bumpy' or 'not smooth' (for lack of a better term). This could be due to non-linearities in airflow due to changes in airflow velocity, but it is likely just noise we want to get rid of. ME7Tuner has an option to fit your curve to a polynomial of a user configurable degree which will "smooth" your curve. Click the "Fit MLHFM" button with a reasonable polynomial degree (I find a 6th degree function to work well) to smooth your curve.
Before attempting to tune open loop fueling, you need to have KRKTE (fueling) and closed loop fueling nailed down. You also need a wideband O2 sensor that is pre-cat. A tail sniffer likely isn't sufficient here.
Note that ME7Tuner is designed to be used with Zeitronix logs, but logs from any wideband can be modified to use the expected headers.
Please open an issue with an example log file if you would like other formats to be supported.
This algorithm is roughly based on mafscaling.
The error from estimated airflow based on measured AFR STFT LTFT at each voltage for MLHFM are calculated and then applied to the transformation.
The raw AFR is calculated as wideband AFR / ((100 - (LTFT STFT)) / 100).
The AFR % error is calculated as (raw AFR - interpolated AFR) / interpolated AFR * 100), where interpolated AFR is interpolated from (raw AFR - ECU Target AFR) / ECU Target AFR * 100).
The corrected kg/hr transformation for MLHFM is calculated as current_kg/hr * ((AFRerror% / 100) 1).
Unlike closed loop corrections, open loop logs must be contained a single ME7Logger file and a single Zeitronix log. Both ME7Logger and Zeitronix logger need to be started before the first pull and stopped after the last pull. ME7Tuner correlates the ME7Logger logs and Zeitronix logs based on throttle position so both sets of logs need to contain the same number of pulls.
- Get ME7Logger
Log the following parameters:
- RPM - 'nmot'
- STFT - 'fr_w'
- LTFT - 'fra_w'
- MAF Voltage - 'uhfm_w'
- MAF g/sec - 'mshfm_w'
- Throttle Plate Angle - 'wdkba'
- Lambda Control Active - 'B_lr'
- Engine Load - rl_w'
- Requested Lambda - 'lamsbg_w'
- Fuel Injector On-Time - 'ti_bl'
Logging Instructions:
- Start both ME7Logger and the Zeitronix Logger and do as many WOT pulls as possible. Perform WOT pulls in 2nd and 3rd gear from 2000 RPM if possible. Stop both loggers when you are finished.
- Save your logs and put them into a directory
- Open ME7Tuner and click on the "Open Loop Fueling" tab at the top
- Click the "ME7 Logs" tab on the left side of the screen.
- Click "Load ME7 Logs" and select the ME7Logger .csv file
- Click "Load AFR Logs" and select the Zeitronix .csv file
- You should see the requested AFR from ME7 plotted in orange and the actual AFR from Zeitronix in red. If the requested AFR doesn't match the actual AFR the MAF scaling is incorrect.
- Click the "Airflow" tab at the bottom of the screen. You will see the airflow measured by the MAF in blue and the estimated airflow from the AFR in red. The measured airflow and estimated airflow should be the same or there the MAF scaling is incorrect.
-
Click the "Configure" filter button in the bottom left of the screen. You can see the minimum throttle angle, minimum RPM, minimum number of points from ME7Logger to count as a pull, the minimum number of points from Zeitronix to count as a pull and a maximum AFR. Note that Zeitronx can log at 40Hz while ME7Logger is usually 20Hz, so you may need to think about the number of points if your logging frequency is different.
-
Click the "Correction" tab on the left side of the screen. You will see the current MLHFM plotted in blue and the corrected MLHFM plotted in red. The corrected MLHFM is also displayed in a table on the right side of the screen and can be copied directly into TunerPro. Clicking "Save MLFHM" will allow you to save MLFHM to a .csv file which can be loaded for the next set of corrections.
- Click the "AFR Correction %" tab at the bottom of the screen. This displays the raw point cloud of Correction Errors with the Mean, Mode and Final AFR correction plotted on-top of the point cloud. Note how noisy the Correction Errors are.
-
Load the corrected MLHFM into a tune, take another set of logs and repeat the process until you are satisfied with your AFR at WOT.
-
You may notice MLHFM starting to become 'bumpy' or 'not smooth' (for lack of a better term). This could be due to non-linearities in airflow due to changes in airflow velocity, but it is likely just noise we want to get rid of. ME7Tuner has an option to fit your curve to a polynomial of a user configurable degree which will "smooth" your curve. Click the "Fit MLHFM" button with a reasonable polynomial degree (I find a 6th degree function to work well) to smooth your curve.
The pressure to load conversions are provided as a sanity check. The key is that the only parameter that affects load is pressure. The barometric pressure, intake air temperature and the pressure to load conversion (KFURL) are assumed to be constant.
In this simplified model the assumptions mean that as long as the turbocharger can produce the boost it will make as much power as any other turbocharger that can provide the boost. In other words, 16psi is 16psi no matter what produces that 16psi. Despite the simplicity of this model I have found it to be very consistent with real world results.
You can edit the barometric pressure, the intake air temperature and pressure to load conversion to see how ME7 would respond to these parameters changing in the real world.
This estimates how much pressure is required to achieve a given load request. This is useful for determining if your hardware can support a given load request.
Note that for 2.7L of displacement to approach 900 horsepower the pressure required is approaching 3bar (45psi) relative and 4bar (60psi) absolute.
ME7Tuner will calculate the estimated airflow for a given load based on engine displacement (in liters) and RPM.
This estimates how much airflow is required to achieve a given load request. This is useful for determining if your MAF can support a given load request.
ME7Tuner will calculate the estimated horsepower for a given load based on engine displacement (in liters) and RPM.
KFMIOP describes optimal engine torque.
Note that KFMIRL is the inverse of KFMIOP, not the other way around.
KFMIOP is the optimum boost table for the engine's configuration, but it is expressed as a normalization relative to the maximum limit of the MAP sensor.
'Torque' is a normalized value between 0 and 1 (or 0% and 100%). KFMIOP represents a table of optimum torque values for the engine at a given load and RPM.
When we look at KFMIOP for a B5 S4 (M-box) we can see that the table is set up around a 2.5 bar (36psi) absolute MAP sensor limit (the stock MAP sensor limit). A pressure of 2.5 bar run through the rlsol calculations to convert to a load request ends up being ~215% load.
The maximum pressure that a K03 can efficiently produce is about 1bar (15psi) relative (2bar absolute) of pressure which results in ~191% load when run through the rlsol calculations.
On the stock M-box KFMIOP you will note that the maximum load is limited to 191% and maximum torque is 89% which is because 191 is 89% of 215... or 191 load is 89% of 215 maximum load. Each column in KFMIOP is mapping itself to a normalized peak torque value given by the peak load of 215% which is defined by the 2.5 bar MAP sensor.
KFMIOP can be converted to a boost table via the plsol calculation after you have derived peak load from the map. Looking at the boost table it appears to be created empirically (on an engine dyno) and is tuned specifically for stock hardware (K03 turbos, etc...). So, unless you have access to an engine dyno there is no way to easily derive an OEM quality KFMIOP for your specific hardware configuration.
Despite this limitation, we can do better than simply extrapolating torque or rescaling the load axis. ME7Tuner takes a new maximum MAP pressure, rescales the load axis and then rescales the torque based on the new maximum load. For example, if you go from a max load of ~215% for a 2.5 MAP bar sensor to ~400% for 4 bar map sensor you would expect the torque request in the 9.75 load column to be reduced by ~50% so the normalized torque isn't requesting a dramatically different value than 9.75. In other words, with the 4 bar MAP sensor optimum torque at 9.75 has been reduced from ~4% to ~2% because the torque is normalized to the maximum load dictated by the MAP sensor.
- Read Torque Monitoring
Additional empirical tuning points:
- Any part of KFMIOP (load/RPM range) that can only be reached above ~60% wped_w is unrestricted and can be raised to keep mimax high such that requested load does not get capped.
- Ensure that mibas remains below miszul to avoid intervention (which you will see in mizsolv) by lowering KFMIOP in areas reachable by actual measured load. This mainly becomes a concern in the middle of KFMIOP.
- On the left side ME7Tuner will analyze the current KFMIOP and estimate the upper limit of the MAP sensor and the real world pressure limit (usually limited by the turbo) of the calibration.
- Based on the results of the analysis a boost table will be derived and can be viewed with the 'Boost' tab
- On the right side you can input the upper limit of the MAP sensor and your desired pressure limit
- After providing the MAP sensor limit and desired pressure limit ME7Tuner will output a new KFMIOP table and axis
- Copy the KFMIOP table and axis to other tables (KFMIRL/KFZWOP/KFZW) to generate corresponding maps.
Note that KFMIOP also produces axes for KFMIOP, KFZWOP and KFZW so you can scale your ignition timing correctly.
KFMIRL is the inverse of the KFMIOP map and exists entirely as an optimization so the ECU doesn't have to search KFMIOP every time it wants to covert a torque request into a load request.
Inverts the input for the output.
- KFMIOP is the input and KFMIRL is the output
- KFMIOP from the binary will be display by default
- Optionally modify KFMIOP to the desired values
- KFMIOP will be inverted to produce KFMIRL on the left side
If you modified KFMIRL/KFMIOP you will want to modify the table and axis of KFZWOP to reflect to the new load range.
The input KFZWOP is extrapolated to the input KFZWOP x-axis range (engine load from generated KFMIOP).
Pay attention to the output! Extrapolation can useful for linear functions, but usually isn't for non-linear functions (like optimal ignition advance). Examine the output and make sure it is reasonable before using it. You will probably have to rework the output.
- Copy and paste your KFZWOP and the x-axis load range generated from KFMIOP
- Copy and paste the output KFZWOP directly into TunerPro.
If you modified KFMIRL/KFMIOP you will want to modify the table and axis of KFZW/2 to reflect to the new load range.
The input KFZW/2 is extrapolated to the input KFZW/2 x-axis range (engine load from generated KFMIOP).
Pay attention to the output! Extrapolation can useful for linear functions, but usually isn't for non-linear functions (like optimal ignition advance). Examine the output and make sure it is reasonable before using it. You will probably have to rework the output.
- Copy and paste your KFZW/2 and the x-axis load range generated from KFMIOP
- Copy and paste the output KFZW/2 directly into TunerPro.
In a turbocharged application the throttle is controlled by a combination of the turbo wastegate (N75 valve) and the throttle body valve. The ECU needs to know if the desired pressure can be reached at a given RPM. If the pressure cannot be reached at the given RPM the throttle opens to 100% to minimize the restriction. If the pressure can be reached, the base throttle position is closed to the choke angle (defined in WDKUGDN), e.g the position at which it can start throttling. The Z-axis of KFVPDKSD is a pressure ratio which is effectively the last 5% transitioning between atmospheric pressure (< 1) to boost pressure (> 1). In other words, the Z-axis is indicating where pressure will be greater than atmospheric (~1) or less than atmospheric (~0.95). In areas where the desired pressure can be made, but that pressure is less than the wastegate cracking pressure (the N75 is unresponsive), the throttle is used to keep boost under control at the requested limit.
ME7Tuner parses a directory of logs and determines at what RPM points a given boost level can be achieved.
You will need a large set of logs.
Required Logged Parameters:
- RPM - 'nmot'
- Throttle plate angle - 'wdkba'
- Barometric Pressure - 'pus_w';
- Absolute Pressure - 'pvdks_w';
ME7Tuner:
- 'Load' a directory of logs using the 'Load Logs' button on the left side
- Wait for ME7Tuner to finishing the parse and calculations
- KFVPDKSD will be produced on the right side
WDKUGDN is the choked flow point of the throttle body at a given RPM. This value is critical for the ECU to estimate airflow based on a throttle angle. The ECU needs to know at what throttle angle airflow becomes throttled/unthrottled. For a given displacement, RPM and throttle body area there is a range beyond the choke point where increasing the throttle angle will not increase airflow. Inversely, there is a range where decreasing the throttle will not decrease airflow until the choke point has been reached. The transition between restricted airflow and unrestricted airflow is the choke point -> the point at which the throttle angle becomes either throttled or unthrottled.
See https://en.wikipedia.org/wiki/Choked_flow.
The model assumes that a gas velocity will reach a maximum of the speed of sound at which point it is choked.
Note that the mass flow rate can still be increased if the upstream pressure is increased as this increases the density of the gas entering the orifice, but the model assumes a fixed upstream pressure of 1013mbar (standard sea level).
Assuming ideal gas behaviour, steady-state choked flow occurs when the downstream pressure falls below a critical value which is '0.528 * upstreamPressure'. For example '0.528 * 1013mbar = 535mbar'. 535mbar on the intake manifold side of the throttle body would cause the velocity of the air moving through the throttle body to reach the speed of sound and become choked.
The amount of air (or pressure assuming a constant density) an engine will consume for a given displacement and RPM can be calculated. How much air the throttle body will flow at a given throttle angle can be determined (KFWDKMSN/KFMSNWDK). Therefore, using the critical value of 0.528, the throttle angle at which choking occurs can be calculated to produce WDKUGDN.
While this model can used to achieve a baseline WDKUGDN, it appears that it has been tuned empirically. Unless you have changed the throttle body or engine displacement WDKUDGN should not have to be modified.
- Calculate WDKUGDN for your engines displacement
Provide a feed-forward (pre-control) factor to the existing PID. Highly recommended. The linearization process can be a lot of work. ME7Tuner can do most of the work for you. You just need to provide the logs.
Read Actual pre-control in LDRPID
The algorithm is mostly based on elRey's algorithm. However, instead of using increments to build the linearization table, ME7Tuner uses a fit one-dimensional polynomial which can (and likely will) produce better results. ME7Tuner can also parse millions of data points to produce the linearization table versus the handful of points you would get from doing it by hand.
-
Log RPM (nmot), Actual Absolute Manifold Pressure (pvdks_w) and Barometric Pressure (pus_w), Throttle Plate Angle (wdkba), Wastegate Duty Cycle (ldtvm), and Selected Gear (gangi)
-
Get as many WOT pulls starting from as low as an RPM as possible to as high as an RPM as possible. You will want a mix of "fixed" duty cycles and "real world" duty cycles.
-
Put all of your logs in a single directory and load select the directory in ME7Tuner with "Load ME7 Logs"
-
Wait awhile. It can take some time to parse the logs.
-
The linearized duty cycle will be output in KFLDRL. Note that it may not be perfect and will likely take some additional massaging to get it right.
-
For feed forward pre-control, ME7Tuner will output a new KFLDIMX and x-axis based on estimations from the linearized boost table. Keep in mind that this is just a ballpark estimation and will also likely require some massaging.
-
I would advise requesting 95% duty cycle at any RPM ranges that can't produce the minimum boost required for cracking the wastegates (because you might as well be spooling as hard as you can here).