# Coding Car Software 55.xx



## jimmy9980 (Nov 16, 2012)

I really don't think that it pulls metadata from pszdata. I would think the cafd its self has all the info in. 

I still think it's something with the token not working with newer versions or encryption changes.


----------



## jimmy9980 (Nov 16, 2012)

Aritaurus said:


> I think you may be right.
> 
> The fact that some people have been able to read their NCD files from 2.55 on 2.54 renamed tells us that it could be some sort of encryption.
> 
> My friend and I are going to try this method next week when he flashes his car to 2.55. We're going to read the ECU's to get the NCD files for HU_NBT, FEM_BODY then rename them to their 2.54 equivalents and edit them using 2.54. Once that's done, we'll load these files back into the cafd directory and code FDL using 2.55.


Ok sounds good let me know how it goes. I'm going to wait before I update to v55


----------



## shawnsheridan (Jan 10, 2009)

jimmy9980 said:


> I really don't think that it pulls metadata from pszdata. I would think the cafd its self has all the info in.
> 
> I still think it's something with the token not working with newer versions or encryption changes.


You are completely wrong. It has nothing to do with Encryption. The new Trimmed files when decrypted and parsed to xml have all the descriptive text removed from then. End of story. A simple comparison of the file sizes of the same CAFD file, Trimmed and Untrimmed, tells you the Trimmed files have data removed as they are a fraction of the size. If it were an Encryption issue, the file sizes would be nearly identical.


----------



## jimmy9980 (Nov 16, 2012)

shawnsheridan said:


> You are completely wrong. It has nothing to do with Encryption. The new Trimmed files when decrypted and parsed to xml have all the descriptive text removed from then. End of story. A simple comparison of the file sizes of the same CAFD file, Trimmed and Untrimmed, tells you the Trimmed files have data removed as they are a fraction of the size. If it were an Encryption issue, the file sizes would be nearly identical.


The part that I'm confused by is if you use a cafd file from 54.1 (Nbt cafd was used) I can read it. So what I did is dump that same readable file (Nbt cafd file ) into the caf folder on the v55 data I'm unable to read it. It looks like a trimmed file. All I did is move it from v54.1 folder to v55 folder. If I put it back there's no issue.

I was using token masters Ndc reader to do this. It's really strange it's almost as if it masks the data.


----------



## shawnsheridan (Jan 10, 2009)

jimmy9980 said:


> The part that I'm confused by is if you use a cafd file from 54.1 (Nbt cafd was used) I can read it. So what I did is dump that same readable file (Nbt cafd file ) into the caf folder on the v55 data I'm unable to read it. It looks like a trimmed file. All I did is move it from v54.1 folder to v55 folder. If I put it back there's no issue.
> 
> I was using token masters Ndc reader to do this. It's really strange it's almost as if it masks the data.


Sorry, but that is not possible. An Untrimmed CAFD from 54.1 placed in 55.0 CAFD folder, overwriting the one from 55.0 would not appear Trimmed, because it isn't trimmed.

You need to test it again. And if it does appear Trimmed to you, where are you seeing it as such? It would not be that way in the CAF-Viewer or FDL-Editor.

Now if it appears Trimmed viewing FP (Vehicle Profile) using the FA-Editor, that is because the FAFP File in 55.0 is Trimmed, not the CAFD file.


----------



## jimmy9980 (Nov 16, 2012)

This what I did

In C:\EsysData

I have both psdzdata 54.1 and 55

I leave one named as psdzdata for the one I will use and the other I put psdzdata55 at the end for v55

I open esys I go FDL Editor current using psdzdata 54.1 I can read my NBT file
CAFD_00000DED_003_013_025.ncd no issue can see all settings.

I close esys 
Now I switch over to psdzdata v55 
open Esys go to fdl editor same file as before in the C:\EsysData\CAF folder I open CAFD_00000DED_003_013_025.ncd again and I see dots for all items.

Something in v55 must be enabled in the Psdzdata that masked the settings. I guess what I'm trying to figure out is why would the same file be viewed in v54.1 but not in v55. Its very odd.



shawnsheridan said:


> Sorry, but that is not possible. An Untrimmed CAFD from 54.1 placed in 55.0 CAFD folder, overwriting the one from 55.0 would not appear Trimmed, because it isn't trimmed.
> 
> You need to test it again. And if it does appear Trimmed to you, where are you seeing it as such? It would not be that way in the CAF-Viewer or FDL-Editor.
> 
> Now if it appears Trimmed viewing FP (Vehicle Profile) using the FA-Editor, that is because the FAFP File in 55.0 is Trimmed, not the CAFD file.


----------



## shawnsheridan (Jan 10, 2009)

Yes, that makes perfect sense. 

You are not reading CAFD, rather you are reading Net Coding Data (.ncd) read out of ECU, which needs the corresponding CAFD to interpret it. The CAFD in 54.1 is not Trimmed, and can interpret your ECU's Net Coding Data. And the the CAFD in 55.0 is Trimmed, and cannot interpret your ECU's Net Coding Data.

CAFD = cafd_00000ded.caf.003_013_025 = PSdZData File (This file can be Trimmed or Untrimmed)
.NCD = CAFD_00000DED_003_013_025.ncd - Raw Coding Data Read Out of ECU - Needs CAFD (Untrimmed) for Interpretation.

Big difference between the two. 

And what you are referring to as the CAFD, isn't the CAFD file at all.

Nothing in 55.0 is masking anything. cafd_00000ded.caf.003_013_025 is trimmed in 55.0, so there is no descriptive text to display next to each Function Data Line (FDL) in the Net Coding Data file (.ncd).

Copy cafd_00000ded.caf.003_013_025 from 54.1 into 55.0, and like magic, you will suddenly be able to read CAFD_00000DED_003_013_025.ncd.


----------



## jimmy9980 (Nov 16, 2012)

shawnsheridan said:


> Yes, that makes perfect sense.
> 
> You are not reading CAFD, rather you are reading Net Coding Data (.ncd) read out of ECU, which needs the corresponding CAFD to interpret it. The CAFD in 54.1 is not Trimmed, and can interpret your ECU's Net Coding Data. And the the CAFD in 55.0 is Trimmed, and cannot interpret your ECU's Net Coding Data.
> 
> ...


Ok that would explain why I can read in 54.1 and not in 55, Ok I understand now how it works


----------



## jimmy9980 (Nov 16, 2012)

shawnsheridan said:


> Yes, that makes perfect sense.
> 
> You are not reading CAFD, rather you are reading Net Coding Data (.ncd) read out of ECU, which needs the corresponding CAFD to interpret it. The CAFD in 54.1 is not Trimmed, and can interpret your ECU's Net Coding Data. And the the CAFD in 55.0 is Trimmed, and cannot interpret your ECU's Net Coding Data.
> 
> ...


If I updated my nbt to v55 It looks like the new cafd file need is cafd_00000ded.caf.003_013_040 which doesnt exist in 54.1. I'm assuming there's no way to get this then. It is also trimmed


----------



## pasa29 (Feb 12, 2013)

Its so much easyer to code trimmed values than you all explain.

The needet information are all still in there. You just have to thing different

And please. If you guys find out how. 

Do not make the mistake to post it here. There are all over Developers in the forums. 

They will trimm the files Completly so there will be never a solution if they know how we do it. So take care


----------



## jimmy9980 (Nov 16, 2012)

pasa29 said:


> Its so much easyer to code trimmed values than you all explain.


How would you code trimmed values if you can't tell the option you are coding ?


----------



## pasa29 (Feb 12, 2013)

I can tell where the option is hidden in what line.


----------



## jimmy9980 (Nov 16, 2012)

pasa29 said:


> I can tell where the option is hidden in what line.


Are you able to figure out new options? There is no options in the drop down menus anymore


----------



## shawnsheridan (Jan 10, 2009)

New option not possible.


----------



## pasa29 (Feb 12, 2013)

Thats Right. New options are very hard to figure out without basic information


----------



## shawnsheridan (Jan 10, 2009)

jimmy9980 said:


> If I updated my nbt to v55 It looks like the new cafd file need is cafd_00000ded.caf.003_013_040 which doesnt exist in 54.1. I'm assuming there's no way to get this then. It is also trimmed


Without creating Flash TAL using 55.0 PSdZData, how do you conclude you will have cafd_00000ded.caf.003_013_040?

Why not cafd_00000ded.caf.003_013_051? Or Why not cafd_00000ded.caf.003_014_012?

Both are newer than cafd_00000ded.caf.003_013_040.

Incidentally, all 3 CAFD's are Trimmed.


----------



## jimmy9980 (Nov 16, 2012)

shawnsheridan said:


> Without creating Flash TAL using 55.0 PSdZData, how do you conclude you will have cafd_00000ded.caf.003_013_040?
> 
> Why not cafd_00000ded.caf.003_013_051? Or Why not cafd_00000ded.caf.003_014_012?
> 
> ...


I did I created a Tal and that's what it said the caf would. Seems like v55 wants to update 90% of my modules mostly caf files Nbt looks like a full update. I was thinking of doing Nbt, kombi and Rear entertainment modules seems they are all needed together. All will get new trimmed cafd files. Not sure if it's even worth it. I'm assuming flashing method still is the same with v55?


----------



## shawnsheridan (Jan 10, 2009)

Yes, flashing with 55.0 is no different.


----------



## VadimAA (Aug 11, 2014)

pasa29 said:


> I can tell where the option is hidden in what line.


HU_NBT_00000ded_003_014_012.xml
3000 34d 00000010b 
Can you tell me what function is at this address?


----------



## pasa29 (Feb 12, 2013)

hy.. according to your information

its an initwer1

Option says UNBELEGT

But i dont have the exact file 003_014_012 but it should be the same

your information are not complete for me and 34d i dont know of it


----------



## VadimAA (Aug 11, 2014)

pasa29 said:


> hy.. according to your information
> 
> its an initwer1
> 
> ...


OK.
start=34 (decimal)
mask=00000010b
Value of the function takes a boolean value 0 or 1


----------



## pasa29 (Feb 12, 2013)

yes i thought you ment that one

yes its Value Option is 01

but if you want to know what it does when you code it.. that i dont know friend..


----------



## VadimAA (Aug 11, 2014)

pasa29 said:


> hy.. according to your information
> 
> its an initwer1
> 
> ...


Starting with cafd_00000ded_003_014_012, this function is no longer just UNBELEGT, and has already specific purpose.
I want to show that in the future will be more and more new functions, values and definitions will be unknown.


----------



## jimmy9980 (Nov 16, 2012)

VadimAA said:


> Starting with cafd_00000ded_003_014_012, this function is no longer just UNBELEGT, and has already specific purpose.
> 
> I want to show that in the future will be more and more new functions, values and definitions will be unknown.


We have no way to know for new items. Current items seems easy to figure out as you can compare old cafd to new. But my concern is the order of the items change order then what?


----------



## pasa29 (Feb 12, 2013)

yes we can know of new values and all of it.. the Development of BMW does have all files Untrimmed..


----------



## jimmy9980 (Nov 16, 2012)

pasa29 said:


> yes we can know of new values and all of it.. the Development of BMW does have all files Untrimmed..


How would we get them ? They are not for public?


----------



## pasa29 (Feb 12, 2013)

if you dont know any developer there is no way to get to them.. and i think if somebody get them he will not post them anywhere


----------



## jimmy9980 (Nov 16, 2012)

pasa29 said:


> if you dont know any developer there is no way to get to them.. and i think if somebody get them he will not post them anywhere


Well that sucks!


----------



## lalamper (Sep 5, 2014)

CAFD_xxxxxxxx.CAF.xxx_xxx_xxx files look inside like this example below, you can see that data part is encrypted.
(I just replaced all < > signs with [ ], otherwise it will not show correctly in the post)

At first we should decrypt it completely as E-sys does in the background when FDL Editor opens up (Maybe Tokenmaster knows the trick). At this point E-sys decodes this file and use it to interpret my NCD file and show parameters for editing.

[?xml version="1.0" encoding="UTF-8"?]
[caf xmlns="http://bmw.com/2005/psdz.data.caf" isEncrypted="true" isNormalized="true" isCompressed="false" version="01.03.00"]
[encryptedData]
.
.
.
[/encryptedData]
[/caf]

After decrypting (or saving the decrypted content from disk/memory) maybe it is possible to match and link untrimmed and trimmed files together. It is also important that some of them are compressed and some of them are not. Decryption key must exist somewhere E-sys! It is based on Java code.
Both (trimmed and untrimmed) XML should contain the same IDs/memory addresses for the same memory spaces and/or functions. Than all we need is to find the corresponding pair and copy the description missing.

How does it sound?
Could somebody decrypt the same PSDZData CAFD file from 54.1 and 55? 
Let it be "cafd_000000f9.caf.007_008_007". This is used for my HU_ENTRY.


----------



## shawnsheridan (Jan 10, 2009)

lalamper said:


> ...
> How does it sound?...


As you contemplate possible solutions, I would be leery of doing so in an open manner.

And if you take this approach, when you are done with CAFD reconstruction, you will have to Encrypt and Sign these modified CAFD's in a manner acceptable to E-Sys.


----------



## lalamper (Sep 5, 2014)

Yes, maybe I should encrypt again and sign it to be accepted by E-sys. Or we can leave it decrypted to see whether E-sys can handle it. There is a flag in XML file that points out if it is encrypted or not: isEncrypted="true".
In this case verifying integrity and authenticity of the data files will not be possible. See TokenMaster blog's (http://tokenmaster.blogspot.hu/2014/01/why-hacking-xmlcrypto-is-bad-really-bad.html)

At the moment I am looking for solution to decrypt the files, but it is not easy as it seems. I have contacted TokenMaster for help as well. He has got more experience with this.


----------



## sdreisei (Dec 11, 2014)

If I understand right, we will be able to code the new software, but in a little bit other way. Does anybody know how I can code the LED Fog Lights into my F30 with software 55.xx? 
Or is there any professional in Austria who could help me? Thanks


----------



## lalamper (Sep 5, 2014)

Post removed.


----------



## shawnsheridan (Jan 10, 2009)

lalamper said:


> I could successfully decrypt and compare trimmed (v55) and untrimmed (v54.1) version of the same CAFD file.
> 
> As I expected there is a link between two files. For each function (or coding line) there is a mask ID, which is the same in both, only function name and comment missing. See it for yourself.
> For the next step I am going to move these info into trimmed version.
> ...


This was already discussed some time ago when Trimming first appeared in 54.2.

It has it's assumptions and limitations, namely if BMW AG remaps the MaskID, then historical MaskID's have no relevance, and for any new function added, there is no historical MaskID from which to mine the descriptive text from.

In any event, I guess you missed this part, or just willfully ignored it:


shawnsheridan said:


> As you contemplate possible solutions, I would be leery of doing so in an open manner.
> ...


As you make public the technical details of any possible solution, you are inviting more counter measures from BMW AG to thwart that solution, thus defeating the purpose of sustained FDL Coding.


----------



## lalamper (Sep 5, 2014)

shawnsheridan said:


> This was already discussed some time ago when Trimming first appeared in 54.2.
> 
> It has it's assumptions and limitations, namely if BMW AG remaps the MaskID, then historical MaskID's have no relevance, and for any new function added, there is no historical MaskID from which to mine the descriptive text from.


Hi Shawn,
Sorry, it seemed to me that many people having newer ISTA/P than Px.54.1 are facing with the problem of FDL coding. At least this forum is full of questions and lot of people searching for reliable solution as only partial workarounds exist.



shawnsheridan said:


> In any event, I guess you missed this part, or just willfully ignored it:
> 
> As you make public the technical details of any possible solution, you are inviting more counter measures from BMW AG to thwart that solution, thus defeating the purpose of sustained FDL Coding.


Yes, you are right, your message avoided my attention. This is true.
But if we have to count on BMWs counter measures, how can we share info and move forward in any questions?


----------



## pasa29 (Feb 12, 2013)

Lalamper look. If you ever find a way to code trimmed files. Dont post ist man. 

We are cutting in out own flesh. 

Bmw dont care. They will remove Any information in the future Updates, and what then. It will be much more difficult or even not Possible to find a way to code them then. 

PLEASE ALL. DONT SHARE ANY SOLUTION OR EVEN A WAY TO IT

We are Fu..... Ourself with it


----------



## lalamper (Sep 5, 2014)

pasa29 said:


> Lalamper look. If you ever find a way to code trimmed files. Dont post ist man.
> 
> We are cutting in out own flesh.
> 
> ...


It is fully understandable, but it means that this whole coding topic can be closed right now. The forum has lost its function in this question.


----------



## shawnsheridan (Jan 10, 2009)

lalamper said:


> Hi Shawn,
> Sorry, it seemed to me that many people having newer ISTA/P than Px.54.1 are facing with the problem of FDL coding. At least this forum is full of questions and lot of people searching for reliable solution as only partial workarounds exist.


Yes, for now there is still really no good solution.



lalamper said:


> Yes, you are right, your message avoided my attention. This is true.
> 
> But if we have to count on BMWs counter measures, how can we share info and move forward in any questions?


Your target audience for such discussions and the number of people that could actually contribute to a solution is likely less then the number of fingers you have on one hand. Thus putting it out there for all is pointless to begin with. Reading and knowing who those few technical experts are, and having offline communications with them is the way to further advance your theories and possible solutions.


----------



## pasa29 (Feb 12, 2013)

No only on this Question relatatet to the Trimmed files. 

Its the best for all of us

Cant you imagine what bmw will do after releasing solution to the trimmed files???


----------



## pasa29 (Feb 12, 2013)

True words Shawn. 

Offline talk with people


----------



## shawnsheridan (Jan 10, 2009)

Jebbe said:


> Thought I read all the instructions but obv not, have to make a new token every time I start the E-sys. Sorry for this.
> 
> Thank you for the fast answers and good information
> 
> Cheers!


No, not true. You make .EST Token one time, and Assign PIN. Then you use E-Sys Launcher to open E-Sys going forward, and it will mange your Token Validation for you including PIN. You never need to create another .EST Token, nor enter PIN again.


----------

