vtl / volvo-cem-cracker

Volvo central electronic module pin cracker via OBD for P1, P2 and P3 platforms
GNU General Public License v3.0
106 stars 46 forks source link

Add the ability to use sub-microsecond latency units. #14

Closed cmolson closed 2 years ago

cmolson commented 2 years ago

I added the ability for the latency to be sub-microsecond. I found with a setting of 4 (0.25us) I was able to crack both 8690719 and 8690720 CEMs that I have here on my bench.

The default is still set to 1, so there should be no noticeable change. I think it is worth it for people with the P1 CEMs like mine to try this out.

cmolson commented 2 years ago

After further investigation, the only part of the change that made this work was:

/ maximum time to collect our samples / limit = TSC + 2 1000 clockCyclesPerLatencyUnit();

Which ended up limiting the timeout in cem_unlock.

I will close this and we can come up with a more appropriate change.