TIP: Click on subject to list as thread! ANSI
echo: aust_c_here
to: All
from: John Gardeniers
date: 1996-04-08 00:32:32
subject: Cluster to sector calculation

* Crossposted from: Local Programming Echo

        Hello All,

        Can someone please, pretty please, help me with what should not be
a problem.  I need to convert a disk cluster number to a sector number.
The calculation I'm using works perfectly on a Drvspace (Doublspace) drive
but fails for anything, except the root directory, on the physical hard
drive. The formula I'm using is:

        Cluster_number * Sectors_per_cluster + Root_directory_sector

        I've tried this on two different computers with different sized
hard drives and just can't work out where the error is.  As this is the
last problem to be solved on my current project I would appreciate any
help anyone can offer.  I should mention that the drives I'm working with
each have a 12 bit FAT.

                John

... C program run... Run, program, run...   PLEASE!!!!
---
* Origin: Melbourne PC User Group +61-3-9699-6788 (3:632/309)
SEEN-BY: 50/99 78/0 620/243 623/630 632/0 107 271 304 309 328 348 360 393 525
SEEN-BY: 632/530 552 998 999 1000 633/371 634/384 388 396 635/301 502 503 544
SEEN-BY: 637/103 639/252 711/401 409 410 413 430 808 809 932 934 712/515
SEEN-BY: 713/888 714/906 800/1 7877/2809
@PATH: 632/309 998 635/503 50/99 711/808 809 934

SOURCE: echomail via fidonet.ozzmosis.com

Email questions or comments to sysop@ipingthereforeiam.com
All parts of this website painstakingly hand-crafted in the U.S.A.!
IPTIA BBS/MUD/Terminal/Game Server List, © 2025 IPTIA Consulting™.