That's good news... I hope this makes things more financially stable for you
Re: Tesla Model 3 Rear Drive Unit Hacking
Posted: Mon Jul 27, 2020 7:46 am
by Jack Bauer
Now in production at JLCPCB.
Re: Tesla Model 3 Rear Drive Unit Hacking
Posted: Tue Jul 28, 2020 2:58 pm
by Jack Bauer
Re: Tesla Model 3 Rear Drive Unit Hacking
Posted: Wed Jul 29, 2020 11:19 pm
by station240
I should be able to help you with programming that particular C2000 micro.
Been programming the 379D version which is just the 377D with some minor changes TI made that didn't alter the code or pin out.
First you need to trace what GPIO72 and GPIO84 are wired to, as these set the boot mode.
It's possible JTAG has been disabled, in order to upload firmware over CAN, hence the need to find the boot mode select pins..
Re: Tesla Model 3 Rear Drive Unit Hacking
Posted: Fri Jul 31, 2020 3:33 am
by JaniK
Nice post Station240 great things.
Re: Tesla Model 3 Rear Drive Unit Hacking
Posted: Fri Jul 31, 2020 8:44 am
by Jack Bauer
GPIO72 (pin 139) goes to an led that flashes at about 10hz on power application.
GPIO84 (pin 154) goes to another led that flashes alternativly with the other. One red one green.
Re: Tesla Model 3 Rear Drive Unit Hacking
Posted: Fri Jul 31, 2020 9:02 am
by Jack Bauer
Just to be clear here while I am happy to explore the blank the TI device and port over the Openinverter system idea there are a few caveats:
1-Reading through the datasheet for the part, I am concerned about the code security module. I would bet my shiny new Keysight scope that Elon will be using that to prevent access to the memories. As to if it would stop the device being erased and reprogrammed with new code is uncertain.
2-the only option I will participate in is the porting of the openinverter. No instaspin or other nonsense.
3-My main focus is the modboard. I will (for as long as I have the drive units) be available to test TI device software options developed by the community.
Ah GPIO72 and GPIO84 are tied to 3.3V via the LEDs then.
I was worried they wouldn't be attached to anything at all, given the size of the pins that would be an issue.
1. Yeah I worry about the various software locks that could be fitted also, but given the complete lack of information we have to try and see.
In theory it could be reprogrammed over CAN but I suspect there are encryption keys for that.
2. Instaspin isn't an option, TI didn't feel like porting it to this micro.
It's a pain to use anyway, took me 2 days just to get it to compile on a micro it is supported on.
3. Fair enough, it's a lot of work just figuring out the pin out of the device.
In other news in honor of the recent success at SpaceX I got me a LaunchPad:)
Re: Tesla Model 3 Rear Drive Unit Hacking
Posted: Mon Aug 03, 2020 10:49 am
by johu
Sounds interesting Due to lack of time I can't be of any assistance in porting the software to C2000. Quick and dirty solution would probably be porting the relevant parts of libopencm3 to C2000, I suppose.
Really cool solution would be to create an openinverter specific HAL that bundles all peripheral access. But again, I don't have time for that right now.
Re: Tesla Model 3 Rear Drive Unit Hacking
Posted: Mon Aug 03, 2020 11:26 am
by Jack Bauer
That's why we have the modboard:)
Re: Tesla Model 3 Rear Drive Unit Hacking
Posted: Mon Aug 03, 2020 2:12 pm
by Jack Bauer
Just arrived:)
Re: Tesla Model 3 Rear Drive Unit Hacking
Posted: Thu Aug 06, 2020 4:48 pm
by MX5EV
I purchased this Launchpad I'd definitely be willing to help as well. Though I don't have a ton of experience programming TI parts. I'm going to try and figure out how to blinking the LEDs mentioned.
Hopefully, once we end up with these motors overflowing at junkyards the price will come down.
Re: Tesla Model 3 Rear Drive Unit Hacking
Posted: Tue Aug 25, 2020 7:33 pm
by station240
One downside of that TI Launchpad board is not all the signals are available.
There is a very tiny connector on the underside with some extra signals, it's cell phone connector small, and TI never did release that addon board to break it out.
Oh and only CANB is connected to a transceiver, CANA needs an extra transceiver chip added (think I'd had bad luck getting that to work)
To be honest we probably need a custom made TMS320F28379D board, for development as Drive Unit PCBs are kinda expensive and come with a heavy lump attached.
I have my own custom TI board for a different processor, however it's just a block of blank PCBs and components till I get everything I need to assemble one. It does have Isolated CAN and JTAG over USB, which I could re-use.
Re: Tesla Model 3 Rear Drive Unit Hacking
Posted: Sat Sep 05, 2020 12:37 pm
by JaniK
Have you found anything in the resolver signaling "sawtooth" or other parts in inverter that would prevent running the M3RDU in reverse?
Re: Tesla Model 3 Rear Drive Unit Hacking
Posted: Sat Sep 05, 2020 1:27 pm
by Jack Bauer
Nope. And with the electric oil pump it can go full bore in reverse without and mechanical mods. Now I just need to make some time to fit and test the new modboard....
Re: Tesla Model 3 Rear Drive Unit Hacking
Posted: Sat Sep 05, 2020 1:47 pm
by JaniK
Cool. Thanks for fast answer.
Re: Tesla Model 3 Rear Drive Unit Hacking
Posted: Tue Sep 29, 2020 1:15 pm
by Jack Bauer
Finally back at the M3 rear du. Time to swap out the old V1 modboard for the V2 and see if we can run closed loop with the inverter back on the drive unit:)
Re: Tesla Model 3 Rear Drive Unit Hacking
Posted: Tue Sep 29, 2020 1:19 pm
by Jack Bauer
Also since I've been away seems this guy has had some major success
Re: Tesla Model 3 Rear Drive Unit Hacking
Posted: Wed Sep 30, 2020 1:57 pm
by Jack Bauer
Good news is the V2 modboard resolver circuit is working perfectly. We are now driving the original Tesla amp and reading back via their filter. BAd news is it seems my current sensor signs are flipped so no foc tuning today.