Wavelet DSP Knock Project

I’ve been hacking in the automotive domain for over a decade now. I have done a few engine swaps, but my MR2 was the first time I ditched the factory engine control unit (ECU) in favor of an aftermarket standalone unit. The stock Toyota ECU makes no provisions for tuning or calibration tweaks. The aftermarket ECU I chose from Haltech would allow me completely define the spark and fuel parameters, along with a host of auxiliary features. It came with a flying lead harness, so I had create the entire engine loom; routing and connecting every wire.





When tuning an aftermarket ECU, special tools can help monitor the engines health. Historically tuners and modders relied on reading the condition of the spark plugs, and a good ear to listen for any audible anamlolies. Today there are a number of more sophisticated technologies avialable. One tuning aid that I sought was a knock detection system. With a background in electrical engineering and signal processing, I began to scour the market for suitable devices. After an exhaustive search, I was not impressed with the available options and decided to tune my car without the aid of knock detection device.

Not long after my car was finished, I enrolled in a senior level signal processing course at NIU. There were two projects for the course: one midterm project which was constrained, and one final project which was completely open ended. I chose to tackle the knock detection system as my final course project.

I set up the standalone ECU to give me two maps: one that would run the engine normally, and one that would make the engine combustion detonate.



I recorded the signal from the knock sensor for a preliminary analysis. Here is what the recorded signal sounds like:

Using Goldwave software I performed a time-frequency plot. You can see the signal of interest shifts a bit higher in frequency when detonation is occuring.


I deceided then to dig deeper and isolate the combustion events. Here is the knock signal slowed down:

The waveform of a single combustion event looks like this:

Combustion event waveform

I fed an example of the knock waveform onto the Matlab wavelet toolbox:




Post in progress…

Leave a Reply