In an effort to better understand the fueling process, at least at the beginner level, I've put together a quick document tree to describe how the ECM functions to decide fueling and timing. I think it would be a really good quick reference/guide for the beginning programmer.
I know the modifiers are missing, and can be added in later, but can someone check the work to determine validity?
Kind of but not quite. Fuel quantity uses many PID loops and set points to regulate engine speed along with many other factors in the equation like friction/fuel modifiers. Which PID loop is used is determined by the engine state it is in, LSG(idle), ASG(between LSG and HSG), HSG, Isochronious(dual synchronized engine application), etc. Your accelerator pedal position is used as a base user commanded fueling vs rpm and is further modified from the PID loop it is in to derive final fueling. Diesel engine speed is regulated by the amount of fuel going in and is constantly checking desired rpm against actual, checking if after the last injector opened if rpm was above or below target rpm and adjusting fueling for the next injection event accordingly to maintain targeted engine speed.
Cranking engine state operates differently from the other engine states as well. Then there's also ambient air temperature/battery temperature used for fuel enrichment when the engine is cold.
I agree that the above tree would only valid in the running mode, not the cranking mode.
From what I can see available in the HP Tuners code these are a list of what I would call modifiers. These are tables which would add a small component of fuel to offset the various external conditions the engine would expect.
Coolant temp fuel quantity
Friction fuel quantity
Cooling fan quantity
AC Compressor quantity
These exist for main injection corrections, and some exist for the pilot and post injection as well. They also exist for timing for main and pilot.
In each of these cases some mm3/timing seems to modify the injection events to compensate for increased load events, like the fan turning on etc. I have not included these, because it would have gotten busy fast, and it seems like their effect would be small in the overall scheme of things.
Also, I have not separated the governors into the 3 categories, but included them into one box. I think perhaps the governor control belongs between the output of the logic box (MM3 output) and the injector PW table because it likely has master control of the fueling given you want your rpm limits to be respected at all times.
Obviously we are not running in parallel unless you are tied to another truck lol. Thus they do not enter my tree.
What specific changes would you make to the tree? Is there a better 'tree' available out there. I know for example the algorithms of the GM ECM and PGM-FI (Honda) have published papers on how their control is achieved. I've read them, they are very detailed but really give a good understanding of how the ecm works. This way you can be sure of how the changes you are making will affect the output from more of an engineering point of view than trial and error.
Simply diesel engine speed control is from fuel control, this is what the governors do through PID loop control and there are set points to determine which governor is used when. Much of the processes is in a cyclical loop. The modifier tables for timing, etc. don?t work the way you think. I?ve explained in other threads how they work. Your ECT correction table for main timing will NOT add or subtract from your air density timing tables.
I didn?t go into overly great detail in this thread but it?s one of the threads where I talked about it. Mainly just said how the ecm decides which pilot timing table to use.