The electronic spark control (of "Knock Sensor") regulates the timing inside of the engine. When combustion inside the engine does not fire properly, a "spark knock" or abnormal vibration can occur. If these vibrations caused by misfires are not reduced, they can cause significant damage to the engine parts.
Knock sensors inside your engine contain piezoelectric crystals tuned to this frequency, and generate electric signals when the vibration occurs.
While one sensor alone can detect engine knocks, two or more sensors are often used in an engine. Multiple sensors in different locations allow the Electronic Spark Control to locate the source of the problem with greater accuracy.