TWI774451B - Controlling method of storage of driving recorder and storage controlling system - Google Patents
Controlling method of storage of driving recorder and storage controlling system Download PDFInfo
- Publication number
- TWI774451B TWI774451B TW110123809A TW110123809A TWI774451B TW I774451 B TWI774451 B TW I774451B TW 110123809 A TW110123809 A TW 110123809A TW 110123809 A TW110123809 A TW 110123809A TW I774451 B TWI774451 B TW I774451B
- Authority
- TW
- Taiwan
- Prior art keywords
- file
- storage device
- data
- location configuration
- configuration table
- Prior art date
Links
- 238000003860 storage Methods 0.000 title claims abstract description 141
- 238000000034 method Methods 0.000 title claims abstract description 32
- 238000010586 diagram Methods 0.000 description 25
- 230000007547 defect Effects 0.000 description 3
- 238000009826 distribution Methods 0.000 description 2
- 238000007796 conventional method Methods 0.000 description 1
- 230000000694 effects Effects 0.000 description 1
- 238000004519 manufacturing process Methods 0.000 description 1
Images
Classifications
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F9/00—Arrangements for program control, e.g. control units
- G06F9/06—Arrangements for program control, e.g. control units using stored programs, i.e. using an internal store of processing equipment to receive or retain programs
- G06F9/44—Arrangements for executing specific programs
- G06F9/445—Program loading or initiating
- G06F9/44505—Configuring for program initiating, e.g. using registry, configuration files
- G06F9/4451—User profiles; Roaming
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F3/00—Input arrangements for transferring data to be processed into a form capable of being handled by the computer; Output arrangements for transferring data from processing unit to output unit, e.g. interface arrangements
- G06F3/06—Digital input from, or digital output to, record carriers, e.g. RAID, emulated record carriers or networked record carriers
- G06F3/0601—Interfaces specially adapted for storage systems
- G06F3/0628—Interfaces specially adapted for storage systems making use of a particular technique
- G06F3/0638—Organizing or formatting or addressing of data
- G06F3/0643—Management of files
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F16/00—Information retrieval; Database structures therefor; File system structures therefor
- G06F16/10—File systems; File servers
- G06F16/16—File or folder operations, e.g. details of user interfaces specifically adapted to file systems
- G06F16/162—Delete operations
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F3/00—Input arrangements for transferring data to be processed into a form capable of being handled by the computer; Output arrangements for transferring data from processing unit to output unit, e.g. interface arrangements
- G06F3/06—Digital input from, or digital output to, record carriers, e.g. RAID, emulated record carriers or networked record carriers
- G06F3/0601—Interfaces specially adapted for storage systems
- G06F3/0602—Interfaces specially adapted for storage systems specifically adapted to achieve a particular effect
- G06F3/0604—Improving or facilitating administration, e.g. storage management
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F3/00—Input arrangements for transferring data to be processed into a form capable of being handled by the computer; Output arrangements for transferring data from processing unit to output unit, e.g. interface arrangements
- G06F3/06—Digital input from, or digital output to, record carriers, e.g. RAID, emulated record carriers or networked record carriers
- G06F3/0601—Interfaces specially adapted for storage systems
- G06F3/0628—Interfaces specially adapted for storage systems making use of a particular technique
- G06F3/0629—Configuration or reconfiguration of storage systems
- G06F3/0631—Configuration or reconfiguration of storage systems by allocating resources to storage systems
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F3/00—Input arrangements for transferring data to be processed into a form capable of being handled by the computer; Output arrangements for transferring data from processing unit to output unit, e.g. interface arrangements
- G06F3/06—Digital input from, or digital output to, record carriers, e.g. RAID, emulated record carriers or networked record carriers
- G06F3/0601—Interfaces specially adapted for storage systems
- G06F3/0628—Interfaces specially adapted for storage systems making use of a particular technique
- G06F3/0655—Vertical data movement, i.e. input-output transfer; data movement between one or more hosts and one or more storage devices
- G06F3/0659—Command handling arrangements, e.g. command buffers, queues, command scheduling
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F3/00—Input arrangements for transferring data to be processed into a form capable of being handled by the computer; Output arrangements for transferring data from processing unit to output unit, e.g. interface arrangements
- G06F3/06—Digital input from, or digital output to, record carriers, e.g. RAID, emulated record carriers or networked record carriers
- G06F3/0601—Interfaces specially adapted for storage systems
- G06F3/0668—Interfaces specially adapted for storage systems adopting a particular infrastructure
- G06F3/0671—In-line storage system
- G06F3/0673—Single storage device
Landscapes
- Engineering & Computer Science (AREA)
- Theoretical Computer Science (AREA)
- Physics & Mathematics (AREA)
- General Engineering & Computer Science (AREA)
- General Physics & Mathematics (AREA)
- Human Computer Interaction (AREA)
- Software Systems (AREA)
- Data Mining & Analysis (AREA)
- Databases & Information Systems (AREA)
- Information Retrieval, Db Structures And Fs Structures Therefor (AREA)
- Automatic Disk Changers (AREA)
Abstract
Description
本發明是關於一種控制方法與控制系統,且特別是有關於一種行車記錄器之儲存裝置的控制方法與儲存裝置控制系統。The present invention relates to a control method and a control system, and in particular, to a control method and a storage device control system of a storage device of a driving recorder.
請參照第1圖,其繪示習知採用FAT檔案系統之儲存裝置900的示意圖。儲存裝置900包括一檔案位置配置表(File-Allocation-Table)920、一檔案目錄表(Directory Entry)930及數個資料區(data cluster)940。以行車記錄器為例,在多次寫入及刪除檔案後,同一檔案之資料可能分散儲存於不連續的資料區940中。舉例來說,如第1圖所示,檔案FA儲存於編號為「13」、「14」、「15」、「19」、「20」之資料區940中。Please refer to FIG. 1 , which is a schematic diagram of a conventional storage device 900 using the FAT file system. The storage device 900 includes a File-Allocation-Table 920 , a File-Allocation-Table 930 and a plurality of
檔案目錄表930用來記錄儲存在儲存裝置900中之檔案名稱與起始資料區編號,檔案位置配置表920則用來記錄資料區的鏈結關係。舉例來說,如第1圖所示,檔案目錄表930指出在儲存裝置900儲存有一個檔案FA,檔案FA的資料儲存於編號為「13」的資料區940。檔案位置配置表920中對應於編號為「13」之資料區940的位置記錄著「14」,其指出檔案FA接下來的資料儲存於編號為「14」的資料區940;檔案位置配置表920中對應於編號為「14」之資料區940的位置記錄著「15」,其指出檔案FA接下來的資料儲存於編號為「15」的資料區940,依此類推;檔案位置配置表920中對應編號為「20」之資料區940的位置記錄著「EOC」,其指出編號為「20」之資料區940是檔案FA的檔尾(End Of Cluster-Chain, EOC)。The file directory table 930 is used to record the file name and the initial data area number stored in the storage device 900, and the file location configuration table 920 is used to record the link relationship of the data areas. For example, as shown in FIG. 1, the file directory table 930 indicates that a file FA is stored in the storage device 900, and the data of the file FA is stored in the
請參照第2圖及第3圖,第2圖繪示習知行車記錄器之檔案寫入方法的流程圖,第3圖繪示根據第2圖之操作之儲存裝置900的示例圖。舉例來說,在啟動行車記錄器的錄影程序後,儲存裝置900中的檔案位置配置表920會被複製一份到動態隨機存取記憶體(Dynamic Random Access Memory, (DRAM))中(步驟S901)。接著,根據DRAM中的檔案位置配置表判斷儲存裝置900的儲存空間是否足夠(步驟S902)。若儲存裝置900有足夠的儲存空間,則會選擇一資料區作為一起始資料區來寫入資料(例如編號為「16」的資料區)(步驟S903),並於檔案目錄表930中新增一檔案名稱(例如「FB」)及一起始資料區的編號(例如「16」)(步驟S904)。然後,選擇另一資料區來寫入資料(例如編號為「17」的資料區)(步驟S905),並將該資料區之編號(例如「17」)記錄在DRAM中之檔案位置配置表中,對應於編號為「16」之資料區的位置(步驟S906),接著將資料寫入該資料區(步驟S907),依此類推,直至檔案寫入程序結束。此外,在DRAM中之檔案位置配置表被更新一特定次數(例如三次)時,根據DRAM中之檔案位置配置表來更新儲存裝置900中的檔案位置配置表920,直至檔案寫入程序結束。在檔案寫入程序結束後,行車記錄器會再次根據DRAM中之檔案位置配置表來更新儲存裝置900中的檔案位置配置表920。Please refer to FIG. 2 and FIG. 3 , FIG. 2 shows a flow chart of a file writing method of a conventional driving recorder, and FIG. 3 shows an example of the storage device 900 according to the operation of FIG. 2 . For example, after starting the video recording program of the driving recorder, the file location configuration table 920 in the storage device 900 will be copied to a dynamic random access memory (DRAM) (step S901 ). ). Next, it is determined whether the storage space of the storage device 900 is sufficient according to the file location configuration table in the DRAM (step S902 ). If the storage device 900 has enough storage space, a data area will be selected as a starting data area to write data (for example, the data area numbered "16") (step S903 ), and added to the file directory table 930 A file name (eg "FB") and an initial data area number (eg "16") (step S904). Then, select another data area to write data (for example, the data area numbered "17") (step S905), and record the number of the data area (for example, "17") in the file location allocation table in the DRAM , corresponding to the position of the data area numbered “16” (step S906 ), then write data into the data area (step S907 ), and so on, until the file writing process ends. In addition, when the file location configuration table in the DRAM is updated a certain number of times (eg, three times), the file location configuration table 920 in the storage device 900 is updated according to the file location configuration table in the DRAM until the file writing process ends. After the file writing process is completed, the driving recorder will update the file location configuration table 920 in the storage device 900 again according to the file location configuration table in the DRAM.
然而,車禍所引起的意外斷電,可能會導致該檔案因缺乏完整的資料鏈結關係(FAT chain)而無法被讀取。舉例來說,如第3圖所示,當檔案FB的資料已寫入編號為「29」的資料區940後遭遇到意外斷電,由於儲存裝置900中的檔案位置配置表920尚未根據DRAM中之檔案位置配置表更新,使得檔案FB之資料鏈結關係不完整,檔案FB儲存在編號為「22」與「29」的資料區的資料無法被讀取。對行車紀錄器而言,車禍時的資料無法被讀取是相當嚴重的問題。However, an unexpected power failure caused by a car accident may cause the file to be unreadable due to the lack of a complete data link (FAT chain). For example, as shown in FIG. 3, when the data of the file FB has been written into the
本發明係有關於一種行車記錄器之儲存裝置的控制方法及儲存裝置控制系統,其利用根據一預設檔案位置配置表(Predetermined File-Allocation-Table)及一預設檔案目錄表(Predetermined Directory Entry)來規劃儲存裝置,避免檔案因意外斷電而無法讀取。The present invention relates to a control method and a storage device control system for a storage device of a driving recorder, which utilizes a preset file location allocation table (Predetermined File-Allocation-Table) and a preset file directory table (Predetermined Directory Entry) ) to plan the storage device so that the files cannot be read due to unexpected power failure.
根據本發明之一實施例,提出一種行車記錄器之一儲存裝置的控制方法。行車記錄器之儲存裝置的控制方法包括以下步驟:根據儲存於一儲存單元之預設檔案目錄表,對該儲存裝置之一檔案目錄表進行組態;根據儲存於該儲存單元之一預設檔案位置配置表,對該儲存裝置之一檔案位置配置表進行組態;以及根據該檔案目錄表與該檔案位置配置表,控制一控制器寫入資料至該儲存裝置中;其中該檔案位置配置表中的複數欄位分別對應於該儲存裝置的複數資料區,且該檔案位置配置表中的各該等欄位在一新資料寫入到對應的該儲存裝置的該等資料區後維持不變。According to an embodiment of the present invention, a method for controlling a storage device of a driving recorder is provided. The control method of the storage device of the driving recorder includes the following steps: configuring a file directory table of the storage device according to a default file directory table stored in a storage unit; according to a default file stored in the storage unit a location configuration table for configuring a file location configuration table of the storage device; and controlling a controller to write data into the storage device according to the file directory table and the file location configuration table; wherein the file location configuration table The plurality of fields in the file correspond to the plurality of data areas of the storage device respectively, and each of the fields in the file location configuration table remains unchanged after a new data is written into the data areas of the corresponding storage device .
根據本發明之一方面,該資料包含來自至少二檔案的一檔案資料,且該檔案位置配置表配置以使該二檔案儲存於交錯的複數資料區中。According to one aspect of the present invention, the data includes a file data from at least two files, and the file location configuration table is configured such that the two files are stored in an interleaved plurality of data areas.
根據本發明之一方面,該至少二檔案為具有相同之一位元率之複數影像檔案,且對該儲存裝置之該檔案位置配置表進行組態之步驟包含對各該至少二檔案配置相同數目的該等資料區。According to an aspect of the present invention, the at least two files are plural image files having the same bit rate, and the step of configuring the file location configuration table of the storage device includes configuring the same number of each of the at least two files of such data areas.
根據本發明之一方面,該至少二檔案為具有互異之位元率之影像檔案,且對該儲存裝置之該檔案位置配置表進行組態之步驟包含根據該等位元率對各該至少二檔案配置該等資料區。According to an aspect of the present invention, the at least two files are image files having different bit rates, and the step of configuring the file location allocation table of the storage device includes assigning each of the at least two files according to the bit rates. The second file configures these data areas.
根據本發明之另一實施例,提出一種儲存裝置控制系統,包括:儲存單元、控制器以及處理器。該儲存單元儲存一預設檔案目錄表及一預設檔案位置配置表。該控制器用以寫入資料至一儲存裝置中。該處理器用以執行下列步驟:根據該預設檔案目錄表,對該儲存裝置之一檔案目錄表進行組態;根據該預設檔案位置配置表,對該儲存裝置之一檔案位置配置表進行組態;以及根據該檔案目錄表與該檔案位置配置表,控制該控制器寫入該資料至該儲存裝置中;其中該檔案位置配置表中的複數欄位分別對應於該儲存裝置的複數資料區,且該檔案位置配置表中的各該等欄位在一新資料寫入到對應的該儲存裝置的該等資料區後維持不變。According to another embodiment of the present invention, a storage device control system is provided, including: a storage unit, a controller, and a processor. The storage unit stores a default file directory table and a default file location configuration table. The controller is used for writing data into a storage device. The processor is used for executing the following steps: configuring a file directory table of the storage device according to the default file directory table; organizing a file location configuration table of the storage device according to the default file location configuration table and controlling the controller to write the data into the storage device according to the file directory table and the file location configuration table; wherein the plurality of fields in the file location configuration table respectively correspond to the plurality of data areas of the storage device , and the fields in the file location configuration table remain unchanged after a new data is written into the data areas of the corresponding storage device.
有關本案的特徵、實作與功效,茲配合圖式作較佳實施例詳細說明如下。Regarding the features, implementation and effects of this case, a preferred embodiment is described in detail as follows in conjunction with the drawings.
有鑑於傳統之行車記錄器之儲存裝置有諸多問題亟待改善,以下提出一種行車記錄器之儲存裝置的控制方法及儲存裝置控制系統,其利用一預設檔案目錄表(Predetermined Directory Entry)及一預設檔案位置配置表(Predetermined File-Allocation-Table)來對儲存裝置之檔案位置配置表與檔案目錄表進行組態,避免檔案因意外斷電而無法讀取。In view of the many problems of the storage device of the traditional driving recorder that need to be improved, a control method and a storage device control system of the storage device of the driving recorder are provided below, which utilizes a predetermined file directory table (Predetermined Directory Entry) and a predetermined directory entry. Set up a file location allocation table (Predetermined File-Allocation-Table) to configure the file location allocation table and file directory table of the storage device to prevent files from being unreadable due to unexpected power failure.
第4圖為根據本發明一實施例所繪示之控制系統100之方塊圖。控制系統100例如是一控制晶片。在本實施例中,控制系統100連接於一攝影機200、一儲存裝置400。控制系統100與攝影機200例如可設置於一行車紀錄器。儲存裝置400例如是一SD記憶卡或一硬碟,可內設或外接於該行車紀錄器。控制系統100包括一儲存單元110、一控制器120、及一處理器130。儲存單元110用以儲存一預設檔案目錄表及一預設檔案位置配置表。控制器120用以寫入資料至儲存裝置400中。處理器130用以對儲存裝置400之一檔案目錄表及一檔案位置配置表進行組態。FIG. 4 is a block diagram of a
第5圖為本發明行車記錄器之儲存裝置的控制方法之一實施例的流程圖。在本實施例中,每當啟動行車紀錄器時,或每當更換儲存裝置400時,處理器130會檢查儲存裝置400中是否有檔案目錄表與檔案位置配置表(步驟S501)。若無,處理器130則直接根據儲存單元110中之預設檔案目錄表與預設檔案位置配置表,對儲存單元110中之檔案目錄表與檔案位置配置表進行組態(步驟S503);若有,處理器130則進一步檢查儲存裝置400中之檔案目錄表與檔案位置配置表,是否與儲存單元110中之預設檔案目錄表與預設檔案位置配置表相同(步驟S502)。若不同,處理器130則直接根據儲存單元110中之該預設檔案目錄表與該預設檔案位置配置表,對儲存單元110中之預設檔案目錄表與預設檔案位置配置表進行組態(步驟S503)。FIG. 5 is a flow chart of one embodiment of the control method of the storage device of the driving recorder of the present invention. In this embodiment, every time the driving recorder is activated or every time the
第6圖為本發明具有被組態的檔案目錄表與檔案位置配置表之儲存裝置400之一實施例的示意圖。儲存裝置400包括根據一預設檔案位置配置表所組態之一檔案位置配置表420、根據一預設檔案目錄表所組態之一檔案目錄表430及數個資料區(data cluster)440。FIG. 6 is a schematic diagram of an embodiment of a
如第6圖所示,處理器130對檔案目錄表430中對應於一檔案之檔名「FC」,及對應於檔案FC之起始資料區為編號為「11」之資料區進行組態,處理器130更對檔案位置配置表420中對應於檔案FC之資料鏈結關係為編號為「11」~「15」之資料區進行組態。相似地,處理器130對檔案目錄表430中對應於一檔案之檔名「FD」,及檔案FD之起始資料區為編號為「16」之資料區進行組態,處理器130更對檔案位置配置表420中對應於檔案FD之資料鏈結關係為編號為「16」~「20」之資料區進行組態。As shown in FIG. 6, the
簡而言之,檔案FC之資料被預設放在編號為「11」~「15」之資料區,檔案FD之資料被預設放在編號為「16」~「20」之資料區。值得注意的是,雖然檔案目錄表430及檔案位置配置表420已完成組態,但儲存裝置400中對應於檔案FC、檔案FD之資料區(亦即編號為「11」~「20」之資料區)中,並沒有存放對應於檔案FC、檔案FD之資料,如第6圖所示。In short, the data of the file FC is preset in the data areas numbered "11" to "15", and the data of the file FD is preset to the data areas numbered "16" to "20". It is worth noting that although the file directory table 430 and the file location configuration table 420 have been configured, the data areas in the
第7圖為本發明寫入資料至儲存裝置400之一實施例的流程圖。在本實施例中,處理器130根據檔案目錄表430與檔案位置配置表420,控制控制器120寫入資料至該儲存裝置400中。FIG. 7 is a flowchart of one embodiment of writing data to the
舉例來說,行車紀錄器開始錄影時,處理器130根據檔案目錄表430選擇一檔案來寫入資料(步驟S704)。在一實施例中,檔案目錄表430中之檔名帶著時間資訊,因此處理器130可以根據檔案目錄表430中之檔名,選擇最舊的一檔案來寫入資料。以第6圖為例,檔案FC為最舊的一檔案。For example, when the driving recorder starts recording, the
接著,處理器130更改檔案目錄表430中對應於該檔案之檔名(步驟S705)。承上例,處理器130將檔案目錄表430中對應於被處理器130選擇來寫入資料之檔案的檔名「FC」更改為「FE」,如第8圖所示。值得注意的是,在檔案目錄表430中,對應於檔案FE之起始資料區維持不變而仍為編號為「11」之資料區。此外,在檔案位置配置表420中,對應於檔案FE之資料鏈結關係維持不變而仍為編號為「11」~「15」之資料區。Next, the
然後,處理器130控制控制器130寫入資料至儲存裝置400中組態給該檔案的資料區(步驟S706)。承上例,處理器130控制控制器130,將資料依序寫入儲存裝置400中之編號為「11」~「15」之資料區,如第8圖所示。Then, the
接著,處理器130判斷是否繼續寫入資料(步驟S707)。若繼續寫入資料,則重複步驟S704~S706;若不繼續寫入資料,則結束本流程。Next, the
由上可知,處理器130在寫入資料至儲存裝置300期間,不會更新檔案位置配置表420,詳細來說,當寫入一新檔案至儲存裝置300時,檔案目錄表430會對應地更新,但檔案位置配置表420並不會因為寫入新檔案或一檔案的資料有更新而所變動,所以即使行車紀錄器遭遇意外斷電,檔案位置配置表420中對應於一檔案的資料鏈結關係仍可保持完整,儲存裝置300中該檔案的資料可以被完整讀取。As can be seen from the above, the
此外,在習知技術中,處理器需花費時間搜尋空白的資料區來寫入資料。在經過多次寫入及刪除檔案後,空白的資料區往往是零散的(fragment),因此降低了寫檔效率。相較於習知技術,本發明中檔案的資料區已組態好且不會變更,因此處理器不需花費時間搜尋空白的資料區來寫入資料,提升了寫檔效率(writing performance)。在一實施例中,檔案的資料區可被組態為連續的(如第6圖所示),可進一步提升寫檔效率。In addition, in the prior art, the processor spends time searching for an empty data area to write data. After many times of writing and deleting files, the blank data area is often fragmented, thus reducing the efficiency of file writing. Compared with the prior art, the data area of the file in the present invention has been configured and will not be changed, so the processor does not need to spend time searching for a blank data area to write data, which improves the writing performance. In one embodiment, the data area of the file can be configured to be continuous (as shown in FIG. 6 ), which can further improve the efficiency of file writing.
此外,在習知技術中,處理器在寫入資料前需確認剩餘空間是否足夠。若不足,處理器需刪除檔案目錄表中對應於至少一檔案之檔名與起始資料區,並刪除檔案位置配置表中對應於該至少一檔案之資料鏈結關係,因此降低了寫檔效率。相較於習知技術,本發明處理器110在寫入資料前無須確認剩餘空間是否足夠,亦無須刪除檔案目錄表中之檔名與起始資料區,及檔案位置配置表中之資料鏈結關係,可更進一步提升寫檔效率。In addition, in the prior art, the processor needs to confirm whether the remaining space is sufficient before writing data. If it is not enough, the processor needs to delete the file name and start data area corresponding to at least one file in the file directory table, and delete the data link relationship corresponding to the at least one file in the file location configuration table, thus reducing the file writing efficiency . Compared with the prior art, the
圖9顯示本發明預先組態的連續資料區的結構之一實施例的示意圖。如先前對應圖6所解釋的,當檔案位置配置表被預先組態為連續資料區的形式時,檔案是如圖9所示的循序被儲存在資料區Index1-IndexN中。亦即,例如在一安全數位(secure digitial;SD)卡中,記憶體被分割為N個區段(section),且每個區段具有例如1000個連續的資料區空間。檔案(例如圖9所示的檔案1-檔案3N)將循序地被寫入這N個區段中,且新檔案將以循環(circular)的方式覆蓋先前的舊檔案。圖9所示的方式非常適用於例如在一段時間僅錄製單一影像檔案的簡單應用程式中。然而當產品應用程式的複雜度提高時,將擁有更多可同時錄製例如兩個或兩個以上的影像(或其他類型)檔案的應用程式。FIG. 9 shows a schematic diagram of one embodiment of the structure of the preconfigured continuous data area of the present invention. As previously explained in relation to FIG. 6 , when the file location configuration table is preconfigured in the form of continuous data areas, the files are sequentially stored in the data areas Index1 - IndexN as shown in FIG. 9 . That is, for example, in a secure digital (SD) card, the memory is divided into N sections, and each section has, for example, 1000 consecutive data area spaces. The files (eg, file 1 - file 3N shown in FIG. 9 ) will be sequentially written into the N segments, and the new file will overwrite the previous old file in a circular manner. The approach shown in Figure 9 is very suitable for simple applications such as recording only a single image file over a period of time. However, as the complexity of production applications increases, there will be more applications that can record, for example, two or more video (or other types of) files simultaneously.
根據上述,圖10顯示本發明預先組態的連續資料區的結構之一實施例的示意圖,其中此連續資料區支援儲存來自不同應用程式的多個檔案。舉例而言,以大檔案與小檔案形式呈現的兩個類型的檔案(例如圖10所示的F檔案1-F檔案3N以及R檔案1-R檔案3N)可實質上同時被儲存在記憶體中,其中大檔案與小檔案分別對應於例如高解析度影像以及低解析度影像。在另一範例中,一個多鏡頭應用程式也可以被實現以實質上同時將例如,但不限於對應於前鏡頭與後鏡頭的影像檔案儲存於記憶體中。因此,如圖10所示,在一個可能的範例中,前相機(F)以及後相機(R)被分配相同數目(例如N)的區段F Index1-F IndexN與R Index1-R IndexN,以儲存影像檔案。如果每個影像檔案的錄製時間為例如一分鐘,則前相機影像檔案(F File X)以及後相機影像檔案(R File X)可同時在一分鐘內被寫入。According to the above, FIG. 10 shows a schematic diagram of one embodiment of the structure of the preconfigured continuous data area of the present invention, wherein the continuous data area supports the storage of multiple files from different applications. For example, two types of files in the form of large files and small files (such as F file 1-F file 3N and R file 1-R file 3N shown in FIG. 10 ) can be stored in the memory at substantially the same time , wherein the large file and the small file respectively correspond to, for example, a high-resolution image and a low-resolution image. In another example, a multi-camera application may also be implemented to store in memory substantially simultaneously, for example, but not limited to, image files corresponding to the front and rear cameras. Therefore, as shown in FIG. 10, in one possible example, the front camera (F) and the rear camera (R) are assigned the same number (eg, N) of segments F Index1-F IndexN and R Index1-R IndexN to Save the image file. If the recording time of each image file is, for example, one minute, the front camera image file (F File X) and the rear camera image file (R File X) can be written simultaneously within one minute.
圖11A以及圖11B顯示圖10的檔案儲存方法的潛在缺陷的示意圖。在圖11A中,安全數位儲存裝置1110包括開機區段1120、檔案位置配置表1130、檔案目錄表1140以及複數資料區1150,並在圖11B中邏輯性地繪示邏輯資料區1160以及1170的寫入操作示意圖。在要同時儲存兩個影像檔案的情境下,如採用傳統的技術來將例如前相機影像檔案(F File X)以及後相機影像檔案(R File X)寫入到安全數位儲存裝置1110中,需要如圖11B所示依連續資料區的形式進行儲存,其中前相機影像檔案(F File X)是連續地儲存於資料區1100-2099中,而後相機影像檔案(R File X)則是連續地儲存於資料區20100-21099中。在這樣的狀況下,檔案位置配置表1130是預先組態以將不同檔案儲存至預設的資料區中。11A and 11B are schematic diagrams showing potential defects of the file storage method of FIG. 10 . In FIG. 11A , the secure
然而,當多個檔案要在這樣的狀況下同時被寫入至安全數位儲存裝置1110時,將產生降低連續安全數位寫入操作的效率的非期望結果。更詳細地說,安全數位寫入操作是基於資料區進行,因此當前相機影像檔案(F File X)以及後相機影像檔案(R File X)被實質上同時寫入至安全數位儲存裝置1110時,實際上的運作會是當前相機影像檔案(F File X)先被寫入至數個資料區後,系統改而將後相機影像檔案(R File X)寫入至數個資料區。系統將持續如圖11B的標號1-8所示,在兩個檔案間來回交換儲存。因此,安全數位儲存裝置1110將不會連續的往鄰近的下一個資料區進行寫入,而是「跳」至一個較遠的資料區寫入另一個檔案。這樣的情形將被認為是「隨機寫入」或「隨機跳躍」,導致安全數位寫入操作的效率下降。However, when multiple files are to be simultaneously written to the secure
圖12A顯示本發明具有被組態的交錯式檔案目錄表以及檔案位置配置表的儲存裝置之一實施例的示意圖。圖12B顯示本發明如何將資料以交錯方法儲存於複數資料區之一實施例的示意圖。在圖12A中,安全數位儲存裝置1210包括開機區段1220、檔案位置配置表1230、檔案目錄表1240以及複數資料區1250,並在圖12B中邏輯性地繪示邏輯資料區1260的寫入操作示意圖。FIG. 12A shows a schematic diagram of one embodiment of a storage device having an interleaved file directory table and a file location configuration table configured according to the present invention. FIG. 12B shows a schematic diagram of one embodiment of how the present invention stores data in a plurality of data regions in an interleaved manner. In FIG. 12A, the secure
為了解決如圖11A以及圖11B所描述的隨機寫入問題,在檔案位置配置表1230所儲存的相關影像檔案的資料區列表是以交錯的形式來格式化或組態。明顯地,藉由將資料區交錯,可消除隨機寫入的狀況。這樣交錯分布的方法可基於在資料區的每個影像檔案的位元率分布比例來進行。In order to solve the random write problem as described in FIGS. 11A and 11B , the data area list of the related image files stored in the file location configuration table 1230 is formatted or configured in an interleaved form. Obviously, by interleaving the data regions, the random write condition can be eliminated. Such a staggered distribution method can be performed based on the distribution ratio of the bit rate of each image file in the data area.
舉例而言,假設前相機影像檔案(F File X)以及後相機影像檔案(R File X)的位元率比例為1:1。在這樣的情形下,檔案位置配置表1230格式化或組態以使前相機影像檔案(F File X)以及後相機影像檔案(R File X)的每個連續資料區都平均地一一交錯,而成為以如資料區1250以及邏輯資料區1260所示的方式進行儲存的資料區。For example, assume that the bit rate ratio of the front camera image file (F File X) and the rear camera image file (R File X) is 1:1. In such a case, the file location configuration table 1230 is formatted or configured so that each successive data area of the front camera image file (F File X) and the rear camera image file (R File X) are evenly interleaved one by one, It becomes a data area that is stored as shown in the
當然,前相機影像檔案(F File X)以及後相機影像檔案(R File X)的位元率也可以放大K倍,表示為K:K(例如K=2)。在這樣的情形下,兩個影像檔案的資料區列表可如圖13A以及圖13B所示的交錯,其中由於交錯資料區比例不限於單一資料區與單一資料區間的比例,圖13A以及圖13B所示的可被認為是「更改後」的交錯式檔案目錄表與檔案位置配置表。因此,圖13A顯示安全數位儲存裝置1310包括開機區段1320、檔案位置配置表1330、檔案目錄表1340以及複數資料區1350,並在圖13B中邏輯性地繪示邏輯資料區1360的寫入操作示意圖。如圖所示,各前相機影像檔案(F File X)以及後相機影像檔案(R File X)被配置為每兩個資料區(K=2)交錯的情形。因此,即使每個獨立的檔案具有較多資料區的額外需求,交錯形式的檔案位置配置表1330以及資料區1350均可克服隨機寫入的狀況。Of course, the bit rate of the front camera image file (F File X) and the rear camera image file (R File X) can also be enlarged by K times, expressed as K:K (eg K=2). In this case, the data area lists of the two image files can be interleaved as shown in FIG. 13A and FIG. 13B . Since the ratio of interleaved data areas is not limited to the ratio of a single data area to a single data interval, the data area lists shown in FIGS. 13A and 13B It shows what can be considered a "changed" interleaved file directory table and file location configuration table. Therefore, FIG. 13A shows that the secure
圖14A顯示本發明另一個具有被組態的更改後的交錯式檔案位置配置表的儲存裝置之一實施例的示意圖。圖14B顯示本發明如何將資料以另一更改後的交錯方法儲存於複數資料區之一實施例的示意圖。圖14A顯示安全數位儲存裝置1410包括開機區段1420、檔案位置配置表1430、檔案目錄表1440以及複數資料區1450,並在圖14B中邏輯性地繪示為邏輯資料區1460。圖14A以及圖14B顯示前相機影像檔案(F File X)以及後相機影像檔案(R File X)的位元率比例並不一定為1:1,而可為不均等的比例,例如2:1。因此,如檔案位置配置表1430所示,每兩個配置給前相機影像檔案(F File X)的資料區是與一個配置給後相機影像檔案(R File X)的資料區交錯。資料區1450以及資料區1460即顯示出這樣範例性的配置方式。FIG. 14A shows a schematic diagram of another embodiment of a storage device having a configured staggered file location allocation table according to the present invention. FIG. 14B shows a schematic diagram of one embodiment of how the present invention stores data in a plurality of data areas with another modified interleaving method. 14A shows that the secure
根據上述,本技術領域具有通常知識者可了解,當將多個檔案個別以連續配置的資料區進行儲存時,會產生非期望的隨機寫入情形。這樣的情形將使安全數位寫入操作的效能下降。本發明提出的交錯方式可克服這樣的缺陷。更進一步地,根據影像檔案間的位元率比例,每個影像檔案的交錯式資料區列表可在格式化時被組態。當檔案被錄製時,系統將使檔案間的安全數位寫入根據位元率比例交替進行。並且,明顯地,隨機的安全數位寫入可被避免,而使連續資料區寫入在安全數位寫入效能被維持的情形下進行。According to the above, those skilled in the art can understand that when a plurality of files are individually stored in consecutively arranged data areas, an unexpected random write situation will occur. Such a situation would degrade the performance of the secure digital write operation. The interleaving method proposed by the present invention can overcome such defects. Furthermore, according to the bit rate ratio between the image files, the list of interleaved data fields for each image file can be configured at the time of formatting. When files are recorded, the system will alternate secure digital writes between files according to the bit rate ratio. And, obviously, random secure bit writes can be avoided, allowing sequential data area writes to be performed with secure bit write performance maintained.
如圖4-7的實施例所述,在未預期的電力失效事件中,最後寫入的資料將由於完整的資料鏈結的存在而可被找回。並且,當循環錄影時,就檔案不會被刪除,而僅有在檔案目錄表(430、1140、1240、1340、1440)的檔案名稱更改,因而改進檔案搬移的效能。這些優點依舊存在於此描述的交錯方法。As described in the embodiments of Figures 4-7, in the event of an unexpected power failure, the last written data will be retrieved due to the existence of a complete data link. Moreover, when recording in a loop, the file will not be deleted, but only the file name in the file directory table (430, 1140, 1240, 1340, 1440) will be changed, thus improving the performance of file transfer. These advantages remain with the interleaving method described herein.
交錯方法亦可使用要實質上同時錄製的影像檔案間的位元率比例,來對每個資料區的配置進行組態。在格式化階段,將資料區列表規劃為交錯狀。當實質上同時的錄製一檔案群組(例如前相機影像檔案(F File X)以及後相機影像檔案(R File X))時,系統將使安全數位寫入根據組態的資料區數目的比例,交錯寫入不同的檔案。這樣的組合可達成連續資料區寫入並維持安全數位寫入的效能。The interleaving method can also use the bit rate ratio between the image files to be recorded substantially simultaneously to configure the configuration of each data area. During the formatting phase, the list of data areas is planned to be staggered. When recording a file group (such as the front camera image file (F File X) and the rear camera image file (R File X)) at substantially the same time, the system will write the security digits in proportion to the number of data areas configured , which interleaves writing to different files. Such a combination can achieve continuous data area writing and maintain the performance of secure digital writing.
最後,須注意的是,上述具有交錯機制的資料區列表可應用在不限於僅兩個影像檔案(例如前相機影像檔案(F File X)以及後相機影像檔案(R File X))上,亦可應用於三個或三個以上的交錯式影像檔案資料區中。Finally, it should be noted that the above data area list with interleaving mechanism can be applied to not only two image files (such as the front camera image file (F File X) and the rear camera image file (R File X)), but also Can be applied to three or more interleaved image file data areas.
雖然本案之實施例如上所述,然而該些實施例並非用來限定本案,本技術領域具有通常知識者可依據本案之明示或隱含之內容對本案之技術特徵施以變化,凡此種種變化均可能屬於本案所尋求之專利保護範疇,換言之,本案之專利保護範圍須視本說明書之申請專利範圍所界定者為準。Although the embodiments of the present case are as described above, these embodiments are not intended to limit the present case. Those with ordinary knowledge in the technical field can make changes to the technical features of the present case according to the explicit or implicit contents of the present case. All may belong to the scope of patent protection sought in this case. In other words, the scope of patent protection in this case must be determined by the scope of the patent application in this specification.
100:控制系統
110:儲存單元
120:控制器
130:處理器
200:攝影機
400:儲存裝置
420:檔案位置配置表
430:檔案目錄表
440:資料區
900:儲存裝置
920:檔案位置配置表
930:檔案目錄表
940:資料區
FA、FB、FC、FD、FE:檔案
S501~S503、S704~S707、S901~S908:步驟
1110、1210、1310、1410:安全數位儲存裝置
1120、1220、1320、1420:開機區段
1130、1230、1330、1430:檔案位置配置表
1140、1240、1340、1440:檔案目錄表
1150、1250、1350、1450:資料區
1160、1170、1260、1360、1460:邏輯資料區
F File X:前相機影像檔案
R File X:後相機影像檔案100: Control System
110: Storage unit
120: Controller
130: Processor
200: Camera
400: Storage Device
420: File location configuration table
430: Archive Directory Table
440:Data area
900: Storage Device
920: File location configuration table
930: Archive Directory Table
940:Data area
FA, FB, FC, FD, FE: File
S501~S503, S704~S707, S901~S908:
[圖1]顯示習知採用FAT檔案系統之儲存裝置的示意圖; [圖2]顯示習知行車記錄器之檔案寫入方法的流程圖; [圖3]顯示根據第2圖之操作之儲存裝置的示例圖; [圖4]顯示根據本發明一實施例所繪示之控制系統之方塊圖; [圖5]顯示本發明行車記錄器之儲存裝置的控制方法之一實施例的流程圖; [圖6]顯示本發明具有被組態的檔案目錄表與檔案位置配置表之儲存裝置之一實施例的示意圖; [圖7]顯示本發明寫入資料至儲存裝置之一實施例的流程圖; [圖8]顯示根據第7圖之操作之儲存裝置的示例圖; [圖9]顯示本發明預先組態的連續資料區的結構之一實施例的示意圖; [圖10]顯示本發明預先組態的連續資料區的結構之一實施例的示意圖,其中此連續資料區支援儲存來自不同應用程式的多個檔案; [圖11A]以及[圖11B]顯示[圖10]的檔案儲存方法的潛在缺陷的示意圖; [圖12A]顯示本發明具有被組態的交錯式檔案目錄表以及檔案位置配置表的儲存裝置之一實施例的示意圖; [圖12B]顯示本發明如何將資料以交錯方法儲存於複數資料區之一實施例的示意圖; [圖13A]顯示本發明一個具有被組態的更改後的交錯式檔案位置配置表的儲存裝置之一實施例的示意圖; [圖13B]顯示本發明如何將資料以一更改後的交錯方法儲存於複數資料區之一實施例的示意圖; [圖14A]顯示本發明另一個具有被組態的更改後的交錯式檔案位置配置表的儲存裝置之一實施例的示意圖;以及 [圖14B]顯示本發明如何將資料以另一更改後的交錯方法儲存於複數資料區之一實施例的示意圖。[Fig. 1] is a schematic diagram showing a conventional storage device using the FAT file system; [Fig. 2] A flow chart showing the file writing method of the conventional driving recorder; [FIG. 3] An exemplary diagram showing the storage device according to the operation of FIG. 2; [ Fig. 4 ] shows a block diagram of a control system according to an embodiment of the present invention; [ FIG. 5 ] is a flowchart showing an embodiment of the control method of the storage device of the driving recorder of the present invention; [ Fig. 6 ] is a schematic diagram showing an embodiment of the storage device having a configured file directory table and a file location configuration table of the present invention; [FIG. 7] is a flowchart showing an embodiment of the present invention for writing data to a storage device; [FIG. 8] An example diagram showing a storage device according to the operation of FIG. 7; [FIG. 9] A schematic diagram showing an embodiment of the structure of the preconfigured continuous data area of the present invention; [FIG. 10] is a schematic diagram showing one embodiment of the structure of the preconfigured continuous data area of the present invention, wherein the continuous data area supports the storage of multiple files from different applications; [FIG. 11A] and [FIG. 11B] are schematic diagrams showing potential defects of the file storage method of [FIG. 10]; [FIG. 12A] is a schematic diagram showing one embodiment of a storage device having a configured interleaved file directory table and a file location configuration table of the present invention; [FIG. 12B] is a schematic diagram showing an embodiment of how the present invention stores data in a plurality of data areas in an interleaved method; [ FIG. 13A ] is a schematic diagram showing an embodiment of a storage device having a configured interleaved file location configuration table of the present invention; [FIG. 13B] is a schematic diagram showing an embodiment of how the present invention stores data in a plurality of data areas with a modified interleaving method; [FIG. 14A] is a schematic diagram showing another embodiment of a storage device having a configured modified staggered file location table of the present invention; and [FIG. 14B] A schematic diagram showing an embodiment of how the present invention stores data in a plurality of data areas with another modified interleaving method.
1210:安全數位儲存裝置1210: Secure Digital Storage Device
1220:開機區段1220: Boot section
1230:檔案位置配置表1230: File location configuration table
1240:檔案目錄表1240: Archive directory table
1250:資料區1250:Data area
1260:邏輯資料區1260: Logical data area
F File X:前相機影像檔案F File X: Front Camera Image File
R File X:後相機影像檔案R File X: Rear Camera Image File
Claims (12)
Applications Claiming Priority (2)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
US16/985,288 US11435922B2 (en) | 2017-06-27 | 2020-08-05 | Control method for storage device of driving recorder and storage device control system |
US16/985,288 | 2020-08-05 |
Publications (2)
Publication Number | Publication Date |
---|---|
TW202207038A TW202207038A (en) | 2022-02-16 |
TWI774451B true TWI774451B (en) | 2022-08-11 |
Family
ID=78100704
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
TW110123809A TWI774451B (en) | 2020-08-05 | 2021-06-29 | Controlling method of storage of driving recorder and storage controlling system |
Country Status (4)
Country | Link |
---|---|
JP (1) | JP7245876B2 (en) |
KR (1) | KR102521528B1 (en) |
CN (1) | CN113535268A (en) |
TW (1) | TWI774451B (en) |
Citations (2)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
US20180373728A1 (en) * | 2017-06-27 | 2018-12-27 | Mstar Semiconductor, Inc. | Control method for storage device of driving recorder and storage device control system |
CN109308267A (en) * | 2017-07-28 | 2019-02-05 | 聚星电子股份有限公司 | The control method and storage device control system of the storage device of drive recorder |
Family Cites Families (10)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
JP2001043631A (en) | 1999-07-29 | 2001-02-16 | Sharp Corp | Data recording method and data recorder |
JP2001325128A (en) | 2000-05-15 | 2001-11-22 | Sony Corp | Method for managing file and recording or reproducing device |
CN1685420B (en) * | 2002-11-08 | 2010-07-07 | Lg电子有限公司 | Method and apparatus for recording and reproducing a multi-component data stream on a high-density recording medium |
US7720356B2 (en) * | 2002-11-12 | 2010-05-18 | Lg Electronics Inc | Recording medium having data structure for managing reproduction of multiple reproduction path video data recorded thereon and recording and reproducing methods and apparatuses |
JP2004355707A (en) | 2003-05-28 | 2004-12-16 | Hitachi Global Storage Technologies Inc | Recording and reproducing method and magnetic disk device |
JP5106576B2 (en) * | 2009-06-04 | 2012-12-26 | パナソニック株式会社 | Recording apparatus, recording method, and program |
TWI541816B (en) * | 2011-06-20 | 2016-07-11 | 鑫創科技股份有限公司 | Traffic recorder, flash memory device and management method thereof |
KR101373703B1 (en) * | 2012-05-23 | 2014-03-13 | 주식회사 코아로직 | Apparatus and method for processing image for vehicle |
KR101553237B1 (en) | 2014-01-17 | 2015-09-30 | 주식회사 엠티오메가 | Fat file system, vehicle multi media data storing apparatus and method that uses it |
TWI555406B (en) | 2014-11-20 | 2016-10-21 | 聯詠科技股份有限公司 | Storage method and processing device and video recording system thereof |
-
2021
- 2021-06-29 TW TW110123809A patent/TWI774451B/en active
- 2021-07-21 CN CN202110824880.4A patent/CN113535268A/en active Pending
- 2021-07-26 KR KR1020210097867A patent/KR102521528B1/en active IP Right Grant
- 2021-07-30 JP JP2021125600A patent/JP7245876B2/en active Active
Patent Citations (3)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
US20180373728A1 (en) * | 2017-06-27 | 2018-12-27 | Mstar Semiconductor, Inc. | Control method for storage device of driving recorder and storage device control system |
TW201905697A (en) * | 2017-06-27 | 2019-02-01 | 晨星半導體股份有限公司 | Control method and storage device control system for storage device of driving recorder |
CN109308267A (en) * | 2017-07-28 | 2019-02-05 | 聚星电子股份有限公司 | The control method and storage device control system of the storage device of drive recorder |
Also Published As
Publication number | Publication date |
---|---|
JP2022031185A (en) | 2022-02-18 |
JP7245876B2 (en) | 2023-03-24 |
KR102521528B1 (en) | 2023-04-13 |
TW202207038A (en) | 2022-02-16 |
KR20220017832A (en) | 2022-02-14 |
CN113535268A (en) | 2021-10-22 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
JP5954751B2 (en) | Method and file system for rolling back data on tape | |
JP4452363B2 (en) | File system | |
JP3266536B2 (en) | Method for pre-formatting and formatting magnetic tape media | |
US20110252212A1 (en) | Storage control system and method | |
US7747810B2 (en) | Address assigning method, disk drive, and data writing method | |
EP1770494A1 (en) | System for controlling the spinning of disks | |
JP2007265403A (en) | Remote mirroring method between tiered storage systems | |
JP2006277737A (en) | Nonvolatile storage device having address predicting function | |
JP6391061B2 (en) | How to write a file on tape | |
JP2008146408A (en) | Data storage device, data rearrangement method for it, and program | |
JP2776335B2 (en) | How to write variable-length sequential records | |
US20090083503A1 (en) | System of creating logical volume and method thereof | |
TWI774451B (en) | Controlling method of storage of driving recorder and storage controlling system | |
JP2005202942A (en) | Information recording medium, data processor and data processing method | |
US10769109B2 (en) | Control method for storage device of driving recorder and storage device control system | |
US11435922B2 (en) | Control method for storage device of driving recorder and storage device control system | |
CN109308267B (en) | Control method and control system of storage device of driving recorder | |
JPH0330034A (en) | Optical disk file managing method | |
GB2536385A (en) | Method for backing up data on tape | |
US6574704B1 (en) | Information storage management device and method, control device and method | |
JP2003272296A (en) | Multi-information recording method and multi- information recording system employing magnetic recording disk unit | |
JP2001290713A (en) | Storage device system and method for acquiring its backup | |
JPH08286838A (en) | Storage controller | |
JPH11102311A (en) | Data base reconstituting device and program storage medium | |
JP2004078445A (en) | Filesystem, file management method, and file management system |