CN-116959506-B - Double-CD seamless connection video recording method based on embedded system
Abstract
The invention relates to the technical field of data storage backup, in particular to a double-optical-disc seamless connection video recording method based on an embedded system. The method comprises the steps of S1, caching video information to be recorded, S2, loading an A disc, S3, recording, S4, periodically detecting the memory duty ratio and adjusting corresponding parameters to corresponding values, S5, continuously recording the B disc, calculating the similarity of the audio information of the A disc, adjusting corresponding operation parameters of a recording unit in the recording process of the B disc to corresponding values according to the similarity, and S6, sending a termination signal to complete the recording. Compared with the prior art, the invention has the beneficial effects that in the process of recording the A disc, the central control unit periodically detects the internal memory duty ratio in the A disc, and adjusts the corresponding parameters to the corresponding values according to the detection result, so that the integrity of recorded data is ensured, and the recording effect is ensured.
Inventors
- MING DE
- ZHU ZHENGHUI
- LI CHANGLV
- Zhan Chuwei
Assignees
- 广东保伦电子股份有限公司
Dates
- Publication Date
- 20260512
- Application Date
- 20230807
Claims (10)
- 1. The method for recording video by double-CD seamless connection based on embedded system is characterized by comprising the following steps: Step S1, a central control unit controls a caching unit to extract and cache stored video information to be recorded from a storage unit; step S2, the central control unit controls the driving unit to load and start the optical disc to be recorded, and marks the optical disc as an A disc; step S3, the central control unit controls the recording unit to record the audio and video information to be recorded in the buffer unit into the disk A; Step S4, the central control unit periodically detects the memory ratio situation of the A disc in the recording process of the recording unit, and judges whether to adjust the operation parameters of corresponding parts in the recording unit to corresponding values according to the detected storage situation, or controls the driving unit to pre-start the B disc and adjust the detection period aiming at the memory ratio of the A disc to corresponding values, wherein the B disc is a spare optical disc of the A disc; Step S5, when the central control unit detects that the storage space in the A disc is insufficient, the recording unit is controlled to continue recording on the B disc so as to complete seamless connection recording of the audio and video information, the central control unit controls the verification unit to calculate the similarity between the recorded audio and video information in the A disc and the audio and video information cached in the cache unit, and the recording unit adjusts the corresponding operation parameters of the recording unit in the recording process of the B disc to corresponding values according to the similarity; And S6, when the recording of the video information to be recorded in the buffer unit is completed, the central control unit sequentially sends a termination signal to the recording unit and the driving unit so that the recording unit can complete the recording of the video to be recorded.
- 2. The method for recording video on a dual-disc seamless connection based on an embedded system according to claim 1, wherein in the step S4, the central control unit periodically detects a memory duty ratio of the a disc, and for the memory duty ratio of the a disc measured in a single time node, the central control unit determines, according to the memory duty ratio, a determination manner whether a storage condition of the a disc meets a preset criterion, including: the first judging mode is that the central control unit judges that the A disc storage condition meets the preset standard and controls the recording unit to maintain the original parameters to continue recording, wherein the first judging mode meets the condition that the memory duty ratio is smaller than or equal to the primary preset memory duty ratio preset in the central control unit; The second judging mode is that the central control unit judges that the A disc storage condition meets a preset standard, and the central control unit judges whether the primary preset memory duty ratio and the secondary preset memory duty ratio are adjusted to corresponding values according to the size of data recorded by the recording unit in a preset time period; the third judging mode is that the central control unit judges that the storage condition of the A disc does not meet a preset standard, the central control unit controls the driving unit to pre-start the B disc and adjusts the detection period aiming at the A disc to a corresponding value according to the difference value between the memory duty ratio in the A disc and the second-level preset memory duty ratio, and the third judging mode meets that the memory duty ratio is larger than the second-level preset memory duty ratio.
- 3. The method for recording video by seamless dual-disc connection based on embedded system according to claim 2, wherein the central control unit calculates a memory duty ratio evaluation value according to the size of the data recorded by the recording unit in the preset duration in the second determination mode, and determines an adjustment mode for the primary preset memory duty ratio and the secondary preset memory duty ratio according to the memory duty ratio evaluation value, wherein: The first adjusting mode is that the central control unit adjusts the first-level preset memory duty ratio to a corresponding value by using a first adjusting coefficient, and adjusts the second-level preset memory duty ratio to a corresponding value by using a second adjusting coefficient; The second adjusting mode is that the central control unit adjusts the first-level preset memory duty ratio to a corresponding value by using a third adjusting coefficient, and adjusts the second-level preset memory duty ratio to a corresponding value by using a fourth adjusting coefficient, and the second adjusting mode meets the condition that the memory duty ratio evaluation value is smaller than the preset memory duty ratio evaluation value.
- 4. The method for recording video by double-CD seamless connection based on embedded system as claimed in claim 3, wherein said central control unit sets memory duty ratio evaluation value R=α×β×L under the first preset condition, wherein α is CD quality influence parameter, β is CD quality influence parameter, L is size of data recorded by recording unit in preset time period; The first preset condition is that the central control unit controls the recording unit to record for a preset duration.
- 5. The method for recording video on a dual-disc seamless joint based on an embedded system according to claim 2, wherein the central control unit records a difference between the memory duty ratio of the a disc and the second preset memory duty ratio as a memory duty ratio difference in the third determination mode, and determines a period adjustment mode for a detection period of the a disc according to the memory duty ratio difference, wherein: the first period adjustment mode is that the central control unit uses a first period adjustment coefficient to adjust the detection period of the A disc to a corresponding value, wherein the first period adjustment mode meets the condition that the memory duty ratio difference value is smaller than a one-level preset memory duty ratio difference value preset in the central control unit; The second period adjustment mode is that the central control unit uses a second period adjustment coefficient to adjust the detection period of the A disc to a corresponding value, and the second period adjustment mode meets the condition that the memory duty ratio difference is larger than or equal to the primary preset memory duty ratio difference and smaller than or equal to a secondary preset memory duty ratio difference preset in the central control unit, and the secondary preset memory duty ratio difference is larger than the primary preset memory duty ratio difference; And the third period adjusting mode is that the central control unit adjusts the detection period of the A disc to a corresponding value by using a third period adjusting coefficient, and the third period adjusting mode meets the condition that the memory duty ratio difference value is larger than the second-level preset memory duty ratio difference value.
- 6. The method for recording video by seamless dual-disc connection based on embedded system according to claim 5, wherein the central control unit controls the verification unit to calculate the similarity between the recorded audio and video information in the a disc and the corresponding information in the audio and video information cached in the cache unit under a second preset condition, and determines a speed adjustment mode for the recording speed of the B disc data according to the similarity, wherein: The first speed adjusting mode is that the central control unit adjusts the data recording speed of the recording unit aiming at the B disc to a corresponding value by using a first speed adjusting coefficient, wherein the first speed adjusting mode meets the condition that the similarity is smaller than one-level preset similarity preset in the central control unit; the second speed adjusting mode is that the central control unit adjusts the data recording speed to a corresponding value by using a second speed adjusting coefficient, wherein the second speed adjusting mode meets the condition that the similarity is larger than or equal to the first-level preset similarity and smaller than or equal to the second-level preset similarity preset in the central control unit, and the second-level preset similarity is larger than the first-level preset similarity; the third speed adjusting mode is that the central control unit adjusts the data recording speed to a corresponding value by using a third speed adjusting coefficient, wherein the third speed adjusting mode meets the condition that the similarity is larger than the second-level preset similarity; And the second preset condition is that the central control unit judges that the memory duty ratio in the disk A reaches the critical duty ratio preset in the central control unit, and the central control unit controls the recording unit to continue recording on the disk B.
- 7. The method for recording video on a dual-disc seamless connection based on an embedded system according to claim 6, wherein the central control unit periodically detects the memory duty ratio in the B disc and marks it as a second memory duty ratio under a third preset condition, and the central control unit determines a secondary decision mode for determining whether the memory space in the B disc meets a preset standard according to the second memory duty ratio, wherein: The first secondary judgment mode is that the central control unit judges that the storage space of the B disc does not meet a preset standard, and the central control unit calculates the ratio of the data size of the audio and video information recorded on the optical disc to the data size of the audio and video information cached in the caching unit to determine whether the B disc can completely record the audio and video information cached in the caching unit; The second-level judging and determining mode is that the central control unit judges that the B disk storage space meets a preset standard, keeps the operation parameters unchanged and continues to record; And the third preset condition is that the central control unit completes the adjustment of the recording speed of the B disc data.
- 8. The method for recording video by seamless dual-disc system according to claim 7, wherein the central control unit calculates the ratio of recorded audio/video information to the audio/video information buffered in the buffer unit in the first secondary judgment mode and records the ratio as a finalization ratio, and determines whether the B disc can completely record the audio/video information buffered in the buffer unit according to the finalization ratio, wherein: The first judgment mode is that the central control unit judges that the B disc can finish the recording of the rest audio and video information, and the central control unit controls the recording unit to keep relevant parameters unchanged and continue the recording; The second judging mode is that the central control unit judges that the audio and video information cached in all the caching units can be carved down by the B disc, and the central control unit adjusts the critical duty ratio for the B disc to a corresponding value according to the difference value between the primary preset finish ratio and the finish ratio; The third judging mode is that the central control unit judges that the B disc can not completely inscribe the audio and video information cached in the caching unit, the central control unit controls the driving unit to pre-start the C disc, adjusts the detection period to a corresponding value and continuously detects the memory duty ratio of the B disc, the third judging mode meets the condition that the completion ratio is smaller than the second-level preset completion ratio, and the C disc is a standby optical disc of the B disc.
- 9. The method for recording video on a dual-disc seamless joint based on an embedded system according to claim 8, wherein the central control unit marks a difference between the first-level preset finalization ratio and the finalization ratio as a finalization difference in the second judgment mode, and determines an adjustment mode for the critical duty ratio of the B disc according to the finalization difference, wherein: The first critical duty ratio adjusting mode is that the unit adjusts the critical duty ratio of the B disc to a corresponding value by using a first duty ratio adjusting coefficient, wherein the first critical duty ratio adjusting mode meets the condition that the completion degree difference is smaller than a first-level preset completion degree difference preset in the central control unit; The second critical duty ratio adjusting mode is that the unit adjusts the critical duty ratio of the B disc to a corresponding value by using a second duty ratio adjusting coefficient, wherein the second critical duty ratio adjusting mode meets the condition that the completion degree difference is larger than or equal to the first-level preset completion degree difference and smaller than or equal to the second-level preset completion degree difference preset in the central control unit, and the second-level preset completion degree difference is larger than the first-level preset completion degree difference; And the third critical duty ratio adjusting mode is that the unit adjusts the critical duty ratio of the B disc to a corresponding value by using a third duty ratio adjusting coefficient, and the third critical duty ratio adjusting mode meets the condition that the completion degree difference is larger than the second-level preset completion degree difference.
- 10. The method for recording and playing video on dual-disc seamless connection based on embedded system as recited in claim 9, wherein the critical duty ratio of the B disc is adjusted to the maximum value of the memory, and the audio and video information cached in all the caching units is still not recorded, and the central control unit controls the driving unit to pre-start the C disc and adjust the detection period to the corresponding value, and continuously detects the memory duty ratio of the B disc.
Description
Double-CD seamless connection video recording method based on embedded system Technical Field The invention relates to the technical field of data storage backup, in particular to a double-optical-disc seamless connection video recording method based on an embedded system. Background The content of the optical disc is required to be consistent when the dual optical discs are recorded at the same time, once the recording error retries and cannot be recovered or the optical disc is damaged, a new optical disc is replaced and recorded again from the recording starting time point of the optical disc with the recording error, so that the content of the optical disc is ensured to be consistent after the optical disc is normally recorded, and the mechanism of retrying the recording can lead to the waste of resources. The Chinese patent publication No. 201210201556.8 discloses a control device for synchronously recording double optical discs, which comprises a video coding module, a video recording module and a recording module, wherein the video coding module is used for coding audio and video, the video recording module is used for writing an audio and video code stream into a hard disc for storage, the recording module is used for recording recorded images onto at least two optical discs, wherein the recorded images in one optical disc consist of a plurality of recorded images, the audio and video images correspond to the audio and video code stream, and the recording and separating module is used for separating discs of the audio and video code stream according to configuration parameters, so that the control device for synchronously recording the double optical discs has the following problems that only seamless connection of audio information can be ensured, and the quality of the recorded audio information cannot be ensured. Disclosure of Invention Therefore, the invention provides a double-CD seamless connection video recording method based on an embedded system, which is used for solving the problems that in the prior art, only the seamless connection of audio information can be ensured and the quality of the audio information under the recording can not be ensured. In order to achieve the above purpose, the present invention provides a method for recording video by double-optical-disc seamless connection based on an embedded system. Comprising the following steps: Step S1, a central control unit controls a caching unit to extract and cache stored video information to be recorded from a storage unit; step S2, the central control unit controls the driving unit to load and start the optical disc to be recorded, and marks the optical disc as an A disc; step S3, the central control unit controls the recording unit to record the audio and video information to be recorded in the buffer unit into the disk A; Step S4, the central control unit periodically detects the memory ratio situation of the A disc in the recording process of the recording unit, and judges whether to adjust the operation parameters of corresponding parts in the recording unit to corresponding values according to the detected storage situation, or controls the driving unit to pre-start the B disc and adjust the detection period aiming at the memory ratio of the A disc to corresponding values, wherein the B disc is a spare optical disc of the A disc; Step S5, when the central control unit detects that the storage space in the A disc is insufficient, the recording unit is controlled to continue recording on the B disc so as to complete seamless connection recording of the audio and video information, the central control unit controls the verification unit to calculate the similarity between the recorded audio and video information in the A disc and the audio and video information cached in the cache unit, and the recording unit adjusts the corresponding operation parameters of the recording unit in the recording process of the B disc to corresponding values according to the similarity; And S6, when the recording of the video information to be recorded in the buffer unit is completed, the central control unit sequentially sends a termination signal to the recording unit and the driving unit so that the recording unit can complete the recording of the video to be recorded. Further, in the step S4, the central control unit periodically detects the memory duty ratio of the a disc, and for the memory duty ratio of the a disc measured in a single time node, the central control unit determines, according to the memory duty ratio, a determination manner whether the storage condition of the a disc meets a preset standard, including: the first judging mode is that the central control unit judges that the A disc storage condition meets the preset standard and controls the recording unit to maintain the original parameters to continue recording, wherein the first judging mode meets the condition that the memory duty ratio is smaller than or equal to the pri