mirror of https://github.com/rusefi/rusefi-1.git
auto-sync
This commit is contained in:
parent
02b11af7fc
commit
91ef7561cf
|
@ -316,7 +316,9 @@ static systime_t timeOfPreviousPrintVersion = (systime_t) -1;
|
|||
|
||||
#if EFI_PROD_CODE || defined(__DOXYGEN__)
|
||||
static void printOutPin(const char *pinName, brain_pin_e hwPin) {
|
||||
appendPrintf(&logger, "outpin%s%s@%s%s", DELIMETER, pinName, hwPortname(hwPin), DELIMETER);
|
||||
if (hwPin != GPIO_UNASSIGNED) {
|
||||
appendPrintf(&logger, "outpin%s%s@%s%s", DELIMETER, pinName, hwPortname(hwPin), DELIMETER);
|
||||
}
|
||||
}
|
||||
#endif /* EFI_PROD_CODE */
|
||||
|
||||
|
@ -338,6 +340,9 @@ static void printInfo(systime_t nowSeconds) {
|
|||
printOutPin(CRANK1, boardConfiguration->triggerInputPins[0]);
|
||||
printOutPin(CRANK2, boardConfiguration->triggerInputPins[1]);
|
||||
printOutPin(VVT_NAME, engineConfiguration->camInput);
|
||||
printOutPin(HIP_NAME, boardConfiguration->hip9011IntHoldPin);
|
||||
printOutPin(TACH_NAME, boardConfiguration->tachOutputPin);
|
||||
printOutPin(DIZZY_NAME, engineConfiguration->dizzySparkOutputPin);
|
||||
#if EFI_WAVE_ANALYZER || defined(__DOXYGEN__)
|
||||
printOutPin(WA_CHANNEL_1, boardConfiguration->logicAnalyzerPins[0]);
|
||||
printOutPin(WA_CHANNEL_2, boardConfiguration->logicAnalyzerPins[1]);
|
||||
|
|
|
@ -14,6 +14,9 @@
|
|||
#include "firing_order.h"
|
||||
#include "efifeatures.h"
|
||||
|
||||
#define HIP_NAME "HIP"
|
||||
#define TACH_NAME "tach"
|
||||
#define DIZZY_NAME "dizzy"
|
||||
|
||||
#define ENUM_16_BITS 20000
|
||||
|
||||
|
|
|
@ -41,6 +41,9 @@
|
|||
#define FAST_MAP_CHART_SKIP_FACTOR 16
|
||||
|
||||
static Logging *logger;
|
||||
/**
|
||||
* this instance does not have a real physical pin - it's only used for engine sniffer
|
||||
*/
|
||||
static NamedOutputPin mapAveragingPin("map");
|
||||
|
||||
/**
|
||||
|
|
|
@ -30,6 +30,10 @@ InjectorOutputPin::InjectorOutputPin() : NamedOutputPin() {
|
|||
reset();
|
||||
}
|
||||
|
||||
engine_pins_s::engine_pins_s() {
|
||||
dizzyOutput.name = DIZZY_NAME;
|
||||
}
|
||||
|
||||
void InjectorOutputPin::reset() {
|
||||
overlappingScheduleOffTime = 0;
|
||||
cancelNextTurningInjectorOff = false;
|
||||
|
|
|
@ -55,7 +55,9 @@ public:
|
|||
bool cancelNextTurningInjectorOff;
|
||||
};
|
||||
|
||||
typedef struct {
|
||||
class engine_pins_s {
|
||||
public:
|
||||
engine_pins_s();
|
||||
OutputPin mainRelay;
|
||||
OutputPin fanRelay;
|
||||
OutputPin acRelay;
|
||||
|
@ -66,8 +68,8 @@ typedef struct {
|
|||
|
||||
InjectorOutputPin injectors[INJECTION_PIN_COUNT];
|
||||
NamedOutputPin coils[IGNITION_PIN_COUNT];
|
||||
OutputPin dizzyOutput;
|
||||
} engine_pins_s;
|
||||
NamedOutputPin dizzyOutput;
|
||||
};
|
||||
|
||||
/**
|
||||
* it's a macro to be sure that stack is not used
|
||||
|
|
|
@ -15,11 +15,11 @@
|
|||
|
||||
EXTERN_ENGINE;
|
||||
|
||||
static OutputPin tachOut;
|
||||
static NamedOutputPin tachOut(TACH_NAME);
|
||||
static scheduling_s tachTurnSignalOff;
|
||||
|
||||
static void turnTachPinLow(void) {
|
||||
tachOut.setValue(false);
|
||||
turnPinLow(&tachOut);
|
||||
}
|
||||
|
||||
static void tachSignalCallback(trigger_event_e ckpSignalType,
|
||||
|
@ -27,7 +27,7 @@ static void tachSignalCallback(trigger_event_e ckpSignalType,
|
|||
if (index != engineConfiguration->tachPulseTriggerIndex) {
|
||||
return;
|
||||
}
|
||||
tachOut.setValue(true);
|
||||
turnPinHigh(&tachOut);
|
||||
scheduleTask("tach off", &tachTurnSignalOff, (int)MS2US(engineConfiguration->tachPulseDuractionMs), (schfunc_t) &turnTachPinLow, NULL);
|
||||
}
|
||||
|
||||
|
|
|
@ -295,18 +295,18 @@ void turnSparkPinLow(NamedOutputPin *output) {
|
|||
turnPinLow(output);
|
||||
#if EFI_PROD_CODE || defined(__DOXYGEN__)
|
||||
if (CONFIG(dizzySparkOutputPin) != GPIO_UNASSIGNED) {
|
||||
doSetOutputPinValue2(&enginePins.dizzyOutput, false);
|
||||
turnPinLow(&enginePins.dizzyOutput);
|
||||
}
|
||||
#endif
|
||||
#endif /* EFI_PROD_CODE */
|
||||
}
|
||||
|
||||
void turnSparkPinHigh(NamedOutputPin *output) {
|
||||
turnPinHigh(output);
|
||||
#if EFI_PROD_CODE || defined(__DOXYGEN__)
|
||||
if (CONFIG(dizzySparkOutputPin) != GPIO_UNASSIGNED) {
|
||||
doSetOutputPinValue2(&enginePins.dizzyOutput, true);
|
||||
turnPinHigh(&enginePins.dizzyOutput);
|
||||
}
|
||||
#endif
|
||||
#endif /* EFI_PROD_CODE */
|
||||
}
|
||||
|
||||
static ALWAYS_INLINE void handleSparkEvent(bool limitedSpark, uint32_t trgEventIndex, IgnitionEvent *iEvent,
|
||||
|
|
|
@ -39,7 +39,7 @@
|
|||
|
||||
#if EFI_HIP_9011 || defined(__DOXYGEN__)
|
||||
|
||||
static NamedOutputPin intHold("HIP");
|
||||
static NamedOutputPin intHold(HIP_NAME);
|
||||
static OutputPin hipCs;
|
||||
|
||||
extern uint32_t lastExecutionCount;
|
||||
|
|
|
@ -309,5 +309,5 @@ int getRusEfiVersion(void) {
|
|||
return 123; // this is here to make the compiler happy about the unused array
|
||||
if (UNUSED_CCM_SIZE[0] * 0 != 0)
|
||||
return 3211; // this is here to make the compiler happy about the unused array
|
||||
return 20160903;
|
||||
return 20160906;
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue