Figured I'd write-up a guide on how to properly tune a mazdaspeed with port injection, the excel sheet I made to assist with this is attached below. This guide assumes you have prior tuning knowledge and glosses over basic knowledge like how to use the R4 software.
Part 1 - Base map
1.) Start by determining the amount of fuel you wish to be covered by your port injection system. One strategy is to keep your MAF curve the same and then cap it off at a certain value where your DI duty cycle isn't too high and then bring in Aux fueling to cover the rest. Your final MAF curve will end up looking like this:

I don't really like this method and prefer to have a more linear blend of AUX fuel where aux fuel begins to cover more and more of the required fueling as airflow increases. For my setup this is required as my HPFP cannot keep up at low RPM due to the quick spooling turbo and high torque. This also reduces the skew to calculated load due to MAF scaling. The end result looks like this:

Anyways, the choice is yours and both work.
2.) To begin, go to the Excel Tab labeled MAF_PI Blend Calculator
-Copy and paste your MAF calibration that has not yet been scaled for port injection into the row called 'Old MAF Table'
-Enter percentages into the row called 'Percent from Aux' depending on how aggressively you want PI to come on and what you want the MAF curve to look like. (The example is very aggressive so that the screenshot is not huge.) If you have a 4" intake and quick spooling turbo you will want to begin at 3v, otherwise beginning at 3.5v is fine.
Note: If you already have a PI map which you are trying to modify, you can enter the values into the 2nd table on the 1st tab of the spreadsheet. This will reverse calculate the percentages for you when you enter the non-PI and PI scaled MAF Cals.

-The output is a new MAF table which you can plug directly into Accesstuner.
-The 'Airflow Covered by Aux' row can be plugged into the Stratified R4 calculator as the MAF (g/s). Make sure that you enter 100% in the "Percentage of fueling by Aux Injectors" box.

-This gives you a map you can plug in directly into your R4 software.
Stratified Calculator Link: http://www.stratifiedauto.com/R4 Fuel Calculator/Index.html
3.) You can now start doing pulls and gathering data. Your AFRs should be in the ballpark but some corrections will be required. For coarse tuning of AFRs I prefer to modify the R4 map to get close to the desired AFR. Here is what my first log looked like with the above method:

Pretty smooth, but could use a little work. Rather than skewing your MAF curve further, it is better to correct this in your R4 map.
If further fine tuning is required after that you can modify the MAF curve.
Part 2 - How to make corrections to the R4 Map
Based on the log above, it might seem logical to just remove 10% from the PI IPW at the MAF voltages where the rich dip occurs. This does not work too great because it doesn't account for 2 factors, 1) Injector Dead Time and 2) The aux fuel is a percentage of total fueling, pulling 10% won't lean out your AFRs by 10%. The rest of the attached Excel file is to help with this.
1.) Go to the 'Inputs' tab of the excel file. Enter your Injector Dead Time and copy/paste your R4 map into the Table.

2.) Enter the % From Aux Fuel values which you used from part 1 of this guide. Notice that the header row voltage corresponds to the R4 Map. The 1st tab in the excel file outputs a linearly interpolated percentage which you can plug in directly.
Copy

Paste

3.) Now you can enter the percent fueling correction you want applied at various MAF voltages. You will need to analyze your logs to determine this. I am working on a way to calculate this from a log automatically but it is not complete yet. Based on the above example we want to remove about 10% from our AFRs from 3.6 to 3.9V.

Note: You will need some logic here. If you are 10% too rich and only 2% of fueling is coming from Aux at that point in time you will need to correct the MAF curve and not the R4 map. This also means the original MAF table you provided was inaccurate.
The spread sheet then performs the following calculations:
-Removes the Injector dead time from the R4 Table.
-Calculates the correction factor to make up for the portion of fueling covered by the DI system in order to make the desired change to AFR.
-Applies the corrections to the R4 table.
-Adds the Injector dead time back into the R4 table and spits out the new table on the Outputs Tab.

(You will need to use your noggin and not copy cells that you did not enter complete data for.)
Thats it! A lot of this is possible to do manually, but this should reduce the number of revisions you have to do and prevent a lot of headache. I just swapped to ID1000 injectors and was able to dial in my PI map in under an hour and a half using this method.
If anyone has any suggestions for the spreadsheet, let me know.
The excel is macro enabled with vba linear interpolation and it isn't an allowed extension on the forum, so you can download it at the following google drive link:
Part 1 - Base map
1.) Start by determining the amount of fuel you wish to be covered by your port injection system. One strategy is to keep your MAF curve the same and then cap it off at a certain value where your DI duty cycle isn't too high and then bring in Aux fueling to cover the rest. Your final MAF curve will end up looking like this:

I don't really like this method and prefer to have a more linear blend of AUX fuel where aux fuel begins to cover more and more of the required fueling as airflow increases. For my setup this is required as my HPFP cannot keep up at low RPM due to the quick spooling turbo and high torque. This also reduces the skew to calculated load due to MAF scaling. The end result looks like this:

Anyways, the choice is yours and both work.
2.) To begin, go to the Excel Tab labeled MAF_PI Blend Calculator
-Copy and paste your MAF calibration that has not yet been scaled for port injection into the row called 'Old MAF Table'
-Enter percentages into the row called 'Percent from Aux' depending on how aggressively you want PI to come on and what you want the MAF curve to look like. (The example is very aggressive so that the screenshot is not huge.) If you have a 4" intake and quick spooling turbo you will want to begin at 3v, otherwise beginning at 3.5v is fine.
Note: If you already have a PI map which you are trying to modify, you can enter the values into the 2nd table on the 1st tab of the spreadsheet. This will reverse calculate the percentages for you when you enter the non-PI and PI scaled MAF Cals.

-The output is a new MAF table which you can plug directly into Accesstuner.
-The 'Airflow Covered by Aux' row can be plugged into the Stratified R4 calculator as the MAF (g/s). Make sure that you enter 100% in the "Percentage of fueling by Aux Injectors" box.

-This gives you a map you can plug in directly into your R4 software.
Stratified Calculator Link: http://www.stratifiedauto.com/R4 Fuel Calculator/Index.html
3.) You can now start doing pulls and gathering data. Your AFRs should be in the ballpark but some corrections will be required. For coarse tuning of AFRs I prefer to modify the R4 map to get close to the desired AFR. Here is what my first log looked like with the above method:

Pretty smooth, but could use a little work. Rather than skewing your MAF curve further, it is better to correct this in your R4 map.
If further fine tuning is required after that you can modify the MAF curve.
Part 2 - How to make corrections to the R4 Map
Based on the log above, it might seem logical to just remove 10% from the PI IPW at the MAF voltages where the rich dip occurs. This does not work too great because it doesn't account for 2 factors, 1) Injector Dead Time and 2) The aux fuel is a percentage of total fueling, pulling 10% won't lean out your AFRs by 10%. The rest of the attached Excel file is to help with this.
1.) Go to the 'Inputs' tab of the excel file. Enter your Injector Dead Time and copy/paste your R4 map into the Table.

2.) Enter the % From Aux Fuel values which you used from part 1 of this guide. Notice that the header row voltage corresponds to the R4 Map. The 1st tab in the excel file outputs a linearly interpolated percentage which you can plug in directly.
Copy

Paste

3.) Now you can enter the percent fueling correction you want applied at various MAF voltages. You will need to analyze your logs to determine this. I am working on a way to calculate this from a log automatically but it is not complete yet. Based on the above example we want to remove about 10% from our AFRs from 3.6 to 3.9V.

Note: You will need some logic here. If you are 10% too rich and only 2% of fueling is coming from Aux at that point in time you will need to correct the MAF curve and not the R4 map. This also means the original MAF table you provided was inaccurate.
The spread sheet then performs the following calculations:
-Removes the Injector dead time from the R4 Table.
-Calculates the correction factor to make up for the portion of fueling covered by the DI system in order to make the desired change to AFR.
-Applies the corrections to the R4 table.
-Adds the Injector dead time back into the R4 table and spits out the new table on the Outputs Tab.

(You will need to use your noggin and not copy cells that you did not enter complete data for.)
Thats it! A lot of this is possible to do manually, but this should reduce the number of revisions you have to do and prevent a lot of headache. I just swapped to ID1000 injectors and was able to dial in my PI map in under an hour and a half using this method.
If anyone has any suggestions for the spreadsheet, let me know.
The excel is macro enabled with vba linear interpolation and it isn't an allowed extension on the forum, so you can download it at the following google drive link:
Template public:_media_site_embed_googledrive not found. Try rebuilding or reinstalling the s9e/MediaSites add-on.
(The forum automatically embeds it but clicking it should give you a download button.Attachments
Last edited: