The technical field of this invention is dynamic control of the sizes of the track buffers that interface with connected storage devices on real-time system.
In a system that simultaneously processes video and audio data in real time such as a DVD/HDD hybrid recorder, a temporary memory called a track buffer is allocated between the storage devices and the system main processor. There are two track buffers: a reading track buffer; and a writing track buffer. The reading-track buffer stores data transferred from storage devices such as ATA/ATAPI. The writing track buffer stores data to be transferred to these devices. These track buffers store the data from/to the storage devices so that the system does not break down if a storage device generates a long waiting time when the system cannot access the storage device. A longer waiting time needs a larger track buffer.
In current consumer DVD/HDD hybrid recording systems, the interfaces between the main processor and the storage devices are constructed one-to-one (called dual-bus solution) in order to avoid system break down. Additionally, the dual-bus solution provides easy architecture design. The sizes of the track buffers are fixed by specification of the storage devices connected to the system.
Taking this into consideration, the trend is to a single interface architecture (called single-bus solution) for dual storage devices.
In the single-bus solution, data communication to any storage devices is affected by the performance of other connected storage devices because multiple storage devices share one system interface 147. If this interference occurs during recording, the amount of data stored in write track buffer grows larger. On the other hand, if it occurs during playback, the amount of data stored in read track buffer becomes smaller. In both cases the system risks track buffer breakdown. Therefore, just as for the dual-bus solution, a large track buffer is needed to avoid system breakdown.
A large track buffer provides high robustness of system performance. This permits stable and continuous data communication for both recording and playback. A large track buffer also causes proportional delay on simultaneous recording and playback on a hard disk drive (HDD3). The larger the track buffer, the greater the delay time. This phenomenon may is weak point for system real-time performance in a DVD/HDD hybrid recording system. On the contrary, a small size track buffer provides us enough memory area for other usages. However selecting large track buffers creates long waiting time and data communication is impossible during the waiting time. Too long waiting time causes system breakdown.
For general storage devices such as ATA/ATAPI, only specific commands and the transitions generate a long waiting time during which data communication with the storage device is impossible. Once the amount of data stored in a write track buffer reaches its maximum or the amount of data stored in read track buffer reaches its minimum, system breakdown occurs. However, stored data in the track buffers seldom reaches both these limitation values even for simultaneous recording and playback. The track buffers have redundant area for most cases. Thus size optimization of the track buffers is possible if the specific cases and the state transitions that generate long wait times are addressed. In spite of this, no prior method dynamically controls the size of the track buffer because of incomplete comprehension of the performance of the storage devices.
This invention controls a system that simultaneously processes video and audio data in real time having read and write track buffers. The invention detects a specific state at one of the storage devices that generates a long delay for communication. Upon this detection, the invention dynamically allocating a fixed amount of memory to read and write track buffers. The storage devices include a first storage device having a long delay caused by mechanical performance, such as a DVD read/write drive and a second storage device not having a long delay caused by mechanical performance such as a hard disk drive.
On detecting insertion of a DVD into a DVD drive for playback, this invention increases the size of the write track buffer and decreases the size of the read track buffer. Following a read initiation interval at the DVD drive, the invention transfers data in the write track buffer to the hard disk drive. The invention re-allocates the memory to the read and write track buffers in fixed initialization amounts thereafter.
On detecting insertion of a DVD into a DVD drive for recording, this invention increases the size of the read track buffer and decreases the size of the write track buffer. Following a record initiation interval at the DVD drive, the invention transfers data in the read track buffer to the DVD drive. The invention re-allocates the memory to the read and write track buffers in fixed initialization amounts thereafter.
These and other aspects of this invention are illustrated in the drawings, in which:
In this invention, the host processor dynamically controls the size of the read and write interface buffers. This permits effective use of a single bus architecture for dual storage devices on a real-time system. The host processor dynamically controls the size of the read and write track buffers in the specific cases that result in a long waiting time during which the system cannot communicate with the storage devices.
This invention is useful in a real-time system having both a DVD drive and a HDD. These specific cases are limited to these initial sequences:
The case that generates the longest waiting time is the initial sequence of reading for DVD playback, especially for a defective disc. As the spindle rotation speed of the DVD drive changes throughout this initial sequence, the host processor stalls data communication to the drive to stabilize of the rotation speed and data detection. This takes around 4 seconds for normal discs and around 6 seconds for defective discs. Data communication with the storage device is impossible for this time. The host processor has to store up to 6 seconds of data for playback or recording in a track buffer.
Next process 400 changes the track buffer allocations (processing block 405). Host processor 310 decreases the size of the reading track buffer for the DVD to just enough for the initial sequence such as the first MKB detection. Host processor 319 allocates the freed memory to the write track buffer for the hard disk drive. This allocation prevents system breakdown caused bus occupancy due to the first MKB process if several storage devices are connected to a single ATA/ATAPI bus. Host processor 310 then starts the initial sequence mentioned for reading the DVD (processing block 406).
Process 400 tests to determine if the initial DVD drive reading initialization sequence is complete (decision block 407). Process 400 repeats this test if the DVD drive reading initialization sequence is not complete (No at decision block 407). Eventually the DVD read initialization sequence finishes (Yes at decision block 407). Host processor 310 restores the DVD read track buffer to its initial size and also reduces the size of the hard disk drive write track buffer by transferring data to the hard disk drive (processing block 408). This completes the track buffer reallocation (exit block 409).
a,
5
b and 5c illustrate the buffer allocations between write track buffer 330w and read track buffer 330r during process 400.
Process 500 begins at start block 501. Process 500 first tests to determine if a DVD is inserted into the DVD drive for recording (decision block 502). If this is not the case (No at decision block 502), the process 500 is inapplicable and ends (exit block 503). If a DVD disk is inserted for recording (Yes at decision block 502), then process 500 increases the size of the read track buffer for the hard disk drive (processing block 505). This enables reading enough data from the hard disk drive to maintain smooth playback until the optical calibration finishes in approximately 7 seconds. Process 500 then reads data to the hard drive (processing block 505) and starts the DVD optical laser power calibration for recording (processing block 506).
Process 500 then tests to determine if the optical laser power calibration is complete (decision block 507). If not (No at processing block 507), then process 500 continues the test. After the optical laser power calibration completes (Yes at decision block 507), host processor 310 increases the size of the write track buffer to prepare for writing to the DVD (processing block 508). Because another 7 seconds waiting occurs, an amount of memory area is equivalent to 7 seconds is necessary.
Process 500 then checks to determine if DVD initial recording has begun (decision block 509). If not (No at processing block 509), then process 500 continues the test. After the first DVD recording begins (Yes at decision block 509), host processor 311 reduces the sizes of both the read track buffer and the write track to their values before this initial DVD write sequence (processing block 510). With this return to normal, process 500 ends (exit block 511).
a,
7
b and 7c illustrate the buffer allocations between write track buffer 330w and read track buffer 330r during process 500.
This invention teaches it is not necessary to provide a very large track buffer that includes redundant area. This invention reduces the redundant buffering area that is only used for specific cases such as disc insertion or the first reading or writing process. With the total track buffer size fixed, the host processor controls the amounts allocated to reading and writing. This method will be particularly effective in a system with a single ATA/ATAPI bus architecture.
This application claims priority under 35 U.S.C. 119(e)(1) from U.S. Provisional Patent Application No. 60/466,969 filed May 1, 2003.
Number | Date | Country | |
---|---|---|---|
60466969 | May 2003 | US |