Patent ID: 6751692
Filing Date: 2004-06-15
Classification: G06F

Abstract:
A method of connecting and accessing a memory device in a cylinder head sector (CHS) mode with an AT attachment (ATA) interface of a host computer using an adapter, said method comprising:connecting the memory device to the adapter; connecting the adapter to the ATA interface; setting a first variable and a second variable to initial values; dividing a memory capacity (in bytes) of the memory device by 512 to determine a total number of sectors; dividing the total number of sectors by a product of the first and second variables to determine a resultant quotient; if the resultant quotient is equal to or less than 65535 and simultaneously has a remainder of zero, assigning the first variable and the second variable as a number of heads and a number of sectors per track, respectively; if either the resultant quotient is greater than 65535 or the remainder is other than zero, updating the first and second variables and dividing the total number of sectors by a product of the updated first and second variables to determine a new resultant quotient; if the new resultant quotient is equal to or less than 65535 and simultaneously has a remainder of zero after said updating of the first and second variables, assigning the updated first variable and the updated second variable as the number of heads and the number of the sectors per track, respectively; if either the new resultant quotient is greater than 65535 or has a remainder other than zero after said updating of the first and second variables, setting the number of heads and the number of tracks to predetermined variables, respectively; assigning a quotient of the total number of sectors divided by a product of the number of heads and the number of sectors per track as a number of cylinders; and assigning a product of the number of heads, the number of sectors per track, and the number of cylinders as a total number of sectors for accessing the memory device in the CHS mode.