*** MicroSquirt issues with VR Sensor input - fix ***

This forum is for discussing ignition setup, tuning, and troubleshooting for MicroSquirt (TM)
Forum rules
Read the manual to see if your question is answered there before posting. If you have questions about MS1/Extra or MS2/Extra or other non-B&G code configuration or tuning, please post them at http://www.msextra.com The full forum rules are here: Forum Rules, be sure to read them all regularly.
Bruce Bowling
Site Admin
Posts: 285
Joined: Mon Feb 16, 2004 4:25 pm
Location: Baltimore, MD

*** MicroSquirt issues with VR Sensor input - fix ***

Post by Bruce Bowling »

There have been a few reports of installations experiencing issues with the Variable Reluctance (VR) input. In particular, issues with cutouts at high RPMs and hot restart issues. After much digging, I have discovered the root-cause of the issues, and a simple circuit-board mod to correct....

Here is the VR circuit:

Image

There is a diode D5 which is used to shunt the VR current whenever the VR voltage reaches a potential above the 5 volt rail (VCC). This is needed to protect the transistor Q4 from emitter-base reverse voltage, and it works just fine for this purpose.

When the VR potential is below the 5V rail the diode is back-biased and is turned off. The transistor Q4 is turned on as the VR potential drops thru zero and below, it stays conducting throughout the entire negative swing.

Here's the issue - the SS12 diode has a reverse voltage rating of 20 volts, kinda weak for this application. A VR sensor can produce as much as 100 volts or more at high RPMs. If the reverse voltage across this diode exceeds its breakdown it will avalanche and conduct, and this effectively shuts off the transistor. There is a voltage-divider arrangement with the diode amongst the resistors and transistor so the breakdown is not at 20 volts but higher, however it is indeed possible. On the other hand, the diode is referenced to the 5V rail, so in effect there is a -15 volt potential on the VR before breakdown (referenced to the VR- input)....

Also, when the breakdown occurs the diode heats up. This lowers the breakdown voltage so the effect occurs at lower voltages. This is the reason for the hot-start issues that some (including myself) have experienced.

So in order to correct this for people experiencing issues (not everybody will have this problem, it depends on the VR arrangement), the fix is to replace this diode with one with a better reverse voltage rating. I have used a thru-hole diode 1N4148 as a replacement - this is a 100V reverse voltage device. luckily, the diode D5 is easily replaced:

First, here is where D5 is located:

Image

You need to remove this diode with a soldering iron. You can heat up one pad and lever the diode up in the air so that it is supported by the other pad, then apply the iron to the other pad to remove.

Next, bend the leads of the 1N4148 so that it fits on the pads. Make sure it does not hand off the edge of the PCB because this can short to the case. Then solder to the pads, adding a little solder. The band of the diode needs to point towards the green polyfuse device right next to it.

Here are photos of the mod:

Image

Image

You can use any diode with a 100V rating or above, like a 1N4004, etc. Also, if you do not feel comfortable performing this mod, send me a PM and I will help.

After performing this mod, you should be able to remove any external resistance on the VR line, since most likely it was added to prevent the diode from the reverse breakdown issue, which showed up as high RPM dropout. Also, all future MicroSquirt units shipped will have a diode with a high breakdown voltage.

- Bruce
obxer
MegaSquirt Newbie
Posts: 27
Joined: Fri Aug 03, 2007 8:13 am
Location: Nags Head, NC USA
Contact:

Re: *** MicroSquirt issues with VR Sensor input - fix ***

Post by obxer »

This might help someone.

I had ignition issues that I thought this mod might resolve for me. I couldn't tach past about 4K RPM.I thought this mod might fix the problem for me but it didn't help at all.

What did work was increasing the gap between trigger wheel and sensor. When I first tried to start my car after completing my conversion I had to decrease the VR <--> Trigger Wheel gap down to about .014 to get a reliable tach for cranking. I'm actually running my trigger wheel and sensor on my cam shaft - 1/2 speed - so at the time I figured I needed to move the sensor closer to get enough amplitude for a reliable signal. I don't know why this was necessary at the time but it was the only way I could get a reliable tach to crank the car.(I've changed ECU's since then, but not made any wiring changes, etc.)

While decreasing the VR <-->Trigger Wheel gap fixed my start up issue, I was plagued by tach issues when I began tuning. I was getting resets occasionally and couldn't tach past about 4K RPM at all. The RPM showed drops to 0 in MLV as I got up around 4K. I made the diode mod posted here hoping that would correct the problem but it didn't help at all. (I used a 400 V 1N4004 - what I could find locally at Radio Shack.) I finally tried opening the VR sensor gap back up to ~.025 even though it wouldn't work at all before and that instantly cured my ignition problems. I don't know why it works now at .025 when it would not fire reliably at all when I first tried to crank. But opening the gap back up instantly cured the resets/drops I got at 4K and now my tach/ignition seems to work perfectly. Anyway - just thought I'd post this here in case it might help someone.

EDIT - Actually, I'm still having a problem with random resets. But it did completely fix my problem with not being able to tach past 4K.
Allen Massey

1988 Evante MK1 - http://www.obrox.com/evante
SQLGUY
Experienced Squirter
Posts: 243
Joined: Sun May 14, 2006 3:03 am
Location: Colorado Springs, CO

Re: *** MicroSquirt issues with VR Sensor input - fix ***

Post by SQLGUY »

I wasn't getting any responses on the Ignition forum, so I decided to move over here where this topic is posted anyway.

As I mentioned there, I removed my 22K of series resistance and swapped D5 for a 1N4003. This restored my can't-rev-to-redline problem, with uS losing tach precisely at 4800RPM.

I looked at your schematic and can't say I'm convinced of your theory. When the VR input goes low, it's going to forward bias Q4, clamping its collector to ground and allowing no more than 2.5V BE; so it should never be possible to put more than 7.5V of reverse voltage across D5. I confirmed this with a scope.

Here's what I was seeing with this setup. I was measuring between ground and the base of Q4. The pulses are about 6V high (2V / div); ground is at the hashed center line. Notice the little nick near the end of the top edges of the pulses... at higher RPMs this nick gets bigger, eventually making enough of a notch in the pulse that I'm pretty sure that's what's killing my tach signal. The p-p of the pulses here never increase with RPM, although the VR input does increase - going up to about 100V p-p at higher RPMs.

Image

I tried adding a 12V Zener across C30. This helped a bit... getting me to 6800 RPM. I also tried removing C30 entirely. That actually gets me to 8500RPM or so. I also tried adding back-to-back 12V Zener's in place of C30... same result, can rev cleanly to 8500RPM or so, then lose tach. Here's what 2K RPM signal looks like between ground and the junction of R26 and R27 with the back-to-back Zeners clipping the peaks at 12V (so 24V p-p).

Image

A possible counter-theory... could the recovery interval of the diode be part of the problem? A 1N4148 is a fast recovery diode (4ns). A 1N4003 is normal recovery (30uS). What was the trr of the original diode?
Bruce Bowling
Site Admin
Posts: 285
Joined: Mon Feb 16, 2004 4:25 pm
Location: Baltimore, MD

Re: *** MicroSquirt issues with VR Sensor input - fix ***

Post by Bruce Bowling »

SQLGUY wrote: As I mentioned there, I removed my 22K of series resistance and swapped D5 for a 1N4003. This restored my can't-rev-to-redline problem, with uS losing tach precisely at 4800RPM.

I looked at your schematic and can't say I'm convinced of your theory. When the VR input goes low, it's going to forward bias Q4, clamping its collector to ground and allowing no more than 2.5V BE; so it should never be possible to put more than 7.5V of reverse voltage across D5. I confirmed this with a scope.
Yes, this makes sense, and I also obtain roughly the same result with PSPICE and with a corrected board, so much for the explanation. The anode of the diode should never swing below 0.7 volts (w.r.t. ground) or above approx 5.6V. However, with that said I was able, with the original SS12 diode, to achieve breakdown with only input amplitude variations. I found this with a new test engine, and I have tested at least 10 boards and they all fail like clockwork until the diode is replaced, both V1 and V2 board versions.

Reviewing the datasheet for the SS12 from Vishay does not revel a lot of data, especially on reverse recovery speed. There is a rating of 1,000 volts/microsecond which is much much faster than anything we are dealing with here. The diode is targeted to be used for DC-DC converters, high frequency inverters, and the like, again much faster than the low KHz range we are dealing with.

However, the Fairchild datasheet yielded a nice factoid:

http://www.fairchildsemi.com/ds/SS/SS12.pdf

See the "Reverse Current @ rated Vr" spec - this is the leakage current - its only 0.2 milliamps at 25 deg C .. But it is 10 milliamps at 100 deg C - Bingo. Remember this part is right next to the voltage regulator, and it was an observed thermal failure. Not sure of the amplitude part, however the failure occurred even at idle situations. Makes more sense.





SQLGUY wrote: Here's what I was seeing with this setup. I was measuring between ground and the base of Q4. The pulses are about 6V high (2V / div); ground is at the hashed center line. Notice the little nick near the end of the top edges of the pulses... at higher RPMs this nick gets bigger, eventually making enough of a notch in the pulse that I'm pretty sure that's what's killing my tach signal. The p-p of the pulses here never increase with RPM, although the VR input does increase - going up to about 100V p-p at higher RPMs.
I see the notch, in fact it is on both sides of the waveform. It seemingly appears right after the saturation point in the waveform, it just rides down lower on the steep slope edge.

I have not experienced this notch that you are experiencing, just checked the bench and engine setup with the same test. I also do not see it with the simulation. However, if I increase the value of the C29 capacitor to a large value in the simulation I can simulate the blip as well, although it takes a lot of capacitance (like 1uf). This capacitor (called a speedup capacitor) is in place to help reduce the phase shift that C30 introduces at higher frequencies - and there is interaction b/w these values. However it is a small effect and the software also can correct for this.

If you want to see if this capacitor is causing your issue, you can remove it easy enough. Here is the board outline, and C30 is the part in white:

Image

See if this makes any change in the RPM signal. I am a bit surprised that a little blip can cause an issue because there is a software filter in place to remove the effect of a very short blip. Whenever an input capture event comes in the software subsequent input captures are masked out until a certain time elapses then it is re-enabled. Any pulse coming in during this time is ignored. The time window is adjustable in the software as a percentage of the previous tooth interval. The missing tooth kinda screws with the interval because of the 2-deltaT time span. But if removing the capacitor eliminates the problem then either the blip is long compared to tooth delta-T and dominates or the s/w filter is not working like we think.

- Bruce
SQLGUY
Experienced Squirter
Posts: 243
Joined: Sun May 14, 2006 3:03 am
Location: Colorado Springs, CO

Re: *** MicroSquirt issues with VR Sensor input - fix ***

Post by SQLGUY »

Hi Bruce,

For mine the solution seems to be to remove C30 (not C29) and change the 1N4003 I had at D5 for a 1N4148. With this setup I can easily rev past red line with no loss of tach.

I tried the 1N4148 with C30 in place, and that still loses tach at 4800 RPM.

I do believe the nick is switching noise from the 1N4003.

I removed the back-to-back Zeners as well. They didn't seem to have any net effect either way. The testing I did with and without the 1N4148 and with and without C30 was done without the Zeners.

So, my conclusion is that your fix of switching to a 1N4148 is helpful, but that other 100V+ diodes are not neccessarily equally suitable. I don't know why the filter cap causes problems with my setup, but there you have it, and hopefully this information will help others.

EDIT: Then again maybe not... when the engine gets really warm I'm now having a host of other problems, including high idle and losing tach at 3500RPM or so. I don't know if it's because uS is hot or because the VR pickup is hot or what. I'm letting everything cool back down now, and I'll post an update later.

EDIT 2: I scoped again at the anode of D5, and also at the output of U10 (pin 1) with the system hot and not running well. I don't see any double-spike any more, in fact the signals remain very clean even when I advance the throttle to the point that I'm losing tach. It would appear that the problem now is after U10, or in software. I've attached a data log. It looks VERY strange to me. Basically, I started the engine, let it "idle" for a few seconds (it's idling high, at about 2200), then I opened the throttle. At about 4800 RPM then engine starts sputtering and the tach jumps back and forth. I held it like that for a few seconds then released the throttle. Any ideas on what could be causing this?

EDIT 3: I went as far as to scope the TachIC at Pin 1 of the CPU. It looks correct and clean and doesn't change when the ECU loses tach. Either the problem is something too subtle to see on the scope, or there's something else happening. I also tried reinstalling C30, just in case... no improvement. The engine isn't completely cold now, but it's pretty cool, and that didn't make any difference either. It really seems like something else is now broken.

I may try reflashing uS, just as a shotgun attempt. - Tried it... reprogrammed to 2.886 and reloaded with a known good msq... no change. So, I guess it is some sort of hardware issue. Other things I tried that didn't help are removing C29 and reinstalling the back-to-back Zeners.

EDIT 4: I think it's solved! (If it doesn't decide to change its mind again). Basically, I went back to take another look and verify that the second VR pickup was no-longer connected; it wasn't. The wire is cut near the uS connector and well covered with electrical tape. Then I thought, "Well, that wire does carry a 100V signal right next to the other wire..., and the input impedance of the circuit was recently increased...." So, to be very sure, I unscrewed the "extra" VR pickup (the top one here) and left it hanging to the side. Now the bike revs nicely again to high RPM. It remains to see whether it revs correctly when hot.

Image

Cheers,
Paul
Attachments
datalog200810181327.xls
(74.56 KiB) Downloaded 182 times
Last edited by SQLGUY on Sat Oct 18, 2008 3:12 pm, edited 7 times in total.
Bruce Bowling
Site Admin
Posts: 285
Joined: Mon Feb 16, 2004 4:25 pm
Location: Baltimore, MD

Re: *** MicroSquirt issues with VR Sensor input - fix ***

Post by Bruce Bowling »

Paul,

Really good testing here! Glad you are able to get above the RPM limit you were experiencing, and the info will be good for others out there.

Of real interest here is the specs on the 1N4004, the recovery time of 30us could easily play into the mix here. And this may be why some experience issues with the MegaSquirt DIY boards as well, since a 1N4001 diode is specified. I will post a sticky on this over at the MSEFI forums and modify the documentation a bit.

Excellent!

- Bruce
jlturpin
Helpful Squirter
Posts: 36
Joined: Wed May 28, 2008 9:22 pm

Re: *** MicroSquirt issues with VR Sensor input - fix ***

Post by jlturpin »

I made this modification to my mS using a 1N4148, on both VR inputs. Just an FYI, the band of the diode goes in the opposite direction on the second VR input and was probably not necessary to change both of these out.

This gave me a net gain of around 2k rpm. I am running a factory Porsche 944 Turbo, using the 132 teeth ring gear and an offset reference sensor (this is what the factory bosch dme uses). Before this mod I could not rev above a max of 2900 RPM, 2600 cleanly so it is close to double. I can now rev cleanly to 5k rpm. If I could get another 2K of clean revving out of it, it would be near perfect with the factory wiring harness, VR sensors and trigger wheel.
grippo
MegaSquirt Guru
Posts: 921
Joined: Mon Feb 16, 2004 6:55 pm

Re: *** MicroSquirt issues with VR Sensor input - fix ***

Post by grippo »

You can try for 2k more, but I really think you will be limited by processor speed - if it doesn't work much above 5000 rpm on the bench with a direct logic level, absolutely stable trigger input I don't think it will work in a car. But a 60-2 tooth should easily go to 10k.
jlturpin
Helpful Squirter
Posts: 36
Joined: Wed May 28, 2008 9:22 pm

Re: *** MicroSquirt issues with VR Sensor input - fix ***

Post by jlturpin »

After doing a lot of reading :RTFM: , and testing :cry: and primarily help from Bruce and SQLGUY :mrgreen: ,I have successfully turned up my rev limiter to 6800 RPM with no TACH loss. Thats right, 132 teeth at 6800 rpm. :yeah!: :yeah!: :yeah!:

This was accomplished by performing the mod that Bruce posted, and the Mod that SQLGUY explained above, removing the capacitor at C30. I am still running a trimmer pot on the vr+ input now, but will try removing it when I have a chance. :yeah!:

132 teeth trigger wheel, running 6800 RPM CLEAN
RedRocketRally
MegaSquirt Newbie
Posts: 18
Joined: Tue Feb 24, 2009 2:25 pm

Re: *** MicroSquirt issues with VR Sensor input - fix ***

Post by RedRocketRally »

I'm experiencing a problem like this one. I looked at the board of my Microsquirt and it has a surface-mount diode in the spot Bruce circled above, but its a V2 board so I believe it has this fix already.

I've attached an msq and datalog file. I'm losing the ignition signal right around 4500 rpm. I have a VR sensor and a 36-1 trigger wheel. Polarity seems to be correct, but RPM drops out around 4500. I've moved the sensor a bit and gotten the cutout to move to about 5100, but it still cuts out. I am directly driving a Ford-style ACCEL wasted-spark coil pack, like the one pictured at the bottom of the dual spark page of the manual.

Any suggestions?
Attachments
datalog200903061212.msl
datalog of rpm cutting out at 4500
(67.13 KiB) Downloaded 191 times
megasquirt200903061152-bg.msq
MSQ file
(25.07 KiB) Downloaded 192 times
Post Reply