rusEFI
The most advanced open source ECU
|
Functions | |
efitick_t | getTimeNowNt () |
efitimeus_t | getTimeNowUs () |
efitimems_t | getTimeNowMs () |
Returns the 32 bit number of milliseconds since the board initialization. More... | |
efitimesec_t | getTimeNowS () |
Current system time in seconds (32 bits) More... | |
Variables | |
static WrapAround62 | timeNt |
efitimems_t getTimeNowMs | ( | ) |
Returns the 32 bit number of milliseconds since the board initialization.
32 bit return type overflows in 23(or46?) days. tag#4554. I think we do not expect rusEFI to run for 23 days straight days any time soon?
Definition at line 34 of file efitime.cpp.
Referenced by assertTimeIsLinear(), printGpsInfo(), sayHello(), StepperMotorBase::setInitialPosition(), slowStartStopButtonCallback(), testMath(), testRusefiMethods(), testSystemCalls(), updateTriggerWaveformIfNeeded(), and writeSdBlock().
efitick_t getTimeNowNt | ( | ) |
64-bit counter CPU/timer cycles since MCU reset
Definition at line 19 of file efitime.cpp.
Referenced by WaveChart::addEvent3(), EtbController::checkOutput(), comp_cam_callback(), comp_shaft_callback(), configureRusefiLuaHooks(), detectHellenBoardId(), endIntegration(), endSimultaneousInjectionOnlyTogglePins(), TriggerCentral::engineMovedRecently(), EngineState::EngineState(), SingleTimerExecutor::executeAllPendingActions(), EventQueue::executeOne(), fireSparkAndPrepareNextSchedule(), StoredValueSensor::get(), getAcrState(), EtbController::getClosedLoopAutotune(), VvtController::getSetpoint(), getTimeNowUs(), PwmConfig::handleCycleStart(), TriggerEmulatorHelper::handleEmulatorCallback(), handleExtiIsr(), initMicrosecondTimer(), Engine::isInShutdownMode(), WaveChart::isStartedTooLongAgo(), HellenBoardIdFinder< NumPins >::measureChargingTimes(), onFastAdcComplete(), LimpManager::onFastCallback(), PrimeController::onIgnitionStateChanged(), PrimeController::onPrimeStart(), RpmCalculator::onSlowCallback(), onStartKnockSampling(), onTdcCallback(), EngineState::periodicFastCallback(), Engine::resetEngineSnifferIfInTestMode(), runBench(), runOneLua(), SingleTimerExecutor::scheduleByTimestampNt(), SingleTimerExecutor::scheduleTimerCallback(), sentTpsDecode(), setHardwareSchedulerTimer(), setHysteresis(), TriggerDecoderBase::setShaftSynchronized(), startAveraging(), startSimultaneousInjection(), MapAverager::stop(), ButtonDebounce::stopConfiguration(), PeriodicController< TStackSize >::ThreadTask(), tle8888startup(), PwmConfig::togglePwmState(), triggerAdcCallback(), triggerScopeGetBuffer(), turnInjectionPinHigh(), turnInjectionPinLow(), turnInjectionPinLowStage2(), turnSparkPinHighStartCharging(), Lps25Sensor::update(), and EngineState::updateTChargeK().
efitimesec_t getTimeNowS | ( | ) |
Current system time in seconds (32 bits)
32 bit integer number of seconds since ECU boot. 31,710 years - would not overflow during our life span.
Definition at line 42 of file efitime.cpp.
Referenced by TriggerDecoderBase::decodeTriggerEvent(), AcController::getAcState(), handleTestCommand(), Engine::periodicSlowCallback(), printRusefiVersion(), sendQcBenchBoardStatus(), THD_FUNCTION(), timeInfo(), updateDevConsoleState(), and updateTunerStudioState().
efitimeus_t getTimeNowUs | ( | ) |
64-bit result would not overflow, but that's complex stuff for our 32-bit MCU
Definition at line 26 of file efitime.cpp.
Referenced by blipIdle(), InjectorOutputPin::close(), configureRusefiLuaHooks(), priv::efiPrintfInternal(), finishIdleTestIfNeeded(), fireSparkBySettingPinLow(), IdleController::getClosedLoop(), IdleController::getRunningOpenLoop(), getSignalOnTime(), getTimeNowMs(), getTimeNowS(), TriggerCentral::handleShaftSignal(), InjectorOutputPin::open(), riseCallback(), runSchedulingPrecisionTestIfNeeded(), TriggerScheduler::scheduleEventsUntilNextTriggerTooth(), SingleTimerExecutor::scheduleForLater(), startDwellByTurningSparkPinHigh(), startIdleBench(), testCallback(), undoIdleBlipIfNeeded(), DynoView::update(), Engine::updateSwitchInputs(), and writeSdBlock().
|
static |
problem: we have three files with bits and pieces of time API and documentation 1) this implementation class 2) rusEFI header efitime.h 3) libfirmware header rusefi_time_types.h
Definition at line 14 of file efitime.cpp.
Referenced by getTimeNowNt(), and EventQueue::insertTask().