1. Field of the Invention
The present invention relates generally to the recording of data onto optical discs, and more particularly to a method for handling buffer under-runs during recording sessions.
2. Description of the Related Art
Optical disc storage of data offers relatively high capacity data storage (e.g., approximately 640 Megabytes) on a relatively small and inexpensive optical disc. Optical disc recording commonly involves recording (sometimes referred to as xe2x80x9cburningxe2x80x9d) several files of data on one or more spiral tracks on a optical disc, which can typically hold between 1 and 99 tracks. A file system (FS) is typically recorded at the beginning of a session and contains addressing information for the files, such as a volume descriptor sequence with address pointers to path tables indicating the file directory structure, and a directory descriptor indicating the file locations and logical block numbers. The volume descriptor sequence by convention (and in compliance with ISO standard 9660) is located in sector 16 (and sectors following sector 16 if needed) of the first track of a recording session. The ISO 9660 Specification (also referred to as the Information Processing-Volume and File Structure of CD-ROM for Information Interchange) is hereby incorporated by reference.
When recording is desired, files of data to be recorded are typically retrieved from a hard disk drive, transferred to a faster access buffer memory, and the files on the buffer memory are continuously recorded onto one or more tracks of an optical disc during a recording session. However, as recording rates for optical discs increase beyond 4xc3x97 (1xc3x97 being defined as normal music playback speed), the rate of recording onto the optical disc frequently exceeds the rate at which the hard drive data source can replenish data in the buffer memory. A buffer under-run occurs when the buffer memory is unable to continuously provide data for an uninterrupted recording of the files to a given track of the optical disc. Eventually, after the buffer under-run occurs, the burn stops. Typically, there is a pre-gap of 150 sectors and a post-gap of 150 sectors for a total gap of 300 sectors (approximately 700 kilobytes) between the end of one track and the beginning of another track. This gap between tracks causes file addressing problems, since the new addresses of the remaining files (which were recorded after the buffer under-run) are not accurately reflected in the FS recorded at the beginning of the session. As such, when a read of a particular file that was recorded after the buffer under-run is desired, the reading will access an incorrect file due to the gap. Furthermore, multiple buffer under-runs can occur during a recording session, depending on the access speed and transfer speed of the data retrieval from the hard drive data source, the size and read/write speed of the buffer memory, and the data transmission rate required for continuously recording data onto the optical disc.
The consequences of one or more buffer under-runs during a recording on an optical disc depend on the type of optical disc used during the recording. A CD-R optical disc can only undergo one recording, and the inaccessible remaining files typically cause the CD-R optical disc to be scrapped and replaced by a fresh CD-R optical disc for a repeated recording. A CD-R/W optical disc can undergo several recordings, since the optical disc can be erased and the recording session can be repeated. However, the repeating recording sessions can take considerable time, especially if the recording is of a large track. Furthermore, regardless of whether the optical disc is CD-R or CD-R/W, another buffer under-run can occur during the repeated recording session, causing the loss of the time spent on the recording session, if not the entire optical disc (in the case of CDR optical discs).
FIG. 1A shows a prior art track 100 on an optical disc resulting from a recording session in which a buffer under-run has occurred. The file system (FS) 102 is recorded at the beginning of the track (which represents the beginning of a session) and then the data 104 recording follows, until stopped by the buffer under-run 106. The dotted lines indicate a missing remainder 108 of the data that would have been recorded in the track 100 if the buffer under-run had not occurred.
FIG. 1B shows a prior art track 100 on an optical disc resulting from a recording session in which a buffer under-run 106 has occurred, and the resulting difference created between a file address and the actual file address as the result of the buffer under-run. The FS 102 is recorded at the beginning of the track, and then the data 104 recording follows, until stopped by the buffer under-run 106. The remainder of the data 108 is recorded in track 2 after the buffer under-run 106. The FS 102, which was recorded before the buffer under-run 106 occurred, points to the address 112 represented as file Nxe2x80x2, shown by dotted lines. The FS 102 address assumes that the file Nxe2x80x2 is located in the first track 100, which is incorrect. The actual address 114 of file N, shown by solid lines, is in the second track 110 as a result of the buffer under-run 106.
Thus, the occurrence of a buffer under-run causes several problems in conventional recording systems. The recording of a track of one or more files is stopped, and a physical gap is created between the original track and a new track of remaining files recorded after the buffer under-run. The addresses of files recorded after a buffer under-run do not correspond to the addresses for the files as indicated by the FS that was recorded before the buffer under-run, because of the gap between the original track and the next track which records the remaining files. Since the addresses of the files recorded after a buffer under-run are incorrect, the entire recording must be repeated on another disc if the disc cannot be erased and rewritten. Otherwise, if the same disc can be erased and rewritten (e.g., CD R/W), the tracks made during the interrupted recording session must be erased and re-recorded. Additional time and cost is required by the duplicate recording session as a result of the buffer under-run in either case.
In view of the foregoing, there is a need for a method that can handle buffer under-runs during a recording session on an optical disc. This method should be configured to avoid the problems of the prior art.
The present invention fills these needs by providing methods that can handle buffer under-runs during a recording session on an optical disc. The invention is a method for maintaining the addressing accuracy of the file system of a recording session, regardless of multiple buffer under-runs that may occur during the recording session. The present invention can be implemented in numerous ways, including as a process, an apparatus, a system, a device, a method, or a computer readable media. Several embodiments of the present invention are described below.
In one embodiment, a method for handling buffer under-runs during the recording of files to an optical disc is disclosed. The method includes reserving a track for recording a file system associated with recording of one or more files on the optical disc. Then, the method moves to record the one or more files onto the optical disc in a track that logically follows the reserved track. In case of a buffer under-run, the method proceeds to close a current track and begin a following track after a gap, thus inserting a gap for each buffer under-run. Path tables and directory descriptors of the file system are then written after recording the one or more files. A volume descriptor sequence of the file system is recorded in the reserved track at a time after recording the path tables and the directory descriptor.
In another embodiment, a method for handling buffer under-run is disclosed. The method includes reserving a track for recording a file system associated with recording of one or more files on an optical disc. After the reserved track, one or more files are recorded on the optical disc in a track that logically follows the reserved track. Path tables and a directory descriptor of the file system are then recorded after recording the one or more files. A volume descriptor sequence of the file system is then recorded in the reserved track at a time after recording the path tables and the directory descriptor. Any buffer under-runs are accounted for by closing a current track and then resuming the recording on a next track.
In yet another embodiment, a computer readable media having program instructions for handling buffer under-runs associated with the recording of one or more data files on a disc is disclosed. The computer readable media includes: (a) program instructions for reserving a track for recording a file system associated with recording of one or more data files on an optical disc; (b) program instructions for recording the one or more data files on the optical disc in a track that logically follows the reserved track; (c) program instructions for closing a track of the recording session upon an occurrence of a buffer under-run; (d) program instructions for recording a continuation of the data files in a next track of the recording session; (e) program instructions for repeating the closing of the next track and the continuation of the recording of the data files upon the occurrence of additional buffer under-runs; (f) program instructions for recording path tables and a directory descriptor for the file system; and (g) program instructions for recording a volume descriptor sequence of the file system in the reserved track at a time after recording the path tables and the directory descriptor.
In still another embodiment, a method for handling buffer under-runs is disclosed. The method includes: (a) reserving a track for recording a file system associated with recording of one or more files on an optical disc; (b) recording the one or more files on the optical disc in a track that logically follows the reserved track; (c) recording the file system except for a volume descriptor sequence after recording the one or more files; and (d) recording the volume descriptor sequence of the file system in the reserved track. In this embodiment, the method further includes: (i) closing a track during the recording of one or more files onto the track when data to be recorded onto the optical disc is unavailable; (ii) recalculating a number of remaining files that were unavailable to recorded; and (iii) resuming the recording of the number of remaining files.
One benefit and advantage of the invention is higher recording throughput of finished and usable optical discs. Another benefit is faster turn-around time for recording a usable optical disc. An additional benefit is the reduction in the cost of scrapping incompletely recorded and unusable optical discs. Yet another benefit is an increased practicality of optical disc recording at a higher recording speed. It should be noted that the benefits buffer under-run handling of the present invention are equally applicable to the ISO 9660 standard, the Joliet CD-ROM Recording Specification, as wells as the Universal Disk Format (UDF) standard, which is a subset of ISO 13346. The Joliet CD-ROM Recording Specification and all UDF standards are hereby incorporated by reference. Of course, other standards that suffer from buffer under-runs may also benefit from the invention claimed herein.
Other advantages of the invention will become apparent from the following detailed description, taken in conjunction with the accompanying drawings, illustrating by way of example the principles of the invention.
USPTO Backgrounds
USPTO Backgrounds