CN105653385A - Vehicle-loaded videorecording method - Google Patents

Vehicle-loaded videorecording method Download PDF

Info

Publication number
CN105653385A
CN105653385A CN201511028772.7A CN201511028772A CN105653385A CN 105653385 A CN105653385 A CN 105653385A CN 201511028772 A CN201511028772 A CN 201511028772A CN 105653385 A CN105653385 A CN 105653385A
Authority
CN
China
Prior art keywords
file
information
videorecording
video
head
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Granted
Application number
CN201511028772.7A
Other languages
Chinese (zh)
Other versions
CN105653385B (en
Inventor
王为
缑家瑞
吕鸣珂
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Shenzhen Emperor Technology Co Ltd
Original Assignee
SHENZHEN LANTAIYUAN INFORMATION TECHNOLOGY Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by SHENZHEN LANTAIYUAN INFORMATION TECHNOLOGY Co Ltd filed Critical SHENZHEN LANTAIYUAN INFORMATION TECHNOLOGY Co Ltd
Priority to CN201511028772.7A priority Critical patent/CN105653385B/en
Publication of CN105653385A publication Critical patent/CN105653385A/en
Application granted granted Critical
Publication of CN105653385B publication Critical patent/CN105653385B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F11/00Error detection; Error correction; Monitoring
    • G06F11/07Responding to the occurrence of a fault, e.g. fault tolerance
    • G06F11/0703Error or fault processing not based on redundancy, i.e. by taking additional measures to deal with the error or fault not making use of redundancy in operation, in hardware, or in data representation
    • G06F11/0706Error or fault processing not based on redundancy, i.e. by taking additional measures to deal with the error or fault not making use of redundancy in operation, in hardware, or in data representation the processing taking place on a specific hardware platform or in a specific software environment
    • G06F11/073Error or fault processing not based on redundancy, i.e. by taking additional measures to deal with the error or fault not making use of redundancy in operation, in hardware, or in data representation the processing taking place on a specific hardware platform or in a specific software environment in a memory management context, e.g. virtual memory or cache management
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F11/00Error detection; Error correction; Monitoring
    • G06F11/07Responding to the occurrence of a fault, e.g. fault tolerance
    • G06F11/08Error detection or correction by redundancy in data representation, e.g. by using checking codes
    • G06F11/10Adding special bits or symbols to the coded information, e.g. parity check, casting out 9's or 11's
    • G06F11/1008Adding special bits or symbols to the coded information, e.g. parity check, casting out 9's or 11's in individual solid state devices
    • G06F11/1068Adding special bits or symbols to the coded information, e.g. parity check, casting out 9's or 11's in individual solid state devices in sector programmable memories, e.g. flash disk

Landscapes

  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Quality & Reliability (AREA)
  • Physics & Mathematics (AREA)
  • General Engineering & Computer Science (AREA)
  • General Physics & Mathematics (AREA)
  • Signal Processing For Digital Recording And Reproducing (AREA)
  • Management Or Editing Of Information On Record Carriers (AREA)

Abstract

The invention belongs to the technical field of vehicle-loaded information storage and discloses a vehicle-loaded videorecording method. The method includes the following steps that a system information area is checked, formatting operation is conducted on a storage medium, and if file total number identification is damaged, the file total number is calculated again according to the storage medium situation and written back into a system information area; a file information header is inspected and checked, if the file information header is damaged, the file information header is recovered according to a videorecording information header, and if the videorecording information head is damaged, the videorecording information header is recovered according to frame header information and I frame index area information in a videorecording file; an index is rebuilt according to the videorecording file, a frame header in the videorecording file is searched for, and the videorecording file is written into the index according to the frame header; the newest videorecording segment of each channel in the storage medium is found out according to new and old idnetificatin in the system information header, and videorecording is started; if the current videorecording file is full, covering is started from the oldest videorecording file. By means of the vehicle-loaded videorecording method, videorecording efficiency can be improved, and abnormity can be repaired.

Description

A kind of vehicle-mounted kinescope method
Technical field
The invention belongs to on-vehicle information technical field of memory, particularly relate to a kind of vehicle-mounted kinescope method.
Background technology
File system is operating system for the method for the file on clear and definite storage device (commonly disk also has the solid state hard disc based on NANDFlash) or subregion and data structure, i.e. the method for constituent act on a storage device. The software mechanism being responsible for and storing fileinfo in operating system is called file management system, is called for short file system. File system is made up of three parts: the interface of file system, the software assembly to object manipulation and management, object and attribute. From system perspective, file system is that the space to file-storage device is organized and distributes, and is responsible for file storage the system that the file being stored in is protected and retrieved. Specifically, it is responsible for user and sets up file, is stored in, reads, revises, dump file, controls the access of file, when user not in use by time cancel file etc.
General file system has the structure of its complexity because of it, because he to meet various different application, such as fat32, ntfs, ext4. Their versatility is good, but being applied in vehicle-mounted video recording occasion, is then not necessarily suitable for. First these file system suffer from the list structure of complexity, when these tables are impaired, will use some special instruments and your file of loss could be retrieved, and when writing these file system, it is easy to produce fragment. Currently available technology has had a kind of predistribution technology to distribute space directly to table, forever motionless, but such is no problem in general video recording occasion, but when being applied to vehicle-mounted, when producing fierceness collision (certain disk itself does not suffer physical damage) or strong electromagnetic interference at automobile, often go wrong, simply going to read it even if not removing written document table, will also result in the damage of table.
Summary of the invention
The purpose of the embodiment of the present invention is in that to provide a kind of vehicle-mounted kinescope method, it is possible to increase video recording efficiency, can repair abnormal.
The embodiment of the present invention is achieved in that
A kind of vehicle-mounted kinescope method, comprises the following steps:
The first step: check system information district, storage medium is formatted operation, and checks that other identifys, if total number of files mark is destroyed, then again total according to storage medium situation calculation document and write back system information district;
Second step: check file information head, to the verification of file information head with check, if destroyed, recover file information head according to video information head, if video information head is destroyed, then according to the frame originating point information in video file and I frame index district Information recovering video information head;
3rd step: according to video file reconstruction index, the frame head in search video file, according in frame head write index, to be synchronized in video information head by the picture recorded in video file;
4th step: according to system information new and old sign in front, find out the video recording section that each passage in storage medium is up-to-date, starts video recording;
5th step: in video process, if current video file record is full, then starts to cover from the oldest video file.
Wherein, when index file occurs bad block, it is marked and finds out replacement block in bad block management district and be replaced.
Wherein, storage medium is carried out power-on and power-off operation, again find storage medium node, reinitialize file system.
Wherein, described storage medium is hard disk or flash card.
The embodiment of the present invention is by directly writing naked disk, avoid the possibility that traditional file systems table is destroyed, simultaneously not again through complicated file system write magnetic dish, magnetic head can be utilized efficiently, can repair according to other regions when key area is destroyed, simultaneously no longer each passage is saved as a file, but storage is gone down in order, it is to avoid the skew back and forth of magnetic head.
Accompanying drawing explanation
Fig. 1 is the method flow diagram of vehicle-mounted video recording in the present invention.
Detailed description of the invention
In order to make the purpose of the present invention, technical scheme and advantage clearly understand, below in conjunction with drawings and Examples, the present invention is further elaborated. Should be appreciated that specific embodiment described herein is only in order to explain the present invention, is not intended to limit the present invention.
The embodiment of the present invention is by directly writing naked disk, avoid the possibility that traditional file systems table is destroyed, simultaneously not again through complicated file system write magnetic dish, magnetic head can be utilized efficiently, can repair according to other regions when key area is destroyed, simultaneously no longer each passage is saved as a file, but storage is gone down in order, it is to avoid the skew back and forth of magnetic head.
Below in conjunction with specific embodiment, implementing of the present invention is described in detail:
The present invention, based on utilizing naked disk to read and write video recording efficiently, directly operates naked disk, and storage medium includes hard disk and flash memory, for hard disk, in order to detailed introduces present disclosure, below some concepts is illustrated or is defined:
Definition one: naked disk; Disk does not have any universal document system (such as fat32, ntfs, ext4 etc.).
Definition two: system information district; For describing the subregion of DISK to Image information, flag bit therein comprises 1. file system versions; 2. whether disk formats mark; 3. hard disk size information; 4. video file sum; 5. verification and
Definition three: file information head; For describing the information of all video recordings inside video file, including 1. video file initial times, terminate the time;2. video recording total length in file; 3. the sum of all i frames in this document; 4. total attribute (start regularly, is reported to the police) of the video recording comprised in this file; 5. video recording section sum; 6. the new and old sign of video file; 7. the use state (use, do not use, bad block occurs) of video file; 8. verification and.
Definition four: video information head: for describing the situation of each video recording section, including 1. this section of video recording initial times, terminates the time; 2. video recording segment length; 3. video recording section i frame number; 4. video recording resolution; 5. the initial i frame skew in I frame index district.
Definition five: frame head: for describing the information of each frame. 1. the channel number belonging to this frame; 2. this frame time is rubbed with the hands; 3. the length of this frame; 4. Frame Properties (P frame I frame audio frame) 5. verify and.
Definition six: I frame index district: be used for depositing in video file all of I frame. Occur damaging once playback video recording frame head in the future, it is possible to skip bad frame according to I frame index and continue to play.
Definition seven: bad block management district: for managing the bad block of index file, when bad block occurs in index time, finds replacement block to be replaced.
Definition eight: video file: the file of hard disk has two kinds, one is index file, and one is video file, has again video recording section in video file. Video file and video recording section are the relations comprised, and namely have multiple video recording section in a video file. Video file then comprises I frame index district and bad block management district. Only one of which index file 128M in hard disk, other are video file entirely, and each video file is all 128M, and the number of video file is maximum according to being assigned to of the size adaptation of hard disk, each video file has a lot of video recording section, not can exceed that at most 250. The corresponding file information head of each video file, each corresponding video information head of video recording section.
Definition nine: index file: comprise system information head, file information head, video information head, bad block management district, only one of which index file in hard disk in 128M index file.
As it is shown in figure 1, a kind of vehicle-mounted kinescope method comprises the steps:
The first step: check system information district, it may be judged whether formatted, if unformatted, it is necessary to prompting user would format; If formatted, then check that other identify, if it find that total number of files mark (content of the 4th definition in system information district) is destroyed, then again totalizes according to hard disk situation, be written back system information district; Wherein, formatting is particularly as follows: be formatted into vehicle-mounted file system, and this file system is system information district, system information head, video information head, bad block management district writes disk by the naked mode write, it it is different with common formatting, it does not have so-called partitions of file table; Totalize specifically according to hard disk situation: what first pass through hard disk drives the size reading hard disk, system information district, system information head, video file head, in bad block management district all indexed files, accounts for 128M. Other data file is each accounts for 128M. Total amount according to hard disk just can calculate the sum of video file.
Second step: check file information head, to the verification of file information head with check, then recovers file information head according to video information head if it find that destroyed. In the process recovered, if it find that video information head has the situation of destruction, then recover video information head according to the frame head (definition five) in video file and I frame index district.
3rd step: rebuild index according to video file, this index comprises file information head and video information head, and the picture of record last time there is also in video file, but be not but synchronized to video information face in front and go, at this moment must synchronizing, otherwise the video recording of this section will be lost. The process synchronized is the frame head in search video file step by step, is then written to index according to frame head, it is simply that by cumulative mode, the information inside frame head is write index the inside.
4th step: finding out each passage needs to start the file of video recording, and record is full to have a flag bit to indicate whether in file information head, also has the new and old flag of a file. During initialization, find the file information head of each passage video recording last time, if having recorded full 128M, then look for next idle file to start record, full without record, continue newly to open video information head and continue record.
5th step: in video process, if when a file has been recorded full (formatting has been allocated in advance), then starts to cover from the oldest file.
Abnormality processing:
1. Bad Block Management: when bad block occurs in index file, it is marked and finds out replacement block in bad block management district to be replaced, bad block management specifies that hard disk index file always not can exceed that at most the damages of 128 file information head, just thinks this hard disk corruptions once exceed. Just a new file information head is opened up in bad block management district to describe the video file that bad file information head is corresponding in time being not above.
2. vibrations abnormality processing: when vehicle in the process of moving, hard disk is easily subject to the interference of vibrations, file system also there will be exception, at this moment need to carry out abnormality processing, the abnormality processing mode taked at present is that hard disk is carried out power-on and power-off, again finding hard disk node afterwards, this is the hard disk node produced according to hard drive. Generally it is mapped on node/dev/diskHDD with udev instrument, reinitializes file system, repeat the first step process to the 5th step.
The foregoing is only presently preferred embodiments of the present invention, be not limited to the present invention, all any amendment, equivalent replacement and improvement etc. made within the spirit and principles in the present invention, should be included within protection scope of the present invention.

Claims (4)

1. a vehicle-mounted kinescope method, it is characterised in that comprise the following steps:
The first step: check system information district, storage medium is formatted operation, and checks that other identifys, if total number of files mark is destroyed, then again total according to storage medium situation calculation document and write back system information district;
Second step: check file information head, to the verification of file information head with check, if destroyed, recover file information head according to video information head, if video information head is destroyed, then according to the frame originating point information in video file and I frame index district Information recovering video information head;
3rd step: according to video file reconstruction index, the frame head in search video file, according in frame head write index, to be synchronized in video information head by the picture recorded in video file;
4th step: according to system information new and old sign in front, find out the video recording section that each passage in storage medium is up-to-date, starts video recording;
5th step: in video process, if current video file record is full, then starts to cover from the oldest video file.
2. the vehicle-mounted kinescope method of one according to claim 1, it is characterised in that: when index file occurs bad block, it is marked and finds out replacement block in bad block management district and be replaced.
3. the vehicle-mounted kinescope method of one according to claim 1, it is characterised in that: storage medium is carried out power-on and power-off operation, again finds storage medium node, reinitialize file system.
4. the vehicle-mounted kinescope method of one according to claim 1, it is characterised in that: described storage medium is hard disk or flash card.
CN201511028772.7A 2015-12-31 2015-12-31 A kind of vehicle-mounted kinescope method Active CN105653385B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201511028772.7A CN105653385B (en) 2015-12-31 2015-12-31 A kind of vehicle-mounted kinescope method

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201511028772.7A CN105653385B (en) 2015-12-31 2015-12-31 A kind of vehicle-mounted kinescope method

Publications (2)

Publication Number Publication Date
CN105653385A true CN105653385A (en) 2016-06-08
CN105653385B CN105653385B (en) 2019-02-01

Family

ID=56491170

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201511028772.7A Active CN105653385B (en) 2015-12-31 2015-12-31 A kind of vehicle-mounted kinescope method

Country Status (1)

Country Link
CN (1) CN105653385B (en)

Cited By (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN107506253A (en) * 2017-08-11 2017-12-22 北京东土科技股份有限公司 A kind of operating system abnormal information store method and device
CN110333887A (en) * 2019-07-04 2019-10-15 郑州天迈科技股份有限公司 Vehicle-mounted machine picture recording module upgrades optimization system
CN110737389A (en) * 2018-07-19 2020-01-31 杭州海康威视系统技术有限公司 Method and device for storing data

Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US3704363A (en) * 1971-06-09 1972-11-28 Ibm Statistical and environmental data logging system for data processing storage subsystem
CN103404146A (en) * 2013-03-11 2013-11-20 华为技术有限公司 Video file repairing method and device
CN103474087A (en) * 2013-09-06 2013-12-25 南京南自信息技术有限公司 Video recording file management method and device for easily preventing disk fragments from being generated
CN103544124A (en) * 2012-07-16 2014-01-29 上海塞尚通信技术有限公司 Access method of Nand Flash memorizer
CN104301681A (en) * 2014-10-22 2015-01-21 厦门市美亚柏科信息股份有限公司 Monitoring video restoration method and device

Patent Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US3704363A (en) * 1971-06-09 1972-11-28 Ibm Statistical and environmental data logging system for data processing storage subsystem
CN103544124A (en) * 2012-07-16 2014-01-29 上海塞尚通信技术有限公司 Access method of Nand Flash memorizer
CN103404146A (en) * 2013-03-11 2013-11-20 华为技术有限公司 Video file repairing method and device
CN103474087A (en) * 2013-09-06 2013-12-25 南京南自信息技术有限公司 Video recording file management method and device for easily preventing disk fragments from being generated
CN104301681A (en) * 2014-10-22 2015-01-21 厦门市美亚柏科信息股份有限公司 Monitoring video restoration method and device

Cited By (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN107506253A (en) * 2017-08-11 2017-12-22 北京东土科技股份有限公司 A kind of operating system abnormal information store method and device
CN107506253B (en) * 2017-08-11 2021-05-18 北京东土科技股份有限公司 Method and device for storing abnormal information of operating system
CN110737389A (en) * 2018-07-19 2020-01-31 杭州海康威视系统技术有限公司 Method and device for storing data
CN110333887A (en) * 2019-07-04 2019-10-15 郑州天迈科技股份有限公司 Vehicle-mounted machine picture recording module upgrades optimization system
CN110333887B (en) * 2019-07-04 2023-04-14 郑州天迈科技股份有限公司 Vehicle-mounted machine video recording module optimization system

Also Published As

Publication number Publication date
CN105653385B (en) 2019-02-01

Similar Documents

Publication Publication Date Title
KR100288203B1 (en) Real time data recording method
CN100578470C (en) Audio/video data access method and device based on raw device
CN101916173B (en) RAID (Redundant Array of Independent Disks) based data reading and writing method and system thereof
CN104811645B (en) A kind of embedded Video data storage method
CN108319602B (en) Database management method and database system
CN106600750B (en) A kind of method of circulation recording, system and automobile data recorder
CN103929609B (en) A kind of video recording playback method and device
JP2017079053A (en) Methods and systems for improving storage journaling
US11750784B2 (en) Automatic video file repair method and system
CN103226965A (en) Time-bitmap-based audio/video data access method
CN101364218A (en) Hard disk video recorder file systems and checking method thereof
CN105653385A (en) Vehicle-loaded videorecording method
CN111367926A (en) Data processing method and device for distributed system
CN103092849A (en) File system cluster management method
US7234078B2 (en) Data recovery method and data recording apparatus
CN100440352C (en) Power failure recovery method
CN103092719B (en) A kind of power-off protection method of file system
CN110222035A (en) A kind of efficient fault-tolerance approach of database page based on exclusive or check and journal recovery
US20070286050A1 (en) Recording apparatus and method, program, and storage medium
CN105744200B (en) The storage method and device of surveillance video
CN110798730A (en) MP4 file recording and repairing method
CN103137159A (en) Direct-to-disc fault-tolerant method for videos in hard-disk based digital video recorder and device thereof
CN105830067A (en) Document information processing method, apparatus, and document processing apparatus and system
KR100501414B1 (en) Method of and apparatus for logging and restoring the meta data in file system
CN104504349B (en) A kind of Video data safe storage device and method

Legal Events

Date Code Title Description
C06 Publication
PB01 Publication
C10 Entry into substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant
TR01 Transfer of patent right

Effective date of registration: 20220804

Address after: 518000 a2901-2902, building 10, Shenzhen Bay science and technology ecological park, No. 10, Gaoxin South ninth Road, high tech Zone community, Yuehai street, Nanshan District, Shenzhen City, Guangdong Province

Patentee after: SHENZHEN EMPEROR TECHNOLOGY Co.,Ltd.

Address before: 518000 north side 504, 5th floor, scientific research building, aerospace micromotor building, Langshan 2nd Road, gaoxinyuan North District, Nanshan District, Shenzhen City, Guangdong Province

Patentee before: SHENZHEN LANTAIYUAN INFORMATION TECHNOLOGY Co.,Ltd.

TR01 Transfer of patent right