SavvyCAN over ESPNow using an ESP32 CAN Gateway (Gadget #1)
HTML-код
- Опубликовано: 6 июн 2024
- Introducing my first CAN gadget.
10 PCBs for $5 USD at www.pcbway.com
Get the CAN Shield - store.mrdiy.ca/p/esp32-can-bu...
Products I used
=============
■ ESP32 (Amazon) - amzn.to/41Gmqdm
■ ESP32 (AliExpress) - s.click.aliexpress.com/e/_Ddz...
■ CAN Shield - store.mrdiy.ca/p/esp32-can-bu...
■ Wemos D1 Mini (Amazon) - geni.us/wemos1min
■ Wemos D1 Mini (AliExpress) - s.click.aliexpress.com/e/_Af36zD
Links
=====
■ Online Flasher - mrdiyca.gitlab.io/mrdiy-esp-o...
■ OpenDBC - github.com/commaai/opendbc
■ LAWICEL - www.canusb.com/files/can232_v...
■ SavvyCAN - www.savvycan.com
Source Code
==========
■ gitlab.com/MrDIYca/canabus/-/...
■ Entire project - gitlab.com/MrDIYca/canabus/-/...
Join this channel to get access to perks:
/ @mrdiyca
Follow on X: x.com/MrDIYca
Music by Sergio Prosvirini from Pixabay. The links above usually are affiliate links that support the channel (no additional cost for you).
00:00 Intro
00:35 First Gadget
00:46 SavvyCAN
01:31 Lawicel
02:07 Traffic
02:30 Sponsor
03:00 Setup
04:05 Gateway update
05:22 Flashing tool
05:35: Outro - Наука
Thanks for the information, I put both the gateway and this receiver together and it works perfectly, look forward to more gadgets.
This is amazing work! I can see a DIY gate opener in your future 😀
I have been thinking for a long time about making a small dashboard where I can see different car temperatures with an ESP32 connected to the OBD2 port, but my knowledge is very basic. I hope to learn from your next videos.
Congrats🎉 very nice job! I wonder if you eventually will make the canbus data to be transmitted over cell network. Would be great to unlock the car via homeassistant even if you parked out of your home garage, also allocate real fuel consumption per user is a nice feature (I do share a car with brothers and someone is never refilling, but cant asign blame). I guess 4-5g will unlock lots of possibilities
great work!
Love it! Awesome!
Might be time to get the CAN gateway I bought back out :)
Perfect!
I really need to figure out how to deal with Can bus on esp32... currently i'm using a feather can m4, but I want to be able to watch the obd2 can bus and the j1939 backbone at the same time... I think the esp32 can handle it and also drive a 40pin tft...
very cool
Can you tell if it is possible to send a ID and data to the car? This to mimic a device but change the value in order to trick the listening device. Problem might be that cars own device keeps sending on the same time.
in theory, yes. it is called man-in-the-middle attack
Hello, your work is awesome ! I've tried to do it, the "ESP32 reader" reads corretly the CAN messages and sends them over esp-now but SavvyCAN don't get any messages from the Wemos D1 mini. I was able to read the serial com from the esp8266 and it's writing things that always start with letter "t" so I think it's working. Do you have any idea of the problem ? On your video you configured a new connection but you did a cut, switching directly to the main software page where CAN message arrive. Is there extra step in the software SavvyCAN ?
It is probably the baud rate. Check my settings at 3:05 (LAWICEL, COM Port X, 115200, 500000)
@@MrDIYca I unfortunately did the same config as you, with the right COM port (on windows), the correct baud rate 115200 (the same as in the code) and the 500kbps (but not relevant like you said in the video). Do the CAN messages appear directly after configuring the new connection ? Because it's not directly showing messages in you video.
@@MrDIYca I succeeded to make it work using Linux instead and using an ESP32 as savvycan gateway ! thanks ChatGPT for converting code
Great work. Would be great if you could write code for ESP32 dev module to act as GADGET: SLCAN/LAWICEL.
The code is written for Arduino, so migrating it to ESP32 should be relatively straightforward
Why all the hassle? Savvy CAN doesn't work on the ESP32?
There's some variant in github to ESP32RET called wifican that allows using the ESP32-S3 to receive and transmit frames with Savvy CAN
Yes, it does beautifully. ESP32RET only works with SavvyCAN. The gateway I designed is meant to serve as a general bridge to many gadgets ( SavvyCAN is one of many). I explained it in a previous video - ruclips.net/video/gtVQeTRps7o/видео.html
Got a library issue as below during sketch compile. Please give me a pointer and help me out. "Arduino/libraries/esp32_can/src/esp32_can_builtin.h:43:25: fatal error: driver/twai.h: No such file or directory
compilation terminated." Thanks
It looks like your Arduino IDE is not configure with ESP32 boards ( or the ESP32 was not selected on compile )
A good read: randomnerdtutorials.com/getting-started-with-esp32
Thanks, after library updates, the code compiles now. Thanks
I'm just using a raspberry pi to convert all the can messages to mqtt and then I connect savvycan to the mqtt broker.
Yes, that is another great way to do it. For my project, I needed a way to communicate with my gadgets without a Wi-Fi stack/router and that is on instantly.
new car has gateway and i can not read the can datas. how can i read the datas
i want to control the door lock of 2022 model wv passat
and also why do we need extra can shield. esp32 has can protocols already?
@@mehmetaliaksoy5585 ESP32 has the logic part of CAN bus integrated but nothing of the necessary hardware. You can look for the TJA1051 module
can you test with realdash software please 😊
We need a group, want to get in touch with you ^^
feel free to post here
Hello, I'm getting some trouble implementing the SLCAN protocol. Any chance to get in touch with you via email? Any help will be really appreciated.
Sure, but can you post here? that way everyone can participate and benefit
@@MrDIYca In my serial terminal, my ESP32 (just for testing that I wrote the correct serial data with SLCAN format) already stream serial output data with this format "T15FF04030203040506070809[CR]" but the SavvyCAN not recognizing it as an incoming data. Can you help me with this?
@@MrDIYca And now I already have a serial output that get the same result with the LAWICEL Manual -> T0000010021133[CR] -> but still no output yet on the SavvyCAN
There's an initial handshake your serial port must manage before proceeding. I suggest reviewing the LAWICEL PDF linked in the description for more details.