Combustion Pressure Monitoring Subsystem Software Design Specification
Inputs:
- Crankshaft Position (Frequency Signal - Interrupt Based)
- Engine Load (Analogue signal – ADC)
- Spark Gap Ion Current (Analogue signal – ADC)
Outputs:
- Optimum ignition timing referenced with engine load and RPM.
Software Components:
Crankshaft Position Sensor Decoder
- Takes input from crankshaft position sensor via input capture.
- Uses crankshaft position sensor input to constantly update engine RPM and crankshaft position.
Angular Event Generation
- Uses engine RPM and crankshaft position inputs to calculate reference tooth and timing variables for output compare to trigger asynchronous events.
- Steps through each event which has not been carried out this cycle to update timing variables.
Angular Event Sorting
- Steps through all current events and determines which event is next in queue for triggering.
- Next event is assigned to an output compare module.
- Output compare becomes active when the next event reference tooth is reached.
Angular Event Triggering
- Output compare calls event at predetermined time to achieve correct phase.
Ion Current Sampling
- Creates asynchronous events to log samples of the spark gap ion current from the ADC module.
- Creates and maintains buffers, pointers and variables to store samples for later use.
Peak Cylinder Pressure Point Calculation
- Operates on the stored ADC samples to determine the crankshaft angle where peak cylinder pressure occurs.
- The results are stored with reference to the engine RPM and load to allow the ECU to update the ignition timing maps.
Timing information transmission
- The stored results are transmitted to the ECU via UART, CAN, SPI?
No comments:
Post a Comment