A DIY CanZE dongle, part 2. Geek talk.

We might have ironed out most issues with the DIY dongle. If there are people willing to build an ESP32 based dongle, especially if they own a Q90, R90, or R110 model, we would like to hear about it. Requirements would be:

  • Preferably drive one of the above models.
  • Willing and able to build a dongle, which requires ordering stuff through Aliexpress or ebay HK, basic soldering skills, and either some basic knowledge of using PlatformIO with Atom (or VSCode) with git, or the ability to upload binaries to an ESP32 development board from the command line.
  • Fool around with it, and be willing to cycle quickly though different updates of CanZE or the ESP32 code.

30 Comments on “A DIY CanZE dongle, part 2. Geek talk.

  1. I’m up for it but have a Q210, I have the soldering skills and can upload binaries to an ESP no issue. I might even prefer to build a PCB with a OBD Socket on it rather than have it on a mix of bits.

        • Well, we have quite a few reports that the standard “Chinese ELMs” work lousy or not at all on the 90 and 110 models, probably since the bus overwhelms the dongle’s resources. I fully expect this dongle to work without any problem and will ie populate the consumption screen without a blink. So if you could simply give it a spin or two, that would be great.

          And should you get bored by that, the new TPMS part worked fine on a Q90 I could check it on, but who knows……

  2. Great. Let me know when you have the parts, see previous post on this subject. By then I should have published the connections (just a few wires), and the code should be a bit more stable.

  3. I have the skills but -at the moment- I don’t have a Zoe. I already owned 2, and want to have the 3. soon…
    So I’m definitely interested.

  4. I am up for it, and trying… I connected the circuit thus morning and now everything is reset. While connected, the car display went gooble de good, “check airback”, “check brake” … when disconnected and off/on, the airback message disappeared but the wrench and brake message remains, oh oh…

    • So you probably messed up the connections on the ODB dongle. I had that once, shorting the CAN-bus, which resulted in some red lights, but everything went back to normal as soon as I disconnected the dongle again.

      My advice is to really check twice the connections to the car before connecting things!

  5. Thanks Bob, I’m using a different CAN transiver than recommended in you built. I left the terminator resistor 120 Ohm in. Normally all the setups I know, use it.
    I’d like to test my setup off car. Since I have more arduinos laying around and one more CAN chip, I’d like to emulate the car before going back. Can you please advice or better, do you even have a sketch to write to CAN and check if CanSee/CanZE receives that properly. I use a LoLin32 with OLED and a 8 LED Neopixel. Pictures and more details follow as soon as I am back home.

    CAN: 3pcs CJMCU-1051 TJA1051 High-speed Low Power CAN Transceiver For Arduino Module Board For Arduino from Electronics on banggood.com
    https://m.banggood.com/3pcs-CJMCU-1051-TJA1051-High-speed-Low-power-CAN-Transceiver-For-Arduino-p-1105611.html

    Wemos: Wemosยฎ ESP32 OLED Module For Arduino ESP32 OLED WiFi Modules + bluetooth Dual ESP-32 Module Board For Arduino from Electronics on banggood.com
    https://m.banggood.com/Wemos-ESP32-OLED-Module-For-Arduino-ESP32-OLED-WiFi-Modules-Bluetooth-Dual-ESP-32-p-1181297.html

  6. some really weird things happen after I took off the 120 ohm resistor and reconnected the circuit; “check brake”, “tire pressure”, “check SOS call”, “check ESC”, … it got so far, I had to disconnect the 12V battery (I could’n switch her off with the START button, remote key card didn’t work) to stop her being noisy (UFO sound) even I was stationary in the garage….
    At least, disconnecting the 12V battery and waiting for 30s helped. It now seems “normal” again and I can drive.
    This is all very strange….

    • This still sounds to me like shorting the CAN bus ๐Ÿ™
      Did you connect all the grounds together? The CAN-ground, the ESP32-ground as well as DC-DC converts grounds?

  7. Hi Bob, yes I tried with connected pins 4 and 5 and only using signal ground (I have not tried using vehicle ground only). More tries next weekend. I ordered an Konnwei 902, I give this a try (it should arrive tomorrow (Tuesday). Maybe I find some time late tomorrow, to check this out and get it connected to CanZE
    The other 2 ELM327 (which are working on my other cars) don’t work with Zoe and CanZE.

    The problems on the car display don’t happen right away, when the dongle is connected, but with the powering up of the program. I can see it by the LEDS going on/off with the black delay between. So I assume as soon as the
    CAN gets initialized and someting is sent, this something triggers it off. I will check the CanSee code to understand what causes the problem.
    I still want the DIY dongle to work, I’m not giving up. Maybe I use a different port of CAN first, before using the CanSee software. I just want to listen first – step by step.

    • A few comments if I may.

      – Use the development branch. We have not been good maintaining a stable master Branch. Should work on that.

      – I agree with Bob, you really need to meticulously quadruple-check the wiring. CANBus is very resilient so the fact that it works when the software is not running is not telling the whole story. 4 and 5 are tied together, no worries there. Be aware that CANBus is a polarized bus. If you mix CAN+ an CAN- on the bus it will not work.

      – you should NOT terminate the bus. Triple termination degrades bus reliability.

      – You mentioned you used another transceiver. Note that almost all transceivers are 5 volt supplied, but that the ESP32 is not 5V tolerant. I would strongly advice for the part list stated in our document, also because some transceivers need additional control pins configured. Yes I know it sounds a bit like an a**, but you are really on your own moving away from what we designed. Believe me, we had issues getting the entire CANbus chain up and running.

      – If you are fully confident about your wiring, and that includes using the same pins for CAN data between the transceiver chip and the ESP32, and we exclude possible faulty components, and you didn’t change anything in the firmware, the next culprit is the power supply. Measure the 3.3 Volt rail. Add a 100 uF capacitor and a 100 nF.

      A KONNWEI is a decent baseline but once you have run this one you will never use it again. The ESP is at least 10 times faster and CanZE becomes a real-time dashboard add-on.

  8. thanks Jeroen for your reply, just to let you know, the Konnwei works, but indeed, its slow.
    I also received some 36 pin ESP32 today, the 30 pin boards are still in the post. Once I got them, I will revert the SW to the unmodified version as you suggest. bI had to use different pins for the r-link CAN since my borad I us3d so far doesn’t have them available.

    The 120 Ohm resistor is off the CAN board. Is the SW working when only one CAN (vehicke CAN) is populated? Or is this causing resets etc?
    I noticed some resets on CAN initialisation on the bench (where no CAN was connected) to see what’s coming out of the serial monitoring. I incuded some debug messages, but never saw the print out after caninit. BT was initialised.

    I will take it step by step first get CAN between two ESPs to work, making sure the wiring is correct and the communication works. I’d wish to have more time ๐Ÿ˜‰

    I power the ESP as suggested in the documentation, using a 12V step down to 5V (I checked that). The CAN breakout has a regulatir on, so it should accept 5V, but I can check. CAN signal level with my MSDO.

    Hopefully, I find the time at the weekend…. off for now.

    • Hi Jeroen, Bob, now I’m in business :-). I have a system running to listen on the CAN and to transfer the data via BT to a terminal.
      here a snippet from my log (wrote my own quickly).

      MSG|DLC 0 1 2 3 4 5 6 7 ASCII
      —-+—————————————
      012E|8: c9 80 00 7f e0 ff ff 00 ‘……..’
      01F8|8: fa 04 ff ef fe 00 08 0d ‘……..’
      017A|8: ff ff ff aa 00 f0 31 a3 ‘……1.’
      017E|8: ff ff ff 00 ff 40 00 ff ‘…..@..’
      012E|8: c9 80 00 7f f0 ff ff 00 ‘……..’
      018A|6: ff f0 00 06 40 00 0d f2 ‘….@…’
      0212|6: fe 3d c0 68 00 00 0a 0d ‘.=.h….’
      0130|8: 00 08 6f fe 00 9f fe ed ‘..o…..’
      012E|8: c9 80 00 7f f0 ff ff 00 ‘……..’
      snip (only 5D7 for odo, speed)
      05D7|7: 00 c4 00 1b 39 90 c8 0a ‘….9…’
      05D7|7: 00 ae 00 1b 39 90 c2 77 ‘….9..w’
      05D7|7: 00 a5 00 1b 39 90 c8 93 ‘….9…’
      05D7|7: 00 c3 00 1b 39 90 e8 ec ‘….9…’
      05D7|7: 01 4f 00 1b 39 90 e0 3f ‘.O..9..?’
      05D7|7: 01 34 00 1b 39 90 e6 e0 ‘.4..9…’
      05D7|7: 01 0f 00 1b 39 90 dc 9d ‘….9…’
      05D7|7: 00 70 00 1b 39 90 f0 b9 ‘.p..9…’
      05D7|7: 00 00 00 1b 39 90 f8 34 ‘….9..4’
      05D7|7: 01 12 00 1b 39 90 d0 01 ‘….9…’
      05D7|7: 01 e1 00 1b 39 a0 ec ec ‘….9…’
      05D7|7: 05 15 00 1b 39 a0 d4 0c ‘….9…’
      05D7|7: 05 93 00 1b 39 a0 f8 9a ‘….9…’
      05D7|7: 06 75 00 1b 39 b0 c4 40 ‘.u..9..@’
      05D7|7: 06 9b 00 1b 39 c0 f6 86 ‘….9…’
      05D7|7: 06 02 00 1b 39 d0 ee ec ‘….9…’
      05D7|7: 03 b9 00 1b 39 e0 f2 a1 ‘….9…’
      05D7|7: 03 c0 00 1b 39 e0 ce 5d ‘….9..]’
      05D7|7: 04 09 00 1b 39 e0 cc 02 ‘….9…’
      05D7|7: 04 4e 00 1b 39 f0 d6 6c ‘.N..9..l’
      05D7|7: 03 eb 00 1b 39 f0 f8 74 ‘….9..t’
      05D7|7: 05 8e 00 1b 3a 00 d2 f7 ‘….:…’
      05D7|7: 06 54 00 1b 3a 10 c8 dc ‘.T..:…’
      05D7|7: 05 77 00 1b 3a 20 fa d7 ‘.w..:…’
      05D7|7: 03 d4 00 1b 3a 30 e4 1d ‘….:0..’
      05D7|7: 02 7a 00 1b 3a 30 ca 68 ‘.z..:0.h’
      05D7|7: 01 cc 00 1b 3a 30 ec 1e ‘….:0..’
      05D7|7: 01 8b 00 1b 3a 30 f6 15 ‘….:0..’
      05D7|7: 00 73 00 1b 3a 40 d6 c2 ‘.s..:@..’
      05D7|7: 00 82 00 1b 3a 40 e0 4e ‘….:@.N’
      05D7|7: 00 69 00 1b 3a 40 e8 ed ‘.i..:@..’
      05D7|7: 00 4f 00 1b 3a 40 ea 77 ‘.O..:@.w’
      05D7|7: 00 00 00 1b 3a 40 ec f3 ‘….:@..’
      05D7|7: 00 00 00 1b 3a 40 ee f1 ‘….:@..’

      Just now, I recompiled and loaded the CanSee and checked with the same terminal program. After I send a few commands, I got a reply of CanSee, started CanZE and – to my surprise, it no works.

  9. Hey there,
    I have a Q90, built a CanSee dongle and im willing to do some occassional testing.
    However, in the CanZE app i only see null values. If i request Diagnostic Trouble Codes i get:
    Query sent, but unexpected result recieved:[-E-BobDue.rtm.empty].
    I get the same values -E-BobDue.rtm.empty on the page of Test ELM327 dongle.

    I get the same values if i simply power the esp32 by USB.

    I triple checked solder connections to between the MCU, CAN trancievers and the OBD connector, those SHOULD be ok.
    (I did confuse the “CND?” pin next to the 5v pin as being ground (The headers are soldered on quite badly, hardly legible). So i did have my LEDs and gnd from power supply connected to that resulting in a boot-loop. So i might have damaged the MCU.)

    Small log from the ELM testing, DTC readout and all data pages:
    14:31:58.205 -> 5d7,
    14:31:58.239 -> 5d7,
    14:32:00.591 -> > com:Sending ISOTP SING request:743,0221800000000000
    14:32:16.251 -> 5d7,
    14:32:16.285 -> 5d7,
    14:32:20.197 -> > com:Sending ISOTP SING request:7e4,031902af00000000
    14:32:38.206 -> 5d7,
    14:32:38.239 -> 5d7,
    14:32:44.193 -> > com:Sending ISOTP SING request:7e4,0114000000000000
    14:32:46.572 -> > com:Sending ISOTP SING request:7e4,031902af00000000
    14:32:46.572 -> > com:Sending ISOTP SING request:7e4,0322200100000000
    14:32:47.056 -> > com:Sending ISOTP SING request:7e4,0322200200000000
    14:32:48.020 -> > com:Sending ISOTP SING request:7e4,0322200300000000
    14:32:49.021 -> > com:Sending ISOTP SING request:7e4,0322200500000000
    14:32:50.022 -> > com:Sending ISOTP SING request:7e4,0322200600000000
    14:32:51.021 -> > com:Sending ISOTP SING request:7e4,0322200b00000000
    14:32:52.024 -> > com:Sending ISOTP SING request:7e4,0322200c00000000
    14:32:53.065 -> 5d7,
    14:32:53.065 -> 5d7,
    14:33:03.716 -> 5d7,
    14:33:03.716 -> 5d7,

    • Maybe you could try leaving the CanSee dongle connected to the computer while it is also connected to the CAN bus and then send an “a” over the serial line to the dongle in order to retrieve all actual free frames it buffered.

    • Niels, looks like the CANbus connection is bad or + and – reversed, or the transceiver chip is broken. If you are close to NL-UT, we could have a peek.

      • Hey there,
        I went to a fellow ZOE driver in Groningen. Asked him to check my car’s bus with his ELM dongle. To my relief that seemed to work just fine. Then, when i was almost at home, i decided to try the CanSee dongle one more time. Plugged it in while parked in front of the driveway. To my surprise it seemed to work this time. Then i drove a few circles around the block to play with my new toy.

        I am not sure why it works now, i haven’t changed anything since. So it does not seem an issue anymore, possibly just a dodgy connection somewhere or i didnt plug it in all the way or something like that. However, i did see a comment somewhere about somebody trying an ELM dongle that did not work at first but suddenly worked later. Is there a particular way you have to plug it in? For example, while it is off? Or when the car is in standby mode? Or when “the engine” is on?

        Either way it works now. So if you guys want me to check out some stuff feel free to contact me (You should have my email. Just dont break my car please! ๐Ÿ˜‰ ). I just posted on the TPMS page as well since i could see pressures between 2550 and 2650 mbar. I am just not sure how to check the physical sensor IDs.
        Cheers!

        • Great it works. And no, there is no specific way. If we’re talking a KONWEI902 then it will boot in the same mode anyway. In my experience you are right though, they sometimes are pretty hard to push in, so indeed wiggle it down.

          To read to physical sensor IDs, just push the READ button on that screen and write them down. If you meant: how can I know which wheel really has which sensor, that is very hard to figure out indeed. You could lower the pressure in one wheel and drive it a bit, but that still would only show that we got the proper field for the pressure, not the IDs per se. Hmmmmm

          • I meant the second part. That is what you wanted to know, right? Lets continue this discussion on the appropriate page.