Put ESP32 on Tesla LDU and SDU board

Create a thread for each item that needs working on by the community
Post Reply
User avatar
johu
Site Admin
Posts: 4318
Joined: Thu Nov 08, 2018 10:52 pm
Location: Kassel/Germany
Has thanked: 35 times
Been thanked: 203 times
Contact:

Put ESP32 on Tesla LDU and SDU board

Post by johu »

I lately did a version of the Nissan Leaf adapter board with the ESP32-WROOM module placed by JLCPCB. This should get rid of the pesky issues that the pluggable ESP8266 module has.

Now I'd like to do the same to he two Tesla boards but I don't have and don't want to learn the PCB design software that they were done in.

If anyone feels like helping out, speak up. I'll link to/attach the needed design files here in the coming days.

https://github.com/jsphuebner/Tesla-Fro ... /master/V7
https://github.com/jsphuebner/Tesla-Dri ... /master/V5
Support R/D and forum on Patreon: https://patreon.com/openinverter - Subscribe on odysee: https://odysee.com/@openinverter:9
User avatar
catphish
Posts: 696
Joined: Fri Oct 08, 2021 11:02 pm
Location: Dorset, UK
Has thanked: 16 times
Been thanked: 39 times

Re: Put ESP32 on Tesla LDU and SDU board

Post by catphish »

Since it's not Kicad I'm afraid I can't be much help, but I'd like to nag instead.

If anyone updates the SDU board, please consider addressing this at the same time! https://github.com/damienmaguire/Tesla- ... t/issues/7
arber333
Posts: 2721
Joined: Mon Dec 24, 2018 1:37 pm
Location: Slovenia
Has thanked: 25 times
Been thanked: 49 times
Contact:

Re: Put ESP32 on Tesla LDU and SDU board

Post by arber333 »

johu wrote: Wed Nov 09, 2022 11:14 pm I lately did a version of the Nissan Leaf adapter board with the ESP32-WROOM module placed by JLCPCB. This should get rid of the pesky issues that the pluggable ESP8266 module has.

Now I'd like to do the same to he two Tesla boards but I don't have and don't want to learn the PCB design software that they were done in.

If anyone feels like helping out, speak up. I'll link to/attach the needed design files here in the coming days.

https://github.com/jsphuebner/Tesla-Fro ... /master/V7
https://github.com/jsphuebner/Tesla-Dri ... /master/V5
Hm... i have a design in ESP32 done for my VCU/BMS board. I made it in design spark.
I made design for 38 pin version. Pinout can be found here: https://www.studiopieters.nl/esp32-pinout/
Do you want to change Tesla board or make an interface for ESP32? What kind of interface do you need?
Which pins would you want to use?
royhen99
Posts: 36
Joined: Sun Feb 20, 2022 4:23 am
Location: N. Wiltshire. UK
Has thanked: 4 times
Been thanked: 10 times

Re: Put ESP32 on Tesla LDU and SDU board

Post by royhen99 »

I am willing to have a go as long as it's only a few hours work. I have not use DesignSpark before but it seems fairly straight forward to use.
I have loaded one of the designs and have the footprint for ESP-WROOM loaded. Picture bellow as proof!
I am a electronics engineer although not working at the moment. I have a lot of schematic experience but most PCB layout was supervising someone else.
I have just completed a simple STM32 board and sent for manufacture so now I have a bit of free time until the boards arrive

Tesla_FDU_V7_2.png
Tesla_FDU_V7_2.png (7.94 KiB) Viewed 715 times
arber333
Posts: 2721
Joined: Mon Dec 24, 2018 1:37 pm
Location: Slovenia
Has thanked: 25 times
Been thanked: 49 times
Contact:

Re: Put ESP32 on Tesla LDU and SDU board

Post by arber333 »

There are some limitations in using just bare ESP32 foot. Namely power draw.
See excerpt from design guide:
It should be noted that the sudden increase in current draw, when ESP32 is in transmission mode, may cause a
power rail collapse. Therefore, it is highly recommended to add another 10 µF capacitor to the power trace, which
can work in conjunction with the 0.1 µF capacitor. LC filter circuit needs to be added near VDD3P3 pins so as to
suppress high-frequency harmonics. The inductor’s rated current is preferably 500 mA and above. Refer to Figure
6 and place the appropriate decoupling capacitor near the other analog power pins.
You could try just adding just minimal TTL serial circuit, but from my experience when transmitting the thing can draw quite a bit of power.
image.png
image.png (11.08 KiB) Viewed 704 times
Full guide can be found here:
https://www.espressif.com/sites/default ... nes_en.pdf
User avatar
johu
Site Admin
Posts: 4318
Joined: Thu Nov 08, 2018 10:52 pm
Location: Kassel/Germany
Has thanked: 35 times
Been thanked: 203 times
Contact:

Re: Put ESP32 on Tesla LDU and SDU board

Post by johu »

royhen99 wrote: Fri Nov 11, 2022 2:34 am I am willing to have a go as long as it's only a few hours work. I have not use DesignSpark before but it seems fairly straight forward to use.
I have loaded one of the designs and have the footprint for ESP-WROOM loaded. Picture bellow as proof!
I am a electronics engineer although not working at the moment. I have a lot of schematic experience but most PCB layout was supervising someone else.
I have just completed a simple STM32 board and sent for manufacture so now I have a bit of free time until the boards arrive
Great, thanks for speaking up. It took me about an hour to do it with FreePcb:
grafik.png
grafik.png (7.29 KiB) Viewed 696 times
I omitted the extra filtering as it has a dedicated LDO but on the Tesla board I'd prefer the same like on V3 mainboard: https://github.com/jsphuebner/inverter- ... rdv3.4.pdf (10 uH, 500mA inductor plus 10uF cap).
I have routed GPIO0 to a pin header next to a GND pin, so for programming I just put a jumper on there and a serial cable with 5V output. So it's GPIO0, GND, GND, 5V, RX, TX . RX/TX as seen from the STM32 processor!
arber333 wrote: Fri Nov 11, 2022 6:00 am There are some limitations in using just bare ESP32 foot. Namely power draw.
Yes, even the ESP8266 has that issue.
catphish wrote: Thu Nov 10, 2022 6:47 pm Since it's not Kicad I'm afraid I can't be much help, but I'd like to nag instead.

If anyone updates the SDU board, please consider addressing this at the same time! https://github.com/damienmaguire/Tesla- ... t/issues/7
Ah yes good shout. royhen, could you?

Please pick any item from the shop for some compensation. Instead I can also send you the modified boards once manufactured.
Support R/D and forum on Patreon: https://patreon.com/openinverter - Subscribe on odysee: https://odysee.com/@openinverter:9
royhen99
Posts: 36
Joined: Sun Feb 20, 2022 4:23 am
Location: N. Wiltshire. UK
Has thanked: 4 times
Been thanked: 10 times

Re: Put ESP32 on Tesla LDU and SDU board

Post by royhen99 »

Both are done. The LDU was a bit tight but I managed to squeeze it in. Not sure how well these work mounted like this, but I cleared the planes under the antenna which should help. Also added 10k resistor arrays on PWM and clock output driver. Not sure if they are needed on the clk. What file name/version should I used for the update files? I can produce gerber and other output files, and pdf/png for schematic and layout if needed for checking. DesignSpark is fairly horrible so you made a good decision not to use it.
User avatar
johu
Site Admin
Posts: 4318
Joined: Thu Nov 08, 2018 10:52 pm
Location: Kassel/Germany
Has thanked: 35 times
Been thanked: 203 times
Contact:

Re: Put ESP32 on Tesla LDU and SDU board

Post by johu »

Wow, are you serious :) that was quick!
Just name them V6 and V8, respectively.
No pull down needed on the clock line. Just attach the files (design, gerber, pdf) here if that's fine for you.
Support R/D and forum on Patreon: https://patreon.com/openinverter - Subscribe on odysee: https://odysee.com/@openinverter:9
royhen99
Posts: 36
Joined: Sun Feb 20, 2022 4:23 am
Location: N. Wiltshire. UK
Has thanked: 4 times
Been thanked: 10 times

Re: Put ESP32 on Tesla LDU and SDU board

Post by royhen99 »

Ok, i'll fix the clock lines. The other thing I was not sure about was the enable pin on the esp32. I think you have just connected it to 3.3V on your deisgn but have read it should have a c-r so that it is enabled after the power supply has stabilised.
User avatar
johu
Site Admin
Posts: 4318
Joined: Thu Nov 08, 2018 10:52 pm
Location: Kassel/Germany
Has thanked: 35 times
Been thanked: 203 times
Contact:

Re: Put ESP32 on Tesla LDU and SDU board

Post by johu »

So far it works well with enable tied to 3v3. In doubt follow the appnote though
Support R/D and forum on Patreon: https://patreon.com/openinverter - Subscribe on odysee: https://odysee.com/@openinverter:9
royhen99
Posts: 36
Joined: Sun Feb 20, 2022 4:23 am
Location: N. Wiltshire. UK
Has thanked: 4 times
Been thanked: 10 times

Re: Put ESP32 on Tesla LDU and SDU board

Post by royhen99 »

Johannes can you confirm the part number for ESP module ( ESP32-WROOM-32E-N4, C701341 has the highest stock level ). I am updating the BOMs, which is a manual process, and while checking the data sheet for the ESP32 I noticed that the footprint I am using is not quite correct.
User avatar
johu
Site Admin
Posts: 4318
Joined: Thu Nov 08, 2018 10:52 pm
Location: Kassel/Germany
Has thanked: 35 times
Been thanked: 203 times
Contact:

Re: Put ESP32 on Tesla LDU and SDU board

Post by johu »

I use this one: C82899. Only two requirements were PCB antenna and solderable in economy process (not standard process)
Support R/D and forum on Patreon: https://patreon.com/openinverter - Subscribe on odysee: https://odysee.com/@openinverter:9
royhen99
Posts: 36
Joined: Sun Feb 20, 2022 4:23 am
Location: N. Wiltshire. UK
Has thanked: 4 times
Been thanked: 10 times

Re: Put ESP32 on Tesla LDU and SDU board

Post by royhen99 »

Ok I will put that in the BOM but as it is not recommended for new designs they may run out of stock.
User avatar
rstevens81
Posts: 215
Joined: Sun Dec 22, 2019 10:36 am
Location: Bristol, UK
Been thanked: 2 times

Re: Put ESP32 on Tesla LDU and SDU board

Post by rstevens81 »

i would make sure that you have a large cap on the 3.3v rail (as well as ones very close to the chip) as the power spike when the wi-fi is enabled, caused me a great del of pain on some of my projects as its caused reboot loops! in had to bodge on some big caps rather than the smd ones.
i typically just go over kill now and put 470uF (through hole or smd) caps on the 12v,5v&3.3v lines, the esp32 dev board reference design is good for inspiration as well. personally i would just put a esp32 dev board footprint on there as you can buy them for sometimes less than you can source the parts for from jlc, also the genuine expressive ones aren't that expensive in the grand scheme4 of things.

for ref my typical psu arrangement i have been using with the esp32 (dev boards)
Image
Attachments
psu-bom.png
psu.png
Rule 1 of EV Club is don't buy a rust bucket....
Which rule does everyone forget 🤪
royhen99
Posts: 36
Joined: Sun Feb 20, 2022 4:23 am
Location: N. Wiltshire. UK
Has thanked: 4 times
Been thanked: 10 times

Re: Put ESP32 on Tesla LDU and SDU board

Post by royhen99 »

Files attached. I hope they are OK, I can change anything if necessary. The placement and rotation data files are not very good but no worse than the previous versions.
Attachments
Tesla_FDU_V8.zip
(411.95 KiB) Downloaded 10 times
Tesla_V6.zip
(449.29 KiB) Downloaded 13 times
User avatar
johu
Site Admin
Posts: 4318
Joined: Thu Nov 08, 2018 10:52 pm
Location: Kassel/Germany
Has thanked: 35 times
Been thanked: 203 times
Contact:

Re: Put ESP32 on Tesla LDU and SDU board

Post by johu »

Awesome, thanks, will check it out later.
Support R/D and forum on Patreon: https://patreon.com/openinverter - Subscribe on odysee: https://odysee.com/@openinverter:9
royhen99
Posts: 36
Joined: Sun Feb 20, 2022 4:23 am
Location: N. Wiltshire. UK
Has thanked: 4 times
Been thanked: 10 times

Re: Put ESP32 on Tesla LDU and SDU board

Post by royhen99 »

Here are the PDF files of the schematics. I forgot to add them earlier.
Attachments
Tesla_V6 - Schematic.pdf
(695.61 KiB) Downloaded 19 times
Tesla_FDU_V8 - Schematic.pdf
(652.55 KiB) Downloaded 14 times
User avatar
johu
Site Admin
Posts: 4318
Joined: Thu Nov 08, 2018 10:52 pm
Location: Kassel/Germany
Has thanked: 35 times
Been thanked: 203 times
Contact:

Re: Put ESP32 on Tesla LDU and SDU board

Post by johu »

Just ordered 5 of each kind. Lets see how they come out :)

Thanks very much for your work, will send quick PM also.
Support R/D and forum on Patreon: https://patreon.com/openinverter - Subscribe on odysee: https://odysee.com/@openinverter:9
User avatar
catphish
Posts: 696
Joined: Fri Oct 08, 2021 11:02 pm
Location: Dorset, UK
Has thanked: 16 times
Been thanked: 39 times

Re: Put ESP32 on Tesla LDU and SDU board

Post by catphish »

royhen99 wrote: Mon Nov 14, 2022 2:23 pm Here are the PDF files of the schematics. I forgot to add them earlier.
Thank you for this! The new pulldowns make me very happy!
User avatar
johu
Site Admin
Posts: 4318
Joined: Thu Nov 08, 2018 10:52 pm
Location: Kassel/Germany
Has thanked: 35 times
Been thanked: 203 times
Contact:

Re: Put ESP32 on Tesla LDU and SDU board

Post by johu »

An enormous truck pulled up here this morning and delivered

Update: programmed fine and works :)
Attachments
IMG_20221216_121920.jpg
Support R/D and forum on Patreon: https://patreon.com/openinverter - Subscribe on odysee: https://odysee.com/@openinverter:9
User avatar
catphish
Posts: 696
Joined: Fri Oct 08, 2021 11:02 pm
Location: Dorset, UK
Has thanked: 16 times
Been thanked: 39 times

Re: Put ESP32 on Tesla LDU and SDU board

Post by catphish »

This is absolutely beautiful. Thank you mr royhen99!

Bonus points for putting a +5v supply for ESP32 programming with a USB UART cable!
Post Reply