Hyundai Venue Forum banner
1 - 4 of 4 Posts

·
Registered
2020 SE, 6 Speed Manual
Joined
·
98 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
·
98 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
·
98 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.
 
1 - 4 of 4 Posts
Top