Jump to content

Photo

How to compare files on one disk vs another disk?


6 replies to this topic

#1 Keatah OFFLINE  

Keatah

    Missile Commander

  • 20,660 posts

Posted Tue Sep 12, 2017 11:11 PM

For curating and de-duping purposes, how would one go about comparing a series of files on 2 .DSK images?

 

For example:

 

DiskA.dsk has 5 files and DiskB.dsk has 5 files, same names, same filesizes.

 

What would be the best way to compare those 5 files and be sure they're the same? Copy II+ in an emulator? Extract via Ciderpress and then compare in Windows checksum? It'd be nice if CP had a checksum feature, but it does not.

 

Any other ideas that would be more efficient and faster? Less tedious?



#2 MarkO OFFLINE  

MarkO

    Dragonstomper

  • 913 posts
  • Location:Albany, Oregon, USA, North Western Hemisphere, Planet Tera

Posted Wed Sep 13, 2017 5:02 PM

Sounds like the need for a Modern PC Utility that can Read a Disk Image, and Follow the Individual Files on them and do Compares and Checksums on them. besides the Whole Disk...

MarkO

#3 Keatah OFFLINE  

Keatah

    Missile Commander

  • Topic Starter
  • 20,660 posts

Posted Wed Sep 13, 2017 7:02 PM

Yes. I have several modern tools on the PC. But to get the files from the .dsk image to the PC. Cp is rather tedious.

#4 Iamgroot OFFLINE  

Iamgroot

    Chopper Commander

  • 135 posts
  • Location:Saskatchewan

Posted Wed Sep 13, 2017 10:23 PM

You don't say on which OS, but under Prodos, the easiest way is to look at the date modified and the file size.  You will be able to see if they are the same size, if one has been modified and which are the most recent.



#5 Keatah OFFLINE  

Keatah

    Missile Commander

  • Topic Starter
  • 20,660 posts

Posted Tue Dec 26, 2017 4:54 AM

It's a mixture of both OSes, but mostly DOS 3.3.

Right now I dump them to windows and crc them there. Can't always trust prodos time stamps. And a file can be different, yet the same size.

#6 Iamgroot OFFLINE  

Iamgroot

    Chopper Commander

  • 135 posts
  • Location:Saskatchewan

Posted Tue Dec 26, 2017 11:17 AM

It's probably most likely applesoft files that you are comparing, since binary files with the same file name rarely change in size unless you are doing programming.

 

It is also extremely rare that modifying an applesoft program will result in the exact same file size as the original.

 

So, probably the easiest method to compare applesoft files is to load each file, then display the end of the program in memory with this statement.

 

PRINT PEEK(175)+256*PEEK(176)

 

It is also quite easy to write your own CRC on the Apple.

Here is a 24-bit one that you can add to your utilities.

 

0300:D8 A5 67 85 06 A5 68 85 07 A0 00 84 08 84 09 18
0310:B1 06 E6 06 71 06 90 06 E6 08 D0 02 E6 09 E6 06
0320:D0 02 E6 07 A6 07 E4 B0 90 EA A6 06 E4 AF 90 E4  
0330:AA A5 09 20 DA FD A5 08 4C 41 F9 00
 

BSAVE CRC.24BIT,A$300,L$3B

 

now just load your applesoft program then type CALL 768



#7 Keatah OFFLINE  

Keatah

    Missile Commander

  • Topic Starter
  • 20,660 posts

Posted Thu Dec 28, 2017 3:49 PM

Interesting, as soon as I return from up north I shall check it out.





Reply to this topic



  


0 user(s) are browsing this forum

0 members, 0 guests, 0 anonymous users