Engine Speed (RPM) Calculation
Overview
Once the synchronization strategy is configured and the ECU is able to synchronize with the engine, the engine speed (RPM) can be calculated.
Engine Speed Calculation
The Engine Speed channel is calculated using the time intervals of crankshaft position sensor readings.
A value must be specified in the Speed mul option otherwise
Engine Speed will read zero.
The Wheel Teeth option defines how many internal teeth time intervals are summed to produce the
Rev Time MSB and
Rev Time channels. Depending upon whether
Wheel Teeth is equal to the number of internal teeth per revolution determines whether or not
Rev Time is really the total time for one revolution of the crankshaft (it may not be).
If Wheel Teeth was 2x the number of internal teeth per revolution then the engine speed would be summed over 2 revolutions of the crankshaft.
If the Speed cycle/Rev option is ON then the speed is derived from 150ms/“Rev Time” instead of 300ms/“Rev Time”, which can act as a tradeoff between maximum engine speed and precision.
The Speed mul option is used to scale the result to a correct RPM value, depending upon the combination of the settings.
Valid settings, e.g. for a calibration with 12 internal teeth:
Max Engine Speed | |||
---|---|---|---|
12 (1 rev) | 50% | OFF | 12799 rpm |
12 (1 rev) | 100% | ON | 25599 rpm |
24 (2 revs) | 100% | OFF | 25599 rpm |
The Pickup comp option compensates for fixed timing drift. The ECU’s calculated RPM value can be compared to that measured using a calibrated tachometer to determine the correct value for this option.
When Starting / Cranking
When the engine is starting, the ECU will be in an unsynchronized state and therefore can’t identify the internal teeth, so a different strategy is required to calculate the engine speed.
This strategy is less accurate that using internal teeth - actual crank teeth may be irregularly spaced due to missing / extra teeth.
Times between physical teeth (‘actual’ teeth) are measured between crank wheel sensor events. Engine speed can be estimated over as few as 2 teeth, but accuracy improves with more teeth. A maximum of 7 teeth intervals may be used to estimate the engine speed during cranking.
Start Actual Teeth configures the number of tooth times to sum for the starting Engine Speed calculation. Until this number of teeth have been detected, the engine speed will be zero.
Start Actual Teeth <2 is a ’left-shift’ - the number of times to double the partial rev-time such that it represents something close to either a single revolution or two revolutions (a 4-stroke engine cycle) of the crankshaft, depending upon the calculation strategy.
Rev Timenot sync’d = Tcycle | rev = T‘Start Actual Teeth’ * 2‘Start Actual Teeth <2’
Depending upon the engine speed calculation strategy, rpm will be estimated over either one or two revolutions of the crankshaft, so the Start Actual Teeth and
Start Actual Teeth <2 must take into account the ratio between
Wheel Teeth and the number of actual-vs-internal-teeth derived from the crankshaft timing wheel using the
Tooth Control table.
For example a few possible settings for Start Actual Teeth and
Start Actual Teeth <2 are shown below, derived from a 36-2 timing wheel configuration:
Item | Value |
---|---|
Crankshaft timing wheel | 36-2 (34 physical teeth) |
Subdivider (physical teeth per internal tooth) | 3 |
Internal teeth per revolution ( |
12 = (36 / 3) |
24 = (12 * 2) | |
Engine speed calculated over | 2 revs |
100% | |
OFF | |
Target estimation tooth count | 72 = (36 * 2), 2 revs |
Reduce to value near 7 by successive divide by 2 | 36 = (72 / 2) |
18 = (72 / 4) | |
9 = (72 / 8) | |
4.5 = (72 / 16) | |
7 = limit 9 to 7 | |
3 = log2(8) | |
Estimated over | 56 = (7 * 8) teeth, 1.65 revs |
Error | -22% = (56 / 72) |
4 = round down 4.5 | |
4 = log2(16) | |
Estimated over | 64 = (4 * 16) teeth, 1.88 revs |
Error | -11% = (64 / 72) |
5 = round up 4.5 | |
4 = log2(16) | |
Estimated over | 80 = (5 * 16) teeth, 2.35 revs |
Error | +11% = (80 / 72) |
The various options for calibration here are a trade-off between accuracy and precision. While a lower Start Actual Teeth value may give a more accurate engine speed (closer to the actual RPM value), it may be less precise than if it had been calculated over more teeth.
The accuracy of the engine speed during this phase is not all that important - any options that depend upon it can be adjusted accordingly. The precision of the engine speed is arguably more important, especially when there are missing / extra teeth on the timing wheel - but the extra precision it does mean that it will take more teeth passing the sensor to achieve a non-zero engine speed value.
Crankshaft timing wheel is a 36-2 (34 actual teeth) and Wheel Teeth is set to 12 (1 internal tooth per 3 actual teeth), then to estimate the engine speed over a single revolution of the crankshaft,
Start Actual Teeth should be set to 12 * 3 = 36 and
Start Actual Teeth <2 should be set to 0.