PyOBD Gets Python3 Upgrades

One of the best things about open source software is that, instead of being lost to the ravages of time like older proprietary software, anyone can dust off an old open source program and bring it up to the modern era. PyOBD, a python tool for interfacing with the OBD system in modern vehicles, was in just such a state with its latest version still being written in Python 2 which hasn’t had support in over three years. [barracuda-fsh] rewrote the entire program for Python 3 and included a few other upgrades to it as well.

Key feature updates with this version besides being completely rewritten in Python 3 include enhanced support for OBD-II commands as well as automating the detection of the vehicle’s computer capabilities. This makes the program much more plug-and-play than it would have been in the past. PyOBD now also includes the python-OBD library for handling the actual communication with the vehicle, while PyOBD provides the GUI for configuring and visualizing the data given to it from the vehicle. An ELM327 adapter is required.

With options for Mac, Windows, or Linux, most users will be able to make use of this software package provided they have the necessary ELM327 adapter to connect to their vehicle. OBD is a great tool as passenger vehicles become increasingly computer-driven as well, but there are some concerns surrounding privacy and security in some of the latest and proposed versions of the standard.

19 thoughts on “PyOBD Gets Python3 Upgrades

    1. USB passthrough with WSL2 works, but is a bit of a hack (it uses USB/IP over the WSL’s virtual network interface – see In my experience this works fine for USB serial devices like the ELM327, though I haven’t tried those specifically.

      Also, if you’ve not tried it before, note that using the ELM327 to talk CAN is somewhat limited in general- it’s poorly supported in older (and knockoff) versions of the chip, it doesn’t support full duplex, and it can’t handle very high speeds (See IT works fine for the basic OBD2 CAN stuff it’s intended for, but it’s not as compelling these days when you can get a “real” USB-CAN adapter for less than $30

    1. While it could be used for that as most states require some sort of inspection and one step of that inspection is usually to check the vehicle for any diagnostic codes (which would be done via the OBD port) many EV’s have a lot more software and can actually “call back” to the manufacturer via cellular connection for updates etc.which could easily be used to pull mileage and report it to the government. Either way you are going to end up having to report your mileage to the government whether the car does it for you or they make you record it as part of the registration process (most if not all jurisdictions ALREADY do this as part of the registration/inspection process).

  1. “One of the best things about open source software is that, instead of being lost to the ravages of time like older proprietary software, anyone can dust off an old open source program and bring it up to the modern era.”

    Yea by rewriting 90% of it

      1. I still give them props for doing it. Python 2->3 may be trivial for basic programs, but someone took the time to do it and share it. They get credit either way.

        It also depends on whether they’re just translating and patching, or if they’re bringing it up to modern techniques too. The latter can be more time consuming.

    1. Don’t know if used in this case, but there are tools to assist with automatic py2->3 migration. Easing such a task significantly, typically handling most of the boring and easy stuff but in most cases still requires some manual work too.

      Anyway, the point was that being F/OSS, we as a collective at least have the opportunity to such things. All it takes is one, or a few, individuals motivated enough.

  2. The pre-built Windows executable gets flagged with multiple warnings on VirusTotal, and while they all seem to be innocuous, I tried building the library on Windows but experienced several errors with wxpython. Anyone have success?

    1. Well, okay I got it to run but it fails to connect to the onboard OBD. I see it spitting out the connect attempts, but no response from the vehicle. The other popular OBD software site states their software doesn’t support Chevy vehicles. Perhaps that’s my problem as I’ve used this OBD interface with other (no longer available) vehicles.

      1. early chevy vehicles even with a OBD 2 style connector use ALDL signals so you might need a very early cable style, later ones used full OBD , check which pins in the OBd connector are used. what chevy is btw ? a geo tracker ? lmao

  3. Cool program, it looks like an easy way to get started with ODB-II, thank you for sharing!

    > Currently it only displays live data – no recording and replay is possible. NOTE: The program only displays the engine data, not airbags, ABS and body control systems. Even if your adapter supports that, you will need a more specialized program for that.

    If you have more sophisticated requirements, it seems like Wireshark has the ability to stream and record data in real-time: is a ~$70 adapter which shows up as a serial port.

    Alternatively, with USB port seems to support several open source software packages (there are clones of Canable 2.0 Pro available for ~$17 on AliExpress, but hopefully the official version will come back in stock soon. You also need to add a ~$5 16-pin ODB-II connector):

    – Cangaroo (Windows, Linux): Send/receive standard and FD frames, decode messages from DBC files

    – SocketCAN (Linux) Native Linux support using slcand (can record and pass into Wireshark)

    – python-can (Windows, Linux, Mac) Easily interface with the CAN bus using your CANable and Python scripts

    You can also use SigRok to visualize the CAN frames:

    Disclaimer: I have no affiliation and have not used either of these, just posting them as possible options.

  4. The most highly-recommended (on the git) interface is the OBDPro USB Scantool, because the firmware can be easily upgraded. The problem is, it seems to be impossible to order the device as the company’s checkout function doesn’t work and they don’t respond to emails. Maybe they went out of business but didn’t shut down the website? Has anyone managed to acquire one of those things?

    Anyway, here is my (unusual) application for the OBD reader: I am designing a custom dashcam for my car, using a GoPro Bones (a stripped-down GoPro camera that has a wired power input instead of built-in battery, and features a trigger connection for controlling the camera). Dashcams normally record at selectable time intervals (and a stock GoPro can be used this way), but I want one that records at selectable *distance* intervals (perhaps you can picture what the difference would be in the resulting timelapse recording. No long pauses at traffic lights, for example). So, my plan is to connect a Raspberry Pi running PyOBD to the camera and the car’s OBD port. The Pi will read the car’s speed and calculate the distance traveled in real time (since there is, I think, no odometer output on OBD). It will then trigger the camera to record a frame at the distance interval I specify, and the GoPro software can stitch these together into a timelapse video. I think the result will be unique and pretty darn cool.

Leave a Reply

Please be kind and respectful to help make the comments section excellent. (Comment Policy)

This site uses Akismet to reduce spam. Learn how your comment data is processed.