Before AdvancedIgnition is released (development branch), we should make the 5cyl work with 60-2 crankwheel, and 1-pulse cam.
The trick is when the missing tooth is detected.
- if camsync was flagged, reset tooth_cnt=0 and act as TW_MISSING
- otherwise (camsync not flagged), tooth_cnt+=3 (instead of +=1 or resetting). This is necessary to make up for the 2 teeth at the 60-2
That way tooth_cnt would count up to almost 120, and another_trigger_tooth=18 (decimal 24) would work fine, with no other mod.
Design decisions
Might be done in
- multitooth.c : independent of the current, operational coil-type + camsync code
- or timing.c : possibly merged with the current, operational coil-type + camsync code
might be configured in
- maybe in tooth_wheel upper 2 bits (not optimal, if we want the 135-crankteeth later)
- or in a dedicated secondary_trigger bit