Tesla Large Drive Unit Support Thread

Topics concerning the Tesla front and rear drive unit drop-in board
Locked
Maverick441
Posts: 11
Joined: Thu Apr 23, 2020 2:30 am
Location: Ventura, CA, USA

Re: Tesla Large Drive Unit Support Thread

Post by Maverick441 »

Need some help on my LDU bench test.

Setup:
wiring base on github.com. 12V power supply with 4A limit, 2S LG Chem @ 118V, BMW E46 Pedal, original Ampseal connector with encoder cable section in place and plug in. Cutoff switch between Battery + to contactor. UDCSW=0, UDCMIN= 0, UCDNOM = 100. Firmware =4.00 (a bit old, I bought the card last year but my other setup wasn't ready yet...).

Test:
set main switch on. Turn on 12V supply, ignition contactor closed, engage start signal, main contactor closed (at this time all contactor is closed). switch on Drive Forward signal, depress pedal and the motor turns very slowly with jerking motion (pedal has to press all the way down, motor not turning at 1/2 way).

Questions:
Firmware is old and needs update, Is the updates on site same for all motor's? LDU, SDU... I don't really see the motor/board type (sorry if I missed). do I only need the foc.bin and sin.bin files? and no .hex files? https://github.com/jsphuebner/stm32-sin ... ag/v5.12.R

For the encoder, I am assuming I retain the original encoder portion of the Ampseal connector is good, is this correct? mainly do I have to split out and give its own 5V power? current version of firmware doesn't have option to change "encmode".

How fast would I expect the LDU to spin with 118V? with pedal full pressed, it barely spins. is this an encoder problem? or is it a pedal signal / calibration problem?

thanks.
Isaac96
Posts: 656
Joined: Sat Oct 05, 2019 6:50 pm
Location: Northern California, USA
Been thanked: 1 time
Contact:

Re: Tesla Large Drive Unit Support Thread

Post by Isaac96 »

You need the sine.bin or sine.hex file (either one works). Not FOC.

Not sure about the encoder wiring, I'll let someone with LDU experience chime in.

118v should be enough to really get it going, so be careful.
For bench testing it would be safer to get some coolant in the inverter, its thermal mass is low and they have burned up on the bench before.

The jerking sounds to me like an encoder problem.
If you turn the motor by hand, can you see the 'speed' and 'turns' values changing?
If you plot 'angle' do you get a nice increasing graph? (It should go up to 360 and back to zero).
These can all show you if the board is reading your encoder correctly.
Maverick441
Posts: 11
Joined: Thu Apr 23, 2020 2:30 am
Location: Ventura, CA, USA

Re: Tesla Large Drive Unit Support Thread

Post by Maverick441 »

Isaac96 wrote: Mon Oct 18, 2021 1:34 am If you turn the motor by hand, can you see the 'speed' and 'turns' values changing?
If you plot 'angle' do you get a nice increasing graph? (It should go up to 360 and back to zero).
These can all show you if the board is reading your encoder correctly.
Isaac96, thanks for the overheat warning. My test setup is limited right now, I don't have room to insert the drive shaft to turn the motor, and my motor is missing one of the coolant intake coupling... :(

I plotted the angle and turn, if I am not mistaken that the "angle" is the angular position when the motor is turning, then I think there's something wrong. when I am NOT pressing, I logged values like a "step sine wave":
Image

Did not notice any meaningful change to angle when pedal is pressed.
Attachments
Angle (10-17-21).jpg
User avatar
johu
Site Admin
Posts: 5681
Joined: Thu Nov 08, 2018 10:52 pm
Location: Kassel/Germany
Has thanked: 153 times
Been thanked: 959 times
Contact:

Re: Tesla Large Drive Unit Support Thread

Post by johu »

What you're seeing is slip frequency. Set fslipmin=0 to get rid of it.
Support R/D and forum on Patreon: https://patreon.com/openinverter - Subscribe on odysee: https://odysee.com/@openinverter:9
P.S.Mangelsdorf
Posts: 753
Joined: Tue Sep 17, 2019 8:33 pm
Location: Raleigh, NC, USA
Has thanked: 89 times
Been thanked: 92 times

Re: Tesla Large Drive Unit Support Thread

Post by P.S.Mangelsdorf »

Maverick441 wrote: Mon Oct 18, 2021 1:24 am
For the encoder, I am assuming I retain the original encoder portion of the Ampseal connector is good, is this correct? mainly do I have to split out and give its own 5V power? current version of firmware doesn't have option to change "encmode".
If you have the original wiring harness from that LDU, you don't need to change encoder wiring. If the wiring harness is from a different LDU, in some rare cases you may have to flip A and B, but otherwise the original ampseal-to-encoder wiring is fine.
If at first you don't succeed, buy a bigger hammer.

1940 Chevrolet w/ Tesla LDU - "Shocking Chevy" - Completed 2023 Hot Rod Drag Week
Maverick441
Posts: 11
Joined: Thu Apr 23, 2020 2:30 am
Location: Ventura, CA, USA

Re: Tesla Large Drive Unit Support Thread

Post by Maverick441 »

Isaac96 wrote: Mon Oct 18, 2021 1:34 am You need the sine.bin or sine.hex file (either one works). Not FOC.
Well updating firmware was not successful. downloaded the latest firmware R5.11.R sine.bin and use the upload function on web interface. message indicate download complete, then status bar starts, but stuck at 57%:

Image

waited for a long time and no change in status, no reaction from other buttons. I have no choice but to reboot the inverter card. It reconnected but all the parameters and spot section has rotating wheel with no values.

Image

I attempt to upload again but it is the same for a few times. The contactor would click uncontrollably for a few second in some of the update attempts.

With the "upload complete" message, what is the meaning of the % status bar? what should be the typical update process like?
on the update section, there's also an option to "upload other files to update the web interface", am I missing this file for the new firmware?

Hope I didn't break my board...
User avatar
johu
Site Admin
Posts: 5681
Joined: Thu Nov 08, 2018 10:52 pm
Location: Kassel/Germany
Has thanked: 153 times
Been thanked: 959 times
Contact:

Re: Tesla Large Drive Unit Support Thread

Post by johu »

You didn't break it. Since contactors are clicking make sure there is no HV.
Right now there is no valid firmware so the board will reboot every 2s and *should* allow to upload another update.
As long as there is no valid firmware you will not see parameters, as they are downloaded from the STM32

Upload complete means the file has been transferred onto the ESP8266 module. The percentage then shows the transfer from the ESP module to STM32
Support R/D and forum on Patreon: https://patreon.com/openinverter - Subscribe on odysee: https://odysee.com/@openinverter:9
User avatar
Roadstercycle
Posts: 118
Joined: Mon Sep 23, 2019 10:28 pm
Location: California
Has thanked: 3 times
Been thanked: 2 times
Contact:

Re: Tesla Large Drive Unit Support Thread

Post by Roadstercycle »

Mowza wrote: Mon Sep 06, 2021 12:58 pm While that certainly makes sense the reason I chose 12v was because that is exactly what was used in this video:



and it seems to work just fine for an initial low speed test. I do not see any other power source in it and everything seems to be wired to the battery on the table.
Just to be clear, in the video or this frame of the video there is a red wire running down behind the 12 volt battery which runs to 2 Chrysler Pacifica batteries. Around 100 volts.
Maverick441
Posts: 11
Joined: Thu Apr 23, 2020 2:30 am
Location: Ventura, CA, USA

Re: Tesla Large Drive Unit Support Thread

Post by Maverick441 »

Finally got the firmware updated after a few attempt, works after I accidentally bump the voltage from 12.0V to 12.3V, which is closer to car battery voltage.
johu wrote: Mon Oct 18, 2021 8:01 am What you're seeing is slip frequency. Set fslipmin=0 to get rid of it.
the min value of my interface for fslipmin = 0.28...

Image

Also able to access encoder setting by this commend (from earlier post)
Image

Default setting for encoder is A/B, which is jerking and very slow. I am able to get the motor to run smoothly and fast with "encoder mode = single", opposed to what Damien suggested... need to figure out why.

Next, will calibrate the throttle paddle, only reacting when the paddle is press down close to half way.

Thanks for all the help and suggestion.
Isaac96
Posts: 656
Joined: Sat Oct 05, 2019 6:50 pm
Location: Northern California, USA
Been thanked: 1 time
Contact:

Re: Tesla Large Drive Unit Support Thread

Post by Isaac96 »

Okay, your encoder A/B might be switched.
Good to hear it's working otherwise!
User avatar
johu
Site Admin
Posts: 5681
Joined: Thu Nov 08, 2018 10:52 pm
Location: Kassel/Germany
Has thanked: 153 times
Been thanked: 959 times
Contact:

Re: Tesla Large Drive Unit Support Thread

Post by johu »

Maverick441 wrote: Fri Oct 22, 2021 2:21 am the min value of my interface for fslipmin = 0.28...
Oh, you're right. Hmm, put it to neutral then, that should disable slip.
Support R/D and forum on Patreon: https://patreon.com/openinverter - Subscribe on odysee: https://odysee.com/@openinverter:9
Maverick441
Posts: 11
Joined: Thu Apr 23, 2020 2:30 am
Location: Ventura, CA, USA

Re: Tesla Large Drive Unit Support Thread

Post by Maverick441 »

Image

I switch the pins for encoder A & B and reset the encmode to A/B. It works the same as previously with encmode = single. I will keep it this way.

However odd, I realized the motor is spinning opposite direction for both Forward and Reverse. I checked the wiring and pin on the Ampseal connector and it is correct. Would there be adverse effect to switch the F/R signal so the motor will run correctly?
jon volk
Posts: 572
Joined: Wed Apr 10, 2019 7:47 pm
Location: Connecticut
Been thanked: 2 times

Re: Tesla Large Drive Unit Support Thread

Post by jon volk »

F and R are swapped on the Tesla board. Its normal.
Formerly 92 E30 BMW Cabrio with Tesla power
Golf_mkIII_E
Posts: 32
Joined: Tue Apr 20, 2021 8:55 pm

Re: Tesla Large Drive Unit Support Thread

Post by Golf_mkIII_E »

Does anybody have any experience with tuning the parameters for braking at low speed? When I brake, before coming to a complete stop the regenerative braking ramps up extremely violently. I have set the brake ramp-up time to about 10 seconds, so I can take my foot of the brake pedal for a second before coming to a stop, to temporarily solve the problem. I also tried tweaking the "brkrampstr" parameter, but I haven't been able to solve the problem. The problem occurs when decelerating beneath 10-5kmh or something like that.

Another question; What do you think is an acceptable "fmax" value? I saw Jon Volk is using 650. Isn't that a little to much? My current topspeed is about 175-180kmh on GPS, but it would be well appreciated if 200kmh was reachable.
P.S.Mangelsdorf
Posts: 753
Joined: Tue Sep 17, 2019 8:33 pm
Location: Raleigh, NC, USA
Has thanked: 89 times
Been thanked: 92 times

Re: Tesla Large Drive Unit Support Thread

Post by P.S.Mangelsdorf »

You can adjust brkmax and brknompedal to change the total amount of regen braking, that reduced the braking violence problem I was having in initial test drives.
If at first you don't succeed, buy a bigger hammer.

1940 Chevrolet w/ Tesla LDU - "Shocking Chevy" - Completed 2023 Hot Rod Drag Week
Golf_mkIII_E
Posts: 32
Joined: Tue Apr 20, 2021 8:55 pm

Re: Tesla Large Drive Unit Support Thread

Post by Golf_mkIII_E »

The problem is that I would like to benefit from the regenerative braking at higher speeds, but I don't want it to behave violently at low speeds.

These are my current parameters:

{
"boost": 2300,
"fweak": 258,
"fweakstrt": 400,
"fconst": 450,
"udcnom": 360,
"fslipmin": 0.84,
"fslipmax": 3.06,
"fslipconstmax": 9,
"sincosofs": 2048,
"fmax": 540,
"dirchrpm": 100,
"dirmode": 1,
"ocurlim": 1400,
"udcgain": 7.46,
"potmin": 470,
"potmax": 4095,
"pot2min": 4095,
"pot2max": 4095,
"potmode": 0,
"throtramp": 5.84,
"throtramprpm": 20000,
"ampmin": 0.34,
"slipstart": 55,
"brknompedal": -35,
"regenramp": 0.09,
"brknom": 0,
"brkmax": -55,
"brkcruise": -30,
"brkrampstr": 10,
"brkout": -10,
"bmslimhigh": 100,
"bmslimlow": -20,
"udcmin": 0,
"udcmax": 426,
"idcmax": 5000,
"idcmin": -5000,
"idckp": 2,
"idcflt": 9,
"tmphsmax": 85,
"tmpmmax": 300,
"throtmax": 100,
"throtmin": -100,
"iacmax": 5000,
"ifltrise": 10,
"ifltfall": 0,
"chargemode": 0,
"chargecur": 0,
"chargekp": 80,
"chargeki": 10,
"chargeflt": 8,
"chargepwmin": 0,
"chargepwmax": 90,
"idlespeed": 250,
"idlethrotlim": 50,
"idlemode": 3,
"speedkp": 0.09,
"speedflt": 5,
"cruisemode": 0,
"udcsw": 290,
"udcswbuck": 540,
"tripmode": 0,
"bootprec": 0,
"pwmfunc": 0,
"pwmgain": 100,
"pwmofs": 0,
"canspeed": 1,
"canperiod": 0,
"nodeid": 1,
"fslipspnt": 0,
"ampnom": 0
}
P.S.Mangelsdorf
Posts: 753
Joined: Tue Sep 17, 2019 8:33 pm
Location: Raleigh, NC, USA
Has thanked: 89 times
Been thanked: 92 times

Re: Tesla Large Drive Unit Support Thread

Post by P.S.Mangelsdorf »

Your regenramp is below the minimum (yours is 0.09 and the parameter database says the minimum is 0.1) That may be causing an issue.

You could also try adjusting brkrampstr to change at what point regen torque is reduced.
If at first you don't succeed, buy a bigger hammer.

1940 Chevrolet w/ Tesla LDU - "Shocking Chevy" - Completed 2023 Hot Rod Drag Week
User avatar
johu
Site Admin
Posts: 5681
Joined: Thu Nov 08, 2018 10:52 pm
Location: Kassel/Germany
Has thanked: 153 times
Been thanked: 959 times
Contact:

Re: Tesla Large Drive Unit Support Thread

Post by johu »

Also try setting brkrampstr to 20 or even 30.
Support R/D and forum on Patreon: https://patreon.com/openinverter - Subscribe on odysee: https://odysee.com/@openinverter:9
rjmcdermott81
Posts: 107
Joined: Thu Dec 03, 2020 5:03 pm

Re: Tesla Large Drive Unit Support Thread

Post by rjmcdermott81 »

Question about temperatures in the LDU. I'm proceeding cautiously with my initial road tests to make sure my coolant setup is sufficient. Also, as an American I have to constantly convert C to F... I drove the car around the block ~20mph and the temperature for tmphs quickly ramps up. At it's peak I saw it go a little above 50C. In my searches it sounds like the Tesla has some protection features around 100C but just wanted to see if what I'm observing sounds normal to everyone else. tmpm moves much more slowly....

Cooling setup is a Davies Craig pump that does 30.38 gpm, but I have it going through the battery coolant plates first and then the LDU. My batteries during testing are ambient (~70F).

Thanks for the help!

Image

Image
User avatar
Boxster EV
Posts: 434
Joined: Fri Jul 26, 2019 9:32 pm
Location: UK
Has thanked: 35 times
Been thanked: 26 times

Re: Tesla Large Drive Unit Support Thread

Post by Boxster EV »

On my unit, presuming the temp readings were accurate, I think restriction kicked in at about 70c. So with 50 you’re okay.

Can you hear/feel coolant flowing through the pipework?
Porsche 986 powered by a Tesla large drive unit. Backwards. Build documented here and Instagram @tesla_porsche here.
rjmcdermott81
Posts: 107
Joined: Thu Dec 03, 2020 5:03 pm

Re: Tesla Large Drive Unit Support Thread

Post by rjmcdermott81 »

Thanks @Boxster EV. I definitely feel coolant flowing through the pipes. I'll do a longer test drive to see if the temperature keeps creeping up. My big concern is that the coolant plates have very narrow passageways which is probably choking the flow. I may end up with either two pumps (one pushing through the batteries and one through the inverter).

Thanks!
User avatar
Boxster EV
Posts: 434
Joined: Fri Jul 26, 2019 9:32 pm
Location: UK
Has thanked: 35 times
Been thanked: 26 times

Re: Tesla Large Drive Unit Support Thread

Post by Boxster EV »

rjmcdermott81 wrote: Sun Dec 05, 2021 7:19 pm Thanks @Boxster EV. I definitely feel coolant flowing through the pipes. I'll do a longer test drive to see if the temperature keeps creeping up. My big concern is that the coolant plates have very narrow passageways which is probably choking the flow. I may end up with either two pumps (one pushing through the batteries and one through the inverter).

Thanks!
I think as long as coolant is moving and you have a sufficient size rad then you’ll be fine with one pump if ambient temperatures aren’t extreme.
Porsche 986 powered by a Tesla large drive unit. Backwards. Build documented here and Instagram @tesla_porsche here.
User avatar
muehlpower
Posts: 570
Joined: Fri Oct 11, 2019 10:51 am
Location: Germany Fürstenfeldbruck
Has thanked: 12 times
Been thanked: 96 times

Re: Tesla Large Drive Unit Support Thread

Post by muehlpower »

rjmcdermott81 wrote: Sun Dec 05, 2021 7:19 pm Thanks @Boxster EV. I definitely feel coolant flowing through the pipes. I'll do a longer test drive to see if the temperature keeps creeping up. My big concern is that the coolant plates have very narrow passageways which is probably choking the flow. I may end up with either two pumps (one pushing through the batteries and one through the inverter).

Thanks!
Since the temperature level of the battery and motor is very different (40 ° C to 70 ° C), some use two separate cooling systems, each with a pump, controlled as required.
rjmcdermott81
Posts: 107
Joined: Thu Dec 03, 2020 5:03 pm

Re: Tesla Large Drive Unit Support Thread

Post by rjmcdermott81 »

A follow-up on my tmphs question for anyone who searches later with the same question/issue. I drove this morning for a longer period and the temperature continued to climb. It would jump rapidly when I gave it throttle and eventually built up to 70C with ~15 blocks of driving.

As a test I decided to take the batteries out of the loop tonight and it made a night and day difference. I did the same drive and the temperature never crossed 30C.

Long story short, don't narrow the cooling loop below 3/4". Good to go.
User avatar
johu
Site Admin
Posts: 5681
Joined: Thu Nov 08, 2018 10:52 pm
Location: Kassel/Germany
Has thanked: 153 times
Been thanked: 959 times
Contact:

Re: Tesla Large Drive Unit Support Thread

Post by johu »

Alright, valuable piece of info. I wonder if it can be conserved in the wiki somehow? Under batteries? Or some new "best practise" page?
Support R/D and forum on Patreon: https://patreon.com/openinverter - Subscribe on odysee: https://odysee.com/@openinverter:9
Locked