Mitsi 4g63 DSM/Evo and NA Miata 4and2 CAS Decoder

For discussing and developing different RPM/Position decoders using our superior modular architecture! One thread per pattern, please.
User avatar
Fred
Moderator
Posts: 15431
Joined: Tue Jan 15, 2008 2:31 pm
Location: Home sweet home!
Contact:

Mitsi 4g63 DSM/Evo and NA Miata 4and2 CAS Decoder

Post by Fred »

This just seemed like too easy a task to not take on and do, as usual, better than M$.

I grabbed the following image from another older thread in this section:

Image

And a CAS disk from my parts bin, and had a think for a while.

I came up with the following diagram:

Image

Green = instant cam sync
Blue = history based cam sync (we know what it is if there was one unknown event before)
Red = instant crank sync
Black = no sync possible

I'll implement it very soon and already have a test car organised :-)

This will be the first decoder to use multi sync level semantics, more dev, more core features, onwards and upwards :-)

Fred.
DIYEFI.org - where Open Source means Open Source, and Free means Freedom
FreeEMS.org - the open source engine management system
FreeEMS dev diary and its comments thread and my turbo truck!
n00bs, do NOT PM or email tech questions! Use the forum!
The ever growing list of FreeEMS success stories!
Costa
Banned!
Posts: 92
Joined: Sat Mar 08, 2008 3:57 am
Location: Sydney, NSW, AU

Re: Mitsi 4g63 DSM/Evo and NA Miata 4and2 CAS Decoder

Post by Costa »

Hi Fred,

I’ve also looked ways to decode this CAS.

I thought I’ll share my solution. It doesn’t have as many sync points during the cycle as your solution.

Here it is;

On each crank signal rising edge check cam signal.
. If cam signal high – Crank sync and Set CamSyncPossible flag.
. If cam signal low – Crank sync at 180 degree offset and Clear CamSyncPossible flag.

On each crank signal falling edge and CamSyncPossible, check cam signal
. If Cam signal high – Cam sync and Clear CamSyncPossible flag.
. If Cam signal low – Cam sync at 360 degree offset and Clear CamSyncPossible flag.

It only using the rising and falling edges of the crank signal.

Therefore, it’s also possible cam sync at 5 degrees before No.4 TDC.
previously: ca7
User avatar
Fred
Moderator
Posts: 15431
Joined: Tue Jan 15, 2008 2:31 pm
Location: Home sweet home!
Contact:

Re: Mitsi 4g63 DSM/Evo and NA Miata 4and2 CAS Decoder

Post by Fred »

Ahh, I see your logic, except with my system, we already had Cam sync when we arrived at number 5btdc number 4 because we definitely knew that at the end of the smaller inner (cam) slot.

I prefer the inner and outer terminology, as i can't really look at it as 2 different signals, they are always perfectly aligned via a chunk of metal and another chunk of plastic. Thus every edge is a valid edge on the camshaft once synced if you know what I mean :-)

Thanks for sharing! BTW, are you a potential user of this code? If so, make sure you're in for a spin2 board when they come out :-) I'd love to start getting feedback on some of my work and fine tuning various things. A lot is rough around the edges right now, but if people start using it, that won't last because they will complain too much :-)

Fred.
DIYEFI.org - where Open Source means Open Source, and Free means Freedom
FreeEMS.org - the open source engine management system
FreeEMS dev diary and its comments thread and my turbo truck!
n00bs, do NOT PM or email tech questions! Use the forum!
The ever growing list of FreeEMS success stories!
User avatar
Fred
Moderator
Posts: 15431
Joined: Tue Jan 15, 2008 2:31 pm
Location: Home sweet home!
Contact:

Re: Mitsi 4g63 DSM/Evo and NA Miata 4and2 CAS Decoder

Post by Fred »

ca7 wrote:I thought I’ll share my solution. It doesn’t have as many sync points during the cycle as your solution.
Also, I don't think it's possible to have more than what I have in the above diagram, but I would love for some smart-arse to prove me wrong on that! :-) If anyone can see a clever way to gain position in more places or faster than what I've demonstrated above, please share and we'll integrate it into the code base! I even thought about relative timing, but that involves the same edges that we already sync on, so as far as I can tell, the above is optimal. Anyone disagree? If so, please share! :-)

Fred.
DIYEFI.org - where Open Source means Open Source, and Free means Freedom
FreeEMS.org - the open source engine management system
FreeEMS dev diary and its comments thread and my turbo truck!
n00bs, do NOT PM or email tech questions! Use the forum!
The ever growing list of FreeEMS success stories!
Costa
Banned!
Posts: 92
Joined: Sat Mar 08, 2008 3:57 am
Location: Sydney, NSW, AU

Re: Mitsi 4g63 DSM/Evo and NA Miata 4and2 CAS Decoder

Post by Costa »

Fred wrote:we already had Cam sync when we arrived at number 5btdc number 4 because we definitely knew that at the end of the smaller inner (cam) slot.
Fred wrote:I prefer the inner and outer terminology, as i can't really look at it as 2 different signals, they are always perfectly aligned via a chunk of metal and another chunk of plastic. Thus every edge is a valid edge on the camshaft once synced if you know what I mean :-)Fred.
Yes, I see it now. :)
Fred wrote:are you a potential user of this code?
No, not for this CAS. But, I am a potential user for a generic missing tooth wheel on a Gen 1 SB chevy V8.
previously: ca7
User avatar
Fred
Moderator
Posts: 15431
Joined: Tue Jan 15, 2008 2:31 pm
Location: Home sweet home!
Contact:

Re: Mitsi 4g63 DSM/Evo and NA Miata 4and2 CAS Decoder

Post by Fred »

I look forward to working with you a little more closely in a few months, then :-)
DIYEFI.org - where Open Source means Open Source, and Free means Freedom
FreeEMS.org - the open source engine management system
FreeEMS dev diary and its comments thread and my turbo truck!
n00bs, do NOT PM or email tech questions! Use the forum!
The ever growing list of FreeEMS success stories!
Aero
QFP80 - Contributor
Posts: 36
Joined: Wed Apr 30, 2008 7:04 pm

Re: Mitsi 4g63 DSM/Evo and NA Miata 4and2 CAS Decoder

Post by Aero »

I like the sound of this Fred!
User avatar
Fred
Moderator
Posts: 15431
Joined: Tue Jan 15, 2008 2:31 pm
Location: Home sweet home!
Contact:

Re: Mitsi 4g63 DSM/Evo and NA Miata 4and2 CAS Decoder

Post by Fred »

http://issues.freeems.org/view.php?id=110

To keep track of work on it in a more formal way.

Aero, I'm counting on you for being my number one DSM tester! You'd best fix that engine! :-)
DIYEFI.org - where Open Source means Open Source, and Free means Freedom
FreeEMS.org - the open source engine management system
FreeEMS dev diary and its comments thread and my turbo truck!
n00bs, do NOT PM or email tech questions! Use the forum!
The ever growing list of FreeEMS success stories!
User avatar
Fred
Moderator
Posts: 15431
Joined: Tue Jan 15, 2008 2:31 pm
Location: Home sweet home!
Contact:

Re: Mitsi 4g63 DSM/Evo and NA Miata 4and2 CAS Decoder

Post by Fred »

OK, checking the 4/2 DSM/Miata/MX-5 pattern with a logic analyser results in:
  • 70/110 for outers
  • 143 for long inner
  • 70 for short inner slot
  • 15 degrees from leading of long inner to leading of outer contained within long inner
  • leading inner edges 360 apart
  • sensor offset not shown
From the mitsi image above it should be:
  • 70/110 for outers
  • 180 for long inner
  • 80 for short inner
  • 56 degrees from leading of long inner to leading of outer contained within long inner
  • leading inner edges 360 apart
  • sensor offset not shown
However when testing my 4/1 disk on my truck I got the following:
  • 68.7/111.3 for outers
  • 140 for long inner
  • Not measured, but physically looks to be narrower angle than outers
  • 15 degrees from leading of long inner to leading of outer contained within long inner
  • leading inner edges 360 apart
  • 68 crank degrees offset from inner and outer sensors, irrespective of disk
So JimStim (and presumably MS2/MS3) match my results much more closely than the Mitsi diagram. In effect, if I setup my angles to match the JimStim, I can develop the code perfectly well as the edge allignment is correct, unlike the 4/1 CAS pattern. Then for a real car the edge numbers can be fine tuned to produce the best result.

Note, the above diagram could have been for a hall variant of the sensor, which interfaces exactly with the OEM ECU. I would place money that the angles are NOT the same on the hall disk as they are on the optical one. Likely two decoders (or sets of settings for them) are required to handle this properly. I await data from the real world before creating the necessary files for two variants, though.

Fred.
DIYEFI.org - where Open Source means Open Source, and Free means Freedom
FreeEMS.org - the open source engine management system
FreeEMS dev diary and its comments thread and my turbo truck!
n00bs, do NOT PM or email tech questions! Use the forum!
The ever growing list of FreeEMS success stories!
User avatar
Fred
Moderator
Posts: 15431
Joined: Tue Jan 15, 2008 2:31 pm
Location: Home sweet home!
Contact:

Re: Mitsi 4g63 DSM/Evo and NA Miata 4and2 CAS Decoder

Post by Fred »

This'll likely get done pretty soon for a certain pillow hugging boy.
DIYEFI.org - where Open Source means Open Source, and Free means Freedom
FreeEMS.org - the open source engine management system
FreeEMS dev diary and its comments thread and my turbo truck!
n00bs, do NOT PM or email tech questions! Use the forum!
The ever growing list of FreeEMS success stories!
Post Reply