English Amiga Board


Go Back   English Amiga Board > Support > support.Other

 
 
Thread Tools
Old 01 October 2019, 01:41   #1
catphish
Registered User
 
Join Date: May 2019
Location: Dorset, UK
Posts: 8
Amiga floppy checksums

I'm working on a tool to read and write Amiga disks with a PC. All is going well, but I one thing about the disk format is confusing me - the sector checksums.


Checksums appear to be calculated by xor'ing the MFM encoded data, ignoring the clock bits. The result appears to be a checksum where all odd bits are zero.


This checksum is then encoded into 2 longs (one for odd bits and one for even bits). The result of this therefore seems to be that the "checksum odd" fields of the header are *always* zero. Is this actually correct? It seems like a bafflingly odd design if so.


This does appear to be the case with the disk I'm testing with, but I wanted some input on whether this is correct!


Thanks! I will likely have more questions and weird and wonderful disk formats soon.
catphish is offline  
Old 01 October 2019, 01:50   #2
lesta_smsc
Registered User
 
lesta_smsc's Avatar
 
Join Date: Feb 2012
Location: United Kingdom
Posts: 3,173
Just to clarify. Are you using a hardware interface to help as floppy disk controller? As far as I was aware, the PC cannot natively support Amiga disk format?

Sent from my SM-G925F using Tapatalk
lesta_smsc is offline  
Old 01 October 2019, 01:58   #3
catphish
Registered User
 
Join Date: May 2019
Location: Dorset, UK
Posts: 8
Yes. I have designed an STM32 based USB floppy controller and I'm now working on the software.

https://i.imgur.com/TEDFmct.jpg
catphish is offline  
Old 01 October 2019, 02:21   #4
lesta_smsc
Registered User
 
lesta_smsc's Avatar
 
Join Date: Feb 2012
Location: United Kingdom
Posts: 3,173
Fantastic! I'm not sure if it will help, but take a look at this project which uses Arduino for the same purpose. It is open source so you may be able to get some ideas for your situation in the code / concept?

http://amiga.robsmithdev.co.uk/

Sent from my SM-G925F using Tapatalk
lesta_smsc is offline  
Old 01 October 2019, 08:26   #5
ross
Defendit numerus
 
ross's Avatar
 
Join Date: Mar 2017
Location: Crossing the Rubicon
Age: 53
Posts: 4,468
Quote:
Originally Posted by catphish View Post
This checksum is then encoded into 2 longs (one for odd bits and one for even bits). The result of this therefore seems to be that the "checksum odd" fields of the header are *always* zero. Is this actually correct? It seems like a bafflingly odd design if so.
Yes, and this is the reason why I deliberately decided to ignore it in my loader.
This increases the decoding speed and does not affect the correctness of the data.
(well, actually you could check if that value is actually zero ).
Could it be a legacy of encoding and decoding done with blitter in 1.x systems? (to align data)
ross is offline  
Old 01 October 2019, 20:15   #6
catphish
Registered User
 
Join Date: May 2019
Location: Dorset, UK
Posts: 8
Thanks for confirming. I will ignore the odd checksum field. It doesn't even matter if the field is corrupt
catphish is offline  
Old 02 January 2020, 16:02   #7
Wiking67
Blowing Out The Flame
 
Wiking67's Avatar
 
Join Date: Apr 2009
Location: Lulea Sweden
Age: 57
Posts: 214
Send a message via MSN to Wiking67
here another: http://nickslabor.niteto.de/projekte/adf-copy-english/
Wiking67 is offline  
Old 02 January 2020, 16:10   #8
lesta_smsc
Registered User
 
lesta_smsc's Avatar
 
Join Date: Feb 2012
Location: United Kingdom
Posts: 3,173
All these projects are great! It would be nice if there was a way to modify and ready made USB FDD but not sure what chipset is in these and whether it would allow any modification.
lesta_smsc is offline  
 


Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Thread Tools

Similar Threads
Thread Thread Starter Forum Replies Last Post
Original Workbench (and related) disks preservation - Checksums required MrDolby project.TOSEC (amiga only) 81 26 January 2024 10:39
ORIGINAL WorkBench checksums Supamax request.Other 186 18 May 2021 19:10
Web page with kickstart list & checksums Gabriel Hardware mods 4 24 January 2010 02:53
Kickstart ROM Checksums vimfuego support.Hardware 1 18 September 2009 07:41
Unknown floppies: how to identify them using their checksums/CRC32? Supamax request.Other 5 13 May 2009 19:08

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT +2. The time now is 11:04.

Top

Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2024, vBulletin Solutions Inc.
Page generated in 0.07510 seconds with 13 queries