Optical disk storage additional recording method and system

文档序号:880246 发布日期:2021-03-19 浏览:14次 中文

阅读说明:本技术 一种光盘存储追加刻录方法及系统 (Optical disk storage additional recording method and system ) 是由 张理 由伟希 白世杰 宁萌 于 2019-10-08 设计创作,主要内容包括:本发明公开一种光盘存储追加刻录方法及系统,所述方法包括获取刻录数据;根据所述刻录数据确定待刻录数据;根据所述待刻录数据确定待刻录光盘光轨;将所述待刻录数据刻录所述待刻录光盘光轨,确定已刻录数据光轨;判断所述已刻录数据光轨有没有完成所述待刻录数据的刻录。如果刻录成功则进行下一刻录数据的刻录,如果刻录失败则重新对所述刻录数据进行刻录。本发明所提供的一种光盘存储追加刻录方法及系统,解决现有技术中光盘文件刻录的实时性差和文件内容丢失的问题。(The invention discloses a method and a system for additionally recording an optical disk storage, wherein the method comprises the steps of obtaining recording data; determining data to be recorded according to the recording data; determining an optical track of the optical disc to be recorded according to the data to be recorded; recording the data to be recorded on the optical track of the optical disc to be recorded, and determining the recorded data optical track; and judging whether the recorded data optical track finishes recording the data to be recorded. If the recording is successful, the next recording data is recorded, and if the recording is failed, the recording data is recorded again. The invention provides a method and a system for additionally recording an optical disk storage, which solve the problems of poor real-time performance of recording an optical disk file and loss of file content in the prior art.)

1. An optical disc storage additional recording method, comprising:

acquiring recording data;

determining data to be recorded according to the recording data; the data to be recorded comprises recording data identification, recording data, ending identification and the capacity of the data to be recorded; the recording data identification is used for identifying the data to be recorded; the end mark is used for identifying the completion of the burning of the data to be burnt;

determining an optical track of the optical disc to be recorded according to the data to be recorded;

recording the data to be recorded on the optical track of the optical disc to be recorded, and determining the recorded data optical track;

judging whether the recorded data optical track finishes recording the data to be recorded or not to obtain a first judgment result;

when the first judgment result shows that the recorded data optical track finishes recording of the data to be recorded, determining that the data to be recorded has been recorded into the optical track of the optical disc to be recorded, and recording successfully; returning to the step of obtaining the burning data and continuing to burn the next data;

when the first judgment result shows that the optical track of the recorded data does not finish recording the data to be recorded, determining that the optical track of the optical disk to be recorded is not recorded by the data to be recorded, and recording fails; returning to the step of determining the optical track of the optical disc with capacity to be recorded according to the data to be recorded, reacquiring the optical track of the optical disc to be recorded, and recording the data to be recorded again.

2. The method of claim 1, wherein determining the track of the optical disc to be written according to the data to be written comprises:

acquiring the end position of the last recorded data optical track;

determining the initial position of the recording data optical track according to the end position of the last recording data optical track and the recording data identification;

determining the end position of the recording data optical track according to the initial position of the recording data optical track and the capacity of the data to be recorded;

and determining the optical track of the optical disc to be recorded according to the initial position of the recorded data optical track and the end position of the recorded data optical track.

3. A method of claim 1, wherein said determining whether the recording of the data to be recorded has been completed on the recorded data track to obtain a first determination result includes:

acquiring recorded data of the recorded data optical track;

and judging whether the recorded data optical track completes recording of the data to be recorded according to the recorded data of the recorded data optical track to obtain a first judgment result.

4. The method of claim 1, wherein when the first determination result indicates that the recording of the data to be recorded has not been completed in the recorded data track, determining that the data to be recorded has not been recorded in the recorded data track, and after the recording fails, further comprising:

and performing zero data completion on the optical track of the optical disc to be recorded which fails to be recorded.

5. An optical disc storage write-once recording system, comprising:

the recording data acquisition module is used for acquiring recording data;

the data to be recorded determining module is used for determining data to be recorded according to the recording data; the data to be recorded comprises recording data identification, recording data, ending identification and the capacity of the data to be recorded; the recording data identification is used for identifying the data to be recorded; the end mark is used for identifying the completion of the burning of the data to be burnt;

a to-be-recorded optical disc optical track determining module, configured to determine an optical track of an optical disc to be recorded according to the to-be-recorded data;

a recorded data optical track determining module, configured to record the data to be recorded into the optical track of the optical disc to be recorded, and determine a recorded data optical track;

the first judging module is used for judging whether the recorded data optical track finishes recording the data to be recorded or not to obtain a first judging result;

the next data recording module, when the first judgment result shows that the recorded data optical track finishes the recording of the data to be recorded, determines that the data to be recorded has been recorded into the optical track of the optical disc to be recorded, and the recording is successful; returning to the step of obtaining the burning data and continuing to burn the next data;

a re-recording module, configured to determine that the data to be recorded is not recorded on the optical track of the optical disc to be recorded and the recording fails when the first determination result indicates that the optical track of the recorded data is not recorded on the optical track of the data to be recorded; returning to the step of determining the optical track of the optical disc with capacity to be recorded according to the data to be recorded, reacquiring the optical track of the optical disc to be recorded, and recording the data to be recorded again.

6. The system of claim 5, wherein the module for determining the track of the optical disc to be written specifically comprises:

an end position obtaining unit of the last recorded data optical track, configured to obtain an end position of the last recorded data optical track;

a start position determining unit for recording the data optical track, configured to determine a start position of the recording data optical track according to the end position of the last recording data optical track and the recording data identifier;

and the end position determining unit is used for determining the end position of the data recording optical track according to the initial position of the data recording optical track and the capacity of the data to be recorded.

7. The system of claim 1, wherein the first determining module further comprises:

a data acquisition unit for recording the recorded data optical track, configured to acquire recorded data of the recorded data optical track;

a first determining unit, configured to determine whether the recorded data track completes recording of the data to be recorded according to the recorded data of the recorded data track, so as to obtain a first determination result.

8. An optical disc storage additionally recording system according to claim 1, further comprising:

and the zero data completion module is used for performing zero data completion on the optical track of the optical disc to be recorded, which fails to be recorded.

Technical Field

The present invention relates to the field of optical disc recording, and in particular, to a method and system for additionally recording an optical disc storage.

Background

With the continuous development of streaming media technology, how to record streaming media files on an optical disc for multiple times becomes an urgent problem to be solved.

For a write-once optical disc, a conventional optical disc recording method is to pack a file to be recorded first to generate a mirror image file, that is, to generate a mirror image file in a UDF (Universal disk format) format from a file in a hard disk according to a standard of a UDF file system, to record the mirror image file in the hard disk or a memory, and then to sequentially read the mirror image file from the hard disk or the memory and record the mirror image file in the optical disc.

The conventional recording method requires that the buffered file is written into the optical disc once when recording is started. That is, after the available capacity of an optical disc is reached, the files and the metadata are written into the optical disc until all the files and the metadata are written into the optical disc, which results in untimely recording of the files, and when the recording of the files fails, the whole optical disc is invalidated, and the recorded content of the optical disc is also invalidated, thereby resulting in the loss of the content of the files.

Disclosure of Invention

The invention aims to provide a method and a system for additionally recording an optical disk storage, which solve the problems of poor real-time performance of recording an optical disk file and loss of file content in the prior art.

In order to achieve the purpose, the invention provides the following scheme:

an optical disc storage additional recording method includes:

acquiring recording data;

determining data to be recorded according to the recording data; the data to be recorded comprises recording data identification, recording data, ending identification and the capacity of the data to be recorded; the recording data identification is used for identifying the data to be recorded; the end mark is used for identifying the completion of the burning of the data to be burnt;

determining an optical track of the optical disc to be recorded according to the data to be recorded;

recording the data to be recorded on the optical track of the optical disc to be recorded, and determining the recorded data optical track;

judging whether the recorded data optical track finishes recording the data to be recorded or not to obtain a first judgment result;

when the first judgment result shows that the recorded data optical track finishes recording of the data to be recorded, determining that the data to be recorded has been recorded into the optical track of the optical disc to be recorded, and recording successfully; returning to the step of obtaining the burning data and continuing to burn the next data;

when the first judgment result shows that the optical track of the recorded data does not finish recording the data to be recorded, determining that the optical track of the optical disk to be recorded is not recorded by the data to be recorded, and recording fails; returning to the step of determining the optical track of the optical disc with capacity to be recorded according to the data to be recorded, reacquiring the optical track of the optical disc to be recorded, and recording the data to be recorded again.

Optionally, the determining, according to the data to be recorded, an optical track of the optical disc to be recorded specifically includes:

acquiring the end position of the last recorded data optical track;

determining the initial position of the recording data optical track according to the end position of the last recording data optical track and the recording data identification;

determining the end position of the recording data optical track according to the initial position of the recording data optical track and the capacity of the data to be recorded;

and determining the optical track of the optical disc to be recorded according to the initial position of the recorded data optical track and the end position of the recorded data optical track.

Optionally, the determining whether the recording of the data to be recorded has been completed on the recorded data track to obtain a first determination result specifically includes:

acquiring recorded data of the recorded data optical track;

and judging whether the recorded data optical track completes recording of the data to be recorded according to the recorded data of the recorded data optical track to obtain a first judgment result.

Optionally, when the first determination result indicates that the recording of the to-be-recorded data is not completed by the recorded data optical track, it is determined that the to-be-recorded data is not recorded by the to-be-recorded optical track, and after the recording fails, the method further includes:

and performing zero data completion on the optical track of the optical disc to be recorded which fails to be recorded.

An optical disc storage write-once recording system, comprising:

the recording data acquisition module is used for acquiring recording data;

the data to be recorded determining module is used for determining data to be recorded according to the recording data; the data to be recorded comprises recording data identification, recording data, ending identification and the capacity of the data to be recorded; the recording data identification is used for identifying the data to be recorded; the end mark is used for identifying the completion of the burning of the data to be burnt;

a to-be-recorded optical disc optical track determining module, configured to determine an optical track of an optical disc to be recorded according to the to-be-recorded data;

a recorded data optical track determining module, configured to record the data to be recorded into the optical track of the optical disc to be recorded, and determine a recorded data optical track;

the first judging module is used for judging whether the recorded data optical track finishes recording the data to be recorded or not to obtain a first judging result;

the next data recording module, when the first judgment result shows that the recorded data optical track finishes the recording of the data to be recorded, determines that the data to be recorded has been recorded into the optical track of the optical disc to be recorded, and the recording is successful; returning to the step of obtaining the burning data and continuing to burn the next data;

a re-recording module, configured to determine that the data to be recorded is not recorded on the optical track of the optical disc to be recorded and the recording fails when the first determination result indicates that the optical track of the recorded data is not recorded on the optical track of the data to be recorded; returning to the step of determining the optical track of the optical disc with capacity to be recorded according to the data to be recorded, reacquiring the optical track of the optical disc to be recorded, and recording the data to be recorded again.

Optionally, the module for determining an optical track of an optical disc to be recorded specifically includes:

an end position obtaining unit of the last recorded data optical track, configured to obtain an end position of the last recorded data optical track;

a start position determining unit for recording the data optical track, configured to determine a start position of the recording data optical track according to the end position of the last recording data optical track and the recording data identifier;

an end position determining unit for recording the data optical track, configured to determine an end position of the recording data optical track according to the start position of the recording data optical track and the capacity of the data to be recorded;

optionally, the first determining module specifically includes:

a data acquisition unit for recording the recorded data optical track, configured to acquire recorded data of the recorded data optical track;

a first determining unit, configured to determine whether the recorded data track completes recording of the data to be recorded according to the recorded data of the recorded data track, so as to obtain a first determination result.

Optionally, the method further includes:

and the zero data completion module is used for performing zero data completion on the optical track of the optical disc to be recorded, which fails to be recorded.

According to the specific embodiment provided by the invention, the invention discloses the following technical effects: the method and the system for additionally recording the optical disk storage solve the problem that data is recorded only after a file reaches the available capacity of one optical disk by continuously additionally recording the recorded data on the optical disk, ensure the real-time performance of the data, and can continuously record the data after the recording of the recorded data fails so as to prevent the file from being lost, ensure the safety of recording the file and prevent the waste of the optical disk.

Drawings

In order to more clearly illustrate the embodiments of the present invention or the technical solutions in the prior art, the drawings needed to be used in the embodiments will be briefly described below, and it is obvious that the drawings in the following description are only some embodiments of the present invention, and it is obvious for those skilled in the art to obtain other drawings without inventive exercise.

FIG. 1 is a flowchart of a method for additionally recording an optical disc storage according to the present invention;

FIG. 2 is a flowchart of an optical disc storage additional recording system according to the present invention.

Description of the drawings: 201-recording data obtaining module, 202-data to be recorded determining module, 203-optical track determining module of optical disc to be recorded, 204-recorded data optical track determining module, 205-first judging module, 206-next data recording module, 207-recording module again.

Detailed Description

The technical solutions in the embodiments of the present invention will be clearly and completely described below with reference to the drawings in the embodiments of the present invention, and it is obvious that the described embodiments are only a part of the embodiments of the present invention, and not all of the embodiments. All other embodiments, which can be derived by a person skilled in the art from the embodiments given herein without making any creative effort, shall fall within the protection scope of the present invention.

The invention aims to provide a method and a system for additionally recording an optical disk storage, which solve the problems of poor real-time performance of recording an optical disk file and loss of file content in the prior art.

In order to make the aforementioned objects, features and advantages of the present invention comprehensible, embodiments accompanied with figures are described in further detail below.

Fig. 1 is a flowchart of a method for additionally recording an optical disc storage according to the present invention, and as shown in fig. 1, the method for additionally recording an optical disc storage includes:

s101, recording data is obtained.

S102, determining data to be recorded according to the recording data; the data to be recorded comprises recording data identification, recording data, ending identification and the capacity of the data to be recorded; the recording data identification is used for identifying the data to be recorded; the end mark is used for identifying the completion of the burning of the data to be burnt;

s103, determining the optical track of the optical disc to be recorded according to the data to be recorded.

S104, recording the data to be recorded on the optical track of the optical disc to be recorded, and determining the recorded data optical track;

s105, judging whether the recorded data optical track completes the recording of the data to be recorded, and obtaining a first judgment result.

S106, when the first judgment result shows that the recorded data optical track finishes recording the data to be recorded, determining that the data to be recorded has been recorded into the optical track of the optical disc to be recorded, and recording successfully; returning to the step of obtaining the recording data and continuing recording the next data.

S107, when the first judgment result shows that the optical track of the recorded data does not finish the recording of the data to be recorded, determining that the optical track of the optical disc to be recorded is not recorded by the data to be recorded, and failing to record; returning to the step of determining the optical track of the optical disc with capacity to be recorded according to the data to be recorded, reacquiring the optical track of the optical disc to be recorded, and recording the data to be recorded again.

In S103, the determining the optical track of the optical disc to be recorded according to the data to be recorded specifically includes:

and acquiring the end position of the last recorded data optical track.

Determining the initial position of the recording data optical track according to the end position of the last recording data optical track and the recording data identification;

determining the end position of the recording data optical track according to the initial position of the recording data optical track and the capacity of the data to be recorded;

and determining the optical track of the optical disc to be recorded according to the initial position of the recorded data optical track and the end position of the recorded data optical track.

Specifically, the optical track of the optical disc to be recorded is determined according to the data to be recorded, and the recorded data is isolated through the optical track of the optical disc.

The judging whether the recording of the data to be recorded is completed or not by the recorded data optical track to obtain a first judgment result specifically comprises:

and acquiring the recorded data of the recorded data optical track.

And judging whether the recorded data optical track completes recording of the data to be recorded according to the recorded data of the recorded data optical track to obtain a first judgment result.

In a specific embodiment, if the recorded data in the recorded data track has the end identifier, the recorded data track is successful in recording the data to be recorded. If the recorded data of the recorded data optical track does not have the end mark, the recorded data optical track does not successfully record the data to be recorded.

Further, when the first determination result indicates that the recording of the data to be recorded is not completed by the recorded data track, it is determined that the data to be recorded is not recorded by the recorded data track, and after the recording fails, the method further includes: and performing zero data completion on the optical track of the optical disc to be recorded which fails to be recorded.

The method for additionally recording the optical disc storage can continue to additionally record after recording data once successfully, thereby not only ensuring the real-time performance of data recording, but also improving the utilization rate of the optical disc space. After the recording of the once recorded data fails, the optical track of the optical disc is re-determined to record the recorded data, so that the recorded data is prevented from being lost, and the waste of the whole optical disc space caused by the recording failure of the once recorded data is prevented.

Fig. 2 is a flowchart of an optical disc storage write-once system according to the present invention, and the optical disc storage write-once system shown in fig. 2 includes: a recording data obtaining module 201, a to-be-recorded data determining module 202, a to-be-recorded optical disc track determining module 203, a recorded data track determining module 204, a first determining module 205, a next data recording module 206, and a re-recording module 207.

The recording data obtaining module 201 is configured to obtain recording data.

The data to be recorded determining module 202 is configured to determine data to be recorded according to the recording data; the data to be recorded comprises recording data identification, recording data, ending identification and the capacity of the data to be recorded; the recording data identification is used for identifying the data to be recorded; and the end mark is used for identifying the completion of the burning of the data to be burnt.

The optical track determining module 203 for determining the optical track of the optical disc to be recorded according to the data to be recorded.

The recorded data track determining module 204 is configured to record the data to be recorded on the optical track of the optical disc to be recorded, and determine the recorded data track.

The first determining module 205 is configured to determine whether the recorded data track has completed recording the data to be recorded, so as to obtain a first determining result.

When the first judgment result indicates that the optical track of the recorded data completes recording of the data to be recorded, the next data recording module 206 determines that the optical track of the optical disc to be recorded is recorded with the data to be recorded, and the recording is successful; returning to the step of obtaining the recording data and continuing recording the next data.

The re-recording module 207 is configured to determine that the data to be recorded is not recorded in the optical track of the optical disc to be recorded and the recording fails when the first determination result indicates that the optical track of the recorded data is not recorded in the data to be recorded; returning to the step of determining the optical track of the optical disc with capacity to be recorded according to the data to be recorded, reacquiring the optical track of the optical disc to be recorded, and recording the data to be recorded again.

The optical track determining module 203 for the optical disc to be recorded specifically includes: an end position obtaining unit of the last data recording optical track, an initial position determining unit of the data recording optical track, an end position determining unit of the data recording optical track and an optical track determining unit of the optical disk to be recorded.

And the end position acquisition unit of the last recorded data optical track is used for acquiring the end position of the last recorded data optical track.

And the initial position determining unit is used for determining the initial position of the recording data optical track according to the end position of the last recording data optical track and the recording data identification.

And the end position determining unit is used for determining the end position of the data recording optical track according to the initial position of the data recording optical track and the capacity of the data to be recorded.

And the optical track determining unit of the optical disc to be recorded is used for determining the optical track of the optical disc to be recorded according to the initial position of the recording data optical track and the end position of the recording data optical track.

The first determining module 205 specifically includes: a data obtaining unit for recording the data track and a first judging unit.

And the data acquisition unit for recording the data optical track is used for acquiring the recorded data of the recorded data optical track.

A first determining unit, configured to determine whether the recorded data track completes recording of the data to be recorded according to the recorded data of the recorded data track, so as to obtain a first determination result.

The invention provides a system for additionally recording optical disc storage, which further comprises: and a zero data completion module.

The zero data padding module is used for performing zero data padding on the optical track of the optical disc to be burned, which fails to be burned.

The embodiments in the present description are described in a progressive manner, each embodiment focuses on differences from other embodiments, and the same and similar parts among the embodiments are referred to each other. For the system disclosed by the embodiment, the description is relatively simple because the system corresponds to the method disclosed by the embodiment, and the relevant points can be referred to the method part for description.

The principles and embodiments of the present invention have been described herein using specific examples, which are provided only to help understand the method and the core concept of the present invention; meanwhile, for a person skilled in the art, according to the idea of the present invention, the specific embodiments and the application range may be changed. In view of the above, the present disclosure should not be construed as limiting the invention.

10页详细技术资料下载
上一篇:一种医用注射器针头装配设备
下一篇:一种全自动光盘存储装置

网友询问留言

已有0条留言

还没有人留言评论。精彩留言会获得点赞!

精彩留言,会给你点赞!