Rockbox.org home
release
dev builds
extras
themes manual
wiki
device status forums
mailing lists
IRC bugs
patches
dev guide



Rockbox mail archive

Subject: Re: Digrom2/ATA2
From: alankorr (alankorr_at_subdimension.com)
Date: 2002-01-21


> I think I found why digrom2 doesn't work for me :

Ok ! fine, you got it. We have 128 fat entries in a fat
sector, so 128 clusters in a fat sector.

Thus,

1) if (cluster < 2 || (cluster * sectors_per_cluster) >=
sectors_per_fat)
  break;

should be :

2) if (cluster < 2 || (cluster >= (sectors_per_fat * 128)))
     break;

just create a variable :
  unsigned long clusters_per_fat = sectors_per_fat * 128;

  ...
  if ((cluster - 2) >= clusters_per_fat)
    break;
 
I'm sorry, line 1) was totally wrong :((( there is a
confusion between the number of sector containing the fat
and the number of clusters the fat handles.

_____________________________________________________________________
// free anonymous email || forums \\ subZINE || anonymous browsing
            subDIMENSION -- http://www.subdimension.com



Page was last modified "Jan 10 2012" The Rockbox Crew
aaa