This code will do sequential (and semi-sequential) injection on engines with 1 to 4 cylinders and semi-sequential on 6 and 8 cylinder engine and timed injection on 5, 10, and 12 cylinder engine with some combinations of triggers and number of squirts. The table below shows what is available and is configured automatically in the code depending on the number of cylinder, the type of trigger, the number of injector drivers and whether staging is enabled.
- Code: Select all
No Staging Staging
# Cyl Cam trigger # Inj # Squirts per 720 deg # Inj # Squirts per 720 deg
1 1 2 2 2
1 * 1 1 2 1
2 1 2 2 2
2 * 2 1 4 1
3 * 1 3 2 3
3 * 3 1 - -
4 - - 2 4
4 2 2 4 2
4 * 4 1 - -
5 * 1 5 2 5
6 1 6 2 6
6 * 2 3 4 3
6 3 2 - -
6 * 3 2 - -
8 - - 2 8
8 2 4 4 4
8 4 2 - -
10 1 10 2 10
12 2 6 4 6
12 3 4 - -
The code can use the standard injector drivers (but is of course limited to 2 in that case). The use of 4 injector drivers requires a small modification on the MS2 board which can be seen here. The modification is simple with the addition of 2 small jumpers to bring the signal from the pins 1 and 4 of the NAND gate chip to the card pins 4 and 5. This requires that the clock circuit on the MS board not be installed (this circuit is not needed for MS2).
That will also require the use of 4 external drivers which can be simple like the VNP5N07 (similar to the Microsquirt drivers) for high-Z injectors. For low-Z injectors, another solution will be required since PWM is no longer available with 4 drivers so the use of inline resistors or LM1949-based drivers (such as on my p&h board) will be required. The 4 drivers will need to be connected to pins 39, 40, 4, 5 for injectors drivers 1,2,3,4, respectively. It will be more practical to connect to the equivalent on the MS board as shown on the linked page.
One more thing is that Megatune 2.25 will not be an option for tuning because it doesn't support the number of tables in the new code so TunerStudio will be the one to use. The menu addition are in the Advanced menu as shown below:

The new configuration window looks like this:

The Sequential option allows the selection of the regular untimed injection, Sequential/semi-sequential injection, and semi-sequential and sequential for siamese-port engines. The timing trigger option is to determine if the timing value will be with respect to the start of the injection pulse, the end of the pulse or the middle of the pulse. The end-of-pulse option is nice if you want to time the injection with the opening or closing of the intake valve so that the injection always finishes at that angle no matter what the pulse width is. The middle-of pulse option times the injection with the middle of the pulse (the middle of the effective pulse without the opening time). This is good when the injection has to be within a certain injection angle window such as on siamese-port engines.
"Fixed timing or tables" is for selecting if the timing will be a fixed value for the entire load/rpm range or for using a table. The timing table is a 6x6 table since the timing should be a rather linear thing and not require more than that. It's also limited due to available memory limitations. The number of timing values is to select between 1 or 2 values but the 2 values are only needed for the siamese-port engine configurations. The following options are to enter the timing values if using a fixed timing value.
The VE trim tables are used to trim the injection pulse width individually on each of the injector drivers. It is possible to add or subtract up to 12.4% in 0.1% increments and the tables are full size 16x16 tables. This is not a real VE trim in that it's not done by adding or subtracting from the VE and then doing the fuel calculations but it has a similar effect with it being used to multiply the final pulse width.
The Injector drivers option is to select between the standard MS injector drivers and the additional drivers as described above. If this is selected when no additional drivers and without the MS2 board modification nothing bad will happen to the board or injectors but at best the injector won't fire and at worst they will do so in a non-effective manner. The last options are for entering separate values for the injector characteristics for the additional injectors. These options are only available if the option to have different values is select in the standard injector menu.
As mentioned, the code also does timed injection, in semi-sequential and full sequential modes, for siamese-port engines such as the classic Mini's engine (Rover's A-series engine) but this will be elaborated on seperately.
I have attached the s19 and ini files. I will provide the source code when the status of the code is clarified with James and Ken. Also, the attached code will only work with even wheels (m-n) and the Rover wheel patterns because I had to disable the other wheel patterns since the code was larger than the available memory. However, upon request, I can produce other s19 files that will have the desired patterns by disabling one mode and enabling another one. Of course, this is only valid for the currently available wheel patterns and the code is based on the beta20090201 version.
Jean
EDIT: Old code removed go here for the new code.




