Adminius / ESP32-ScanMyTesla

CAN to BlueTooth Adapter for ScanMyTesla on ESP32
GNU General Public License v3.0
25 stars 6 forks source link

Connection between ESP and CAN #2

Open Genesisfm opened 1 month ago

Genesisfm commented 1 month ago

Hello,

I have the follow 2 modules: Mini Kit Esp32 Module https://nl.aliexpress.com/item/1005007235340350.html?spm=a2g0o.order_list.order_list_main.11.103779d2DyVTS3&gatewayAdapt=glo2nld

Sn65hvd230 Vp230 Can Board https://nl.aliexpress.com/item/1005006438437964.html?spm=a2g0o.order_list.order_list_main.23.103779d2DyVTS3&gatewayAdapt=glo2nld

And my question is how do i have to connect TX and RX from the Sn65hvd230 to the Mini Kit Esp32? I tryed port 16 and 17 but that doesnt work :(

Thank you BR Robert

Adminius commented 1 month ago

Hey Robert, the modules should be ok. I'm using same in other projects.

But I'm not sure if the sketch still work in general. Can library und ESP IDF had a lot or rewrites. I have to try it by my self...

Genesisfm commented 1 month ago

Thank you for your fast reaction, to be shure i want to check my pinout: 4000f7bb33b4f3fa619e079742fda1535bab8ba9 I have to connect my Can interfact to I016 and I017?

Adminius commented 1 month ago

Yes, 16 and 17

Genesisfm commented 1 month ago

Ok i checked that and it doesn't work, i also removed the termination resistor of 120 ohm without any positive result :(

Genesisfm commented 1 month ago

I was wondering if you had managed to test it out yet? Perhaps it is possible to share the old libraries it works with?

Adminius commented 1 month ago

Hey Robert, I tested it today and it still works. can_common 0.3.0 ESP32_CAN 0.2.3 esp32 Core 2.0.16

I will try to update to the newest versions and try it again. My idea was to get rid of extra libs, because now esp32 core provides very good api (that is also now used in collin80's libs) But it means whole rewrite :/

What exactly is not working?

I tried with this modules and it doesn't work: https://www.aliexpress.com/item/1005006209071522.html But it works fine with this: https://www.aliexpress.com/item/1005006408102971.html

Attached is binary that should work. ESP32-ScanMyTesla.ino.esp32.zip

Genesisfm commented 1 month ago

Hi, I ordered an other can module i think there is something wrong with it. I was able to make a bluetooth connection but a got a time out on the canbus 😑 Thank you very much.

Genesisfm commented 1 month ago

Hi another question, which esp32 module are you using? Thx

Genesisfm commented 3 weeks ago

Hi, I tried another CAN bus module but stil the same problem, what is the issue: When i connect with Scan my tesla i see: Creating bluetooth socket... Connecting to OBD2 adapter ESP-SMT... Initializing adapter ... Connecting to car... Using ST1110 command set Setting filters... --- the text above will erased--- Then nothing...

krasanen commented 1 week ago

This was working fine with SN65HVD230 + ESP32 DEVKIT V1. Maybe double check that RX/TX or CAN-H/CAN-L are not reversed?

Adminius commented 1 week ago

I'm using the same as pn the picture abow: Wemos D1 Mini ESP32

P.S. I rewrote the whole sketch to use native ESP32 TWAI driver wirhout external libraries and testing it since few days. I hope I can release it this week. Also some optimisations were implemented.

Genesisfm commented 1 week ago

I currently have several ESP32s, including the ESP32 DEVKIT V1. I still have to test this but I notice that the hardware does not all match (aliexpress...) Ps. i also not have the orginal Wemos D1 mini ESP but the D1 mini clone...

Adminius commented 1 week ago

all my HW is from Ali and all of it are kind of clones :)