Nissan Leaf Resolver offsets

Nissan Leaf/e-NV200 drive stack topics
User avatar
johu
Site Admin
Posts: 5684
Joined: Thu Nov 08, 2018 10:52 pm
Location: Kassel/Germany
Has thanked: 153 times
Been thanked: 960 times
Contact:

Nissan Leaf Resolver offsets

Post by johu »

So it turns out the Leaf motors are marked with a resolver calibration value that needed to be entered into the inverter whenever a mechanic swapped either motor or inverter. So on this thread I wanted to collect some of these numbers to find the system. They can be found on the bottom of the motor. Here are some:

Somehow I think it's a group of 3 2 digit hex numbers and 1 digit on Gen 1 motors?:
  • 8A00000000 (Gen 1)
  • 8E00000000 (Gen 1)
  • 9400000000 (Gen 1)
  • 8600490054
  • 8500070057
  • 8400650056
  • 84007D005F
  • 8200DF005D - syncofs = 1000 (where 360°=65536). So 0x4 if 360°= 256
  • 800044004A
  • 7F0036005D
  • 7F0055005D
  • 7500C1004E
  • 7E001B005A
So all the first and the last number are sort of close together. The middle one doesn't follow that scheme. The Gen 1 motor seems to have only the first number set.

If it is really 3 and why, I don't know. Maybe for forward and reverse but what is the 3rd?

EDIT: many numbers now. Since I've pretty much tuned syncofs for my motor others can start doing so. Maybe add the numbers to their original post in bold so I can see it. Or we might just transfer it to a wiki page.
I can say for sure that syncofs 1000 +- 500 seemed the point for my motor were it would not spin on ID current. 1000 means 1000*360/65536=5.5°. If we assume 360° is 256 in Nissans world then syncofs_256=1000*256/65536 = 0x4. If we further assume that they phase shift their calibration by 180° for some reason then 0x2 would be perfect for my motor since 0x2 + 0x80 = 0x82.
In this case to convert the first digit to an openinverter-syncofs you would calculate syncofs = ((digit + 0x80) mod 256)*256
Lets get this confirmed.

Maybe I should add this here: To find syncofs you set throtid=1, throtiq=0.05. Now find a syncofs where the motor won't move at all, even at full throttle. Careful, the motor can spin up uncontrolled! I think disabling regen actually helps. Jacking up the wheels instead of neutral gear to be able to use the cars brake certainly helps.
Support R/D and forum on Patreon: https://patreon.com/openinverter - Subscribe on odysee: https://odysee.com/@openinverter:9
D@F
Posts: 59
Joined: Mon Dec 24, 2018 1:12 pm
Has thanked: 1 time

Re: Nissan Leaf Resolver offsets

Post by D@F »

do you have a photo of them, i will check mine this evening.
D@F
Posts: 59
Joined: Mon Dec 24, 2018 1:12 pm
Has thanked: 1 time

Re: Nissan Leaf Resolver offsets

Post by D@F »

2158F4C8-3D8D-4DF2-BE3B-D8CC7AF3EC83.jpeg
Is it that?
User avatar
johu
Site Admin
Posts: 5684
Joined: Thu Nov 08, 2018 10:52 pm
Location: Kassel/Germany
Has thanked: 153 times
Been thanked: 960 times
Contact:

Re: Nissan Leaf Resolver offsets

Post by johu »

Yes, so 8100650056 it seems?
Support R/D and forum on Patreon: https://patreon.com/openinverter - Subscribe on odysee: https://odysee.com/@openinverter:9
D@F
Posts: 59
Joined: Mon Dec 24, 2018 1:12 pm
Has thanked: 1 time

Re: Nissan Leaf Resolver offsets

Post by D@F »

81 or 84 i have to confirm tomorow morning
D@F
Posts: 59
Joined: Mon Dec 24, 2018 1:12 pm
Has thanked: 1 time

Re: Nissan Leaf Resolver offsets

Post by D@F »

I Check it and is 84.
884026CF-6EAC-416C-B6FE-886D5641D674.jpeg
User avatar
Jack Bauer
Posts: 3563
Joined: Wed Dec 12, 2018 5:24 pm
Location: Ireland
Has thanked: 1 time
Been thanked: 87 times
Contact:

Re: Nissan Leaf Resolver offsets

Post by Jack Bauer »

Here is mine. Gen 1 leaf.
Attachments
2019-04-13 14.04.23.jpg
I'm going to need a hacksaw
User avatar
dima
Posts: 157
Joined: Sun Dec 09, 2018 9:35 pm
Location: Canada

Re: Nissan Leaf Resolver offsets

Post by dima »

Maybe the rotor "wiggly" cuts with 3 error offsets?
Some heavy math reading. https://patentimages.storage.googleapis ... 030532.pdf

Resolver SinglSyn TS2208? https://www.tamagawa-seiki.com/products ... glsyn.html
Chip AU6805? https://www.tamagawa-seiki.com/products ... coder.html ...the 3 ERRCD are suspicious (Manual)

Image
nailgg
Posts: 119
Joined: Sat Dec 22, 2018 8:40 pm

Re: Nissan Leaf Resolver offsets

Post by nailgg »

Mine: 7F 00 36 00 5D
Attachments
photo_2019-04-17_15-36-53.jpg
arber333
Posts: 3241
Joined: Mon Dec 24, 2018 1:37 pm
Location: Slovenia
Has thanked: 74 times
Been thanked: 223 times
Contact:

Re: Nissan Leaf Resolver offsets

Post by arber333 »

I have a motor Gen1 EM61 with offset code
8E00000000
Attachments
IMG_20190420_173053.jpg
nailgg
Posts: 119
Joined: Sat Dec 22, 2018 8:40 pm

Re: Nissan Leaf Resolver offsets

Post by nailgg »

While looking at the Ebay link @Kevin Sharpe posted in the "auctions of interests" topic, found this: 800055005D

With this one, 3 out of 5 non-Gen1 motors have 5D in the last portion.

Here: https://www.ebay.co.uk/itm/MOTOR-ASSY-T ... 2997840962
purplespark
Posts: 52
Joined: Fri Feb 15, 2019 10:22 am
Location: United Kingdom

Re: Nissan Leaf Resolver offsets

Post by purplespark »

A bit late but here's mine ,gen2 ,

84 00 7D 00 5F
zippy500
Posts: 181
Joined: Fri Jan 04, 2019 8:42 am
Location: United Kingdom
Has thanked: 29 times
Been thanked: 3 times

Re: Nissan Leaf Resolver offsets

Post by zippy500 »

I have a faulty inverter, its just not possible then just to get anyone just to fit then,

Does anyone know how to reprogram the offset on a different inverter ?
User avatar
celeron55
Posts: 774
Joined: Thu Jul 04, 2019 3:04 pm
Location: Finland
Has thanked: 27 times
Been thanked: 110 times
Contact:

Re: Nissan Leaf Resolver offsets

Post by celeron55 »

I've dumped the eeprom in my gen2 inverter, and the resolver offsets were there, so desoldering the eeprom and writing them there is a possibility. Not sure about checksums.

Here's the eeprom dump: https://gist.github.com/celeron55/e052f ... 2838cb1235

The value found in there is 78 0073 0058.
User avatar
johu
Site Admin
Posts: 5684
Joined: Thu Nov 08, 2018 10:52 pm
Location: Kassel/Germany
Has thanked: 153 times
Been thanked: 960 times
Contact:

Re: Nissan Leaf Resolver offsets

Post by johu »

Nice work!
So once I have the FOC software done you could find the syncofs value and we can match it against what is printed on the motor. I basically set iq=0 and looked for the offset where the motor wouldn't move
Support R/D and forum on Patreon: https://patreon.com/openinverter - Subscribe on odysee: https://odysee.com/@openinverter:9
User avatar
Cookie6000
Posts: 246
Joined: Wed May 08, 2019 9:27 am
Location: Wicklow, IRL
Has thanked: 12 times
Been thanked: 32 times
Contact:

Re: Nissan Leaf Resolver offsets

Post by Cookie6000 »

My recent purchase is from a Gen1 EM61 - offset code
9400000000
20190719_211527.jpg
Home of the #Audi8e - https://twitter.com/FiachraCooke
User avatar
mcgousha
Posts: 28
Joined: Mon Mar 11, 2019 4:20 pm
Location: Surrey, UK
Contact:

Re: Nissan Leaf Resolver offsets

Post by mcgousha »

My Gen 2 EM57 from a 2014 Leaf:

80 00 44 00 4A
This seemed like a great idea at the time
https://www.youtube.com/channel/UCca95a ... 33wJBAMe5g
doobedoobedo
Posts: 260
Joined: Sat Jan 12, 2019 12:39 am
Location: UK

Re: Nissan Leaf Resolver offsets

Post by doobedoobedo »

8500070057
User avatar
johu
Site Admin
Posts: 5684
Joined: Thu Nov 08, 2018 10:52 pm
Location: Kassel/Germany
Has thanked: 153 times
Been thanked: 960 times
Contact:

Re: Nissan Leaf Resolver offsets

Post by johu »

many numbers now. Since I've pretty much tuned syncofs for my motor others can start doing so. Maybe add the numbers to their original post in bold so I can see it. Or we might just transfer it to a wiki page.
I can say for sure that syncofs 1000 +- 500 seemed the point for my motor were it would not spin on ID current. 1000 means 1000*360/65536=5.5°. If we assume 360° is 256 in Nissans world then syncofs_256=1000*256/65536 = 0x4. If we further assume that they phase shift their calibration by 180° for some reason then 0x2 would be perfect for my motor since 0x2 + 0x80 = 0x82.
In this case to convert the first digit to an openinverter-syncofs you would calculate syncofs = ((digit + 0x80) mod 256)*256
Lets get this confirmed.
Support R/D and forum on Patreon: https://patreon.com/openinverter - Subscribe on odysee: https://odysee.com/@openinverter:9
doobedoobedo
Posts: 260
Joined: Sat Jan 12, 2019 12:39 am
Location: UK

Re: Nissan Leaf Resolver offsets

Post by doobedoobedo »

I may be being dim, but I'm trying to work out what you mean.

Working your example:
syncofs = ((digit + 0x80) mod 256)*256

1000 = ((0x84 + 0x80) mod 256) * 256 --> actually 1024

where does 0x84 come from? Your example nissan code (first post) starts 0x82.
User avatar
dima
Posts: 157
Joined: Sun Dec 09, 2018 9:35 pm
Location: Canada

Re: Nissan Leaf Resolver offsets

Post by dima »

I there a missing *2 in formula?

javascript code would look like this:

Code: Select all

var a = ((0x82 + 0x80) * 2 % 256) * 256;
a = Math.round(a/1000)*1000;
var b = a*360/65536;
b = Math.round(b*10)/10;
console.log(a + " @ " + b + "°");
doobedoobedo
Posts: 260
Joined: Sat Jan 12, 2019 12:39 am
Location: UK

Re: Nissan Leaf Resolver offsets

Post by doobedoobedo »

OK so I've just done my syncofs: 500

The plate on the motor says 8500070057 which using Dima's formula would give me a syncofs of 2560 - motor spins fine with this setting (60V no load), but it's obviously not correct.
PoloLbricolo
Posts: 78
Joined: Wed Apr 10, 2019 2:32 pm
Location: France
Been thanked: 1 time

Re: Nissan Leaf Resolver offsets

Post by PoloLbricolo »

My gen2 leaf motor says 86000D 0057
I don't really understand the formula to calculate the offset.
To do the experimental method, how do you set throtid=1, throtiq=0.05 from the web interface ?

Paul
User avatar
johu
Site Admin
Posts: 5684
Joined: Thu Nov 08, 2018 10:52 pm
Location: Kassel/Germany
Has thanked: 153 times
Been thanked: 960 times
Contact:

Re: Nissan Leaf Resolver offsets

Post by johu »

Hm maybe the formula can be simplified. If v is the first value, so v=0x86 in your case
then syncofs = (v - 0x80) * 256
So (0x86 - 0x80) = 6
syncofs = 6 * 256 = 1536

But as this is speculative, experimental is better. With the new software its also easier.
Find the parameter throdiq in web interface and type 0. Find throtid and set to -1 . Put car in first gear and change syncofs until you feel no more force.
Support R/D and forum on Patreon: https://patreon.com/openinverter - Subscribe on odysee: https://odysee.com/@openinverter:9
PoloLbricolo
Posts: 78
Joined: Wed Apr 10, 2019 2:32 pm
Location: France
Been thanked: 1 time

Re: Nissan Leaf Resolver offsets

Post by PoloLbricolo »

Thanks a lot !
I've done the experiment and between 600 and 1000 same behaviour, the car didn't move at all. i've put 768 (1536/2) and it works well.
Post Reply