Segment Swap utility

They go by many names, P01, P59, VPW, '0411 etc. Also covering E38 and newer here.
User avatar
joukoy
Posts: 392
Joined: Tue Dec 17, 2019 3:27 am
cars: Pontiac Firebird 1978

Re: Segment Swap utility

Post by joukoy »

0.7.3
Fixed V6 cheksum
Patch - XML linking (need tuning, now looking only from same folder where xml was when patch created)
Attachments
V6.xml
(652 Bytes) Downloaded 204 times
kur4o
Posts: 948
Joined: Sun Apr 10, 2016 9:20 pm

Re: Segment Swap utility

Post by kur4o »

Great work so far.

I found some exceptions. Here is some test files to work on.
testBINswithlist.rar
(451.61 KiB) Downloaded 198 times
On 1mb files the checksum area is a little different, 0-3fff,10000-end of bin. It applies to all 1 mb files.
I also found that on 256mb files the checksum area is also different. It is supposed to be 4000-end of bin. Still have to confirm it.


The other file have the OS stored at 7FFF8, maybe read both addresses end of bin -6, and end of bin -8 and or specify a list of os locations that can be read and compare all them for match with the list.

Or use the location of a55a check bytes[last 2 bytes or, end of bin-4] for identification.

It will be nice to print the taken from bin OS at the info dialog, and if not in the list, print that OS is not supported yet.

Can you make the test file to have some fields that are not read, for example add some // infront of the line. This way some extra info can be added for ease of work.

I found a list of most of the OS used, but not all have known checksum addresses. Can we leave the OS numbers in the text file and if not followed by :chk[address] print a message that the OS is still not configured. That way we can make a full list of all Oss and add checksum addresses when they are available.
User avatar
joukoy
Posts: 392
Joined: Tue Dec 17, 2019 3:27 am
cars: Pontiac Firebird 1978

Re: Segment Swap utility

Post by joukoy »

Now program will create folders: XML, Patches and Binfiles in startupfolder when started.
They are default folders for each file type, but it will remember (until closed) last folder where you open each filetype.

I can remove this if not useful.

If third line of patch is XML filename, it will be searched from original location and XML-folder.

You can setup checksum area in XML-file. Do you think there should be hard-coded area for V6 binaries to make them work with single xml ? I think I will disagree...

Program should read only rows with ":" from V6 os-list, so you can add comments.

btw, CHEKCSUMS_V6_FWD.rtf have long list of OS id's with checksum addresses, are you using it ?
kur4o
Posts: 948
Joined: Sun Apr 10, 2016 9:20 pm

Re: Segment Swap utility

Post by kur4o »

3 xmls with 3 text files for 256kb,512kb and 1mb files might be the best way.

Now there is the problem with that odd ball 512kb bins. The one I send you[9377739.bin] is not recognized since the OS is at 7fff8 location, while on most of the other bins it is at 7fffa location. I hope you can find a workaround this.

The OS text file will be better to be searched for in the xml folder, and I don`t think there is a need for the bin folder. Maybe use the exe folder at startup and remember the last used folder.

I am having some problem, maybe a bug. I always got unsupported OS error even though it is setup in the text file and is recognized by the program.

The rtf file seems really incomplete and it will be long manual transfer of the data. I found another list of all the OSs but there is no checksum location in it.

The OS only list is here
download/file.php?id=22062
User avatar
joukoy
Posts: 392
Joined: Tue Dec 17, 2019 3:27 am
cars: Pontiac Firebird 1978

Re: Segment Swap utility

Post by joukoy »

Converted OS:Checksumaddress file
Attachments
GM-V6.txt
(3.54 KiB) Downloaded 201 times
User avatar
joukoy
Posts: 392
Joined: Tue Dec 17, 2019 3:27 am
cars: Pontiac Firebird 1978

Re: Segment Swap utility

Post by joukoy »

kur4o wrote:3 xmls with 3 text files for 256kb,512kb and 1mb files might be the best way.

Now there is the problem with that odd ball 512kb bins. The one I send you[9377739.bin] is not recognized since the OS is at 7fff8 location, while on most of the other bins it is at 7fffa location. I hope you can find a workaround this.

The OS text file will be better to be searched for in the xml folder, and I don`t think there is a need for the bin folder. Maybe use the exe folder at startup and remember the last used folder.

I am having some problem, maybe a bug. I always got unsupported OS error even though it is setup in the text file and is recognized by the program.

The rtf file seems really incomplete and it will be long manual transfer of the data. I found another list of all the OSs but there is no checksum location in it.

The OS only list is here
download/file.php?id=22062
0.7.5

V6: Fixed a bug, now detecting OS correctly.
V6: Looking backwards max 20 bytes from end of file for a55a => OS location
V6: OS-list moved to XML-folder
Latest XML, PATCH and BIN -folder automatcially saved and remembered after app closed.

Other small fixes & improvements.
kur4o
Posts: 948
Joined: Sun Apr 10, 2016 9:20 pm

Re: Segment Swap utility

Post by kur4o »

Worked great so far. I tested it with random v6s bins and there is zero issues.

It turns out that there are 3 different cases. 96-97 256 and 512kb bins,98-on 512kb and 1mb bins. The main difference is the are that is included in the checksum. 96-97 is 0-end of bin, 98-on is skip 4000-7fff area and 1mb bins is skip 4000-ffff.

Now looking at the patch side. It will be good to have a force compare switch that overrides the protection for comparison for advanced users or some odd bins that OS doesn`t matter that much. Maybe some comments section for the xml files for usage or info button for the xml.
I have been thinking to add more info fields, like service number and vin. The config is spot on so only an extra fields will be needed. Printing the xml file name in the setup dialog for identification and maybe adding the load button to the main patcher window and rename setup segments to config or settings and rename checksum button to fix checksums, now it is some confusing.

I am still thinking what can be improved on the patcher side, the checksums now seems almost done and I can start making some config files.

Awesome job.

edit
I also noticed that comparing is extremely slow with lots of differences. Can we improve that.

Any chance the compiler can be done for net 3.5 just for testing.

The v6 text file you converted saved alot of manual work.
Big thanks.
User avatar
joukoy
Posts: 392
Joined: Tue Dec 17, 2019 3:27 am
cars: Pontiac Firebird 1978

Re: Segment Swap utility

Post by joukoy »

Universal patcher 0.8.0

Lot of modifications.
Tip: doubleclick address -textbox in segment setup.

C# is not compatible with .Net 3.5, 4.0 is minimum.
ironduke
Posts: 579
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 »

Hey, I just found this and this is awesome!!!! Figuring it out as I go..

one issue so far is the E38.xml file.. Doesn't the CVN need to have the bytes swapped???

Other than that, this is great.. I was able to create my own patch, use it, then have it fix the CVN and sums for me for the file.. Awesome work!!!!
User avatar
joukoy
Posts: 392
Joined: Tue Dec 17, 2019 3:27 am
cars: Pontiac Firebird 1978

Re: Segment Swap utility

Post by joukoy »

ironduke wrote:Hey, I just found this and this is awesome!!!! Figuring it out as I go..

one issue so far is the E38.xml file.. Doesn't the CVN need to have the bytes swapped???

Other than that, this is great.. I was able to create my own patch, use it, then have it fix the CVN and sums for me for the file.. Awesome work!!!!
True, XML files need updating.
Uploaded new versions.
Post Reply