Login Register

Vida CEM swapping

A mid-size luxury crossover SUV, the Volvo XC90 made its debut in 2002 at the Detroit Motor Show. Recognized for its safety, practicality, and comfort, the XC90 is a popular vehicle around the world. The XC90 proved to be very popular, and very good for Volvo's sales numbers, since its introduction in model year 2003 (North America). P2 platform.
Post Reply
ghettob
Posts: 11
Joined: 12 January 2026
Year and Model: 2011
Location: Finland
Has thanked: 1 time

Re: Vida CEM swapping

Post by ghettob »

vtl wrote: 12 Jan 2026, 15:00
ghettob wrote: 12 Jan 2026, 03:20 hi.

I've encountered a massive obstacle with the teensy build.

I've managed to get the car to programming mode, but the teensy keeps bootlooping causing the car to go in and out of programming mode thus being unable to crack the pin.

Any advice?
Copy your terminal output, paste on gist.github.com, share a link here.

ghettob
Posts: 11
Joined: 12 January 2026
Year and Model: 2011
Location: Finland
Has thanked: 1 time

Post by ghettob »

I reuploaded the p3 ino to the teensy and plugged the module to the car. Serial monitor shows this.


I then checked the upload output, which had red lines.

vtl
Posts: 4723
Joined: 16 August 2012
Year and Model: 2005 XC70
Location: Boston
Has thanked: 114 times
Been thanked: 603 times

Post by vtl »

It is making progress, look for "hash collision"

dikidera
Posts: 1304
Joined: 15 August 2022
Year and Model: S60 2005
Location: Galaxy far far away
Has thanked: 67 times
Been thanked: 175 times

Post by dikidera »

crasbe wrote: 12 Jan 2026, 14:48
dikidera wrote: 02 Jan 2026, 19:38 The ETM was the module that helped me crack CAN signal configuration, understanding how the CAN ids were calculated in the entire P2 Volvo lineup. Really good learning experience.
Would you mind sharing some of your insights?
Damien Maguire (known for converting BMWs and lately also Volvos to Electric Vehicles) and myself have been working on reverse engineering the CAN messages on the P2 series, but since we have different generations of cars (he has 2003, I have 2002), it's twice the amount of work without knowing the system behind it.
Edit: Here is the repository with the start of DBC files and some annotated logs: https://github.com/damienmaguire/Volvo- ... ngineering

From what I found out is that the P2 generation used the "Volcano" software to generate the CAN bus IDs and timing. There seems to be some structure in the IDs but I could never really pinpoint it. There always was "oh, this looks like it could be it" and then there's an outlier that broke the structure...
It is actually quite simple. It is the physical representation of the CAN module's memory layout.In other words, the ID is the serialized data in the registers of whatever MCU.Sometimes depending on the MCU, the ID is encoded with/without the RTR/IDE bit.

There is no one solution to decode them all, each MCU has a different CAN layout, so encoding of IDs will be different everywhere.

Here is a python script, that given a HW part number, will extract all diagnostic parameters with names and units(if applicable) from VIDA. It was written by AI yes. May contain bugs.

In the meantime I have started reverse engineering TF80SC. It has been most illuminating, we can see a different architecture compared to AW55 mediated by an improved compiler, data is now passed in structures, pointers, pointers to pointers.

We have several important structures, 4 identical structures related to commands, and 4 identical structures for what is likely shift process.
Attachments
dump_ecu_diagnostics.zip
(7.5 KiB) Downloaded 4 times

radziuC30  
Posts: 12
Joined: 4 January 2026
Year and Model: C30
Location: Polska
Has thanked: 2 times

Post by radziuC30 »

ghettob wrote: 13 Jan 2026, 02:27
vtl wrote: 12 Jan 2026, 15:00
ghettob wrote: 12 Jan 2026, 03:20 hi.

I've encountered a massive obstacle with the teensy build.

I've managed to get the car to programming mode, but the teensy keeps bootlooping causing the car to go in and out of programming mode thus being unable to crack the pin.

Any advice?
Copy your terminal output, paste on gist.github.com, share a link here.
Hello, I have the same problem, how can I solve it?

ghettob
Posts: 11
Joined: 12 January 2026
Year and Model: 2011
Location: Finland
Has thanked: 1 time

Post by ghettob »

It seems that it is not getting throught to start the process correctly, as it keeps waking the car from programming mode and putting it back in.

I had the cracker in the v60 for over 2 hours and it just kept looping in and out of programming mode.

vtl
Posts: 4723
Joined: 16 August 2012
Year and Model: 2005 XC70
Location: Boston
Has thanked: 114 times
Been thanked: 603 times

Post by vtl »

Grab everything you see on the teensy's console, end to end, paste to gist.github.com, drop a link here.

crasbe
Posts: 91
Joined: 8 December 2022
Year and Model: 02 S60, 98 V70 (EV)
Location: Germany
Has thanked: 31 times
Been thanked: 79 times

Post by crasbe »

dikidera wrote: 13 Jan 2026, 09:18
Here is a python script, that given a HW part number, will extract all diagnostic parameters with names and units(if applicable) from VIDA. It was written by AI yes. May contain bugs.
Thank you for the script! I played around with SQL requests and some Python parsing too, but your script is a lot nicer indeed.
My VIDA installation is stuck in an old 32-bit Windows 7 VM, so I'll probably have to get a newer Windows version to export the database to SQLite format and actually play around with the script.

What is still unclear to me: as far as I could tell the VIDA database only contains the diagnostic responses? At least the links that vtl posted were all based on diagnostic requests. What I'm interested in is the normal CAN bus communication, which does not include the diagnostic requests.
The goal would be to replace the ECM entirely and "pretend" to be the ECM, which would require replicating all the CAN messages it usually sends. Those aren't the diagnostic messages though.

Is that what the "status" category is for? Is that the data that's sent on the CAN buses during normal operation? (As I said, I haven't played around with your script yet, maybe the answer would be obvious from the output).
Check out my 3D Printed Parts for Volvo P2 and P80 on Printables :D

ghettob
Posts: 11
Joined: 12 January 2026
Year and Model: 2011
Location: Finland
Has thanked: 1 time

Post by ghettob »

vtl wrote: 13 Jan 2026, 15:34 Grab everything you see on the teensy's console, end to end, paste to gist.github.com, drop a link here.
I have the pin already for this car and it's not even close. Terminal output is from a 15min session

Master branch does not even start the programming mode, so all the gists are from p3 branch


vtl
Posts: 4723
Joined: 16 August 2012
Year and Model: 2005 XC70
Location: Boston
Has thanked: 114 times
Been thanked: 603 times

Post by vtl »

ghettob wrote: 14 Jan 2026, 04:13
vtl wrote: 13 Jan 2026, 15:34 Grab everything you see on the teensy's console, end to end, paste to gist.github.com, drop a link here.
I have the pin already for this car and it's not even close. Terminal output is from a 15min session

Master branch does not even start the programming mode, so all the gists are from p3 branch
It is making progress. P3 CEM falls off the programming mode when punched hard, that's why it awakes and gets down again. The only way it stays in programming mode is if message rate is greatly reduced, to about what DiCE can do.

p3 code is not integrated into master, yes. I was thinking of integrating sirloin's one_pass and p3 branches (and now cem_b, too), but testing the code on at least 4 CEMs would kill me.

Post Reply
  • Similar Topics
    Replies
    Views
    Last post