Live data from Hacker News

Hacking a VW Golf Power Steering ECU

blog.willemmelching.nl

151–160 of 174 posts

Re: Hacking a VW Golf Power Steering ECU

#151
post #116

>> Only try this on an actual car if you know what you’re doing. Even though only two very small patches are made to the model specific calibration values, making changes to your EPS might have unintended consequences. The author has no idea what he's doing, or more specifically what hazards might be lurking right under his nose. I worked in EPS for 6 years and it's all really cool stuff right up until you download c…

In this case the EPS already came stock with the functionality to request torque over CAN, that part of the code or the amount of torque was not touched. I agree it would not be a good idea to patch that functionality into an EPS that doesn't come with that from the factory.

One system I know of had to have software to reduce torque at the end stops or it could destroy FETs and shut down. If this system needed such protection, we might wonder if its included when taking external torque commands. I would if I wrote the code, but you never know when operating outside their expected use cases.

It's also much more benign to destroy components than to have actual bugs. And he's not changing software at the source level.

Re: Hacking a VW Golf Power Steering ECU

#152
post #2

This is probably one of the best write-ups I've seen around the basics of automotive control unit reverse engineering. More modern VW control units are the same in broad strokes - they use UDS on ISO-TP instead of KWP on TP2.0, but this is just evolution of the same fundamentals. And instead of the wacky SGO format inside of FRF update files, they use the ASAM MCD-2 D-ODX format to define flashing layers. Most Europe…

Agree. Absolutely awesome article except for this one little line:

> Ensure the patches to the calibration values are safe before using.

How would you do that? I've worked on both ends of steering on VW Bugs and Golfs (steering column fixes and tie rod replacements). You don't want to mess either of these up either, but the repairs are (a) well documented and (b) relatively easy to verify you did them correctly.

By contrast, I've seen software break catastrophically in the past from "harmless" updates like changing the number of commas in a version string. In this case it's not the kinda doesn't work problem but hitting an unexpected corner case on the freeway that would worry me.

Re: Hacking a VW Golf Power Steering ECU

#153

Earlier quoted context omitted.

ah yes, the casual arrogance of treating other people's lives as just 'rounding errors'. The only fortunate part, I suppose, is the kind of personality disorder that thinks/acts that way is likewise a rounding error.

>ah yes, the casual arrogance of treating other people's lives as just 'rounding errors'. >The only fortunate part, I suppose, is the kind of personality disorder that thinks/acts that way is likewise a rounding error. Oh take your hand wringing and shove it. How many man hours per capita per year are spent operating sketchy modified vehicles? How many man hours per capita per year are spent driving distracted, intox…

Before taking any anatomically adverse actions, I would need a better argument than whataboutism. The fact that something is statistically less likely than other bad things does not make it good.

Re: Hacking a VW Golf Power Steering ECU

#155
This is timely! I just made the decision to buy a car (either a 2021 or 2022 Subaru WRX, most likely), and have been curious about hacking the ECU, CAN bus, etc.

I’m aware that tuning is a thing, but it’s generally not my scene. What I really want is to do the work myself instead of going to a tuner or buying one of those Cobb kits.

Can HN recommend any resources and/or other technically-oriented communities?

Re: Hacking a VW Golf Power Steering ECU

#156
post #2

This is probably one of the best write-ups I've seen around the basics of automotive control unit reverse engineering. More modern VW control units are the same in broad strokes - they use UDS on ISO-TP instead of KWP on TP2.0, but this is just evolution of the same fundamentals. And instead of the wacky SGO format inside of FRF update files, they use the ASAM MCD-2 D-ODX format to define flashing layers. Most Europe…

Agree. Absolutely awesome article except for this one little line: > Ensure the patches to the calibration values are safe before using. How would you do that? I've worked on both ends of steering on VW Bugs and Golfs (steering column fixes and tie rod replacements). You don't want to mess either of these up either, but the repairs are (a) well documented and (b) relatively easy to verify you did them correctly. By c…

The calibration values were discovered through static analysis, so the code referencing those values can be followed to determine if unexpected side effects may be present. Obviously this process is imperfect, but it's not like blindly throwing bytes in and hoping something comes out.

I'm not a big advocate for comma/OpenPilot or EPS patching stuff in general, but I thought the patch in this example was fairly benign and reasonable as these things go - it was a data patch to the calibration area rather than a code patch, and the altered calibration contained relatively straightforward values with clear references and obvious effects.

Re: Hacking a VW Golf Power Steering ECU

#157

This is timely! I just made the decision to buy a car (either a 2021 or 2022 Subaru WRX, most likely), and have been curious about hacking the ECU, CAN bus, etc. I’m aware that tuning is a thing, but it’s generally not my scene. What I really want is to do the work myself instead of going to a tuner or buying one of those Cobb kits. Can HN recommend any resources and/or other technically-oriented communities?

NASIOC is the oldest WRX forum on the internet, you should find a lot of knowledgeable people there.

Re: Hacking a VW Golf Power Steering ECU

#158

Very few ECUs have CCP/XCP writing wide open. A lot of magic is in the area of defeating the cryptographic signature check on the device (hash of flashed contents).

This is true, although in a previous job I was surprised to be working on systems that could receive steering commands with unencrypted CAN messages.

As others have mentioned most USA manufacturers are moving to encrypted CAN buses now though.

Re: Hacking a VW Golf Power Steering ECU

#159

> Unfortunately, steering commands are not accepted after 6 minutes of continuous operation or below 50 km/h. is this for safety or does the duty cycle of this require some off-time for cooling or whatever?

I think the 6 minute timeout it could be a fallback mode in case the component sending the commands malfunctions and keeps spamming the same command in a loop over and over again.

Granted, if this happens while driving you're likely to have an accident anyway, but if you don't, then waiting 6 minutes would allow you to reclaim your steering for the rest of the journey.

Post reply on HN