Segment Swap utility

They go by many names, P01, P59, VPW, '0411 etc. Also covering E38 and newer here.
Snoman002
Posts: 20
Joined: Tue Jul 28, 2020 12:18 pm
cars: 2005 Quadrasteer
2009 US Spec VXR8

Re: Segment Swap utility

Post by Snoman002 »

kur4o wrote:The mandatory fields are: Vehicle make,type, platform, engine type[displacement], trans and driveline. Not any of this can be found in the bin, Only by decoding the vin and the rpo codes. Or you can define each cal part number. For example p/n xxxxxxxxx- engine cal for 2003 5.3l lm3 used with OS yyyyyyyy.
Thanks.

Yes, I figured VIN decoding would be part of it and I have done so for the ones I have processed so far. Unfortunately RPO codes would be difficult to pull unless a free online vin->rpo source could be found. Once the structure is defined more an automated process against the Repo could be generated for processing cals and other such info.

I will start building out a rough XML structure for now, although moving forward I will need to figure out a tool that can process these automatically or semi-automatically.
In-Tech
Posts: 787
Joined: Mon Mar 09, 2020 4:35 pm
Location: California

Re: Segment Swap utility

Post by In-Tech »

Hello,
I don't know excel very well. When I save csv and open in excel all of it is a mess garbled together. I'm sure it's something simple stupid I need to do to the format if someone wants to point me to a readme on it.
Thanks
User avatar
Gampy
Posts: 2333
Joined: Sat Dec 15, 2018 7:38 am

Re: Segment Swap utility

Post by Gampy »

If the data is all in a single column (like column A), then select that column and from the Menu,

Select: Data
Select: Text To Columns

That will open the Text to Columns dialog,

Select: Delimited
Select: Next
Select: Comma (Make Comma the only delimiter)
Select: Finish

-Enjoy
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!
In-Tech
Posts: 787
Joined: Mon Mar 09, 2020 4:35 pm
Location: California

Re: Segment Swap utility

Post by In-Tech »

Gampy,
I did make some progress, a couple of the hex id's are trying to become a formula so I'll keep messing with it but huge gains from where it started.
Thanks
User avatar
Gampy
Posts: 2333
Joined: Sat Dec 15, 2018 7:38 am

Re: Segment Swap utility

Post by Gampy »

The values in the csv, are they decimal or hex??

Hex and excel don't get along so well, it's a conversion nightmare, yea it's doable, butt ugly!
Best to convert pre import.

If you want, PM me your csv (or an example of the troublesome area) and I'll tell ya how to sort it out. Excel and I have had a long term relationship.
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!
In-Tech
Posts: 787
Joined: Mon Mar 09, 2020 4:35 pm
Location: California

Re: Segment Swap utility

Post by In-Tech »

PM and file sent,
Using Universal Patcher if you open a .bin then go to the File Info tab there is a button for "Save CSV" that I am trying to use. You can try with any file.
Thanks
User avatar
Gampy
Posts: 2333
Joined: Sat Dec 15, 2018 7:38 am

Re: Segment Swap utility

Post by Gampy »

It would be best if we can get joukoy to convert the hex values to decimal on export and do a little cleaning.

Else create a script or program to re-write it ...

[edit]
It is a csv with a Semi-Colon separator ... so the excel delimiter needs to be Semi-Colon not Comma!

-Enjoy
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!
In-Tech
Posts: 787
Joined: Mon Mar 09, 2020 4:35 pm
Location: California

Re: Segment Swap utility

Post by In-Tech »

Gampy wrote: [edit]
It is a csv with a Semi-Colon separator ... so the excel delimiter needs to be Semi-Colon not Comma!

-Enjoy
Yepper, got that far.
Thanks
User avatar
joukoy
Posts: 392
Joined: Tue Dec 17, 2019 3:27 am
cars: --
Contact:

Re: Segment Swap utility

Post by joukoy »

Gampy wrote:It would be best if we can get joukoy to convert the hex values to decimal on export and do a little cleaning.


-Enjoy
Version 0.12.38 have new button: "Export to CSV(Dec)"
It is done "wrong way", converting from hex values to decimal while exporting, but I think it works ok.
"Right way" is storing values as decimal when reading from binary, but this requires too much work.

Another mod: "Search tables" is off by default.
User avatar
Gampy
Posts: 2333
Joined: Sat Dec 15, 2018 7:38 am

Re: Segment Swap utility

Post by Gampy »

Thank you joukoy.

Can you do two more things please ...
1. Clean up the eeprom_data row so it's valid csv. (add fields)
2. Change the format of the Address field on the OS row, it is currently,

Code: Select all

0 - 1279, 1280 - 16383, 131072 - 1048573
Maybe to

Code: Select all

0:1279 - 1280:16383 - 131072:1048573
The comma's are challenging Excels intelligence. (meaning it's breaking the csv import.)

Number 1 cannot be easily worked around, Number 2 can easily be worked around with a copy/paste technique, it just can't be directly imported.

Thanks
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!
Post Reply