Segment Swap utility

They go by many names, P01, P59, VPW, '0411 etc. Also covering E38 and newer here.
ironduke
Posts: 583
Joined: Thu Feb 13, 2020 11:32 pm
cars: Mainly GM trucks, a Cruze and an Equinox for dailys..

Re: Segment Swap utility

Post by ironduke »

joukoy wrote:Found this:
https://github.com/dzidaV8/XdfMover
And it looks like xdf editing is quite simple task (?)
Can you send an example xdf file, I can use as template for DTC codes? Other tables are not important now.
page before I posted the DTC section of an XDF already, I can make up an XDF of just the DTCs and post up the entire thing shortly..

Don't want to side track too much, but is this of any use to anyone? you mentioned some DTC's were missing info, I think those aren't used by this OS, but see if this link works for you, I was digging out mode 6 info for something else and thought this might be helpful to a few here..

https://gsi.ext.gm.com/gmspo/mode6/2019parms.html


Here's a complete XDF for that OS.. I used your plug in for the CVN/Checksums, didn't check but hopefully I got it right..
12639835.dtc.list.only.zip
(19.56 KiB) Downloaded 133 times
User avatar
joukoy
Posts: 392
Joined: Tue Dec 17, 2019 3:27 am
cars: --
Contact:

Re: Segment Swap utility

Post by joukoy »

0.12.47 have basic xdf-export implemented.

It will not create complete xdf, only part of it, where DTC codes are defined.
Should it create .txt file instead of .xdf, when it is not a working xdf file?

Please test.
ironduke
Posts: 583
Joined: Thu Feb 13, 2020 11:32 pm
cars: Mainly GM trucks, a Cruze and an Equinox for dailys..

Re: Segment Swap utility

Post by ironduke »

That is awesome!!! I'm sure we'll tweak it a bit but I just built an XDF for DTC's for an 08 silverado in all of 2 minutes using your program, sweet!!
I'll check it with some more bins later tonight, but it looks good..
I'm not real good at XDF and working with tuner pro, might be a easier way to import this into an xdf? I'll try and do some research, but given that there are only so many E38 os's out there if I'm given a bin of each one I can build one of these these for each OS..
Man this is superb!!! This is exactly what I wanted.. Thanks a TON!!!!

All I did was creat an xdf and make it 200000 in size, then saved the xdf.. I added the text below to the top of what you created..

Edited to add, if anyone wants this for their own bin either post it up or send it to me and I'll get a XDF for DTC codes built for your bin.. that'll help get them built for everyone else.
here's the one I just made.. please check it and report back..
12622161.2007.silverado.zip
(18.38 KiB) Downloaded 136 times

Code: Select all

<XDFFORMAT version="1.60">
  <XDFHEADER>
    <flags>0x1</flags>
    <deftitle>12639835 OS</deftitle>
    <description></description>
    <BASEOFFSET offset="0" subtract="0" />
    <DEFAULTS datasizeinbits="8" sigdigits="2" outputtype="1" signed="0" lsbfirst="0" float="0" />
    <REGION type="0xFFFFFFFF" startaddress="0x0" size="0x200000" regionflags="0x0" name="Binary File" desc="This region describes the bin file edited by this XDF" />
    <CATEGORY index="0x0" name="DTC&apos;s" />
  </XDFHEADER>
  <XDFTABLE uniqueid="0x1E2E" flags="0x30">
    <title>DTC table</title>
    <description>00 MIL and reporting off
01 type A/no mil
02 type B/no mil
03 type C/no mil
04 not reported/no mil 
05 type A/mil 
06 type B/mil 
07 type c/mil </description>
    <CATEGORYMEM index="0" category="1" />
    <XDFAXIS id="x" uniqueid="0x0">
      <EMBEDDEDDATA mmedelementsizebits="8" mmedmajorstridebits="-32" mmedminorstridebits="0" />
      <indexcount>1</indexcount>
      <outputtype>3</outputtype>
      <datatype>0</datatype>
      <unittype>0</unittype>
      <DALINK index="0" />
      <LABEL index="0" value="" />
      <MATH equation="X">
        <VAR id="X" />
      </MATH>
    </XDFAXIS>
    <XDFAXIS id="y" uniqueid="0x0">
      <EMBEDDEDDATA mmedelementsizebits="8" mmedmajorstridebits="-32" mmedminorstridebits="0" />
Then I pasted your code and then I pasted the code below at the end.. It included the code for CVN and checksum which I have set up already in tuner pro..

Code: Select all

<decimalpl>1</decimalpl>
      <min>0.000000</min>
      <max>7.000000</max>
      <outputtype>2</outputtype>
      <MATH equation="X">
        <VAR id="X" />
      </MATH>
    </XDFAXIS>
  </XDFTABLE>
  <XDFCHECKSUM uniqueid="0x2CDC">
    <title>CVN </title>
    <REGION>
      <pluginmoduleid>cbebdc26-cd53-460b-8d61-898d18dca53f</pluginmoduleid>
      <datastart>0x0</datastart>
      <dataend>0x0</dataend>
      <storeaddress>0x0</storeaddress>
      <calculationmethod>0x0</calculationmethod>
    </REGION>
  </XDFCHECKSUM>
  <XDFCHECKSUM uniqueid="0x7B14">
    <title>Checksum</title>
    <REGION>
      <pluginmoduleid>cbebdc26-cd53-460b-8d61-898d18dca53f</pluginmoduleid>
      <datastart>0x0</datastart>
      <dataend>0x0</dataend>
      <storeaddress>0x0</storeaddress>
      <calculationmethod>0x1</calculationmethod>
    </REGION>
  </XDFCHECKSUM>
User avatar
joukoy
Posts: 392
Joined: Tue Dec 17, 2019 3:27 am
cars: --
Contact:

Re: Segment Swap utility

Post by joukoy »

I will check tomorrow, if I can generate complete xdf.
Maybe by converting one file as template, containing keywords, which will be replaced with real data?
ironduke
Posts: 583
Joined: Thu Feb 13, 2020 11:32 pm
cars: Mainly GM trucks, a Cruze and an Equinox for dailys..

Re: Segment Swap utility

Post by ironduke »

joukoy wrote:I will check tomorrow, if I can generate complete xdf.
Maybe by converting one file as template, containing keywords, which will be replaced with real data?
kind of what I was thinking, but just remembered that there aren't always the same number of codes so you'll have to do something about that..

If your getting real fancy maybe it can read the OS and put that in the name of the file it creates?

Code below could go into the XDF and you can read the OS of the file to make sure it matches the OS of the XDF. Don't know if there's a better way in tuner pro to read/show the OS, but it worked for me..

Code: Select all

<XDFTABLE uniqueid="0x6D5E" flags="0x0">
    <title>Operating System- do NOT edit, this must match OS of this XDF</title>
    <CATEGORYMEM index="0" category="0" />
    <XDFAXIS id="x" uniqueid="0x0">
      <EMBEDDEDDATA mmedelementsizebits="8" mmedmajorstridebits="-32" mmedminorstridebits="0" />
      <units>ASCII</units>
      <indexcount>8</indexcount>
      <outputtype>4</outputtype>
      <datatype>0</datatype>
      <unittype>0</unittype>
      <DALINK index="0" />
      <LABEL index="0" value="1" />
      <LABEL index="1" value="2" />
      <LABEL index="2" value="3" />
      <LABEL index="3" value="4" />
      <LABEL index="4" value="5" />
      <LABEL index="5" value="6" />
      <LABEL index="6" value="7" />
      <LABEL index="7" value="8" />
      <MATH equation="X">
        <VAR id="X" />
      </MATH>
    </XDFAXIS>
    <XDFAXIS id="y" uniqueid="0x0">
      <EMBEDDEDDATA mmedelementsizebits="8" mmedmajorstridebits="-32" mmedminorstridebits="0" />
      <indexcount>1</indexcount>
      <outputtype>4</outputtype>
      <datatype>0</datatype>
      <unittype>0</unittype>
      <DALINK index="0" />
      <LABEL index="0" value="0.00" />
      <MATH equation="X">
        <VAR id="X" />
      </MATH>
    </XDFAXIS>
    <XDFAXIS id="z">
      <EMBEDDEDDATA mmedaddress="0x1000E" mmedelementsizebits="8" mmedrowcount="1" mmedcolcount="8" mmedmajorstridebits="0" mmedminorstridebits="0" />
      <decimalpl>0</decimalpl>
      <min>0.000000</min>
      <max>255.000000</max>
      <outputtype>4</outputtype>
      <MATH equation="X">
        <VAR id="X" />
      </MATH>
    </XDFAXIS>
  </XDFTABLE>
Last edited by ironduke on Wed Nov 04, 2020 8:15 am, edited 1 time in total.
User avatar
Gampy
Posts: 2333
Joined: Sat Dec 15, 2018 7:38 am

Re: Segment Swap utility

Post by Gampy »

ironduke wrote:

Code: Select all

    <title>Operating System- do NOT edit, this must patch OS of this XDF</title>
Is "patch" a typo ??
Intelligence is in the details!

It is easier not to learn bad habits, then it is to break them!

If I was here to win a popularity contest, their would be no point, so I wouldn't be here!
ironduke
Posts: 583
Joined: Thu Feb 13, 2020 11:32 pm
cars: Mainly GM trucks, a Cruze and an Equinox for dailys..

Re: Segment Swap utility

Post by ironduke »

Gampy wrote:
ironduke wrote:

Code: Select all

    <title>Operating System- do NOT edit, this must patch OS of this XDF</title>
Is "patch" a typo ??
Yup.. That was a typo.. fixed it.. thanks..

keep your eye out for more, I'm prone to messing something up, it's my super power..
User avatar
joukoy
Posts: 392
Joined: Tue Dec 17, 2019 3:27 am
cars: --
Contact:

Re: Segment Swap utility

Post by joukoy »

Version 0.12.48

If you have template in XML -folder, for example e38-template.xdf, you can create automatically minimal xdf for tunerpro. (Currently only e38 and e67)
Thank you for great ideas, ironduke!
User avatar
joukoy
Posts: 392
Joined: Tue Dec 17, 2019 3:27 am
cars: --
Contact:

Re: Segment Swap utility

Post by joukoy »

kur4o wrote:Joukoy,

adding some edit, save function[If you are willing to experiment]. It will work on most binaries and there is no need to create xdf for each OS.
Implemented in 0.12.49
Now you can set DTC codes on/off for e38/e67 binaries
ironduke
Posts: 583
Joined: Thu Feb 13, 2020 11:32 pm
cars: Mainly GM trucks, a Cruze and an Equinox for dailys..

Re: Segment Swap utility

Post by ironduke »

I had to copy over the Reference-CVN.xml file to the XDF folder to get it to run, hope that's ok, it was missing in the new zipped XML folder.

How to use the templates? When i save as xdf am I supposed to point it to the template? Won't that overwrite that file? or should I make a copy of that template and then select it??

Tried making a copy of that template file, renaming it with the OS I was trying it with but it just overwrote the file.. It lost all the info in the original template folder.

Tried editing right in Universal Patcher, changed a code but what do I do after that? I can see it change on the left but there's no save button? tried using the modify bin tab but saving the bin doesn't do anything.. Can't seem to figure it out..
Last edited by ironduke on Wed Nov 04, 2020 11:10 pm, edited 2 times in total.
Post Reply