Rev Limiter - simple solution?
Moderators: JeffC, rdoherty, stieg, brentp
Rev Limiter - simple solution?
Firstly I would like to say that the MJLJ looks like an excellent piece of kit. I will probably be ordering a PCB and processor within the next couple of weeks.
From reading the various posts on this website it seems that implementing a hard rev limiter is not as simple as it first appears. Simply using the rev limit output of the MJLJ with a relay to cut power to the coil may cause problems:
<a href="http://picasso.org/mjlj/?q=node/396">Submitted by David Withers on Sat, 06/04/2005 - 17:59.</a>
<blockquote>
If the + 12v or coil -ve is switched during the dwell period of one of the coils, this will probably generate a spark, which, if generated, must be more advanced than the intended timing at that rpm. This will cause detonation, possibly at max rpm and load. It is conceivable that this will damage the engine, particularly if repeated.</blockquote>
While I'm sure that <a href="http://www.with.nildram.co.uk/MJLJ/Limi ... ">Davids's thyristor circuit</a> solution works well, it seems to me that there may be a simpler way...
The difficulty with simply cutting power to the coil with a relay is that the power must not be cut during the dwell period, but only while there is no current flowing in the coil. Is it possible that the MJLJ firmware could be modified so that the rev limit output is only activated at a safe time while there is no current flowing in the coil?
I think this is possible. The rev limit output needs to be synchronised with the operation of the EDIS coil outputs. The MJLJ should be able to use the PIP signal for this. Although there seems to be confusion about the exact timing of the PIP signal, this should not matter.
From <a href="http://www.dainst.com/info/edis/edis.ht ... is.html</a>:
<blockquote>
When the number of teeth required passes the VR sensor, the EDIS module emits the PIP signal to the ECU. The PIP signal is emitted at the TDC of the cylinder.
...
The Ford patent says that the SAW is communicated to the EDIS module approximately 10us after 10° ATDC. This is to ensure that there are no spark events occurring, since the SAW accumulator can not be set externally while it's being read or cleared.</blockquote>
From <a href="http://www.megasquirt.info/ms2/EDIS.htm ... DIS.htm</a>
<blockquote>
In other words, when this signal (Ford calls it the PIP, for Profile Ignition Pick-up) goes from +12V to ground, one of the ignition coils is firing. This signal follows the ignition coils, not the VR sensor (as indicated on some incorrect documentation floating around).
...
Note that the SAW pulse must be synchronized with the PIP negative going pulse (i.e, when the PIP drops to zero). It cannot be applied asynchronously to the PIP signal, otherwise incorrect advance commands will be interpreted by the EDIS module. SAW should be initiated a short period after the falling edge of the PIP signal.</blockquote>
This suggests that the MJLJ could activate a rev limit relay after the falling edge of PIP (ie during the SAW pulse), with confidence that it will not cause a spark at the wrong time.
How difficult would it be to modify the firmware so that the rev limit output operates in this way? Is there a reason why this would not work that I have missed?
Let me know what you think.
Ben
From reading the various posts on this website it seems that implementing a hard rev limiter is not as simple as it first appears. Simply using the rev limit output of the MJLJ with a relay to cut power to the coil may cause problems:
<a href="http://picasso.org/mjlj/?q=node/396">Submitted by David Withers on Sat, 06/04/2005 - 17:59.</a>
<blockquote>
If the + 12v or coil -ve is switched during the dwell period of one of the coils, this will probably generate a spark, which, if generated, must be more advanced than the intended timing at that rpm. This will cause detonation, possibly at max rpm and load. It is conceivable that this will damage the engine, particularly if repeated.</blockquote>
While I'm sure that <a href="http://www.with.nildram.co.uk/MJLJ/Limi ... ">Davids's thyristor circuit</a> solution works well, it seems to me that there may be a simpler way...
The difficulty with simply cutting power to the coil with a relay is that the power must not be cut during the dwell period, but only while there is no current flowing in the coil. Is it possible that the MJLJ firmware could be modified so that the rev limit output is only activated at a safe time while there is no current flowing in the coil?
I think this is possible. The rev limit output needs to be synchronised with the operation of the EDIS coil outputs. The MJLJ should be able to use the PIP signal for this. Although there seems to be confusion about the exact timing of the PIP signal, this should not matter.
From <a href="http://www.dainst.com/info/edis/edis.ht ... is.html</a>:
<blockquote>
When the number of teeth required passes the VR sensor, the EDIS module emits the PIP signal to the ECU. The PIP signal is emitted at the TDC of the cylinder.
...
The Ford patent says that the SAW is communicated to the EDIS module approximately 10us after 10° ATDC. This is to ensure that there are no spark events occurring, since the SAW accumulator can not be set externally while it's being read or cleared.</blockquote>
From <a href="http://www.megasquirt.info/ms2/EDIS.htm ... DIS.htm</a>
<blockquote>
In other words, when this signal (Ford calls it the PIP, for Profile Ignition Pick-up) goes from +12V to ground, one of the ignition coils is firing. This signal follows the ignition coils, not the VR sensor (as indicated on some incorrect documentation floating around).
...
Note that the SAW pulse must be synchronized with the PIP negative going pulse (i.e, when the PIP drops to zero). It cannot be applied asynchronously to the PIP signal, otherwise incorrect advance commands will be interpreted by the EDIS module. SAW should be initiated a short period after the falling edge of the PIP signal.</blockquote>
This suggests that the MJLJ could activate a rev limit relay after the falling edge of PIP (ie during the SAW pulse), with confidence that it will not cause a spark at the wrong time.
How difficult would it be to modify the firmware so that the rev limit output operates in this way? Is there a reason why this would not work that I have missed?
Let me know what you think.
Ben
Nice post Ben...
Nice post Ben...
I'm interested as I've built David's thyristor circuit and it doesn't work. It works fine in the house with a 12v bulb pretending to be the coil, but in the car it just stops all sparks all the time (eg whether or not connected to the MJLJ; whether or not its input line is earth, floating or at +12v)
Some random thougts...
- I'll do some measurements on the car with a scope this w/e to see/check the relationship between the PIP and the coil current
- I don't think I'd be that happy with a relay (double pole I suppose to cut both coils) in terms of it being a mechanical component with non-optimal potential failure modes, speed of response, contact bounce issues etc...
- ...so I'd want an electronic component...
- ...for which the most obvious is a power MosFET or a VB921 (a special purpose High Current Ignition Coil Driver - which I can't find a distributor for in the UK)...
-...so then you might as well use a thyristor...
-...which (IMHO) is a very cute design...
-...but I can't get the circuit to work!
I'll report back, and have another go with the thyristor circuit (not that I can work out what to do with it...)
I'm interested as I've built David's thyristor circuit and it doesn't work. It works fine in the house with a 12v bulb pretending to be the coil, but in the car it just stops all sparks all the time (eg whether or not connected to the MJLJ; whether or not its input line is earth, floating or at +12v)

Some random thougts...
- I'll do some measurements on the car with a scope this w/e to see/check the relationship between the PIP and the coil current
- I don't think I'd be that happy with a relay (double pole I suppose to cut both coils) in terms of it being a mechanical component with non-optimal potential failure modes, speed of response, contact bounce issues etc...
- ...so I'd want an electronic component...
- ...for which the most obvious is a power MosFET or a VB921 (a special purpose High Current Ignition Coil Driver - which I can't find a distributor for in the UK)...
-...so then you might as well use a thyristor...
-...which (IMHO) is a very cute design...
-...but I can't get the circuit to work!
I'll report back, and have another go with the thyristor circuit (not that I can work out what to do with it...)
Rev Limiter
I agree with your comments about mechanical relays. I was thinking of a solid state relay, both for electrical reliability and mechanical ruggedness.
Having thought about it a bit more, I am not sure that a single relay can be used even if synchronised to the PIP signal. I assume that the EDIS keeps the dwell period roughly constant (for a given coil and battery voltage), so the dwell angle will increase with increasing RPM. I guess at high RPM the dwell period could take up most of the time between sparks. With the EDIS using a twin coil, the dwell periods of the two coils could presumably overlap. In this case there will always be current flowing on one or the other or both of the coils.
I would be interested to know the results of your scope measurements. I am a long way from having the system running in a car, so can't do any measurements myself. Can you confirm if PIP is related to the coils or the VR sensor, and if the dwell periods overlap each other or the SAW signal at high RPM? What is your dwell period and does it remain fairly constant?
Did you get the thyristor circuit working? If your wiring to the coils is correct, the problem may be false triggering of the thyristors. Check with the scope for 0V across R5 and R6, with no spikes that could cause false triggering.
Having thought about it a bit more, I am not sure that a single relay can be used even if synchronised to the PIP signal. I assume that the EDIS keeps the dwell period roughly constant (for a given coil and battery voltage), so the dwell angle will increase with increasing RPM. I guess at high RPM the dwell period could take up most of the time between sparks. With the EDIS using a twin coil, the dwell periods of the two coils could presumably overlap. In this case there will always be current flowing on one or the other or both of the coils.
I would be interested to know the results of your scope measurements. I am a long way from having the system running in a car, so can't do any measurements myself. Can you confirm if PIP is related to the coils or the VR sensor, and if the dwell periods overlap each other or the SAW signal at high RPM? What is your dwell period and does it remain fairly constant?
Did you get the thyristor circuit working? If your wiring to the coils is correct, the problem may be false triggering of the thyristors. Check with the scope for 0V across R5 and R6, with no spikes that could cause false triggering.
Finally done *some*
Finally done *some* measurements...
http://www.megasquirt.info/ms2/EDIS.htm says
"When the EDIS module receives proper a VR signal, it generates a 12-volt square-wave signal with a period linked to the next cylinder to fire. In other words, when this signal (Ford calls it the PIP, for Profile Ignition Pick-up) goes from +12V to ground, one of the ignition coils is firing. This signal follows the ignition coils, not the VR sensor (as indicated on some incorrect documentation floating around)."
Well I measured that PIP going from ground to +12v is coincident with one of the coils is firing. For a given coil, and 4 cylinders, every other positive-going transition is for the same coil firing. So the same as they say, but on the opposite transition! I'm sure I didn't measure it wrong...
So, assuming that:
1) this is correct
2) we don't know when the rev limit output in the MJLJ becomes active with respect to the PIP signal transitions...
...I still think there's a chance of a simple external rev limiter circuit.
I think the design is along the lines of:
1)...Disable the coil primary current when PIP transitions to high 'AND' rev limit output is active
2)...and hold the coil primary current disabled until...
3)...the rev limit output becomes inactive
1) allows for:
...the rev limit circuit to become active before a PIP +ve transition (ie when PIP is 0V), but allows that spark to occur
...the rev limit circuit to become active after a PIP +ve transition (ie when PIP is 12V), but doesn't disable the coil (which could be in it's dwell time, thus producing a mal-timed spark) until the spark has actually occurred
...i.e a guaranteed clean cutoff all the time.
So it's a sort of "delayed positive edge triggered on one input, latching on the other input, AND gate"!
Turning it into a circuit is something we can probably do if anyone is interested....
Of course, there could be a firmware mod (hey, it might not even be needed it if we're lucky!) to ensure that the rev limit output only changes very close to, or at the same time as a positive PIP transition. Then just that could be used...your thoughts Brent?
http://www.megasquirt.info/ms2/EDIS.htm says
"When the EDIS module receives proper a VR signal, it generates a 12-volt square-wave signal with a period linked to the next cylinder to fire. In other words, when this signal (Ford calls it the PIP, for Profile Ignition Pick-up) goes from +12V to ground, one of the ignition coils is firing. This signal follows the ignition coils, not the VR sensor (as indicated on some incorrect documentation floating around)."
Well I measured that PIP going from ground to +12v is coincident with one of the coils is firing. For a given coil, and 4 cylinders, every other positive-going transition is for the same coil firing. So the same as they say, but on the opposite transition! I'm sure I didn't measure it wrong...
So, assuming that:
1) this is correct
2) we don't know when the rev limit output in the MJLJ becomes active with respect to the PIP signal transitions...
...I still think there's a chance of a simple external rev limiter circuit.
I think the design is along the lines of:
1)...Disable the coil primary current when PIP transitions to high 'AND' rev limit output is active
2)...and hold the coil primary current disabled until...
3)...the rev limit output becomes inactive
1) allows for:
...the rev limit circuit to become active before a PIP +ve transition (ie when PIP is 0V), but allows that spark to occur
...the rev limit circuit to become active after a PIP +ve transition (ie when PIP is 12V), but doesn't disable the coil (which could be in it's dwell time, thus producing a mal-timed spark) until the spark has actually occurred
...i.e a guaranteed clean cutoff all the time.
So it's a sort of "delayed positive edge triggered on one input, latching on the other input, AND gate"!
Turning it into a circuit is something we can probably do if anyone is interested....
Of course, there could be a firmware mod (hey, it might not even be needed it if we're lucky!) to ensure that the rev limit output only changes very close to, or at the same time as a positive PIP transition. Then just that could be used...your thoughts Brent?
what if
Q: What happens if a relay is fired and cuts off signal from VRS?
Q: What happens if a relay is fired and shorts 3 inputs to a coil, i.e. cyl doubles and ign sw?
As far as I go, I don't care about Megajolt's rev limiter, I'll be using Megasquirt for that, and if not, then I have ECC-V do that for me anyway. Those computers cut fuel and spark, alternating between banks.
Q: What happens if a relay is fired and shorts 3 inputs to a coil, i.e. cyl doubles and ign sw?
As far as I go, I don't care about Megajolt's rev limiter, I'll be using Megasquirt for that, and if not, then I have ECC-V do that for me anyway. Those computers cut fuel and spark, alternating between banks.
Q: What happens if a relay
Q: What happens if a relay is fired and cuts off signal from VRS?
A: A very good question! I'll investigate tonight
Q: What happens if a relay is fired and shorts 3 inputs to a coil, i.e. cyl doubles and ign sw?
A: If the coil is in its dwell period (ie primary current is flowing) then there will be a spark when the current is cut. This spark is highly likely to occur at the wrong time - which is the situation we are trying to avoid. Worse still, this premature spark will be advanced compared with the real spark required, which is potentially bad news for an engine at very high rpm
"As far as I go, I don't care about Megajolt's rev limiter"
Well, it is of major importance to me, and a "proper" spark-cutting rev limiter is a highly desirable feature of Megajolt, which is why I'm pursuing it!
A: A very good question! I'll investigate tonight
Q: What happens if a relay is fired and shorts 3 inputs to a coil, i.e. cyl doubles and ign sw?
A: If the coil is in its dwell period (ie primary current is flowing) then there will be a spark when the current is cut. This spark is highly likely to occur at the wrong time - which is the situation we are trying to avoid. Worse still, this premature spark will be advanced compared with the real spark required, which is potentially bad news for an engine at very high rpm
"As far as I go, I don't care about Megajolt's rev limiter"
Well, it is of major importance to me, and a "proper" spark-cutting rev limiter is a highly desirable feature of Megajolt, which is why I'm pursuing it!
Q: What happens if a relay
Q: What happens if a relay is fired and cuts off signal from VRS?
A: A very good question! I'll investigate tonight
It will be a waste of time investigating...
...no VRS signal to EDIS -> no PIP signal to MJLJ -> no rpm information -> no way of operating rev limiter functionality
A: A very good question! I'll investigate tonight
It will be a waste of time investigating...
...no VRS signal to EDIS -> no PIP signal to MJLJ -> no rpm information -> no way of operating rev limiter functionality
-
- Posts: 0
- Joined: Tue Apr 25, 2006 9:43 am
this is something I REALLY
this is something I REALLY would appreciate if came. as the soft one thats in the megajolt now really only help a little bit, and only under load. Im not that electronically inclined , so dont know how much I can help you guys, jsut wanted to say that I support your work!
I've got a friend who knows
I've got a friend who knows a lot about electronics, ex-scientist from Ukraine, used to work on some classified things. I'll ask him what he thinks a solution could be.
But, about the VRS, I remember washing my vehicle and loom to the sensor came off, I was unable to start it. My thinking is that if there is not VRS signal to EDIS, EDIS will not work, thus we cut the spark. As relay resets, we got EDIS working and Megajolt operating it.
When will relay reset? A circuit could be made to make it reset in several milliseconds after it cut VRS signal, or perhaps Megajolt will reset it when it does not receives PIP signal, it could assume RPM of 0.
Does this make sense?
Another question is if we get rid of undesirable behavior of spark by cutting VRS to limit REVs?
But, about the VRS, I remember washing my vehicle and loom to the sensor came off, I was unable to start it. My thinking is that if there is not VRS signal to EDIS, EDIS will not work, thus we cut the spark. As relay resets, we got EDIS working and Megajolt operating it.
When will relay reset? A circuit could be made to make it reset in several milliseconds after it cut VRS signal, or perhaps Megajolt will reset it when it does not receives PIP signal, it could assume RPM of 0.
Does this make sense?
Another question is if we get rid of undesirable behavior of spark by cutting VRS to limit REVs?
I see where you're coming
I see where you're coming from...I'll give it some further thought...
I'm still not convinced that cutting the coil primary even during it's dwell time would be a particular problem. OK, so you potentially get one spark at the wrong time before the sparks stop completely - does that one spark really matter??
I have a Degree in electronics (a long time ago, mind!) and have also worked on many classified things - they aren't always as exciting as people think. Maybe I should meet your Ukrainian friend...or maybe I'd better not!
I'm still not convinced that cutting the coil primary even during it's dwell time would be a particular problem. OK, so you potentially get one spark at the wrong time before the sparks stop completely - does that one spark really matter??
I have a Degree in electronics (a long time ago, mind!) and have also worked on many classified things - they aren't always as exciting as people think. Maybe I should meet your Ukrainian friend...or maybe I'd better not!
If you stay on the rev limit
If you stay on the rev limit you get multiple sparks. Most drivers don't let go of throttle when hitting rev limit, they shift instead. A common scenario, especially with stock shifters, is when you try to power shift 2nd to 3rd and miss it, you don't let go throttle, you try to shift again. That's half a second to second worth of detonation.
I screwed up my last 4.6 that way (crappy map). Stock cast pistons just crack, and it didn't show up during a compression test either.
I screwed up my last 4.6 that way (crappy map). Stock cast pistons just crack, and it didn't show up during a compression test either.
Re: Finally done *some*
Thanks for looking in to this. I've now got my MJLJ built, so will try to do some tests myself on the bench with a simulated VRS signal.
I agree with you - a circuit could be built, but it would be much neater and simpler if the logic was part of the firmware.
I agree with you - a circuit could be built, but it would be much neater and simpler if the logic was part of the firmware.
Re: what if
It would be interesting to know what happens when the VRS signal is cut. It could be a simple solution, but depends on the behaviour of the EDIS in this situation. It probably wasn't a concern when the EDIS was originally designed. I'll look in to it if I can get a full system running on the bench.