Page 1 of 1
v2.883i - 2nd bug fix
Posted: Thu Jan 03, 2008 8:40 am
by grippo
We have recently helped several people in getting microsquirt running with several dual spark mode configurations. In the course of doing this it was found that ignition outputs were occasionally missed or had longer dwells - later timing than they were supposed to. This only happened at low rpms - below about 250 rpm. This code version fixed these problems, so I am putting it out to replace the existing 2.833b version. There were no changes in features, so existing 2.883 inis and msqs will work fine.
Posted: Thu Jan 03, 2008 9:00 am
by Bernard Fife
Al,
These are also posted on the code page (
http://www.megamanual.com/ms2/code.htm).
Lance.
Posted: Sat Jan 19, 2008 1:13 pm
by MoveX
Hi Al,
I think t_chgoff could be the reason for missed sparksat 2.883b code. The 300ms are one crank rotation at 198 rpm and that's the timeout for every spark channel.
Karl
Posted: Sun Jan 20, 2008 10:51 am
by grippo
That is an interesting coincidence, but if the 300 ms condition is met, the logic should force a spark, not prevent it, and if the condition was not met, then that is good because you would never want a 300 ms dwell. But it might apply to the second problem which also sometimes occurred, where I would set the output compare to start the dwell, bu the dwell never happened. However I looked at the logic for t_chgoff and it should only be set to non-infinity value at the time the dwell is actually turned on. But it is true the problems occurred only within a narrow rpm range from about 180 to 195 rpm, which unfortunately is a common cranking rpm range. I tried dumping delta times everywhere the registers were set, and everything looked perfect, but occasionally in this rpm range either no spark or extended dwell. The only assumption I made was that the processor was following the C instructions, but with CodeWarrior who knows. So rather than dig into the assembler, I constructed a watchdog from the .128 ms timer since this is more than enough accuracy below cranking rpm - like less than 0.1 deg.
I would like to find the cause of the problem, and I will keep the tchgoff coincidence in mind, but I think at some point I may convert the code to vsn 4.5 and see if the problem is still there without the watchdog.