Hyundai Venue Forum banner
1 - 7 of 7 Posts

· Registered
2020 SE, 6 Speed Manual
Joined
·
213 Posts
Discussion Starter · #1 · (Edited)
Yes, it IS possible!

In a different thread about wheel upgrades, I talked about whether or not it would be possible to change the overall diameter of the wheels & tires while maintaining a relatively accurate speedometer. To recap, my 2020 Venue SE comes with 185/65R15 (24.5 inch total diameter), but SEL and Denim trims come with 205/55R17 (25.9 inch total diameter). This is not just an instance of increasing the amount of wheel while decreasing the amount of sidewall. It's almost an inch and half difference in overall diameter, which makes a noticeable difference in the amount of empty space in the wheel wells. Some may think that the speedometer is just calibrated somewhere in the middle of the two sizes, but that doesn't appear to be the case here. My speedometer is more or less dead-on accurate compared to GPS speed measurements, and there are different configurations of ECU for the Venue depending on wheel sizes. So it's a pretty safe bet that a different revolutions-per-km value is programmed into the car depending on the wheel size.

Based on info from the Hyundai shop manual and electrical diagrams, the speedometer info comes from the 4 wheel sensors, goes to the ESC system (ABS & traction control), and from there is sent over the CAN bus where the instrument cluster picks up the data and displays the speed.

Rectangle Slope Font Schematic Parallel

Font Parallel Number Symmetry Monochrome


Knowing that the speed data was traveling on an actual data network instead of just a wire making electrical pulses, I had kind of given up on swapping wheels. Then one day I stumbled across Canny Logic, a company that makes programmable CAN bus devices (https://cannylogic.com/).

I sent an email asking if it was possible to use one of their devices to intercept and rewrite CAN bus data. I got an email back from Konstantin (who has been very helpful in this entire process) saying that yes, it was possible. I would need their Canny Duo device, which has two CAN network interfaces on it.

After playing around with the device for a few weeks, I am happy to report that I have SUCCESSFULLY implemented this device as a speedometer ratio calibrator within my Venue's CAN bus.
 

· Registered
2020 SE, 6 Speed Manual
Joined
·
213 Posts
Discussion Starter · #2 · (Edited)
How I did it:

First, let's take a look at what we're trying to accomplish here. CAN bus is a specialized data network that allows all kind of components in your car to talk to each other. Your car's components are constantly talking, sending out all kinds of data across the network. At the same time, they're also listening for messages that are relevant to them. If a component has no use for a message, it just ignores it. The CAN network is terminated on each end by a 120 ohm resistor. There are several different CAN networks in our cars, but the one we're worried about for this purpose is "C-CAN" (chassis CAN).

If we look at the network diagrams from Hyundai, you can see that the instrument cluster is one of the endpoints of the C-CAN network.

Product Rectangle Slope Schematic Font


Rectangle Product Slope Font Line


So our goal here is to place the Canny device just before the cluster so that it intercepts the data. If the data contains vehicle speed information, it will adjust the value before sending it on to the cluster. If it doesn't, it will just forward it along the network unchanged.


Now that we know the big picture, let's get into the details. How do we tell the device what data to look for and how to modify it? Fortunately, some people who are much smarter than me have done some of that work. The comma.ai team makes an open-source product called openpilot, and in their github repo they have a bunch of dbc files that describe the CAN bus data for various makes and models including Hyundai: opendbc/hyundai_kia_generic.dbc at master · commaai/opendbc

CAN bus data is sent in chunks of hexadecimal data, which then must be converted to binary, and then the individual bits of binary have to be interpreted. I won't get into the technical details of how to extract and modify the speed data (although I'll be happy to answer any questions). But for our purposes, I'm looking at this section of the dbc file:

BO_ 902 WHL_SPD11: 8 ABS
SG_ WHL_SPD_FL : 0|[email protected]+ (0.03125,0.0) [0.0|511.96875] "km/h"
SG_ WHL_SPD_FR : 16|[email protected]+ (0.03125,0.0) [0.0|511.96875] "km/h"
SG_ WHL_SPD_RL : 32|[email protected]+ (0.03125,0.0) [0.0|511.96875] "km/h"
SG_ WHL_SPD_RR : 48|[email protected]+ (0.03125,0.0) [0.0|511.96875] "km/h"


Essentially, the speed of each wheel is represented by 14 bits. The value must be scaled by 0.03125 to get the value in km/h, and the speed represented can range from 0 to 511.96875.
So as an example: if the number 2560 came across the CAN bus, it would represent a speed of 80 km/h: 2560 x 0.03125 = 80.

The Canny products are programmed with a graphical interface, which makes it relatively easy to program. I put together a quick proof-of-concept that would just simply double the speed value, just to see if it could be done. I sent a CAN data with a speed of 10 mph to the cluster, and success! The speedometer read 20 mph!


It took a bit more work (and some very much appreciated help from Konstantin) to actually implement the multiplier that I wanted.
 

· Registered
2020 SE, 6 Speed Manual
Joined
·
213 Posts
Discussion Starter · #3 · (Edited)
Installation:

I mentioned before that this device would be installed just before the data gets to the cluster. I really didn't want to cut into my cluster wiring harness, so I searched around and found this: https://www.amazon.com/dp/B07FG7XTVF
It's actually a wiring harness for a Nissan Leaf, but it uses the same connectors as the Hyundai Venue instrument cluster. My intention was to use this as a pass-through for everything EXCEPT the C-CAN wires, which would be rerouted to the Canny. I had to move some of the pins around to match the pinout for Hyundai, and I was also able to remove a bunch that weren't needed.

Pins 32 and 33 are the ones being rerouted to the Canny:
Font Parallel Number Screenshot Slope


As a bonus, some of the wires for the Nissan harness were 2-to-1, which meant that I could use those wires on pins 37 and 29 to send power and ground to both the cluster and the Canny device.

Circuit component Electrical wiring Font Cable Hardware programmer


After putting the wire harness in between the existing connector and the cluster, I routed the power, ground, and C-CAN wires down to the fuse box just to make it easy to access the Canny device in the future. I also added some connectors to the ends of the wires so that it's easy to disconnect the Canny and plug the CAN bus wires back together to run "stock".

Automotive lighting Body jewelry Automotive design Font Headgear



With the Canny device plugged in:
Electrical wiring Cable Computer hardware Wire Electrical supply



I tested everything out this weekend, and everything seems to work exactly as I would expect. Speedometer reads the GPS speed + the programmed offset. I used some mile markers on the highway to see if the odometer and trip meter are also adjusted, and it looks like they are. Cruise control also works fine - Setting it at 80 mph results in a cruise speed of 80 mph at the cluster (in other words, the speed value that your speedo shows is the same one used for cruise control).

I'm very glad that I finally was able to figure out a way to switch out these tiny wheels and still keep my speedometer correct. Although now that winter is almost upon us, I will probably wait until spring to put the new shoes on my Venue.
 

· Registered
2020 SE, 6 Speed Manual
Joined
·
213 Posts
Discussion Starter · #5 ·
🚨 UPDATE 🚨
I wanted to come back and update this thread because I came up with a new method of altering the speedometer ratio. Two reasons I did this:

  1. The Canny device I mentioned earlier comes from Russia. With current world events, that means I would not be able to get a replacement in the foreseeable future (if necessary).​
  2. The Canny device also had an odd quirk where every once in a while (maybe around once a week) I would briefly have some warning lights on my instrument cluster illuminate for a few seconds, then go out. This wasn't an issue with the logic that I used to program it, because even when I set it to do nothing but forward the Can Bus data - without any alteration - it would still do this. Aside from the lights coming on for a few seconds, there were no other side effects. My guess was that there were maybe some isolated instances where the Canny device could not keep up with the amount of data being sent to it....although I couldn't be sure.​

I looked around at some of the other ready-made Can Bus devices, and eventually I figured out that I could probably put together an Arduino based device to do the same thing myself. After looking into the different Arduino dev boards available, I eventually settled on the Teensy 4.1, mainly because it already has 2 Can Bus chips built into it (actually it has 3, but I only need 2 for my purposes).
Circuit component Hardware programmer Passive circuit component Electronic component Computer hardware


There is also a Teensy 4.0 board that is about half the size and would work equally well as a Can gateway. I chose to use the 4.1 because it has a SD card slot, which I figured may be useful someday if I ever wanted to log the data.

Aside from the Teensy device, here are the other parts I used:
  • Two Waveshare SN65HVD230 Can Bus transceivers. I used these because they had the best ratings, and because they were the only ones that ran on 3.3v instead of 5v (The Teensy board uses 5v to power on, but the IO pins can only accept up to 3.3v).
  • 12v to 5v step-down so I can power the Teensy using the car's power.
  • 8 Pin SIP switch - I use this to control the settings of the Can Bus filtering.
  • 6 pin JST connector - 12v, ground, plus two sets of Can Bus High+Low.
  • A PCB to tie it all together
  • Odds & ends such as wire, solder, silicone tape, etc.

I won't get into the details of how I assembled it. You could solder these components together in any number of ways, especially if you used a different PCB. The exact arrangement and routing of everything isn't important....Only that you get it all correctly working together. That being said, my aim was to get everything in as small a package as possible so I could easily tuck it into my fuse box compartment. Here's what I came up with:

Front of the board: You can see the Teensy 4.1, the SIP switch on the right, and the JST connector at the bottom.
Passive circuit component Circuit component Hardware programmer Electronic component Computer hardware


Back of the board: Here you can see the two Can Bus transceivers, and the 12v to 5v step down. I put pieces of silicone tape under these components so they wouldn't create a short against the main PCB.
Circuit component Passive circuit component Hardware programmer Electronic component Font



For programming the Can Bus data manipulation I used the FlexCanT4 library.
I won't get into the details of how I programmed this device, although I will try to answer any questions that anyone has. You should have some experience in programming, and you definitely need to understand how to convert between binary, decimal, and hexadecimal. I work as a database administrator, and I haven't done any real programming since college over 20 years ago. But I am familiar with the concepts enough to be able to search for what I'm looking for and figure it out.

I wanted to find a nice small plastic enclosure for it, but never found anything suitable In the end I just covered the whole thing in heatshrink tubing.
Here's it is connected to the car:

Automotive exterior Gas Vehicle door Electronic device Machine


You can see that switches 1 through 6 add different percentages to the speedometer reading that is sent to the instrument cluster. In my case I have switches 1, 2, 3, and 5 turned on, which means the speed sent to the speedometer will be increased by 5.75%.

Switch 7 is enabled, which disables the upshift indicator "idiot light".
Switch 8 is enabled to use the upshift indicator location as an extra turn signal indicator as I described in this post.

Conclusion:
I have been running this setup in my car for the past 2-3 months without issue.
One cool thing about the Teensy is that you can set the CPU to run at different speeds, from 24MHz to 600MHz. I initially tried it at 24MHz, and it would sometimes generate the same cluster warning lights that I sometimes had with the Canny device. I bumped it up to the next speed (150MHz) and it has been running flawlessly, with absolutely no errors since then.
 

· Registered
Joined
·
2 Posts
Wow, that is amazing work. Thanks for sharing.

I just came across the Yellow Box speedometer recalibrator and it looks similar to your solution (are the electrical pulses the data?). Do you think Yellow Box would work for the Hyundai Venue?

Some say the average autoshop is able to change the "wheel diameter" or "rotation/mile" on the ECU (or wherever the values are stored) to calibrate the speedometer inexpensively. Is this far from true?
 

· Registered
2020 SE, 6 Speed Manual
Joined
·
213 Posts
Discussion Starter · #7 ·
Wow, that is amazing work. Thanks for sharing.

I just came across the Yellow Box speedometer recalibrator and it looks similar to your solution (are the electrical pulses the data?). Do you think Yellow Box would work for the Hyundai Venue?

Some say the average autoshop is able to change the "wheel diameter" or "rotation/mile" on the ECU (or wherever the values are stored) to calibrate the speedometer inexpensively. Is this far from true?

I don't think that Yellow Box would work w/ the Venue speedometer. The Yellow Box seems to be an adjustable Pulse-Width Modulator. It takes an input signal consisting of alternating on/off electrical signals, and sends them back out after applying an adjustment to them. When I was trying different things out, I found a device that looks pretty similar on Amazon. Long story short: It did change the way certain things controlled by the ECU reacted, but the speedometer was not affected. (Link to that post here)

The Venue speedometer is actually controlled by data it receives on the can bus network, which is not the same as electrical pulses. Actually I assume most modern cars work this way. You need something that can receive the data packets and rewrite them. It's like the difference between an foreign electrical adapter that simply converts 220v to 110v, compared to your home network router that serves as a bridge between your computer and the internet. The router is "smart" enough to be able to read the data packets and determine where they are supposed to go. The electrical adapter is more of a "dumb" device for lack of a better word.

I know some cars have different ways of changing settings like this in the ECU. VW/Audi cars seem to be pretty accommodating to this as long as you have the right tools. As far as I could find, there is no way to do this on Hyundai/Kia. In fact, there are different ECU part numbers for the Venue based on certain options - one of which is the wheel size. I even found a Hyundai service tech on Reddit and had a chat about this, and he said the only configuration they can do is setting the VIN on a new ECU. And even for the VIN, once it's been written it cannot be changed.

I did a lot of searching and reading about this stuff, so let me know if you have any other questions.
 
1 - 7 of 7 Posts
Top