instant RPM for idle control #925
This commit is contained in:
parent
47d8cdf0ac
commit
cc011ee081
|
@ -222,8 +222,13 @@ static percent_t automaticIdleController(DECLARE_ENGINE_PARAMETER_SIGNATURE) {
|
||||||
|
|
||||||
efitick_t nowNt = getTimeNowNt();
|
efitick_t nowNt = getTimeNowNt();
|
||||||
// check if within the dead zone
|
// check if within the dead zone
|
||||||
//float rpm = engine->triggerCentral.triggerState.calculateInstantRpm(NULL, nowNt PASS_ENGINE_PARAMETER_SUFFIX);
|
|
||||||
float rpm = GET_RPM();
|
float rpm;
|
||||||
|
if (CONFIG(useInstantRpmForIdle)) {
|
||||||
|
rpm = engine->triggerCentral.triggerState.calculateInstantRpm(NULL, nowNt PASS_ENGINE_PARAMETER_SUFFIX);
|
||||||
|
} else {
|
||||||
|
rpm = GET_RPM();
|
||||||
|
}
|
||||||
if (absI(rpm - targetRpm) <= CONFIG(idlePidRpmDeadZone)) {
|
if (absI(rpm - targetRpm) <= CONFIG(idlePidRpmDeadZone)) {
|
||||||
engine->engineState.idle.idleState = RPM_DEAD_ZONE;
|
engine->engineState.idle.idleState = RPM_DEAD_ZONE;
|
||||||
// current RPM is close enough, no need to change anything
|
// current RPM is close enough, no need to change anything
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
// this section was generated automatically by rusEfi tool ConfigDefinition.jar based on integration\rusefi_config.txt Mon Sep 09 21:25:07 EDT 2019
|
// this section was generated automatically by rusEfi tool ConfigDefinition.jar based on integration\rusefi_config.txt Tue Sep 10 22:56:58 EDT 2019
|
||||||
// by class com.rusefi.output.CHeaderConsumer
|
// by class com.rusefi.output.CHeaderConsumer
|
||||||
// begin
|
// begin
|
||||||
#ifndef CONTROLLERS_GENERATED_ENGINE_CONFIGURATION_GENERATED_STRUCTURES_H
|
#ifndef CONTROLLERS_GENERATED_ENGINE_CONFIGURATION_GENERATED_STRUCTURES_H
|
||||||
|
@ -1095,7 +1095,7 @@ struct engine_configuration_s {
|
||||||
bool useTLE8888_cranking_hack : 1;
|
bool useTLE8888_cranking_hack : 1;
|
||||||
/**
|
/**
|
||||||
offset 76 bit 18 */
|
offset 76 bit 18 */
|
||||||
bool issue_294_18 : 1;
|
bool useInstantRpmForIdle : 1;
|
||||||
/**
|
/**
|
||||||
offset 76 bit 19 */
|
offset 76 bit 19 */
|
||||||
bool issue_294_19 : 1;
|
bool issue_294_19 : 1;
|
||||||
|
@ -2820,4 +2820,4 @@ typedef struct persistent_config_s persistent_config_s;
|
||||||
|
|
||||||
#endif
|
#endif
|
||||||
// end
|
// end
|
||||||
// this section was generated automatically by rusEfi tool ConfigDefinition.jar based on integration\rusefi_config.txt Mon Sep 09 21:25:07 EDT 2019
|
// this section was generated automatically by rusEfi tool ConfigDefinition.jar based on integration\rusefi_config.txt Tue Sep 10 22:56:58 EDT 2019
|
||||||
|
|
|
@ -1260,8 +1260,6 @@
|
||||||
#define isMapAveragingEnabled_offset_hex 5c4
|
#define isMapAveragingEnabled_offset_hex 5c4
|
||||||
#define isSdCardEnabled_offset 744
|
#define isSdCardEnabled_offset 744
|
||||||
#define isSdCardEnabled_offset_hex 2e8
|
#define isSdCardEnabled_offset_hex 2e8
|
||||||
#define issue_294_18_offset 76
|
|
||||||
#define issue_294_18_offset_hex 4c
|
|
||||||
#define issue_294_19_offset 76
|
#define issue_294_19_offset 76
|
||||||
#define issue_294_19_offset_hex 4c
|
#define issue_294_19_offset_hex 4c
|
||||||
#define issue_294_21_offset 76
|
#define issue_294_21_offset 76
|
||||||
|
@ -1925,6 +1923,8 @@
|
||||||
#define useIacTableForCoasting_offset_hex 2e8
|
#define useIacTableForCoasting_offset_hex 2e8
|
||||||
#define useIdleTimingPidControl_offset 744
|
#define useIdleTimingPidControl_offset 744
|
||||||
#define useIdleTimingPidControl_offset_hex 2e8
|
#define useIdleTimingPidControl_offset_hex 2e8
|
||||||
|
#define useInstantRpmForIdle_offset 76
|
||||||
|
#define useInstantRpmForIdle_offset_hex 4c
|
||||||
#define useLcdScreen_offset 744
|
#define useLcdScreen_offset 744
|
||||||
#define useLcdScreen_offset_hex 2e8
|
#define useLcdScreen_offset_hex 2e8
|
||||||
#define useLinearCltSensor_offset 1464
|
#define useLinearCltSensor_offset 1464
|
||||||
|
|
|
@ -300,7 +300,7 @@ bit showSdCardWarning;
|
||||||
bit cj125isUrDivided;looks like 3v range should be enough, divider not needed
|
bit cj125isUrDivided;looks like 3v range should be enough, divider not needed
|
||||||
bit useTLE8888_hall_mode;
|
bit useTLE8888_hall_mode;
|
||||||
bit useTLE8888_cranking_hack;
|
bit useTLE8888_cranking_hack;
|
||||||
bit issue_294_18;
|
bit useInstantRpmForIdle;
|
||||||
bit issue_294_19;
|
bit issue_294_19;
|
||||||
bit issue_294_21;
|
bit issue_294_21;
|
||||||
bit issue_294_22;
|
bit issue_294_22;
|
||||||
|
|
|
@ -82,7 +82,7 @@ enable2ndByteCanID = false
|
||||||
|
|
||||||
; see PAGE_0_SIZE in C source code
|
; see PAGE_0_SIZE in C source code
|
||||||
; CONFIG_DEFINITION_START
|
; CONFIG_DEFINITION_START
|
||||||
; this section was generated automatically by rusEfi tool ConfigDefinition.jar based on integration\rusefi_config.txt Mon Sep 09 21:25:46 EDT 2019
|
; this section was generated automatically by rusEfi tool ConfigDefinition.jar based on integration\rusefi_config.txt Tue Sep 10 22:56:58 EDT 2019
|
||||||
|
|
||||||
pageSize = 20000
|
pageSize = 20000
|
||||||
page = 1
|
page = 1
|
||||||
|
@ -109,7 +109,7 @@ page = 1
|
||||||
cj125isUrDivided = bits, U32, 76, [15:15], "false", "true"
|
cj125isUrDivided = bits, U32, 76, [15:15], "false", "true"
|
||||||
useTLE8888_hall_mode = bits, U32, 76, [16:16], "false", "true"
|
useTLE8888_hall_mode = bits, U32, 76, [16:16], "false", "true"
|
||||||
useTLE8888_cranking_hack= bits, U32, 76, [17:17], "false", "true"
|
useTLE8888_cranking_hack= bits, U32, 76, [17:17], "false", "true"
|
||||||
issue_294_18 = bits, U32, 76, [18:18], "false", "true"
|
useInstantRpmForIdle = bits, U32, 76, [18:18], "false", "true"
|
||||||
issue_294_19 = bits, U32, 76, [19:19], "false", "true"
|
issue_294_19 = bits, U32, 76, [19:19], "false", "true"
|
||||||
issue_294_21 = bits, U32, 76, [20:20], "false", "true"
|
issue_294_21 = bits, U32, 76, [20:20], "false", "true"
|
||||||
issue_294_22 = bits, U32, 76, [21:21], "false", "true"
|
issue_294_22 = bits, U32, 76, [21:21], "false", "true"
|
||||||
|
@ -2911,6 +2911,7 @@ cmd_set_engine_type_default = "w\x00\x31\x00\x00"
|
||||||
|
|
||||||
dialog = idleSettings, "", yAxis
|
dialog = idleSettings, "", yAxis
|
||||||
field = "Idle IAC control mode", idleMode
|
field = "Idle IAC control mode", idleMode
|
||||||
|
field = useInstantRpmForIdle, useInstantRpmForIdle
|
||||||
field = "use ETB for idle", useETBforIdleControl
|
field = "use ETB for idle", useETBforIdleControl
|
||||||
field = "ETB Idle range", etbIdleThrottleRange, {useETBforIdleControl == 1}
|
field = "ETB Idle range", etbIdleThrottleRange, {useETBforIdleControl == 1}
|
||||||
field = "Use separate Ignition Table for idle", useSeparateAdvanceForIdle
|
field = "Use separate Ignition Table for idle", useSeparateAdvanceForIdle
|
||||||
|
|
|
@ -1931,6 +1931,7 @@ cmd_set_engine_type_default = "w\x00\x31\x00\x00"
|
||||||
|
|
||||||
dialog = idleSettings, "", yAxis
|
dialog = idleSettings, "", yAxis
|
||||||
field = "Idle IAC control mode", idleMode
|
field = "Idle IAC control mode", idleMode
|
||||||
|
field = useInstantRpmForIdle, useInstantRpmForIdle
|
||||||
field = "use ETB for idle", useETBforIdleControl
|
field = "use ETB for idle", useETBforIdleControl
|
||||||
field = "ETB Idle range", etbIdleThrottleRange, {useETBforIdleControl == 1}
|
field = "ETB Idle range", etbIdleThrottleRange, {useETBforIdleControl == 1}
|
||||||
field = "Use separate Ignition Table for idle", useSeparateAdvanceForIdle
|
field = "Use separate Ignition Table for idle", useSeparateAdvanceForIdle
|
||||||
|
|
|
@ -82,7 +82,7 @@ enable2ndByteCanID = false
|
||||||
|
|
||||||
; see PAGE_0_SIZE in C source code
|
; see PAGE_0_SIZE in C source code
|
||||||
; CONFIG_DEFINITION_START
|
; CONFIG_DEFINITION_START
|
||||||
; this section was generated automatically by rusEfi tool ConfigDefinition.jar based on integration\rusefi_config.txt Mon Sep 09 21:25:51 EDT 2019
|
; this section was generated automatically by rusEfi tool ConfigDefinition.jar based on integration\rusefi_config.txt Tue Sep 10 22:57:03 EDT 2019
|
||||||
|
|
||||||
pageSize = 20000
|
pageSize = 20000
|
||||||
page = 1
|
page = 1
|
||||||
|
@ -109,7 +109,7 @@ page = 1
|
||||||
cj125isUrDivided = bits, U32, 76, [15:15], "false", "true"
|
cj125isUrDivided = bits, U32, 76, [15:15], "false", "true"
|
||||||
useTLE8888_hall_mode = bits, U32, 76, [16:16], "false", "true"
|
useTLE8888_hall_mode = bits, U32, 76, [16:16], "false", "true"
|
||||||
useTLE8888_cranking_hack= bits, U32, 76, [17:17], "false", "true"
|
useTLE8888_cranking_hack= bits, U32, 76, [17:17], "false", "true"
|
||||||
issue_294_18 = bits, U32, 76, [18:18], "false", "true"
|
useInstantRpmForIdle = bits, U32, 76, [18:18], "false", "true"
|
||||||
issue_294_19 = bits, U32, 76, [19:19], "false", "true"
|
issue_294_19 = bits, U32, 76, [19:19], "false", "true"
|
||||||
issue_294_21 = bits, U32, 76, [20:20], "false", "true"
|
issue_294_21 = bits, U32, 76, [20:20], "false", "true"
|
||||||
issue_294_22 = bits, U32, 76, [21:21], "false", "true"
|
issue_294_22 = bits, U32, 76, [21:21], "false", "true"
|
||||||
|
@ -2911,6 +2911,7 @@ cmd_set_engine_type_default = "w\x00\x31\x00\x00"
|
||||||
|
|
||||||
dialog = idleSettings, "", yAxis
|
dialog = idleSettings, "", yAxis
|
||||||
field = "Idle IAC control mode", idleMode
|
field = "Idle IAC control mode", idleMode
|
||||||
|
field = useInstantRpmForIdle, useInstantRpmForIdle
|
||||||
field = "use ETB for idle", useETBforIdleControl
|
field = "use ETB for idle", useETBforIdleControl
|
||||||
field = "ETB Idle range", etbIdleThrottleRange, {useETBforIdleControl == 1}
|
field = "ETB Idle range", etbIdleThrottleRange, {useETBforIdleControl == 1}
|
||||||
field = "Use separate Ignition Table for idle", useSeparateAdvanceForIdle
|
field = "Use separate Ignition Table for idle", useSeparateAdvanceForIdle
|
||||||
|
|
|
@ -82,7 +82,7 @@ enable2ndByteCanID = false
|
||||||
|
|
||||||
; see PAGE_0_SIZE in C source code
|
; see PAGE_0_SIZE in C source code
|
||||||
; CONFIG_DEFINITION_START
|
; CONFIG_DEFINITION_START
|
||||||
; this section was generated automatically by rusEfi tool ConfigDefinition.jar based on integration\rusefi_config.txt Mon Sep 09 21:25:49 EDT 2019
|
; this section was generated automatically by rusEfi tool ConfigDefinition.jar based on integration\rusefi_config.txt Tue Sep 10 22:57:01 EDT 2019
|
||||||
|
|
||||||
pageSize = 20000
|
pageSize = 20000
|
||||||
page = 1
|
page = 1
|
||||||
|
@ -109,7 +109,7 @@ page = 1
|
||||||
cj125isUrDivided = bits, U32, 76, [15:15], "false", "true"
|
cj125isUrDivided = bits, U32, 76, [15:15], "false", "true"
|
||||||
useTLE8888_hall_mode = bits, U32, 76, [16:16], "false", "true"
|
useTLE8888_hall_mode = bits, U32, 76, [16:16], "false", "true"
|
||||||
useTLE8888_cranking_hack= bits, U32, 76, [17:17], "false", "true"
|
useTLE8888_cranking_hack= bits, U32, 76, [17:17], "false", "true"
|
||||||
issue_294_18 = bits, U32, 76, [18:18], "false", "true"
|
useInstantRpmForIdle = bits, U32, 76, [18:18], "false", "true"
|
||||||
issue_294_19 = bits, U32, 76, [19:19], "false", "true"
|
issue_294_19 = bits, U32, 76, [19:19], "false", "true"
|
||||||
issue_294_21 = bits, U32, 76, [20:20], "false", "true"
|
issue_294_21 = bits, U32, 76, [20:20], "false", "true"
|
||||||
issue_294_22 = bits, U32, 76, [21:21], "false", "true"
|
issue_294_22 = bits, U32, 76, [21:21], "false", "true"
|
||||||
|
@ -2896,6 +2896,7 @@ cmd_set_engine_type_default = "w\x00\x31\x00\x00"
|
||||||
|
|
||||||
dialog = idleSettings, "", yAxis
|
dialog = idleSettings, "", yAxis
|
||||||
field = "Idle IAC control mode", idleMode
|
field = "Idle IAC control mode", idleMode
|
||||||
|
field = useInstantRpmForIdle, useInstantRpmForIdle
|
||||||
field = "use ETB for idle", useETBforIdleControl
|
field = "use ETB for idle", useETBforIdleControl
|
||||||
field = "ETB Idle range", etbIdleThrottleRange, {useETBforIdleControl == 1}
|
field = "ETB Idle range", etbIdleThrottleRange, {useETBforIdleControl == 1}
|
||||||
field = "Use separate Ignition Table for idle", useSeparateAdvanceForIdle
|
field = "Use separate Ignition Table for idle", useSeparateAdvanceForIdle
|
||||||
|
|
|
@ -82,7 +82,7 @@ enable2ndByteCanID = false
|
||||||
|
|
||||||
; see PAGE_0_SIZE in C source code
|
; see PAGE_0_SIZE in C source code
|
||||||
; CONFIG_DEFINITION_START
|
; CONFIG_DEFINITION_START
|
||||||
; this section was generated automatically by rusEfi tool ConfigDefinition.jar based on integration\rusefi_config.txt Mon Sep 09 21:25:53 EDT 2019
|
; this section was generated automatically by rusEfi tool ConfigDefinition.jar based on integration\rusefi_config.txt Tue Sep 10 22:57:05 EDT 2019
|
||||||
|
|
||||||
pageSize = 20000
|
pageSize = 20000
|
||||||
page = 1
|
page = 1
|
||||||
|
@ -109,7 +109,7 @@ page = 1
|
||||||
cj125isUrDivided = bits, U32, 76, [15:15], "false", "true"
|
cj125isUrDivided = bits, U32, 76, [15:15], "false", "true"
|
||||||
useTLE8888_hall_mode = bits, U32, 76, [16:16], "false", "true"
|
useTLE8888_hall_mode = bits, U32, 76, [16:16], "false", "true"
|
||||||
useTLE8888_cranking_hack= bits, U32, 76, [17:17], "false", "true"
|
useTLE8888_cranking_hack= bits, U32, 76, [17:17], "false", "true"
|
||||||
issue_294_18 = bits, U32, 76, [18:18], "false", "true"
|
useInstantRpmForIdle = bits, U32, 76, [18:18], "false", "true"
|
||||||
issue_294_19 = bits, U32, 76, [19:19], "false", "true"
|
issue_294_19 = bits, U32, 76, [19:19], "false", "true"
|
||||||
issue_294_21 = bits, U32, 76, [20:20], "false", "true"
|
issue_294_21 = bits, U32, 76, [20:20], "false", "true"
|
||||||
issue_294_22 = bits, U32, 76, [21:21], "false", "true"
|
issue_294_22 = bits, U32, 76, [21:21], "false", "true"
|
||||||
|
@ -2907,6 +2907,7 @@ cmd_set_engine_type_default = "w\x00\x31\x00\x00"
|
||||||
|
|
||||||
dialog = idleSettings, "", yAxis
|
dialog = idleSettings, "", yAxis
|
||||||
field = "Idle IAC control mode", idleMode
|
field = "Idle IAC control mode", idleMode
|
||||||
|
field = useInstantRpmForIdle, useInstantRpmForIdle
|
||||||
field = "use ETB for idle", useETBforIdleControl
|
field = "use ETB for idle", useETBforIdleControl
|
||||||
field = "ETB Idle range", etbIdleThrottleRange, {useETBforIdleControl == 1}
|
field = "ETB Idle range", etbIdleThrottleRange, {useETBforIdleControl == 1}
|
||||||
field = "Use separate Ignition Table for idle", useSeparateAdvanceForIdle
|
field = "Use separate Ignition Table for idle", useSeparateAdvanceForIdle
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
package com.rusefi.config.generated;
|
package com.rusefi.config.generated;
|
||||||
|
|
||||||
// this file was generated automatically by rusEfi tool ConfigDefinition.jar based on integration\rusefi_config.txt Tue Sep 10 22:45:42 EDT 2019
|
// this file was generated automatically by rusEfi tool ConfigDefinition.jar based on integration\rusefi_config.txt Tue Sep 10 22:56:58 EDT 2019
|
||||||
|
|
||||||
// by class com.rusefi.output.FileJavaFieldsConsumer
|
// by class com.rusefi.output.FileJavaFieldsConsumer
|
||||||
import com.rusefi.config.*;
|
import com.rusefi.config.*;
|
||||||
|
@ -837,7 +837,6 @@ public class Fields {
|
||||||
public static final int isManualSpinningMode_offset = 1476;
|
public static final int isManualSpinningMode_offset = 1476;
|
||||||
public static final int isMapAveragingEnabled_offset = 1476;
|
public static final int isMapAveragingEnabled_offset = 1476;
|
||||||
public static final int isSdCardEnabled_offset = 744;
|
public static final int isSdCardEnabled_offset = 744;
|
||||||
public static final int issue_294_18_offset = 76;
|
|
||||||
public static final int issue_294_19_offset = 76;
|
public static final int issue_294_19_offset = 76;
|
||||||
public static final int issue_294_21_offset = 76;
|
public static final int issue_294_21_offset = 76;
|
||||||
public static final int issue_294_22_offset = 76;
|
public static final int issue_294_22_offset = 76;
|
||||||
|
@ -1245,6 +1244,7 @@ public class Fields {
|
||||||
public static final int useFSIO9ForServo2_offset = 1464;
|
public static final int useFSIO9ForServo2_offset = 1464;
|
||||||
public static final int useIacTableForCoasting_offset = 744;
|
public static final int useIacTableForCoasting_offset = 744;
|
||||||
public static final int useIdleTimingPidControl_offset = 744;
|
public static final int useIdleTimingPidControl_offset = 744;
|
||||||
|
public static final int useInstantRpmForIdle_offset = 76;
|
||||||
public static final int useLcdScreen_offset = 744;
|
public static final int useLcdScreen_offset = 744;
|
||||||
public static final int useLinearCltSensor_offset = 1464;
|
public static final int useLinearCltSensor_offset = 1464;
|
||||||
public static final int useLinearIatSensor_offset = 1464;
|
public static final int useLinearIatSensor_offset = 1464;
|
||||||
|
@ -1307,7 +1307,7 @@ public class Fields {
|
||||||
public static final Field CJ125ISURDIVIDED = Field.create("CJ125ISURDIVIDED", 76, FieldType.BIT, 15);
|
public static final Field CJ125ISURDIVIDED = Field.create("CJ125ISURDIVIDED", 76, FieldType.BIT, 15);
|
||||||
public static final Field USETLE8888_HALL_MODE = Field.create("USETLE8888_HALL_MODE", 76, FieldType.BIT, 16);
|
public static final Field USETLE8888_HALL_MODE = Field.create("USETLE8888_HALL_MODE", 76, FieldType.BIT, 16);
|
||||||
public static final Field USETLE8888_CRANKING_HACK = Field.create("USETLE8888_CRANKING_HACK", 76, FieldType.BIT, 17);
|
public static final Field USETLE8888_CRANKING_HACK = Field.create("USETLE8888_CRANKING_HACK", 76, FieldType.BIT, 17);
|
||||||
public static final Field ISSUE_294_18 = Field.create("ISSUE_294_18", 76, FieldType.BIT, 18);
|
public static final Field USEINSTANTRPMFORIDLE = Field.create("USEINSTANTRPMFORIDLE", 76, FieldType.BIT, 18);
|
||||||
public static final Field ISSUE_294_19 = Field.create("ISSUE_294_19", 76, FieldType.BIT, 19);
|
public static final Field ISSUE_294_19 = Field.create("ISSUE_294_19", 76, FieldType.BIT, 19);
|
||||||
public static final Field ISSUE_294_21 = Field.create("ISSUE_294_21", 76, FieldType.BIT, 20);
|
public static final Field ISSUE_294_21 = Field.create("ISSUE_294_21", 76, FieldType.BIT, 20);
|
||||||
public static final Field ISSUE_294_22 = Field.create("ISSUE_294_22", 76, FieldType.BIT, 21);
|
public static final Field ISSUE_294_22 = Field.create("ISSUE_294_22", 76, FieldType.BIT, 21);
|
||||||
|
@ -2091,7 +2091,7 @@ public class Fields {
|
||||||
CJ125ISURDIVIDED,
|
CJ125ISURDIVIDED,
|
||||||
USETLE8888_HALL_MODE,
|
USETLE8888_HALL_MODE,
|
||||||
USETLE8888_CRANKING_HACK,
|
USETLE8888_CRANKING_HACK,
|
||||||
ISSUE_294_18,
|
USEINSTANTRPMFORIDLE,
|
||||||
ISSUE_294_19,
|
ISSUE_294_19,
|
||||||
ISSUE_294_21,
|
ISSUE_294_21,
|
||||||
ISSUE_294_22,
|
ISSUE_294_22,
|
||||||
|
|
Loading…
Reference in New Issue