Oil Feed Outputs
Overview
GEMS ECUs typically provide 4 Oil Feed output controllers for controlling solenoid pumps. This section discusses Oil Feed 1, but the same principles apply to the other Oil Feed output controllers.
Tip
Oil Feed outputs may also be repurposed and used as slow pulse width modulated (PWM) outputs, or low resolution user signals.
It is recommended that the behaviour of the oil outputs is tested following configuration. Monitoring the associated output pin channel using a Scope View or a physical oscilloscope is recommended.
Oil Feed Configuration
Each oil feed controller has a set of configuration options. Considering Oil Feed 1:
Option | Description |
---|---|
Selects an input channel for varying the duty cycle. The MSB of the raw input value is displayed by the |
|
Specifies upper/lower byte of the input channel, if it is 16bit. This is usually set to OFF. In some cases (e.g. Little Endian data coming via CAN bus) the bytes of the raw input channel may require swapping. | |
Multiplier for re-scaling the raw input value, saturates at 100% duty cycle in case of overflow. The result is stored in |
|
PWM channel number for high rate / precision PWM, using PWM output settings with duty cycle |
|
Digital output pin for low rate PWM, only used if |
Warning
Changing the output pin (Oil Feed 1 PWM Out or
Oil Feed 1 Out) may leave the prior output in an undefined state. It is recommended to store the calibration and power-cycle the ECU following output pin changes.
Digital Output Configuration
If the Oil Feed output is using a digital output instead of a PWM output, a low frequency / low precision PWM is generated by software.
The following common options are effective in this mode:
Option | Description |
---|---|
If ON then when |
|
Duty cycle to use when engine is not running ( |
|
Use a fixed-length ON pulse, with the duty cycle affecting the duration of the space between ON pulses. | |
If ON then the output will be switched off when the engine is not running ( |
Fixed Mode
Enabled when Oil Feed 1 Fixed On = ON.
This mode uses a fixed duration ON pulse and variable duration OFF interval.
Option | Description |
---|---|
ON | |
Maximum duration of variable part of OFF period, in milliseconds (added to |
|
If set, changes the type of complement operation performed on |
|
Minimum duration of OFF period, in milliseconds. | |
Fixed duration of ON pulse, in milliseconds. | |
Reports current period of signal. | |
Count-up timer, used for signal generation. |
The duration of the ‘OFF’ interval is calculated by scaling option Oil Feed 1 Fixed T.B. by the (inverted) duty cycle percentage shown by
Oil Feed 1 Duty.
The OFF interval can’t ever be 0 and will have a lower limit of 1ms. The lower limit may be clamped to a higher value by setting the Oil Feed 1 OFF min option.
Oil Feed 1 Fixed ON Duty option defines the duration of the ON pulse. This added to the calculated OFF duration to give the total period of the PWM signal and is placed in
Oil Feed 1 Period.
Oil Feed 1 T Count counts up every millisecond.
When Oil Feed 1 T Count exceeds the value of
Oil Feed 1 Period, the output is switched on and
Oil Feed 1 T Count is reset to 0.
When Oil Feed 1 T Count reaches
Oil Feed 1 Fixed ON Duty, the output is switched off.
Proportional Mode
Enabled when Oil Feed 1 Fixed On = OFF.
Proportional mode has a fixed period and varies the duty cycle of the signal over that period. Additionally this mode can limit the total number of pulses delivered to the output after ECU reset.
Option | Description |
---|---|
OFF | |
Maximum ON period | |
If set, changes the type of complement operation performed on |
|
Total period of the PWM signal, in milliseconds. | |
Maximum number of pulses to deliver to the output before ECU reset. If 0, then no limit is applied. | |
Reports the number of pulses delivered to the output when |
|
Stores the result of scaling |
|
Count-down timer, used for signal generation. |
New calibrations may prefer to use Oil Feed 1 Fixed On = ON.
Warning
In Proportional Mode, some ECUs will have an initial 65 second delay before the output PWM becomes operational.
Low values in Oil Feed 1 Duty result in higher duty cycles (effectively inverted).
Oil Feed 1 T Count is decremented every millisecond. When
Oil Feed 1 T Count reaches zero, the output is switched off.
When the output is switched off, Oil Feed 1 T Count is reset to
Oil Feed 1 Time base. Additionally the result of scaling
Oil Feed 1 Duty Max by
Oil Feed 1 Duty is stored in
Oil Feed 1 Duty Time. Note that this does not happen in ‘Fixed Mode’.
When Oil Feed 1 T Count reaches the value of
Oil Feed 1 Duty Time, the output is switched ON.
When switching on the output, if Oil Feed 1 P Max option is non-zero then the
Oil Feed 1 P Count will count up to this value, and the output will cease to be switched on again until the ECU is reset when
Oil Feed 1 P Max pulses have been delivered to the output.
Note
Oil Feed 1 Duty Max should be less than or equal to
Oil Feed 1 Time base. The sense of
Oil Feed 1 Duty is inverted, so that a value of 0 is really 100% duty cycle. This can be inverted by setting a negative output pin number in
Oil Feed 1 Out.
Mapped Control
The ECU provides user tables and maps that may be used to control the Oil Feed outputs.
See ECU Internal Routing for details on how to route these user maps to the Oil Feed outputs.