MegaSquirt III Engine Management System
-
Upload
catalin555 -
Category
Documents
-
view
246 -
download
1
Transcript of MegaSquirt III Engine Management System
-
8/12/2019 MegaSquirt III Engine Management System
1/48
Introduction
This manual is intended to give tuning tips and to detail individual settings for the
MegaSquirt III Engine Management System. Each firmware feature is explained in its
own section starting with the basics and then covering more advanced features.
Engine and Sequential Settings
This section contains the most basic settings required to run an engine with the
MegaSquirt III.
Settings
Required uel !
-
8/12/2019 MegaSquirt III Engine Management System
2/48
"asic settings follow#
o Engine $isplacement ! This should be the engine%s displacement in
&ubic Inches or &ubic &entimeters 'depending on the &I$ vs. &&
setting in the (nits section).
o *umber of &ylinders ! Enter the engine%s number of cylinders. or therotary engine+ enter , cylinders for a -!rotor engine+ cylinders for a
/!rotor engine+ etc.
o In0ector low ! Enter the amount of fuel that a single one of the
engine%s fuel in0ectors can flow in 1ounds per 2our 'lb3hr)+ or &ubic
&entimeters per Minute '&&3min) 'depending on the lb3hr or cc3min
setting in the (nits section).
o 4ir!uel Ratio ! Enter the air fuel ratio that should be targeted. (sually
stoichiometric for the particular fuel in use should be used.
&ontrol 4lgorithm ! This setting controls the method with which engine load
is calculated. Engine load represents how hard the engine has to wor5 and can
be based on many factors such as manifold pressure+ throttle position+ air
mass+ or combinations of these. *ote that this setting only sets the control
algorithm for fuel in0ection and related settings6 it does not set the control
algorithm for ignition and related settings.
The following settings may be selected#
o Speed $ensity ! (se the M41 'Manifold 4bsolute 1ressure) sensor to
determine load. In this case+ the vertical axis of any fuel table loo5ups
is in 5ilopascals '51a). The maximum value reported by the M41
sensor 'in non!turbo applications) will be the same as the barometricpressure.
o 1ercent "aro ! This setting is similar to the Speed $ensity setting in
that the M41 sensor is used to determine load. 2owever+ instead of
directly using the manifold pressure+ the manifold pressure is divided
by barometric pressure to give a percentage of barometric pressure.
This setting can be useful for those who regularly drive at high
altitudes. It ensures that regardless of barometric pressure+ all table
loo5ups operate over 7!8779.
or example+ if barometric pressure is :7 51a+ and the engine is
operating at ;7 51a+ the actual value used for table loo5ups is;751a3:751a or -.;9.
o 4lpha!* ! (se the throttle position to determine load on the engine. "e
sure to calibrate the throttle range using Tools->Calibrate TPS
before using this setting.
o M4M41 ! This setting is for users who are using a Mass 4irflow
sensor+ but want to tune using the standard
-
8/12/2019 MegaSquirt III Engine Management System
3/48
used to determine the amount of fuel to in0ect. More information on
this load mode is in another dialog%s description.
o IT" ! This mode was created specifically for naturally aspirated
engines running with independent throttle bodies. It combines alpha!n
'at high engine loads) with speed density 'at low engine loads)+ using
the load calculation that ma5es the most sense at each R1M. orexample+ most IT" setups do not have good vacuum at idle or low
R1M+ and slightly touching the throttle ma5es them lose all vacuum+
but at higher R1M start to respond more li5e a traditional single
throttle body engine. This mode allows the use of speed density at low
engine loads and switches to alpha!n at high loads+ with an ad0ustable
switchpoint curve over R1M 'detailed in another section).
Squirts 1er Engine &ycle ! $etermines the number of times per engine cycle
'two revolutions on a four!stro5e engine) in0ectors are squirted when in a
batch in0ection mode. This setting has no effect when in0ecting sequentially.
In0ector Staging ! This setting is used only in batch in0ection modes. It
determines whether the two in0ection channels are squirted at the same time+or in an alternating fashion.
Engine Stro5e ! Sets the firmware for either a four!stro5e engine or a two!
stro5e engine.
*umber of &ylinders ! Sets the number of cylinders for the engine. *ote that
fully sequential in0ection is only possible with up to : cylinders.
In0ector 1ort Type ! This setting is not used by the firmware and is included
for historical purposes.
*umber of In0ectors ! $etermine the number of in0ectors installed on the
engine. ully sequential in0ection is only possible with up to : cylinders and :
in0ectors. >hen used with the staged in0ection feature+ this should be set to thenumber of primary in0ectors.
Engine Type ! $etermines whether the engine is an even!fire engine or odd!
fire engine. 4n even fire engine is an engine where the cran5shaft moves an
equal number of degrees between each cylinder%s top dead center 'T$&). 4n
odd fire engine may have a different number of degrees between T$& on
some cylinders when compared with others.
Sequential uel In0ection settings follow#
Main fuel outputs !
o Std fuel ! (se the standard v/3/.;? board batch in0ector outputs.o MS/@ fuel ! (se the MS/@ expansion board%s outputs to drive the fuel
in0ectors. Anly one in0ector should be used per output.
Sequential An !
o Aff ! (se batch in0ection. An MS/x outputs+ the channels are divided
into two groups+ and all in0ectors in a group are squirted
simultaneously.
o Semi!Sequential ! (se batch in0ection+ but allow the angle of in0ection
to be specified. >hen used with the MS/@ in0ector outputs+ in0ectors
should be wired in the same manner they would be wired for fully
sequential in0ection.
o ully Sequential ! (se fully sequential in0ection. In this mode+ outputs
4!2 are squirted in sequence+ so care must be ta5en to use the correct
-
8/12/2019 MegaSquirt III Engine Management System
4/48
wiring for the engine%s fireing order. or example+ for a four cylinder
engine with firing order 8!/!,!-+ the following wiring should be used#
Autput 4 ! &ylinder 8
Autput " ! &ylinder /
Autput & ! &ylinder ,
Autput $ ! &ylinder - 4ngle Specifies !
o End of Squirt ! The angle specified in the in0ector timing table
specifies the angle of the end of each squirt. This should be used by
most people for most engines.
o Middle of Squirt ! The angle specified in the in0ector timing table
specifies the angle of the middle of each squirt.
o "eginning of Squirt ! The angle specified in the in0ector timing table
specifies the angle of the beginning of each squirt.
In0ector Trim !
o Aff ! 1er!in0ector fuel trim is disabled. 4ll in0ectors will have the same
pulse!width.
o An ! 1er!in0ector fuel trim is enabled. Each in0ector%s pulse!width can
be trimmed lower or higher than the value calculated using the fuel
equation.
iring order#
The firing order should be set to the firing order that your engine uses. It does not
affect the order in which the outputs are triggered. Instead it is used to associate an
in0ector trim table with a particular physical output so that when in0ector trim is
applied+ it is applied to the correct cylinder. It is also used if closed!loop EBA is beingdone per!cylinder.
ITB Load Mode
IT" tuning mode builds on the capabilities of the dual table blended tuning approach
but solves one of the more significant drawbac5s to that tuning mode# it provides the
blended Speed!$ensity34lpha!* behavior of the blended dual tables in 0ust a single
table. This single table approach is a significant improvement as all the automatic
tuning tools available through TunerStudio now wor5 correctly with the single table.
These tools are not easily used on the blended tuning approach as TunerStudio doesnot understand the multiplicative coupling between the two tables.
ITB Load
This new tuning mode introduces a new engine load type to Megasquirt+ the IT" load.
This load type is selected in the tuning configuration the same way that 4lpha!*+
Speed!$ensity+ or blended tuning are selected. IT" load is also available for the other
tuning settings including 4R+ Ignition+ and Enhanced 4ccel Enrichment.
The IT" Coad is derived from a combination of M41 and T1S values as well as other
IT"!related tuning curves that all wor5 together to create a calculated value that is
-
8/12/2019 MegaSquirt III Engine Management System
5/48
used as the DIT" CoadD and applied to the axis of the tuning tables in the same way
that M41 is used for Speed!$ensity tuning or T1S is used for 4lpha!* tuning.
ITB Load VE Table
IT" Coad tuning uses a single
-
8/12/2019 MegaSquirt III Engine Management System
6/48
only need a few data points to plot the curve. 4 data point at low+ medium+ and high
R1M from a log file is usually enough. 4 spreadsheet or 0ust graph paper can then be
used to establish enough data points to fill in the table for this curve.
IT" Coad tuning requires that the M41 signal be above the %Baro switchpointand
that the T1S value be above the value defined on this curve to switch from Speed!$ensity tuning to 4lpha!* tuning. Therefore+ you want this curve to be relatively
accurate and you may even want to set the values on the curve a few percent low to
ensure that the T1S value has been met when the M41 reaches the %Baro
switchpoint.
"esides defining the switch point to 4lpha!* tuning+ this curve also establishes the
lower T1S value that will be used to interpret the range of
-
8/12/2019 MegaSquirt III Engine Management System
7/48
-
8/12/2019 MegaSquirt III Engine Management System
8/48
or example+ if you have allocated the region between 79 IT" Coad and 8779 IT"
Coad on your
-
8/12/2019 MegaSquirt III Engine Management System
9/48
exceed the %Baro switchpointwithout entering 4lpha!* mode. An engines with
aggressive cams with higher overlap+ it is possible for the fast idle M41 to exceed the
%Baro switchpoint. >hen this happens+ you do not want to enter 4lpha!* mode
tuning since the throttle is still reading fully closed. The Idle TPS Threshold %
prevents you entering 4lpha!* mode and you can use the warm up enrichment curve
to compensate for any tuning errors caused by being stuc5 at the maximum Speed!$ensity bin while the M41 is greater than the %Baro switchpoint.
AFR/EGO Control
This section contains the settings necessary to do closed!loop Exhaust Bas Axygen
'EBA) control on the MegaSquirt III engine management system. &losed!loop EBA
control allows the amount of fuel being in0ected to be changed so that the 4ir uel
Ratio '4R) matches the 4R set in the 4R table.
Settings
Basic E! settin"s
These settings are used to control the behavior of the closed!loop EBA algorithm.
Ignition Events per Step ! >hile closed!loop EBA is active+ how often the
correction is run is determined by this setting. It is the number of ignition
events per correction.
&ontroller Step Si=e ! This setting is only used with the DSimpleD EBA
algorithm. It controls how large each correction DstepD is. So if the 4R does
not match the desired 4R+ and &ontroller Step Si=e is configured to be 89+
each time a correction is made+ that correction will be 89.
&ontroller 4uth ! This setting controls the maximum amount of ad0ustment
performed by the closed!loop algorithm.
4ctive 4bove &oolant ! "elow the temperature defined by this setting+ closed!
loop EBA will not activate.
-
8/12/2019 MegaSquirt III Engine Management System
10/48
4ctive above R1M ! "elow the R1M defined by this setting+ closed!loop EBA
will not activate.
4ctive "elow T1S ! 4bove the throttle position defined by this setting+ closed!
loop EBA will not activate.
4ctive below Coad ! 4bove the load defined by this setting+ closed!loop EBA
will not activate. 4ctive 4bove Coad ! "elow the load defined by this setting+ closed!loop EBA
will not activate.
EBA delay after start ! The time in seconds after engine!start before closed!
loop EBA can be activated.
4lgorithm ! This controls the type of closed!loop algorithm used#
o Simple ! This method of closed!loop EBA control is well!suited to use
with a narrowband A- sensor. If the current 4R 'or EBA voltage for
narrowband) incorrect+ the amount of fuel being in0ected is ad0usted by
Controller Step Sizeevery Ignition Events per Stepignition
events. This method often results in the actual 4R oscillating above
and below the target.
o 1I$ ! This method incorporates a 1roportional Integral $erivative
control loop which tuned properly+ ad0usts the amount of fuel being
in0ected to quic5ly get to the target+ and then maintains the target
without any oscillation 'when tuned correctly).
EBA Sensor Type ! This setting enables EBA control and allows the user to
choose between using a wideband sensor or narrowband sensor.
The following settings are supported#
o $isabled ! *o EBA sensor enabled.o *arrowband ! Sensor in use is a narrowband sensor.
o >ideband ! Sensor in use is a wideband sensor.
*umber of Sensors ! This setting is used to select the number of oxygen
sensors in use by the MS/. (p to eight sensors can be configured.
E! Ports -
The EBA 1orts settings allow the user to select the input port used to read the signal
from the oxygen sensor. The number of EBA ports available depends on the number
of sensors selected.
The following ports are available for the first EBA input#
*ormal EBA
HS; '4$&)
HS, '4$&?)
E@TM41 '4$&88)
EBA- '4$&8-)
Spare 4$& '4$&8/)
&4* EBA
&4* 4$&78 &4* 4$&7-
-
8/12/2019 MegaSquirt III Engine Management System
11/48
&4* 4$&7/
&4* 4$&7,
&4* 4$&7;
&4* 4$&7
&4* 4$&7?
&4* 4$&7: &4* 4$&7F
&4* 4$&87
&4* 4$&88
&4* 4$&8-
&4* 4$&8/
&4* 4$&8,
&4* 4$&8;
&4* 4$&8
&4* 4$&8?
&4* 4$&8: &4* 4$&8F
&4* 4$&-7
&4* 4$&-8
&4* 4$&--
&4* 4$&-/
&4* 4$&-,
The remaining EBA ports have the following input options#
Aff
HS; '4$&) HS, '4$&?)
E@TM41 '4$&88)
EBA- '4$&8-)
Spare 4$& '4$&8/)
&4* EBA
&4* 4$&78
&4* 4$&7-
&4* 4$&7/
&4* 4$&7,
&4* 4$&7; &4* 4$&7
&4* 4$&7?
&4* 4$&7:
&4* 4$&7F
&4* 4$&87
&4* 4$&88
&4* 4$&8-
&4* 4$&8/
&4* 4$&8,
&4* 4$&8;
&4* 4$&8 &4* 4$&8?
-
8/12/2019 MegaSquirt III Engine Management System
12/48
&4* 4$&8:
&4* 4$&8F
&4* 4$&-7
&4* 4$&-8
&4* 4$&--
&4* 4$&-/ &4* 4$&-,
A#$%E! Sensor Mappin"
The 4R3EBA Sensor Mapping settings allow individual in0ectors to be associated
with available EBA sensors.
The following in0ector channels can be associated with a sensor#
MS/@ In04 MS/@ In0"
MS/@ In0&
MS/@ In0$
MS/@ In0E
MS/@ In0
MS/@ In0B
MS/@ In02
-
8/12/2019 MegaSquirt III Engine Management System
13/48
"ecause of this+ the best algorithm to use with a narrowband sensor is the DsimpleD
algorithm.
The simple algorithm ad0usts the mixture richer if the sensor reads lean+ and leaner if
the sensor reads rich. It ad0usts Controller Step Sizepercent every Ignition
Events per Step. This can lead to a small oscillation in A-!based correction oncethe 4R reaches close to stoichiometric.
The following steps are recommended when tuning the simple algorithm with a
narrowband sensor#
8. Ignition Events per Step ! >hen first tuning the engine+ this should be set to a
fairly low number ',!:) so that if the 4R is very far off+ it is corrected
quic5ly. Ance the engine is better tuned+ this number can be switched to a
higher number to gain more stable correction behavior ':!8 or more).
-. &ontroller Step Si=e ! >hen first tuning the engine+ this should be set to -9 so
that when correcting+ the engine reaches stoichiometric quic5ly. Ance the
engine is well tuned+ this should be reduced to 89 to gain more stable
correction.
/. &ontroller 4uth ! >hen first tuning the engine+ this should be set to -79 or
higher. &are must be ta5en to watch how the algorithm is correcting. In some
situations+ it is possible for the sensor to read very lean when really the engine
is running very rich. Ance the engine is tuned+ this should be set between ;9
and 879.
,. Engagement Settings ! Most of the remaining settings control how and when
the closed loop algorithm is engaged. Engagement with a narrowband sensor
should happen when the engine is nearly fully warm+ ;77!8777 rpm aboveidle+ below :79 throttle+ below about :79 load+ 0ust above the lowest load
seen when barely pressing the throttle+ and at least /7 seconds after the engine
starts. These settings are because the sensor must be hot to operate+ must not
be used at high load due to the fact that the engine should be operated rich of
stoichiometric+ and must not be used at very low load because the oscillations
will cause the engine speed to oscillate.
Si&ple Al"orith& with (ide'and Sensor
Tuning the simple algorithm with a wideband sensor is essentially the same as tuning
it with a narrowband sensor with the caveat that the 4R target table is used to set the4R target. It is still recommended that the EBA algorithm not be used at high
throttle position3load due to the fact that the accuracy of the wideband sensor
decreases dramatically with pressure and temperature changes caused by high load.
PID Al"orith& with Narrow'and Sensor
>hen using a narrowband sensor with the 1I$ algorithm+ all the same
recommendations for settings given in the section describing the Simplealgorithm
should be followed.
4dditionally+ since it is nearly impossible to 5eep the narrowband sensor fromoscillating+ it is recommended to start by tuning the %I% term until the target is reached
-
8/12/2019 MegaSquirt III Engine Management System
14/48
with minimal oscillation. Ance this point is reached. It is recommended that very little
'if any) %1% term is used since the %1% part of the 1I$ algorithm causes instantaneous
reaction+ and the response of the sensor is not proportional to the distance from
stoichiometric.
PID Al"orith& with (ide'and Sensor
>hen using a wideband sensor with the 1I$ algorithm+ the same steps as when using
a narrowband sensor can be followed for tuning the %I% term.
4dditionally+ since the response of most wideband controllers and sensors is linear
with 4R+ a larger %1% term can be used to help correct for fast changes in 4R.
&aution must still be used however since there is a significant delay between the
amount of fuel being in0ected changing and MS/ registering an 4R change as a
result.
inally+ a small amount of %$% term can be used to help slow response during very fast
changes. This helps reduce overshoot of the target.
Idle Control
The MS/ firmware has several methods for controlling idle speed#
An3Aff armup!only modes
These modes are open!loop and only control valve position based on coolant
temperature.
o I4& Stepper 4lways An ! Ceave I4& stepper power on even when not
moving.
o I4& Stepper Moving Anly ! 1ower up I4& stepper motor only when
necessary for moving.
o 1>M >armup ! 1>M valve in warmup only mode.
o 8;!minute I4& ! 1ower up the I4& for 8; minutes for warmup+ then
power it down.
&losed!loop modes
These modes are closed!loop. The user must set a target R1M curve+ and
several other settings to determine when the code goes into closed loop mode.
o 1>M &losed Coop ! 1>M idle valve in closed loop mode.
o I4& &losed Coop Moving Anly ! &losed loop I4& mode where the
I4& motor is only turned on when the valve needs to move.
o I4& &losed Coop 4lways An ! &losed loop I4& mode where the I4&
motor is on whether the valve needs to move or not.
-
8/12/2019 MegaSquirt III Engine Management System
15/48
Each mode is described in detail below.
On/Off Vale
The An3Aff M!based modes have certain settings which are shared#
-
8/12/2019 MegaSquirt III Engine Management System
16/48
1ossible Settings#
o Aff ! $o not use / wire mode.
o I$CE ! (se the I$CE port as the second control pin.
o "oost ! (se the "oost control pin as the second control pin.
o
-
8/12/2019 MegaSquirt III Engine Management System
17/48
4ll warmup!only modes also have the following common setting#
&ran5!to!Run Taper Time ! Time in seconds to go from the cran5 position to
the run position.
The four warmup!only output options are detailed below.
IAC Motor Co&&on Settin"s
The I4& Stepper modes all have several common settings. Those settings are detailed
here.
Time Step Si=e ! This is the number of milliseconds the firmware will waitbetween each step. If a valve does not move reliably+ this setting should be
increased.
Minimum K of steps to move ! This is the minimum number of steps the
controlling piece of code has to command before the code that moves the
valve will actually try to move the valve.
Start
-
8/12/2019 MegaSquirt III Engine Management System
18/48
IAC (ar&up Movin" !nly
I4& >armup Moving Anly is an open!loop algorithm which sets the valve position
based directly on coolant temperature. Jeep in mind that this mode turns off the valve
between each set of steps. If the valve does not wor5 reliably in this setting+ it may be
necessary to use the 4lways An setting. In addition to the common I4& motorsettings+ this mode also has the following setting#
Initial Time Step Si=e ! This is the number of milliseconds the firmware will
wait after turning on the idle valve before trying to move the pintle.
IAC (ar&up Always !n
This mode is exactly the same as I4& >armup Moving only+ but does not have the
Initial Time Step Si=e setting since it leaves the valve turned on all the time.
)*-&inute IAC
This mode is exactly the same as the other I4& >armup modes+ but leaves the valve
on for 8; minutes after start+ then turns it off.
P(M (ar&up
This mode wor5s functionally the same as the I4& >armup options+ but for a 1>M
valve instead.
Closed-loo# %odes
The MS/ firmware employs a 1I$ '1roportional Integral $erivative) method of
control for controlling idle speed to meet the user!specified target R1M. Target R1M
is specified in a &oolant!temperature!based curve. &ommon settings for all closed!
loop modes as well as options specific to each type of valve are listed below.
Closed Loop Co&&on Settin"s
4 curve for setting the target R1Ms based on coolant temperature is used by all closed
loop idle!speed control modes. 4ll other idle!speed control settings are listed as well#
-
8/12/2019 MegaSquirt III Engine Management System
19/48
Settings common between all modes are listed here#
&losed Coop Idle M closed loop and I4& closed loop
respectively. They specify the duty or number of steps at which the
idle valve is fully open. This can be set lower than the fully open
position in order to limit the maximum value to which a valve will
open.
o Idle
-
8/12/2019 MegaSquirt III Engine Management System
20/48
!eave "alve Closed #bovesetting is to 5eep the valve closed when
shifting gears+ but open it on longer overrun events.
&losed Coop Idle 1I$ $elays and "ehavior !
o Min duty3steps for 1I$ ! This is the minimum duty that the 1I$ code
will use while engaged.
o R1M with valve closed ! This should be set to the engine%s R1M withthe idle valve closed.
o R1M with valve open ! This should ideally be set to the R1M with the
valve fully open. It can however be set lower than this value to
increase the sensitivity of the 1I$ algorithm.
o 1I$ delay ! This is how long in seconds all other conditions for
entering 1I$ control must be met for before the code will engage 1I$
control.
o &ran5 to run taper ! 2ow long after starting the code will wait to
engage 1I$ control.
o 1I$ ramp to target time ! This setting controls how long after the 1I$
control algorithm engages the code will ta5e to reach the target. The
code starts with an R1M target of whatever the current R1M may be+
and then slowly over the ramp to target seconds reduces the target to
the value set using the target R1M curve. This can be used to help
larger 1!values be used+ ma5ing it easier to tune 1I$ to catch sudden
drops in idle speed.
o 1I$ &ontrol Interval ! This controls how often the 1I$ control code
runs.
-
8/12/2019 MegaSquirt III Engine Management System
21/48
1ossible Settings#
Standard
(se
-
8/12/2019 MegaSquirt III Engine Management System
22/48
Tunin" $eco&&endations
"efore trying to tune closed loop idle speed control+ be sure to try tuning warmup
only idle speed control. >ith warmup only control+ a higher step!count or duty should
yield higher R1M. Ma5e sure that this is the case+ and that smooth idle speed can be
attained with warmup only before moving on to closed loop control.
There are two main things to tune when tuning closed!loop idle speed control#
1I$ gains
&onditions for entering 1I$ control
It is recommended that tuning is done in stages. or example+ 1I$ cannot be tuned if
the code is never entering the 1I$ loop. "ecause of this it is a good idea to start by
tuning the conditions for entering 1I$ control.
These settings include#
(se
-
8/12/2019 MegaSquirt III Engine Management System
23/48
To tell whether the code is entering 1I$ idle control+ the D&C IdleD indicator in
TunerStudio must be used. If the current gauge cluster in TunerStudio does not
include this indicator+ temporarily switch to a cluster that does.
Most modern AEM cars enter idle speed regulation in a very similar manner. The
MS/ idle speed control algorithm was designed to emulate this behavior. Thesequence of events that the code was designed to follow are listed below#
8. Throttle Cift ! An throttle lift+ the code opens the valve to the value learned in
the last iteration of the 1I$ loop L the dashpot adder. The logic here is that the
last learned value should result in an R1M close to the target R1M. The
dashpot adder is added so that when R1M settles+ it settles to an R1M slightly
higher than the target. This is in case the air conditioning was turned on or
I4T increased or anything else that might ma5e R1M lower than the last time
the 1I$ code ran.
-. R1M settles ! 4fter throttle lift+ eventually the clutch is pushed in and R1M
drops to wherever it will settle given the learned value L the dashpot adder.2opefully the idle has settled to an R1M that is less than the commanded
target L the Idle 4ctivation R1M adder. I so+ then the code will wait for the
amount of time specified by the 1I$ delay+ and then enter 1I$ control. If R1M
settles above the commanded target L Idle 4ctivation R1M adder+ the code
then starts chec5ing the 1I$ loc5out detection conditions. 4ssuming those
condtions are met+ the code will still enter the 1I$ loop after the amount of
time specified by the 1I$ delay.
/. 1I$ control activates+ R1M starts dropping to target ! 4fter the 1I$ delay
expires+ the 1I$ code will be activated. R1M will slowly drop to the target
over the number of seconds specified by the 1I$ ramp to target time.
,. *ormal idle speed reached ! R1M reaches the commanded target. 1I$
continues regulating R1M until the throttle is pressed.
Ance the code is reliably entering 1I$ on every throttle lift+ it is time to actually tune
the 1I$ code to reach and hold the R1M target.
The settings that are associated with or affect the operation of the 1I$ algorithm are
listed below#
Idle Apen $uty3steps and Idle
-
8/12/2019 MegaSquirt III Engine Management System
24/48
4ir &onditioning being turned on. Setting it too low can result in the loop
being overly sensitive to R1M changes. Typically 877ms wor5s well.
1I$ controller gains ! These control the actual response of the code to changes
in R1M+ as well as how well the code will reach the target. Tips for tuning
these are listed below.
The following basic steps should be used for tuning the 1I$ controller gains#
8. ero all the gains ! Set all the gains to 79. This is so that the effects of tuning
the I!term in the next step are not confused with the effects of any other
setting.
-. Tune the Integral 'I) gain ! The Integral gain is the only term that controls
whether the code actually reaches its target. 2igher values for Integral gain
will result in the code being able to get closer to the commanded target6
however+ a value that is too high will result in oscillation. The easiest way to
determine a good value for the I term is to 5eep increasing it until oscillation
occurs+ then slightly lower it. If this value is increased to -779 withoutreaching a point where oscillation occurs+ then the R1M with valve opened
setting can be decreased as far as necessary+ and the open duty3steps setting
and closed duty3steps setting can be made further apart to ma5e the 1I$ loop
more sensitive.
/. Tune the 1roportional '1) gain ! 4fter tuning the I gain so that the R1M
reaches the commanded target without oscillation+ the 1 gain can be tuned.
The best way to tune this is to set it as high as possible without getting any
oscillation. 4fter setting this+ try turning on the air conditioning or other
accessories that normally lower R1M or increase load. >hen these accessories
are turned on+ the R1M should dip a bit then recover 'the valve position
should increase significantly). (sing longer 1I$ ramp to target times can also
ma5e it so that when the 1I$ algorithm engages+ a higher 1 gain can be set
without causing oscillation.
,. Tune the $erivative '$) gain ! or most users+ use of the $ gain should not be
necessary. It substantially dampens the response of the loop.
Some final tips#
Idle uel Tuning ! "efore even attempting to tune &losed!loop Idle speed
control+ tune the area around idle so that if R1M goes up or down or load goes
up or down+ the 4R stays close to the same value. &hanging 4R can affectidle speed+ which can then cause the 1I$ code to try to correct+ getting into an
unrecoverable oscillation.
Idle 4dvance ! The idle advance feature can be used to help DcatchD the idle in
situations where heavy load is suddenly added while the engine is idling. It is
recommended that the advance is increased with increasing load+ and
decreased with decreasing load. This way when the air conditioning or electric
fan are turned on+ the sudden increase in load causes a corresponding increase
in timing which generates more power. 4lso+ this feature can be used so that
on idle without load+ slightly less than what would normally be considered
DoptimalD timing can be used. This causes the idle valve to need to open
further to 5eep a particular idle speed. Then when sudden load is added+ the
-
8/12/2019 MegaSquirt III Engine Management System
25/48
timing increases and the valve position does not have to change as much to
cope with the sudden load increase.
Idle Advance
The Idle 4dvance feature is useful to fine!tune ignition timing at idle. It is particularly
useful to help catch sudden load increases on the engine at idle by increasing timing
when load increases to help the engine generate more power+ 5eeping R1M from
dropping severely.
Idle Adance Settings
This section describes the Idle 4dvance settings.
Idle advance on
o An ! Turn the idle advance feature on.
o Aff ! Turn the idle advance feature off.
T1S is below '9) ! The T1S must be below this value before idle advance will
engage.
and R1M is below 'rpm) ! The R1M must also be below this value before idleadvance will engage.
and load is above '9) ! The engine load must also be above this value before
idle advance will engage.
and &CT is above 'degrees) ! The engine coolant temperature must also be
above this value before idle advance will engage.
and after delay 'sec) ! 4ll the other conditions must be met for this amount of
time before idle advance will engage.
Idle 4dvance Timing curve ! This is a four!point curve with Coad as the @!
axis and timing as the !axis. This curve determines the actual timing once the
idle advance feature has engaged.
-
8/12/2019 MegaSquirt III Engine Management System
26/48
Idle Adance Tuning
There are two main types of settings to tune for the Idle advance feature#
Idle 4dvance engagement settings ! These settings control the conditions
under which Idle 4dvance will engage.
Idle 4dvance Timing curve ! This curve controls the actual ignition timing
once all the Idle 4dvance engagement conditions have been met.
Tunin" Idle Advance En"a"e&ent Settin"s
The Idle 4dvance engagement settings should be set so that idle advance will engage
in roughly the same conditions that occur during normal+ warmed!up idle.
Settings recommendations#
Bo to idle advance when#
T1S is below ! This setting should be set as low as possible. Typically settings
between 7.;9 and 89 should be used. If numbers that are too low are used+
then idle advance may not engage if there is some play in the throttle body or
there are minor electrical fluctuations that cause the closed T1S 9 to vary. If
numbers that are too high are used+ then idle advance may engage at
undesirable times.
and R1M is below ! This setting should typically be set 0ust above the desiredidle R1M+ and below the lowest R1M at which the driver normally drives in
gear. or example+ if the desired idle R1M is :77+ then a good value for this
setting is 8777.
and load is above ! This setting should be set 0ust below the load value seen
during a normal idle with no load on the engine.
and &CT is above ! This setting should be set to the temperature at which the
engine idle characteristics no longer change. Benerally this is when the engine
is fully warm.
and after delay ! This setting should be set to a value that is long enough for
the engine R1M and load to become stable before idle advance engages.
Tunin" Idle Advance Ti&in"
In general+ the most stable idle is reached by decreasing the idle timing+ and
increasing the amount of air entering the engine 'using an idle air valve or similar). 4s
such the idle advance timing should be as low as possible while retaining a smooth
idle. Since less timing is used during normal idle conditions+ as load increase+ the
timing should also increase to counteract R1M decrease when the load increases.
-
8/12/2019 MegaSquirt III Engine Management System
27/48
Boost Control
The MS/ irmware has two algorithms for controlling boost#
Apen!Coop ! Solenoid duty comes from an :x: duty table 'T1SxR1M). &losed!loop ! 4 1roportional!Integral!$erivative '1I$) loop controls solenoid
duty to match the actual boost to the boost target. 4n :x: target table
'T1SxR1M) or a !point boost vs vehicle speed curve is used to figure out the
boost target.
In addition to the algorithm selection+ there are several other settings that must be
properly configured in order to use the boost control feature. The full boost control
settings dialog can be found below#
Boost Control Co!!on Settings
This section covers settings that are used by both the open!loop and closed!loop
control algorithms.
"oost &ontrol Enabled ! This controls whether the boost control feature is
enabled or disabled.
"oost &ontrol 1in ! This sets which output pin is used to control the boost
control solenoid. 4vailable options include#
o I4&8
o I4&-o HS88
-
8/12/2019 MegaSquirt III Engine Management System
28/48
o Idle
o 11/
Autput 1olarity ! This is used to set the polarity of the output. Set properly+
lower reported duty should correspond to a more closed wastegate and yield
more boost.
4vailable options include#
o *ormal ! 8779 output pin duty means the wastegate is fully open.
o Inverted ! 79 output pin duty means the wastegate is fully open.
Solenoid requency 'high) ! This setting controls the frequency range of the
valve.
4vailable options include#
o 8.;J2= ! Aperate the solenoid at 8.;J2=.
o (se Reduced ! &hoosing this setting enables the Solenoid requency
'mid) selection 'detailed below).
o Slow ! &hoosing this setting enables the Solenoid requency 'low)
selection 'detailed below).
Solenoid requency 'mid) ! This selection is enabled when D(se ReducedD is
chosen.
4vailable options include#
o ?:72=
o /F72=o -72=
o 8F;2=
o 8;2=
o 8/72=
o 8882=
Solenoid requency 'low) ! This selection is enabled when DSlowD is chosen.
4vailable options include#
o ?:2=
o /F2=
o -2=
o 8F.;2=
o 8;.2=
o 8/2=
o 88.82=
&ontrol Interval ! This setting is used to control how often the boost control
algorithm runs.
&losed $uty ! This setting controls the lowest allowed reported duty.
*ormally this should be 79.
Apen $uty ! This setting controls the highest allowed reported duty. *ormallythis should be 8779.
-
8/12/2019 MegaSquirt III Engine Management System
29/48
Additional Closed-loo# settings
Enabling the closed!loop boost control algorithm enables the following additional
settings#
"oost &ontrol lower limit ! This setting controls the pressure at which the 1I$algorithm is enabled and starts controlling the boost solenoid 'and therefore
boost pressure).
1roportional Bain ! 1roportional gain affects the strength with which changes
in input immediately affect changes in output.
Integral Bain ! The Integral Bain setting affects the response to continued
difference between the target boost and the actual boost.
$erivative Bain ! The $erivative Bain setting helps to slow down the response
of the 1roportional and Integral gain settings as the target is reached. This
should be used sparingly as it can also completely dampen the other two
Bains.
%iscellaneous Boost Control Configuration
This section covers all remaining boost control settings.
!ver'oost Protection
Averboost protection wor5s similarly to a rev!limiter+ except that it can stop engine
operation when boost exceeds a user!set limit. In addition+ use of the overboost
protection feature is required when using the closed!loop boost control algorithm.
The following settings affect the operation of overboost protection#
Averboost 1rotection !
o *one ! $isables overboost protection.
o uel &ut ! Stops the engine by cutting fuel.
o Spar5 &ut ! Stops the engine by cutting spar5.
o "oth ! Stops the engine using both fuel and spar5 cut.
Maximum "oost ! The maximum boost 'in 51a) at which the engine should be
operated.
2ysteresis ! The amount boost must drop by 'in 51a) after hitting the
maximum boost before fuel or spar5 are restored.
&ut @ spar5s ! &ut this many spar5 events ...
rom events ! rom this many possible spar5 events.
!ther Boost Control Settin"s
The following settings remain#
"oost Table Switching ! This option when enabled allows a switch input to be
configured which switches between two different boost duty or target tables.
Settings include#
-
8/12/2019 MegaSquirt III Engine Management System
30/48
o Aff
o Tableswitch
o 1E73HS?
o 1E8
o HS87
o HS88o HS;
o HS,
o Caunch in
o $atalog in
"oost Timed rom Caunch ! If launch control is enabled+ this setting allows a
specific boost duty or target to be used for a set amount of time after launch.
Specific Caunch $uty3Target ! If launch control is enabled+ this setting
controls what target 'closed!loop) or duty 'open!loop) is used for boost
control.
Caunch "oost $uty ! This is the duty used by Specific Caunch $uty3Target. Caunch boost target ! This is the boost target used by Specific Caunch
$uty3Target.
"oost vs speed ! this item enables the use of the boost vs speed curve. It has
the following options#
o Aff
o
-
8/12/2019 MegaSquirt III Engine Management System
31/48
*otice that areas which should have low boost have higher duties. This is because a
higher duty should correspond with a more opened wastegate+ which should
correspond roughly to lower boost. If while tuning open!loop boost+ higher duty
results in higher boost and closed!loop boost control will eventually be used+ toggle
the Autput 1olarity setting to the opposite of its current setting.
To tune the actual boost levels+ 0ust ad0ust the duty table so that boost reaches the
desired level at each point in the table.
(se open!loop boost control to try out different frequency settings and find the
settings that wor5 the best for the particular solenoid being used.
Settin" up !ver'oost Protection
The boost control settings dialog contains the Averboost 1rotection settings. Settingthis ups very similar to setting up a rev!limiter. &hoose from uel &ut or Spar5 cut or
"oth. If the engine being tuned is still equipped with a catalytic converter+ spar5 cut
should not be used.
The maximum boost should be set up a few 51a higher than the maximum target
boost will be in the closed!loop boost target table. 2ysteresis should be set so that
M41 0itter does not cause it to alternate rapidly between on and off.
Tunin" Closed-loop 'oost control
The first step for tuning &losed!loop boost control is to set the desired targets in the
"oost &ontrol Target table. Typically lower throttle positions will have lower boost
targets#
-
8/12/2019 MegaSquirt III Engine Management System
32/48
Typically+ the defaults for the following settings can be used#
&ontrol Interval ! The default for this setting is -7 ms. This is typically a good
place to start. Cower settings can be used if overshoot cannot be tuned out
when tuning the 1I$ parameters.
&losed $uty ! 4 closed duty of 79 is the default. This should be tuned to thevalue that starts to open the wastegate+ but typically 79 wor5s well.
Apen $uty ! 4n open duty value of 8779 is the default. This should be tuned
to the value that fully opens the wastegate+ but typically 8779 wor5s well.
"oost &ontrol Cower Cimit ! This setting is used to set the pressure at which
1I$ boost control is engaged. The default for this setting is 877. If a faster rise
to target is desired this setting can be set to a higher number+ but the safest
number is 877 since it gives the 1I$ code the most time to react to climbing
boost.
*ATE# The output polarity setting only changes the actual duty on the output.
Regardless of this setting+ the boost control algorithm is designed to operate on the
assumption that more duty G less boost.
The next step after setting up the target table and supporting settings is to tune the 1I$
gains#
8. Set Integral and $ifferential Bains to 79 ! To ma5e tuning the 1roportional
gain easier+ set the Integral and $ifferential gains to 79.
-. Set 1roportional gain to 8779 and slowly lower ! >hile tuning 1roportional
gain+ higher numbers mean slower boost climb and lower final boost. or
safety+ start with a very high gain '8779 should be sufficient). ind the R1Mthat typically spools quic5ly+ and fully and quic5ly depress the accelerator.
-
8/12/2019 MegaSquirt III Engine Management System
33/48
*ote how much boost is reached. If boost overshoots the target dramatically+
increase the 1roportional gain. Atherwise+ reduce the 1roportional gain and try
again. $o this until boost reaches the target with a small amount of overshoot.
/. Tune the Integral Bain ! The next step after the target is reached consistently is
to tune the Integral gain. Starting from the R1M used to tune the 1!gain+ fully
depress the accelerator and watch the boost as the engine climbs through theR1M range. 4s the engine accelerates through the rev range+ the boost will
probably creep away from the target. Jeep increasing the I gain until the
controller adequately maintains the target with minimal oscillation. It may be
necessary to increase the 1 gain a bit after tuning the I gain since the two gains
tend to counteract each other.
,. tune the $erivative Bain ! Increase the $ gain until the overshoot is
minimi=ed. &are must be ta5en when increasing the $ gain as too much $
gain can over!dampen the effects of the 1 and I gains.
Staged InjectionStaged in0ection allows the use of one set of small in0ectors for low!load and3or low
R1M operation of the engine with the ability to engage a second set of in0ectors at
higher load and R1M when the primary set of in0ectors would otherwise reach their
maximum operational duty cycle. The MSIII%s staged in0ection function supports
staging equally between the primary in0ectors and secondary in0ectors during staged
operation as well as staging completely to the secondary set of in0ectors.
Staged In&ection Behaior in '#grade %ode
In (pgrade mode+ all primary in0ectors should be connected to in0ector channel 8+ andall secondary in0ectors should be connected to in0ector channel -.
Staged In&ection Behaior in %S() %ode
In MS/@ mode+ >hen used with a , cylinder 'or less) engine+ The primary in0ectors
are in0ector channels 4 through $+ and the secondaries are channels E through 2+ or
optionally+ the secondaries can be connected non!sequentially to the mainboard
channels 8 and -. If connected to channels 8 and -+ the secondaries will run in D-
squirts alternatingD configuration.
If used with more than , cylinders+ the secondaries will automatically run on the
mainboard channels 8 and - in D- squirts alternatingD configuration.
Staged In&ection Behaior in %S() Se*uential %ode
In MS/@ Sequential mode+ the same output guidelines apply as in MS/@ non!
sequential mode except that in the case that the secondaries can be connected to the
MS/@ outputs+ they run fully sequential+ and if they are connected to the
-
8/12/2019 MegaSquirt III Engine Management System
34/48
Staged In&ection Settings
This section describes the all the settings associated with staged in0ection.
Staged In0ection irst 1arameter ! This setting enables staged in0ection and
sets the primary staging parameter+ which is used to determine when to engage
the secondary in0ectors. This setting includes the following options#
o Aff ! Staging disabled.
o R1M Stage at a specific R1M.
o M41 Stage at a specific M41.
o T1S Stage at a specific throttle position.
o $uty Stage at a specific primary in0ector duty cycle.
o Table Stage based on the table included in the dialog.
or table!based staging+ 79 means not staged at all+ and 8779 means
fully staged. 4nywhere between 79 and 8779 means partially staged.
The firmware calculates the primary and secondary pulse!widths based
on the in0ector si=es specified elsewhere in the dialog.
1rimary In0ector si=e 'cc) ! Si=e of primary in0ectors in cubic centimeters.
Secondary In0ector si=e 'cc) ! Si=e of secondary in0ectors in cubic centimeters.
Transition fully to secondaries ! This setting is used to determine whether the
fully staged state means that the primary and secondary pulse!widths are
equal+ or if the fully staged state means that primaries are shut down
completely and staging transitions fully to the secondary in0ectors. Thefollowing settings are possible#
-
8/12/2019 MegaSquirt III Engine Management System
35/48
o Aff ! The fully staged state means that the primary and secondary
in0ector pulse!widths are equal.
o An ! The fully staged state means that the primaries are shut down+ and
staging transitions fully to the secondary in0ectors.
Secondary Autputs ! This setting controls whether the MS/@ outputs are used
for secondaries or the hen staged in0ection engages+ the
pulse width will go immediately to the fully staged width.
Transition events 'ign events) ! This setting is used when Bradual staging is
enabled to determine how many ignition events it will ta5e to go from no
staging to fully staged.
1rimary reduction delay 'ign events) ! This setting is used to delay the
reduction of the primary pulse width by the number of ignition events after the
secondaries start coming online. It is only enabled when the gradual transition
feature is enabled.
Secondary Enrichment 'ms) ! This setting is used to in0ect more fuel on thesecondaries than the fully staged calculation determines. This is useful when
there is a small lean spot 0ust after staged in0ection fully engages. This setting
is only available when the gradual transition feature is enabled.
1rimary staging threshold 'units) ! This setting is used to determine when
staged in0ection engages when using R1M+ M41+ T1S+ or $uty. It is not
available when using table!based staging.
1rimary staging hysteresis ! This setting is used to determine when staged
in0ection shuts off. or example+ if R1M is selected as the staged in0ection first
parameter+ and the primary staging threshold is ,877+ and the primary staging
hysteresis is /77+ then staged in0ection will shut off the secondaries and return
the primaries to their normal pulse width at /:77 rpm. This setting is not
available when using table!based staging.
-
8/12/2019 MegaSquirt III Engine Management System
36/48
Second parameter ! This setting is used to add a second method for
determining when to stage. The following settings are available#
o Aff
o R1M
o M41
o T1So $uty
*ote that this setting should not be set the same as the first parameter setting.
This setting is not available with table!based staging.
Secondary staging threshold 'units) ! This setting determines the R1M+ M41+
T1S+ or $uty at which the secondary staged parameter allows staged in0ection
to engage. This setting is not available unless a second staging parameter is
enabled.
Secondary staging hysteresis 'units) ! This setting is used with the secondary
staging threshold setting to determine when staged in0ection will shut off. This
setting is not available unless a second staging parameter is enabled.
Secondary staging logic ! This setting is used to determine whether both the
primary and secondary staging parameters must be met to engage staged
in0ection+ or if only one of the parameters must be met. This setting is not
available in table!based staging mode.
Tuning Staged In&ection
It is recommended that on any setup with secondaries placed further up the inta5e
tract than the primaries+ table!based staging is used. It is possible to achieve a muchsmoother transition to staged in0ection in all situations when tuning with this method.
Tunin" Ta'le-'ased Sta"ed In+ection
The following tips should be followed when tuning table!based staged in0ection#
R1M and Coad transition bins ! Ma5e the two R1M bins and two Coad bins
where staged in0ection first engages close together. 4lso ma5e the staging
percent 0ump to 87!-79 almost immediately 'as shown in the dialog at the
beginning of the staged in0ection section). This is so that a very small amount
of time is spent with the secondary in0ectors at or near the in0ector opening
time for those in0ectors. Spending a lot of time near the in0ector opening time
can lead to inconsistent fueling+ especially if the secondary in0ector opening
time has not been determined and the default value is being used.
Transition to 8779 engaged ! The transition to 8779 engaged should be
determined using experimentation. In general+ the transition should be set so
that the primaries stay close to their maximum duty cycle ':79 is
recommended) for as long as possible. This ensures that reduction to the
primary pulse!width does not result in a lean situation. The table displayed at
the beginning of the staged in0ection settings section is a good example of how
to tune table!based staging for a smooth transition on a naturally aspiratedengine.
-
8/12/2019 MegaSquirt III Engine Management System
37/48
Tunin" All other Sta"ed In+ection Modes
4ll staged in0ection modes that do not use the table to determine the staging amount
can be tuned similarly. The following tips should be used#
1rimary staging parameter ! It is usually recommended that the primarystaging parameter used is $uty. This ensures that staged in0ection engages
when the duty cycle of the primary in0ectors warrants it instead of trying to
guess what R1M or load will cause use of the secondaries to be necessary.
Secondary staging parameter ! It is recommended that this parameter only be
used with forced induction engines. It should be used to ensure that staging is
fully complete before going into boost so that any lean spots caused by staging
are gone.
Bradual transition ! The gradual transition code was introduced to try to solve
the same problems that table!based staging solves. *otably the small lean spot
in 4R briefly after staged in0ection engages. It should be set to transition
over as many ignition events as possible for the smoothest transition. If doing
this still causes a lean spot+ the primary reduction delay can be used along with
the secondary enrichment setting to ma5e sure that slightly more fuel than
calculated using the normal fuel calculations is in0ected. If enabling the
gradual transition feature still does not get rid of the brief lean spot after
staging is engaged+ it is recommended that table!based staging is used.
-
8/12/2019 MegaSquirt III Engine Management System
38/48
-
8/12/2019 MegaSquirt III Engine Management System
39/48
Settings
MA" sa#le #et$od! whether to use the Event Averageor Ti#ed Mini#u#
method. >hen Event 4verage is selected+ no other settings on this page are required.
MA" Sa#le %indo&! how wide the sampling window should be in degrees.
'o( Sa#le Events! how many windows to ta5e the minimum across. or 8+- cyl ,!
stro5e engines this should typically be set to - ! more details below. or -!sto5es or
larger numbers of cylinders set to 8.
"$ase detect t$res$old! when using a M41 sensor in place of a &am sensor 'on 8cyl
or
MA" sa#le ti#ing! this curve sets the start of the sample window in degrees
"T$& for each ignition event. The number must always be less than the number of
-
8/12/2019 MegaSquirt III Engine Management System
40/48
degrees per event. '?-7 3 numcyls for a , stro5e i.e. for ,cyl there are 8:7deg per
event+ for :cyl there are F7deg.)
Event Average
or the ma0ority of engines+ this scheme is proven to give the most consistent results.The multiple runners and overlapping inta5e events on a multi!cylinder engine lead to
resonance and pulsations in M41 that vary across the R1M range and load. Ta5ing an
average over the cycle side!steps these problems and gives a useable M41 reading for
the fuel calculations and other table loo5ups.
Ance this mode is enabled+ the other settings on the M41 sampling page are not
needed or used.
Ti#ed Mini#u#
or some engines+ particularly 8 and - cylinder four stro5e engines+ where there are
fewer and more intermittent inta5e events it is necessary to specify where M41
sampling will occur in order to get a repeatable reading.
-
8/12/2019 MegaSquirt III Engine Management System
41/48
2ere is a M41 log from a 8cyl ,!stro5e engine.
Abserve the large variation in M41 signal during the ?-7 degree cycle. It can be seenthat one M41 window falls on the inta5e stro5e 'where the M41 reaches a minimum)
and the next M41 window is on the power stro5e 'M41 is near atmospheric.)
An this engine it was important to#
Set the appropriate M41 sample angle and window width to capture the dip in
M41
To set *o. Events to -.
The ideal M41 sample angle may either be determined by#
using the M41 logger 'registered TunerStudio only) and opening the datalogs
created in MegaCog
-
8/12/2019 MegaSquirt III Engine Management System
42/48
Event no. Min. M41 in window M41 used for fuelling
8 ?7 ?7
8 F: F:
8 ?7.; ?7.;
8 F: F:
This results in the M41 bouncing around between ?7 and F: resulting in
unpredictable tuning. (sing Event Averagewould be equally poor.
*ow ! with *o. Events set to -.
Event no. Min. M41 in window M41 used for fuelling
8 ?7 ?7
- F: )*
8 ?7.; ?7.;
- F: )*(+
This gives a more realistic and more repeatable M41 signal and is a good start for
tuning ! the atmospheric readings of F:51a on the %dead% windows are ignored.
The 1hase detect threshold is in use on this particular engine. It allows 8cyl and
certain -cyl engines to run sequential fuel and spar5 without a cam sensor. The
Megasquirt %loo5s% at the M41 signal during the reading and compares it to the
threshold to determine whether this is an inta5e stro5e.
Acceleration Enric$#ent
-
8/12/2019 MegaSquirt III Engine Management System
43/48
4cceleration Enrichment is used to ma5e sure the engine has enough fuel during
throttle opening to ma5e the engine accelerate smoothly+ and to ma5e sure the amount
of fuel in0ected during throttle lift is reduced enough to avoid over!rich conditions.
The following sections explain the various types of acceleration enrichment.
Basic Acceleration Enrich!ent Settings
The following includes the basic 4cceleration Enrichment settings#
Cow R1M threshold ! "elow this R1M+ all the standard acceleration
enrichment settings set in the #cceleration izardare used as is.
2igh R1M threshold ! 4bove this R1M+ standard acceleration enrichment is
scaled out completely. "etween the !ow &P' thresholdand the (igh &P'
threshold+ standard acceleration enrichment is scaled down linearly from the
settings listed in the acceleration wi=ard to nothing.
Enhanced 4ccel Enrichment !
o E4E ! This is a inta5e port wall!wetting acceleration enrichment
algorithm. It is the preferred wall!wetting algorithm for use with MS/.
o @!tau ! This is a similar wall!wetting algorithm to E4E. It is included
for those upgrading from the MS-3"NB firmware.
o @!tau with &CT compensation ! This is the same as @!tau+ but with
additional compensation settings for coolant temperature.
Enhanced Acceleration Enrich!ent +EAE,
,ow EAE (ors
The Enhanced 4cceleration Enrichment feature is based on the concept that the fuel
in0ected does not all enter the engine on every in0ector squirt. Instead+ a portion of thefuel collects on the port and3or inta5e runner walls. The fuel collected there forms a
puddle+ from which some fuel enters the engine on every inta5e event 'see diagrams
below).
$iagram showing fuel entering puddle here. $iagram showing fuel leaving puddle
here.
$uring steady!state conditions 'such as cruise or idle)+ the amount of fuel entering the
puddle+ the amount of fuel leaving the puddle+ and the amount of each in0ector squirt
going directly into the engine reach a state of equilibrium. 2owever+ during throttle
opening or throttle closing transient conditions+ the amounts of fuel entering thepuddle+ leaving the puddle+ and going directly into the engine change. (ntil
-
8/12/2019 MegaSquirt III Engine Management System
44/48
equalibrium is reached again+ the amount of in0ected fuel must change to ensure that
the intended amount of fuel 'from the normal fuel equations and
-
8/12/2019 MegaSquirt III Engine Management System
45/48
This curve determines how much fuel is being suc5ed from the walls on each
inta5e 'valve open) event. It is a percentage '!axis) of the total amount of
fuel that has adhered to the walls based on load '@!axis)+ so therefore the
percentages are much smaller 'about 87x smaller) than the #dhere-to-walls
coe))icients.
E4E 4dhere!to!walls R1M correction !
-
8/12/2019 MegaSquirt III Engine Management System
46/48
This curve modifies the E#E #dhere-to-wallscurve. It allows the amount of
correction specified by the E#E #dhere-to-wallscurve to be increased or
decreased based on R1M.
E4E Suc5ed!from!walls R1M correction !
This curve modifies the E#E Suc*ed-)rom-wallscurve. It allows the amount
of correction specified by the E#E Suc*ed-)rom-wallscurve to be increasedor decreased based on R1M.
E4E 4dhere!to!walls &CT correction !
-
8/12/2019 MegaSquirt III Engine Management System
47/48
This curve modifies the E#E #dhere-to-wallscurve. It allows the amount of
correction specified by the E#E #dhere-to-wallscurve to be increased or
decreased based on coolant temperature.
E4E Suc5ed!from!walls &CT correction !
This curve modifies the E#E Suc*ed-)rom-wallscurve. It allows the amount
of correction specified by the E#E Suc*ed-)rom-wallscurve to be increasedor decreased based on coolant temperature.
Tunin" EAE
Since E4E%s main purpose is to ensure that the proper amount of fuel specified by the
-
8/12/2019 MegaSquirt III Engine Management System
48/48
?. Tune the E#E #dhere-to-wallscurve and E#E Suc*ed-)rom-wallscurve
until 4R and response are smooth and stable.
:. Ma5e sure that the throttle movements used are small and slow+ allowing the
4R to reach steady!state before moving the throttle again. Ma5e sure that the
whole load range is covered+ and that every load seen during engine operation
is covered by each of the curves.F. &hoose a few other R1M ranges+ and slowly step on and release the throttle.
Tune the E#E #dhere-to-walls &P' correctionand E#E Suc*ed-)rom-
walls &P' correctioncurves until the response and 4R are correct at the
R1Ms chosen. Typically Idle and high cruise R1Ms should be chosen. 2igh
cruise R1Ms for example are when speed is maintained but the gear selection
is reduced by one or two gears.
87. Shut off the engine+ and allow it to cool completely. Start the engine6 as the
coolant temperature increases+ ad0ust the E#E #dhere-to-walls C!T
correctionand E#E Suc*ed-)rom-walls C!T correctioncurves so that
response and 4R are stable.
88. Ance small+ slow throttle movements are tuned+ larger ones can be verified+ as
well as normal driving with gear shifts
8-. inally+ try to quic5ly blip the throttle while free!revving. If response is slower
than desired+ a very small amount of T1Sdot or M41dot acceleration
enrichment may be re!enabled. Ta5e care to only use it for high T1Sdot values
and use very little. Hust enough to get E4E to respond is all that is required.
The following table explains what corrective actions to ta5e depending on whether the
engine goes lean or rich in specific situations#