-
Notifications
You must be signed in to change notification settings - Fork 9.2k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
All "Supported Cars" need to move to fingerprinting 2.0 #1238
Comments
Do you want to try spending some time on fingerprinting 2.0 through a giraffe? Then we can remove the code completely. |
To maintain this. Which I don't mind doing I would like to have access our at least get the sentry unrecognised car errors. The partial can messages that are captured give a good enough indication of the car type and possible missing signals |
I'm actively looking at this, because fingerprinting 1.0 doesn't really work for VW anyway. The current OP and Panda example UDS query code tries to work, and it elicits partial responses from a few addresses, but it doesn't fully succeed on anything at this time. This week I'll be snooping diagnostic comms from VCDS to see what the difference is. I have a hypothesis that some things are fine with UDS over ISO-TP but some things may need UDS over VW/Bosch CAN TP 1.6 or 2.0, because German Engineering™. To be verified. Once we get comms working to the steering rack, I'm confident we can use it for high quality fingerprinting. The racks are widely shared between vehicles, but can be queried for a four-digit number that identifies what assist characteristic map it was loaded with, which lets us discriminate between harder cases like the 16,384 VW Golf variants, etc. |
I have done some testing with FW fingerprinting on Subaru Crosstrek 2018 I used discovered ECU addresses from fw_versions.py scan and ran some ISO-TP queries using panda
ROM ID seems promising enough for testing FW fingerprinting, so I set up subaru-fw-fingerprinting branch and added experimental Subaru FW query and Impreza FW fingerprint for getting some feedback from other Subaru users |
Nice work! Looking forward to the PRs to add this :) Once we have the query shipped for a brand I can help going through all the logs on our side and fill the database with all the versions we got back. |
After a weekend of tinkering and traffic monitoring, with some ugly local hacks, I have
Example session with ABS/ESC that embodies all three issues above:
Partial examples for 0xF187 VEHICLE_MANUFACTURER_SPARE_PART_NUMBER:
VW are ridiculously good at parts-bin sharing on this platform, so a lot of the stuff won't identify in a way that helps you tell VW MQB vehicles apart. To make a very long story short, we want to ask the airbag module at 0x715 for data ID 0xF187.
From that we'll know enough about the car to assign a good-enough model name, wheelbase, mass, and PIF tune. Later on, if we really need to distinguish between Golf/Golf GTI/Golf R, or Audi A3/S3/RS3, we can mix in the ABS/ESC controller and probably get what we need. Last thought... Can I just skip all this and use the VIN? Seriously. I know you had some sort of problem with Honda/Toyota, but if the VIN starts with a Volkswagen factory WMI, I know for a fact that looking at the 7th and 8th digits gets me what I need, going back at least 25 years. It's about the same info I'd get from identifying the airbag module. We get the VIN for free on BP/C2, and I can even get it from a broadcast message on White/Grey Panda (community only, sure). I'll have to use VIN on the upcoming PQ35/PQ46/NMS port, because that stuff is too old to speak UDS. If you're amenable to "Fingerprinting 2.0" using VIN as an optional part of the mix, I'd much rather go that way for VW, and I'm willing to put in the work. |
What does the manufacturer (ODIS?) diagnostic software for VW use to check if a firmware update available applies to the connected vehicle? Part of the goal is to ensure the driving interface is correct (if there are differences the firmware is different/updated). |
ODIS will check the combination of the software/spare part number and the software version number. See page 7 here: https://static.nhtsa.gov/odi/tsbs/2018/MC-10149864-9999.pdf I don't have ODIS handy, but Ross-Tech VCDS will get identical data. Example:
In this case, either 0xF187 or 0xF188 returns "5Q0959655J" for the SW part number, and 0xF189 returns "0830" for the SW version. For this particular module, the reported 0xF188 SW and 0xF191 HW part numbers are the same, but that's definitely not always the case. Here's the same ECU list as my earlier comment, but queried with 0xF189 instead of 0xF187:
The only module that responded to UDS/OBD_VERSION_REQUEST was the engine ECU, everything else I needed these different queries for. If there's ever a functional change, something that would change the APIs or behaviors or other software contract matters, something that would make it suitable or unsuitable as a replacement part in a given car, the software part number will change. If it's a bugfix only, it's true that sometimes only the software version will change. I get what you're saying about verifying firmware versions for safety purposes, but we have to identify the car too, and I'm not convinced the SW version numbers alone will work for us. We could potentially collect both. Or, and this would probably be easier, I'd be very amenable to looking at both the VIN and UDS SW version numbers together. |
When I was looking into the WMI for Honda/Toyota it was a complete mess. None of the lists I found online was complete. Each one I found had ones the others didn't and then I saw ones in the incoming data that was in none of the lists. Then there is also Japan, where they don't use VIN but a "frame number" which on Toyota gets returned instead when you query VIN (https://en.wikipedia.org/wiki/Japanese_domestic_market#VIN). tl;dr. Is there a good source for WMI for VW that also works in Japan? Maybe this list is complete since it's maintained by the Germans? |
I just pulled up a VIN for a 2014 Golf GTI that was supposedly manufactured for the Japanese market and it looks quite traditional to me:
The only market I was even a little worried about was China, because my PartsLink24 subscription doesn't work on cars made over there. But since then I've gotten a 2017 Audi A3 from China and although I'd never seen that WMI before, it has a legitimate Audi A3 chassis code (8V) and otherwise looks like a standard VIN: VW's own ODIS software used on Volkswagen, Audi, SEAT, Škoda, Bentley and Lamborghini, as well as third-party diagnostic software like VCDS, all look at that 7th and 8th digit chassis code to decide what sort of car it is. I can't speak for all cars from all manufacturers, but I've been immersed in the international VW scene for many years before OP came into existence and I'm very confident we can make VINs work for us. Proposal: If you're concerned about VINs being variable format, like JDM frame numbers, let's treat them as such. Let each port optionally be able to "claim" a VIN (or pseudo-VIN) with a pure regex instead of worrying about WMIs per se. Here's a regex that would match everybody on the VW community port right now:
Naturally if no port claims the VIN, or a port doesn't have a claim regex, OP would keep doing fingerprinting as it was before, so we don't have to boil the ocean solving VINs for every supported port all at once, or ever. If a VIN claim regex gets a match, that port's CARs become the only candidates. We could have another optional per-CAR TL;DR: If we do that ^^ stuff, we can make VIN/VW work without breaking anybody else, then you get the benefit of being able to convert other ports when/if/as you wish, and FP 2.0 gets faster. |
Crappy pseudo-code logic for my proposed approach:
Hopefully that make sense. Even if not using it for full model recognition, there's an opportunity to further speed up the UDS query process, which is time sensitive for everyone, by gradually adding at least some VIN recognition to various ports, to focus the set of queries to run. |
Thanks for taking the time to look into this so deeply. It really sounds to me like the combination of the CAN address and software version (0xF189) for VW will work equivalent to Honda and Toyota firmware queries. Our experience has been that different vehicle models/trims with the same hardware have different software versions because the tuning specific to that vehicle is part in the firmware (requiring different software version numbers to properly identify when updates apply). This means that the combination of a set of CAN addrs and version strings does identify vehicles uniquely at the level OP requires. My suggestion is to stick with that unless we can point to situations where that approach is insufficient. |
I'm attaching a dump of every UDS data value the modules in my car are willing to report from the standardized manufacturer-independent UDS identifier list. all-type-all-address-query.txt We got lucky and found the EPS module will report a composite of its per-vehicle parameterization via There are several issues we still need to discuss:
As an example, note the 2019 Tiguan and 2019 Golf Alltrack in the attached file share exactly the same HW part num, SW part num, and SW version IDs.
TL;DR: I still strongly advocate for using the VIN, backed up by UDS validation of versions, as the most correct and future-proof solution. But, I'll file a discussion PR with something that works well-enough to kick the can down the road. |
Move fingerprinting 1.0, and subsequently white/grey panda, to "Community Maintained." Honda and Toyota are already good.
After these 4 are migrated, we can move all of fingerprinting 1.0 to community maintained.
The text was updated successfully, but these errors were encountered: