FreeEMS
0.2.0-SNAPSHOT-282-g9efc524
|
Decoder for the Honda J Series V6 engine, using one cam wheel and the crank wheel. More...
#include "../inc/freeEMS.h"
#include "../inc/utils.h"
#include "../inc/interrupts.h"
#include "../inc/decoderInterface.h"
Go to the source code of this file.
Macros | |
#define | DECODER_MAX_CODE_TIME 150 |
#define | NUMBER_OF_REAL_EVENTS 24 |
#define | NUMBER_OF_VIRTUAL_EVENTS 24 |
#define | DECODER_IMPLEMENTATION_C |
Functions | |
void | decoderInitPreliminary () |
void | perDecoderReset () |
void | PrimaryRPMISR () |
RPM ISRs, IC timer for engine position and RPM. | |
void | SecondaryRPMISR () |
RPM ISRs, IC timer for engine position and RPM. |
Variables | |
unsigned char | camTeethSeen = 0 |
unsigned char | previousCrankTeethSeen = 0 |
unsigned char | crankTeethSinceLastCamTooth = 0 |
const unsigned short | eventAngles [] |
const unsigned char | eventValidForCrankSync [] = {1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1} |
Decoder for the Honda J Series V6 engine, using one cam wheel and the crank wheel.
Definition in file JSeries-12CrankWith6-2Cam.c.
#define DECODER_MAX_CODE_TIME 150 |
Definition at line 38 of file JSeries-12CrankWith6-2Cam.c.
#define NUMBER_OF_REAL_EVENTS 24 |
Definition at line 39 of file JSeries-12CrankWith6-2Cam.c.
#define NUMBER_OF_VIRTUAL_EVENTS 24 |
Definition at line 40 of file JSeries-12CrankWith6-2Cam.c.
#define DECODER_IMPLEMENTATION_C |
Definition at line 41 of file JSeries-12CrankWith6-2Cam.c.
void decoderInitPreliminary | ( | void | ) |
Definition at line 60 of file JSeries-12CrankWith6-2Cam.c.
References TCTL4.
void perDecoderReset | ( | void | ) |
Definition at line 65 of file JSeries-12CrankWith6-2Cam.c.
References camTeethSeen, crankTeethSinceLastCamTooth, and previousCrankTeethSeen.
void PrimaryRPMISR | ( | void | ) |
RPM ISRs, IC timer for engine position and RPM.
There are multiple copies of this interrupt handler, each is linked with the rest of the code once such that if there are N decoder implementations and/or variants, then there are N loadable binaries produced after a full build.
For details on any specific decoder implementation, see the documentation for that specific file.
Definition at line 72 of file JSeries-12CrankWith6-2Cam.c.
References decoderSetting::accelerationInputEventTimeTolerance, ADCBuffers, BIT0, CALC_FUEL_IGN, CAM_SYNC, Clocks, coreStatusA, COUNT_OF_EVENTS_IMPOSSIBLY_HIGH_NOISE, Counters, KeyUserDebug::currentEvent, DEBUG_TURN_PIN_OFF, DEBUG_TURN_PIN_ON, decoderSetting::decelerationInputEventTimeTolerance, DECODER_BENCHMARKS, KeyUserDebug::decoderFlags, fixedConfig2::decoderSettings, edgeTimeStamp, eventAngles, fixedConfigs2, KeyUserDebug::inputEventTimeTolerance, KeyUserDebugs, LAST_PERIOD_VALID, LAST_TIMESTAMP_VALID, lastPrimaryEventTimeStamp, lastPrimaryTicksPerDegree, NBIT0, numberOfRealEvents, PORTB, PRIMARY_EVENT_ARRIVED_TOO_EARLY, PRIMARY_EVENT_ARRIVED_TOO_LATE, KeyUserDebug::primaryTeethSeen, PTIT, resetToNonRunningState(), sampleEachADC(), Counter::syncedADCreadings, TC0, TFLG, TFLGOF, ticks_per_degree_multiplier, ticksPerDegreeRecord, LongTime::timeLong, Clock::timeoutADCreadingClock, timerExtensionClock, LongTime::timeShorts, and timeStamp.
void SecondaryRPMISR | ( | void | ) |
RPM ISRs, IC timer for engine position and RPM.
There are multiple copies of this interrupt handler, each is linked with the rest of the code once such that if there are N decoder implementations and/or variants, then there are N loadable binaries produced after a full build.For details on any specific decoder implementation, see the documentation for that specific file.
Definition at line 160 of file JSeries-12CrankWith6-2Cam.c.
References BIT0, BUG_REACHED_UNREACHABLE_CODE, CAM_SYNC, camTeethSeen, COUNT_OF_EVENTS_IMPOSSIBLY_HIGH_NOISE, COUNT_OF_EVENTS_IMPOSSIBLY_LOW_NOISE, crankTeethSinceLastCamTooth, KeyUserDebug::currentEvent, DEBUG_TURN_PIN_OFF, DEBUG_TURN_PIN_ON, DECODER_BENCHMARKS, KeyUserDebug::decoderFlags, KeyUserDebugs, NBIT0, OK_TO_SCHEDULE, PORTB, previousCrankTeethSeen, KeyUserDebug::primaryTeethSeen, resetToNonRunningState(), KeyUserDebug::secondaryTeethSeen, SET_SYNC_LEVEL_TO, and TFLG.
unsigned char camTeethSeen = 0 |
Definition at line 48 of file JSeries-12CrankWith6-2Cam.c.
Referenced by perDecoderReset(), and SecondaryRPMISR().
unsigned char previousCrankTeethSeen = 0 |
Definition at line 49 of file JSeries-12CrankWith6-2Cam.c.
Referenced by perDecoderReset(), and SecondaryRPMISR().
unsigned char crankTeethSinceLastCamTooth = 0 |
Definition at line 50 of file JSeries-12CrankWith6-2Cam.c.
Referenced by perDecoderReset(), and SecondaryRPMISR().
const unsigned short eventAngles[] |
Definition at line 52 of file JSeries-12CrankWith6-2Cam.c.
const unsigned char eventValidForCrankSync[] = {1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1} |
Definition at line 58 of file JSeries-12CrankWith6-2Cam.c.