This commit is contained in:
rusefillc 2022-01-18 00:27:20 -05:00
parent 82c918df6c
commit 3e8207f393
8 changed files with 70 additions and 40 deletions

View File

@ -271,8 +271,10 @@ uint16_t rpmAcceleration;dRPM;"RPM/s",1, 0, 0, 0, 0
uint16_t autoscale mafEstimate;@@GAUGE_NAME_AIR_FLOW_ESTIMATE@@;"kg/h",{1/@@PACK_MULT_MASS_FLOW@@}, 0, 0, 0, 0
uint16_t instantRpm;;"rpm", 1, 0, 0, 0, 0
float di_nextStart;"DI: next start";"v", 1, 0, 0, 100, 0
! we have some unused bytes to allow compatible TS changes
uint8_t[108 iterate] unusedAtTheEnd;;"",1, 0, 0, 0, 0
uint8_t[104 iterate] unusedAtTheEnd;;"",1, 0, 0, 0, 0
bit launchSpeedCondition
bit launchRpmCondition

View File

@ -1,4 +1,4 @@
// this section was generated automatically by rusEFI tool ConfigDefinition.jar based on (unknown script) console/binary/output_channels.txt Sat Jan 15 22:43:04 UTC 2022
// this section was generated automatically by rusEFI tool ConfigDefinition.jar based on (unknown script) console/binary/output_channels.txt Tue Jan 18 00:21:26 EST 2022
// by class com.rusefi.output.CHeaderConsumer
// begin
#pragma once
@ -910,9 +910,15 @@ struct ts_outputs_s {
*/
uint16_t instantRpm = (uint16_t)0;
/**
* "DI: next start"
v
* offset 360
*/
uint8_t unusedAtTheEnd[108];
float di_nextStart = (float)0;
/**
* offset 364
*/
uint8_t unusedAtTheEnd[104];
/**
offset 468 bit 0 */
bool launchSpeedCondition : 1 {};
@ -936,79 +942,79 @@ struct ts_outputs_s {
bool launchActivatePinState : 1 {};
/**
offset 468 bit 7 */
bool unusedBit_181_7 : 1 {};
bool unusedBit_182_7 : 1 {};
/**
offset 468 bit 8 */
bool unusedBit_181_8 : 1 {};
bool unusedBit_182_8 : 1 {};
/**
offset 468 bit 9 */
bool unusedBit_181_9 : 1 {};
bool unusedBit_182_9 : 1 {};
/**
offset 468 bit 10 */
bool unusedBit_181_10 : 1 {};
bool unusedBit_182_10 : 1 {};
/**
offset 468 bit 11 */
bool unusedBit_181_11 : 1 {};
bool unusedBit_182_11 : 1 {};
/**
offset 468 bit 12 */
bool unusedBit_181_12 : 1 {};
bool unusedBit_182_12 : 1 {};
/**
offset 468 bit 13 */
bool unusedBit_181_13 : 1 {};
bool unusedBit_182_13 : 1 {};
/**
offset 468 bit 14 */
bool unusedBit_181_14 : 1 {};
bool unusedBit_182_14 : 1 {};
/**
offset 468 bit 15 */
bool unusedBit_181_15 : 1 {};
bool unusedBit_182_15 : 1 {};
/**
offset 468 bit 16 */
bool unusedBit_181_16 : 1 {};
bool unusedBit_182_16 : 1 {};
/**
offset 468 bit 17 */
bool unusedBit_181_17 : 1 {};
bool unusedBit_182_17 : 1 {};
/**
offset 468 bit 18 */
bool unusedBit_181_18 : 1 {};
bool unusedBit_182_18 : 1 {};
/**
offset 468 bit 19 */
bool unusedBit_181_19 : 1 {};
bool unusedBit_182_19 : 1 {};
/**
offset 468 bit 20 */
bool unusedBit_181_20 : 1 {};
bool unusedBit_182_20 : 1 {};
/**
offset 468 bit 21 */
bool unusedBit_181_21 : 1 {};
bool unusedBit_182_21 : 1 {};
/**
offset 468 bit 22 */
bool unusedBit_181_22 : 1 {};
bool unusedBit_182_22 : 1 {};
/**
offset 468 bit 23 */
bool unusedBit_181_23 : 1 {};
bool unusedBit_182_23 : 1 {};
/**
offset 468 bit 24 */
bool unusedBit_181_24 : 1 {};
bool unusedBit_182_24 : 1 {};
/**
offset 468 bit 25 */
bool unusedBit_181_25 : 1 {};
bool unusedBit_182_25 : 1 {};
/**
offset 468 bit 26 */
bool unusedBit_181_26 : 1 {};
bool unusedBit_182_26 : 1 {};
/**
offset 468 bit 27 */
bool unusedBit_181_27 : 1 {};
bool unusedBit_182_27 : 1 {};
/**
offset 468 bit 28 */
bool unusedBit_181_28 : 1 {};
bool unusedBit_182_28 : 1 {};
/**
offset 468 bit 29 */
bool unusedBit_181_29 : 1 {};
bool unusedBit_182_29 : 1 {};
/**
offset 468 bit 30 */
bool unusedBit_181_30 : 1 {};
bool unusedBit_182_30 : 1 {};
/**
offset 468 bit 31 */
bool unusedBit_181_31 : 1 {};
bool unusedBit_182_31 : 1 {};
/**
* offset 472
*/
@ -1206,4 +1212,4 @@ struct ts_outputs_s {
};
// end
// this section was generated automatically by rusEFI tool ConfigDefinition.jar based on (unknown script) console/binary/output_channels.txt Sat Jan 15 22:43:04 UTC 2022
// this section was generated automatically by rusEFI tool ConfigDefinition.jar based on (unknown script) console/binary/output_channels.txt Tue Jan 18 00:21:26 EST 2022

View File

@ -178,7 +178,8 @@ void HpfpController::pinTurnOff(HpfpController *self) {
}
void HpfpController::scheduleNextCycle() {
if (!enginePins.hpfpValve.isInitialized()) {
noValve = !enginePins.hpfpValve.isInitialized();
if (noValve) {
m_running = false;
return;
}
@ -186,10 +187,14 @@ void HpfpController::scheduleNextCycle() {
angle_t lobe = m_lobe.findNextLobe();
angle_t angle_requested = m_requested_pump;
if (angle_requested > engineConfiguration->hpfpMinAngle) {
angleAboveMin = angle_requested > engineConfiguration->hpfpMinAngle;
if (angleAboveMin) {
nextStart = lobe - angle_requested - m_deadtime;
engine->outputChannels.di_nextStart = nextStart;
engine->module<TriggerScheduler>()->scheduleOrQueue(
&m_event, TRIGGER_EVENT_UNDEFINED, 0,
lobe - angle_requested - m_deadtime,
nextStart,
{ pinTurnOn, this });
// Off will be scheduled after turning the valve on

View File

@ -3,7 +3,9 @@ struct_no_prefix high_pressure_fuel_pump_s
angle_t m_requested_pump;Computed requested pump duration in degrees (not including deadtime)
float fuel_requested_percent
float fuel_requested_percent_pi
bit haveValve
bit noValve
bit angleAboveMin
angle_t nextLobe
angle_t nextStart
end_struct

View File

@ -1,4 +1,4 @@
// this section was generated automatically by rusEFI tool ConfigDefinition.jar based on (unknown script) controllers/engine_cycle/high_pressure_fuel_pump.txt Tue Jan 18 05:08:39 UTC 2022
// this section was generated automatically by rusEFI tool ConfigDefinition.jar based on (unknown script) controllers/engine_cycle\high_pressure_fuel_pump.txt Tue Jan 18 00:21:14 EST 2022
// by class com.rusefi.output.CHeaderConsumer
// begin
#pragma once
@ -20,7 +20,7 @@ struct high_pressure_fuel_pump_s {
float fuel_requested_percent_pi = (float)0;
/**
offset 12 bit 0 */
bool haveValve : 1 {};
bool noValve : 1 {};
/**
offset 12 bit 1 */
bool angleAboveMin : 1 {};
@ -114,8 +114,16 @@ struct high_pressure_fuel_pump_s {
/**
offset 12 bit 31 */
bool unusedBit_5_31 : 1 {};
/** total size 16*/
/**
* offset 16
*/
angle_t nextLobe = (angle_t)0;
/**
* offset 20
*/
angle_t nextStart = (angle_t)0;
/** total size 24*/
};
// end
// this section was generated automatically by rusEFI tool ConfigDefinition.jar based on (unknown script) controllers/engine_cycle/high_pressure_fuel_pump.txt Tue Jan 18 05:08:39 UTC 2022
// this section was generated automatically by rusEFI tool ConfigDefinition.jar based on (unknown script) controllers/engine_cycle\high_pressure_fuel_pump.txt Tue Jan 18 00:21:14 EST 2022

View File

@ -332,6 +332,8 @@ float getOutputValueByName(const char *name) {
return engine->outputChannels.mafEstimate;
if (strEqualCaseInsensitive(name, "instantRpm"))
return engine->outputChannels.instantRpm;
if (strEqualCaseInsensitive(name, "di_nextStart"))
return engine->outputChannels.di_nextStart;
if (strEqualCaseInsensitive(name, "launchSpeedCondition"))
return engine->outputChannels.launchSpeedCondition;
if (strEqualCaseInsensitive(name, "launchRpmCondition"))

View File

@ -973,6 +973,7 @@ TEMPLOG_MAP_AT_DIFFGauge = TEMPLOG_MAP_AT_DIFF,"TEMPLOG_MAP_AT_DIFF", "", -10000
TEMPLOG_MAP_AT_CYCLE_COUNTGauge = TEMPLOG_MAP_AT_CYCLE_COUNT,"TEMPLOG_MAP_AT_CYCLE_COUNT", "", -10000.0,10000.0, -10000.0,10000.0, -10000.0,10000.0, 3,3
gaugeCategory = GDI
di_nextStartGauge = di_nextStart,"DI: next start", "v", 0.0,100.0, 0.0,100.0, 0.0,100.0, 0,0
m_requested_pumpGauge = m_requested_pump,"DI: Pump Angle", "deg", 0.0,0.0, 0.0,0.0, 0.0,0.0, 0,0
fuel_requested_percentGauge = fuel_requested_percent,"DI: fuel_requested_percent", "v", 0.0,100.0, 0.0,100.0, 0.0,100.0, 0,0
fuel_requested_percent_piGauge = fuel_requested_percent_pi,"DI: fuel_requested_percent_pi", "v", 0.0,100.0, 0.0,100.0, 0.0,100.0, 0,0

View File

@ -1,6 +1,6 @@
package com.rusefi.config.generated;
// this file was generated automatically by rusEFI tool ConfigDefinition.jar based on (unknown script) controllers/engine_cycle/high_pressure_fuel_pump.txt Tue Jan 18 05:08:39 UTC 2022
// this file was generated automatically by rusEFI tool ConfigDefinition.jar based on (unknown script) controllers/engine_cycle\high_pressure_fuel_pump.txt Tue Jan 18 00:21:14 EST 2022
// by class com.rusefi.output.FileJavaFieldsConsumer
import com.rusefi.config.*;
@ -9,7 +9,7 @@ public class HighPressureFuelPump {
public static final Field M_REQUESTED_PUMP = Field.create("M_REQUESTED_PUMP", 0, FieldType.FLOAT);
public static final Field FUEL_REQUESTED_PERCENT = Field.create("FUEL_REQUESTED_PERCENT", 4, FieldType.FLOAT);
public static final Field FUEL_REQUESTED_PERCENT_PI = Field.create("FUEL_REQUESTED_PERCENT_PI", 8, FieldType.FLOAT);
public static final Field HAVEVALVE = Field.create("HAVEVALVE", 12, FieldType.BIT, 0);
public static final Field NOVALVE = Field.create("NOVALVE", 12, FieldType.BIT, 0);
public static final Field ANGLEABOVEMIN = Field.create("ANGLEABOVEMIN", 12, FieldType.BIT, 1);
public static final Field UNUSEDBIT_5_2 = Field.create("UNUSEDBIT_5_2", 12, FieldType.BIT, 2);
public static final Field UNUSEDBIT_5_3 = Field.create("UNUSEDBIT_5_3", 12, FieldType.BIT, 3);
@ -41,11 +41,13 @@ public class HighPressureFuelPump {
public static final Field UNUSEDBIT_5_29 = Field.create("UNUSEDBIT_5_29", 12, FieldType.BIT, 29);
public static final Field UNUSEDBIT_5_30 = Field.create("UNUSEDBIT_5_30", 12, FieldType.BIT, 30);
public static final Field UNUSEDBIT_5_31 = Field.create("UNUSEDBIT_5_31", 12, FieldType.BIT, 31);
public static final Field NEXTLOBE = Field.create("NEXTLOBE", 16, FieldType.FLOAT);
public static final Field NEXTSTART = Field.create("NEXTSTART", 20, FieldType.FLOAT);
public static final Field[] VALUES = {
M_REQUESTED_PUMP,
FUEL_REQUESTED_PERCENT,
FUEL_REQUESTED_PERCENT_PI,
HAVEVALVE,
NOVALVE,
ANGLEABOVEMIN,
UNUSEDBIT_5_2,
UNUSEDBIT_5_3,
@ -77,5 +79,7 @@ public class HighPressureFuelPump {
UNUSEDBIT_5_29,
UNUSEDBIT_5_30,
UNUSEDBIT_5_31,
NEXTLOBE,
NEXTSTART,
};
}