auto-sync

This commit is contained in:
rusEfi 2014-12-14 22:03:37 -06:00
parent 868bfba153
commit 939c8a6d71
3 changed files with 8 additions and 2 deletions

View File

@ -13,6 +13,7 @@
#include "engine.h" #include "engine.h"
#include "engine_state.h" #include "engine_state.h"
#include "efiGpio.h" #include "efiGpio.h"
#include "trigger_central.h"
#if EFI_PROD_CODE #if EFI_PROD_CODE
#include "injector_central.h" #include "injector_central.h"
@ -24,7 +25,8 @@
static Logging logger; static Logging logger;
#endif #endif
EXTERN_ENGINE; EXTERN_ENGINE
;
/** /**
* We are executing these heavy (logarithm) methods from outside the trigger callbacks for performance reasons. * We are executing these heavy (logarithm) methods from outside the trigger callbacks for performance reasons.
@ -94,6 +96,9 @@ void Engine::watchdog() {
isSpinning = false; isSpinning = false;
#if EFI_PROD_CODE || EFI_SIMULATOR #if EFI_PROD_CODE || EFI_SIMULATOR
scheduleMsg(&logger, "engine has STOPPED"); scheduleMsg(&logger, "engine has STOPPED");
if (engineConfiguration->isPrintTriggerSynchDetails) {
triggerInfo(engine);
}
#endif #endif
stopPins(); stopPins();

View File

@ -225,7 +225,7 @@ extern PwmConfig triggerSignal;
extern uint32_t maxLockTime; extern uint32_t maxLockTime;
extern uint32_t maxEventQueueTime; extern uint32_t maxEventQueueTime;
static void triggerInfo(Engine *engine) { void triggerInfo(Engine *engine) {
#if (EFI_PROD_CODE || EFI_SIMULATOR) || defined(__DOXYGEN__) #if (EFI_PROD_CODE || EFI_SIMULATOR) || defined(__DOXYGEN__)
trigger_shape_s *ts = &engine->triggerShape; trigger_shape_s *ts = &engine->triggerShape;

View File

@ -35,6 +35,7 @@ private:
}; };
#endif #endif
void triggerInfo(Engine *engine);
uint64_t getCrankEventCounter(void); uint64_t getCrankEventCounter(void);
uint64_t getStartOfRevolutionIndex(void); uint64_t getStartOfRevolutionIndex(void);
void hwHandleShaftSignal(trigger_event_e signal); void hwHandleShaftSignal(trigger_event_e signal);