Arduino assigning output to wrong pin
During my testing I found that occasionally when the arduino would sync it would flip the logic 180 degrees out. For example I currently have one VWAG coil plugged into cylinder 4. During start up the Arduino syncs and the logic is correct. After a minute the logic will flip 180 degrees and now the pin for cyl four is now firing number two.
I am not sure how this could be caused by one coil being plugged in, but within the week I plan to install all four and try again.
Can you make a branch that has the sync enabled for every cycle?
I will start writing a branch that syncs every revolution so you can test with that.
Although, having only one coil hooked up next to the high voltage spark plug wires might be just what caused this. It would be interesting to see if hooking up all 4 COPs would make it stable. I can rev just fine to 8000rpm in sequential mode.
Another solution would be to also sample in the 'ECU ignition' signal into the atmega, and disable interrupts while the sparkplug is firing. That would make it extremely robust, but again require hardware changes to any boards you are sketching.
Prototype branch "dalathegreat-ignition-sync-fix" created, heading out to test this on a real engine now.
Note! This version samples in ignition events to pin28!
Wow! I just returned from testing, and it worked! I can now run wasted spark without it breaking the sequencing!
Try it and see if it helps your situation too! All it requires in hardware terms is a new jumperwire from IGNITION -> Pin28 , See the grey wire in this crude sketch.

Be sure to use the "dalathegreat-ignition-sync-fix" branch, it is labeled proto v0.01
That is great news! Good idea sampling the ignition. I should be able to test this on Saturday or Sunday. I need to get a Non RR valve cover so I can fit these VWAG coils. The RR valve cover is too tall for #1 to sit properly.
Please retry with v1.4 stable release , this hopefully solves your issue :)