JP2006146467A - Recording medium and storage area changing method - Google Patents

Recording medium and storage area changing method Download PDF

Info

Publication number
JP2006146467A
JP2006146467A JP2004334140A JP2004334140A JP2006146467A JP 2006146467 A JP2006146467 A JP 2006146467A JP 2004334140 A JP2004334140 A JP 2004334140A JP 2004334140 A JP2004334140 A JP 2004334140A JP 2006146467 A JP2006146467 A JP 2006146467A
Authority
JP
Japan
Prior art keywords
active area
recording
recording medium
storage
reproducing apparatus
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.)
Pending
Application number
JP2004334140A
Other languages
Japanese (ja)
Inventor
Yasushi Imamura
泰 今村
Yasushi Ueda
泰志 上田
Makoto Okazaki
誠 岡▲崎▼
Daisuke Kondo
大輔 近藤
Mamiko Akizuki
麻水子 秋月
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.)
Panasonic Holdings Corp
Original Assignee
Matsushita Electric Industrial 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 Matsushita Electric Industrial Co Ltd filed Critical Matsushita Electric Industrial Co Ltd
Priority to JP2004334140A priority Critical patent/JP2006146467A/en
Publication of JP2006146467A publication Critical patent/JP2006146467A/en
Pending legal-status Critical Current

Links

Images

Landscapes

  • Information Retrieval, Db Structures And Fs Structures Therefor (AREA)

Abstract

<P>PROBLEM TO BE SOLVED: To provide a recording medium which has a storage means which is divided into a plurality of storage areas and automatically switches a storage area when the remainder of an active area becomes small so as to use a large-capacity recording medium in a conventional recording-and-reproducing device. <P>SOLUTION: A readable and writable recording medium 100, which is connected to an external recording-and-reproducing device to use, is provided with; a storage means 160 having a plurality of storage areas; a controller 120 which controls the storage means 160 based on instructions from the recording-and-reproducing device; an active area designation register 140 which designates an active area from the plurality of storage areas; and an active area changing means 150 which switches an active area if the remainder of the active area is at a preliminarily fixed threshold value or less. By this, the recording medium can control the switching of the storage areas. <P>COPYRIGHT: (C)2006,JPO&NCIPI

Description

本発明は、記憶領域を切り替えることができる記録媒体及び記憶領域切り替え方法に関する。   The present invention relates to a recording medium capable of switching storage areas and a storage area switching method.

デジタルカメラや携帯電話などの記録再生装置は、コンパクトフラッシュ(登録商標)やSD(Secure Digital)カードに代表されるフラッシュメモリを用いたメモリカードを記録媒体とする。近年、半導体技術や実装技術の進展に伴い、メモリカードの容量は2ギガバイト(以下GB)を超えようとしている。また、数十GBの容量を持つ磁気ディスク装置を、仮想的にメモリカードとして見せる装置も提案されている(例えば、特許文献1参照)。   A recording / playback apparatus such as a digital camera or a mobile phone uses a memory card using a flash memory represented by a CompactFlash (registered trademark) or SD (Secure Digital) card as a recording medium. In recent years, with the progress of semiconductor technology and mounting technology, the capacity of a memory card is about to exceed 2 gigabytes (hereinafter referred to as GB). There has also been proposed a device that virtually shows a magnetic disk device having a capacity of several tens GB as a memory card (see, for example, Patent Document 1).

一方、従来の多くの記録再生装置は、代表的なファイルシステムであるFAT16(File Allocation Table 16)を用いて、記録媒体内の静止画ファイルや動画ファイルなどを管理している。しかし、FAT16は、クラスタを管理するアドレスが16ビットのファイルシステムである。クラスタサイズを32キロバイト(以下KB)とすると、FAT16ファイルシステムで管理できる容量は、最大2GBでしかない。従って、従来のFAT16の記録再生装置において、容量が2GBを超える記録媒体を利用する場合、2GBを超える領域を容易に取り扱えないという課題がある。   On the other hand, many conventional recording / playback apparatuses manage still image files, moving image files, and the like in a recording medium using FAT16 (File Allocation Table 16) which is a typical file system. However, the FAT 16 is a file system whose address for managing a cluster is 16 bits. If the cluster size is 32 kilobytes (hereinafter referred to as KB), the capacity that can be managed by the FAT16 file system is only 2 GB at maximum. Therefore, in a conventional FAT16 recording / reproducing apparatus, when a recording medium having a capacity exceeding 2 GB is used, there is a problem that an area exceeding 2 GB cannot be easily handled.

この課題に対して、従来のメモリカード及び記憶領域切り替え方法は、2GB以内の複数の記憶領域を持つメモリカードにメカニカルスイッチを具備することにより、複数の記憶領域の中から一つを選択できるようにしている(例えば、特許文献2参照)。
特開2004−213487号公報 特開2004−86503号公報
In response to this problem, the conventional memory card and storage area switching method can select one of a plurality of storage areas by providing a mechanical switch in a memory card having a plurality of storage areas within 2 GB. (For example, refer to Patent Document 2).
JP 2004-213487 A JP 2004-86503 A

前記従来の構成では、複数の記憶領域から一つを選択するために、新たにメカニカルスイッチを追加しなければならない。   In the conventional configuration, a new mechanical switch has to be added to select one from a plurality of storage areas.

しかしながら、メモリカードの形状は規格で決まっている。例えば、SDカードの場合はSDメモリカード規格により、外形寸法が24.0mm(W)×32.0mm(L)×2.1mm(T)であり、ライトプロテクト用のスイッチの位置も決められている。新たにメカニカルスイッチを追加するには、新たに規格を策定しなければならないという課題がある。   However, the shape of the memory card is determined by the standard. For example, in the case of an SD card, the external dimensions are 24.0 mm (W) × 32.0 mm (L) × 2.1 mm (T) according to the SD memory card standard, and the position of the write protect switch is also determined. Yes. In order to add a new mechanical switch, there is a problem that a new standard has to be formulated.

また、メモリカードの形状を変更するためには、メモリカード生産のための金型を変更しなければならないので、製造コストが高価になるという課題がある。   In addition, in order to change the shape of the memory card, it is necessary to change the mold for producing the memory card, so that there is a problem that the manufacturing cost becomes expensive.

本発明は、前記従来の課題を解決するもので、規格で定められた形状の変更を伴わずに、複数の記憶領域の中から一つを選択することができる記録媒体及び記憶領域切り替え方法を提供することを目的とする。   The present invention solves the above-mentioned conventional problems, and provides a recording medium and a storage area switching method capable of selecting one of a plurality of storage areas without changing the shape defined by the standard. The purpose is to provide.

前記従来の課題を解決するために、本発明の記録媒体は、外部の記録再生装置に接続して使用する読み書き可能な記録媒体において、前記記録再生装置と接続されるインターフェースと、複数の記憶領域を持つ記憶手段と、記録媒体固有の特性値を保持する内部レジスタと、前記記録再生装置の指示もしくは前記内部レジスタの値に基づいて前記記憶手段を制御するコントローラと、前記複数の記憶領域の中の一つの領域をアクティブ領域として指定するアクティブ領域指定レジスタと、前記アクティブ領域指定レジスタに前記アクティブ領域の切り替えを指示するとともに、前記記録再生装置に切り替えた新たなアクティブ領域を認識させるアクティブ領域切り替え手段とからなり、前記アクティブ領域切り替え手段は、前記アクティブ領域の残記憶容量に基づいてアクティブ領域を切り替えるか否かを判断することを特徴とするものである。   In order to solve the above-described conventional problems, the recording medium of the present invention is a readable / writable recording medium used by connecting to an external recording / reproducing apparatus, an interface connected to the recording / reproducing apparatus, and a plurality of storage areas A storage unit having a characteristic value unique to the recording medium, a controller for controlling the storage unit based on an instruction from the recording / reproducing apparatus or the value of the internal register, and a plurality of storage areas An active area designation register for designating one area of the active area as an active area, and an active area switching means for instructing the active area designation register to switch the active area and for causing the recording / reproducing apparatus to recognize the new active area. The active area switching means comprises the active area. It is characterized in that to determine whether to switch the active region based on the remaining storage capacity.

さらに記録媒体において、前記アクティブ領域切り替え手段は、前記コントローラからファイルシステムを受け取り前記アクティブ領域の残量を算出する残量算出手段と、前記残量と予め定めた閾値とを比較し前記アクティブ領域の切り替えを判定するアクティブ領域切り替え判定手段と、前記アクティブ領域切り替え判定手段によって前記アクティブ領域を切り替える判定がなされた場合に、前記アクティブ領域指定レジスタの値を更新するアクティブ領域指定レジスタ更新手段と、前記インターフェースを制御してカードの挿抜信号を発生し、前記記録再生装置にカードの挿抜を行ったと検知させる挿抜制御手段とからなることを特徴とするものである。   Further, in the recording medium, the active area switching unit compares the remaining amount with a predetermined threshold value by comparing a remaining amount calculating unit that receives a file system from the controller and calculates the remaining amount of the active area, and compares the remaining amount of the active area. An active region switching determination unit that determines switching; an active region designation register updating unit that updates a value of the active region designation register when the active region switching determination unit determines to switch the active region; and the interface And a card insertion / removal control means for generating a card insertion / removal signal and detecting that the recording / reproducing apparatus has inserted / removed the card.

さらに記録媒体において、前記コントローラは、前記アクティブ領域指定レジスタからアクティブ領域の容量を計算するアクティブ領域容量計算手段と、前記アクティブ領域容量計算手段の計算結果を基に前記内部レジスタの一部を置換する内部レジスタ変換手段とを含むことを特徴とするものである。   Further, in the recording medium, the controller replaces a part of the internal register based on the calculation result of the active area capacity calculating means and the active area capacity calculating means for calculating the capacity of the active area from the active area designation register. And internal register conversion means.

さらに記録媒体において、前記コントローラは、前記アクティブ領域指定レジスタからアドレスのオフセットを計算するオフセット計算手段と、前記オフセット計算手段の計算結果と前記記録再生装置から送信されたアドレスを加算する加算器とを含むことを特徴とするものである。   Further, in the recording medium, the controller includes an offset calculating unit that calculates an offset of the address from the active area designation register, and an adder that adds the calculation result of the offset calculating unit and the address transmitted from the recording / reproducing apparatus. It is characterized by including.

さらに記録媒体において、前記コントローラは、前記記録再生装置が読み書きするファイルシステムを蓄積する手段を含むことを特徴とするものである。   Further, in the recording medium, the controller includes means for storing a file system that is read and written by the recording / reproducing apparatus.

さらに記録媒体において、前記アクティブ領域指定レジスタが指定する記憶領域を外部から認識できる表示手段を備えることを特徴とするものである。   Further, the recording medium further comprises display means for recognizing the storage area designated by the active area designation register from the outside.

さらに記録媒体において、前記アクティブ領域指定レジスタが指定する記憶領域が切り替わったことを外部から認識できる表示手段を備えることを特徴とするものである。   Further, the recording medium further comprises display means for recognizing from the outside that the storage area designated by the active area designation register has been switched.

さらに本発明の記憶領域切り替え方法において、外部の記録再生装置に接続して使用する読み書き可能であり、前記記録再生装置と接続されるインターフェースと、複数の記憶領域を持つ記憶手段と、記録媒体固有の特性値を保持する内部レジスタと、前記記録再生装置の指示や前記内部レジスタの値に基づいて前記記憶手段を制御するコントローラと、前記複数の記憶領域の中からアクティブ領域を指定するアクティブ領域指定レジスタと、前記アクティブ領域の残量に基づいて前記アクティブ領域を切り替えるアクティブ領域切り替え手段とからなる記録媒体の記憶領域切り替え方法において、前記アクティブ領域のファイルシステムを読み出すステップと、前記ファイルシステムを基に前記アクティブ領域の残量を算出するステップと、前記残量と予め定めた閾値とを比較し前記アクティブ領域の切り替えを判定するステップと、前記アクティブ領域を切り替える判定がなされた場合に、前記アクティブ領域指定レジスタの値を更新するステップと、前記アクティブ領域を切り替える判定がなされた場合に、前記インターフェースを制御して疑似的にカードの挿抜を発生して前記記録再生装置にカードの挿抜を検知させるステップからなることを特徴とするものである。   Furthermore, in the storage area switching method of the present invention, it is possible to read and write by connecting to an external recording / reproducing apparatus, an interface connected to the recording / reproducing apparatus, a storage means having a plurality of storage areas, and a recording medium specific An internal register that holds the characteristic value of the controller, a controller that controls the storage means based on an instruction of the recording / reproducing apparatus and a value of the internal register, and an active area designation that designates an active area from the plurality of storage areas In a storage area switching method of a recording medium comprising a register and an active area switching means for switching the active area based on a remaining amount of the active area, a step of reading a file system of the active area, and based on the file system Calculating a remaining amount of the active area; Comparing the remaining amount with a predetermined threshold to determine switching of the active region, updating a value of the active region designation register when the determination of switching the active region is made, and the active When it is determined to switch the area, the interface is controlled to generate a card insertion / removal in a pseudo manner so that the recording / reproducing apparatus detects the card insertion / removal.

本発明の記録媒体及び記憶領域切り替え方法によれば、規格で定められた形状の変更を伴わずに、記録媒体内にある複数の記憶領域の中から一つを選択することができる。   According to the recording medium and the storage area switching method of the present invention, one of a plurality of storage areas in the recording medium can be selected without changing the shape defined by the standard.

以下に、本発明の記録媒体及び記憶領域切り替え方法の実施の形態を図面とともに詳細に説明する。   Embodiments of a recording medium and a storage area switching method of the present invention will be described below in detail with reference to the drawings.

図1は、本発明の第1の実施例における記録媒体のブロック図を示す。図1において、記録媒体100はSDメモリカードを想定している。110は記録再生装置(図示せず)と信号のやり取りを行うインターフェース、130は記録媒体100の固有情報を保存している内部レジスタ、160は複数の記憶領域を持つ記憶手段である。120は、SDメモリカードの規格に従って、記録再生装置との通信プロトコルの制御及び内部レジスタ130や記憶手段160とのアクセスを行うコントローラである。140は複数の記憶領域の中からアクティブ領域を指定するアクティブ領域指定レジスタ、150はアクティブ領域の残量に基づいてアクティブ領域を切り替えるアクティブ領域切り替え手段である。   FIG. 1 shows a block diagram of a recording medium in the first embodiment of the present invention. In FIG. 1, the recording medium 100 is assumed to be an SD memory card. Reference numeral 110 denotes an interface for exchanging signals with a recording / reproducing apparatus (not shown), 130 denotes an internal register for storing unique information of the recording medium 100, and 160 denotes storage means having a plurality of storage areas. A controller 120 controls the communication protocol with the recording / reproducing apparatus and accesses the internal register 130 and the storage unit 160 in accordance with the SD memory card standard. Reference numeral 140 denotes an active area designation register that designates an active area from among a plurality of storage areas, and reference numeral 150 denotes active area switching means for switching the active area based on the remaining amount of the active area.

SDメモリカードにおいて、インターフェース110は、図2に示すように複数の端子とインターフェースドライバ200から構成される。図2は、本発明の第1の実施例におけるインターフェース110の詳細を示す図である。端子は、全部で9個あり、外部の記録再生装置(図示せず)と接続される。端子VDDと端子VSS1、端子VSS2により、記録媒体100は記録再生装置から電源を供給される。また、端子CLK(クロック信号)に同期した端子CMD(コマンドやレスポンス)及び端子DAT0、端子DAT1、端子DAT2、端子DAT3(データ)が送受信される。インターフェースドライバ200は、SDメモリカードの規格に従って、端子からコマンドやデータを取り込んだり、レスポンスやデータを端子へ出力したりする。なお、端子DAT3と兼用の端子CDは、カードが記録再生装置と接続されているかどうかの検出に用いられる。   In the SD memory card, the interface 110 includes a plurality of terminals and an interface driver 200 as shown in FIG. FIG. 2 is a diagram showing details of the interface 110 in the first embodiment of the present invention. There are a total of nine terminals, which are connected to an external recording / reproducing apparatus (not shown). The recording medium 100 is supplied with power from the recording / reproducing apparatus through the terminal VDD, the terminal VSS1, and the terminal VSS2. Further, the terminal CMD (command or response) synchronized with the terminal CLK (clock signal) and the terminal DAT0, the terminal DAT1, the terminal DAT2, and the terminal DAT3 (data) are transmitted and received. The interface driver 200 fetches commands and data from the terminals and outputs responses and data to the terminals according to the SD memory card standard. The terminal CD also used as the terminal DAT3 is used for detecting whether or not the card is connected to the recording / reproducing apparatus.

内部レジスタ130は、SDメモリカードの規格に従って、複数のレジスタから構成される。各レジスタは、記録再生装置からのコマンドによって読み出され、記録再生装置の動作に影響を与える。例えば、カードの動作電源電圧やカードの各仕様値などが記録されている。後述するアクティブ領域の最大バイト数が記録されているレジスタもあり、記録再生装置はこの値をカードの記憶容量として認識する。   The internal register 130 includes a plurality of registers according to the SD memory card standard. Each register is read by a command from the recording / reproducing apparatus, and affects the operation of the recording / reproducing apparatus. For example, the operating power supply voltage of the card, each specification value of the card, and the like are recorded. There is also a register in which the maximum number of bytes in the active area described later is recorded, and the recording / reproducing apparatus recognizes this value as the storage capacity of the card.

記憶手段160は、一つ以上の記憶領域から構成されている。図3は、本発明の第1の実施例における記憶手段160の構成を示す図である。図3では、8GBの容量を持つ記憶手段160が、2GBの容量を持つ4個の記憶領域(第一の記憶領域161〜第四の記憶領域164)から構成される例を示している。また、図3では、第一の記憶領域161がFAT16ファイルシステムにフォーマットされている例を示している。FAT16ファイルシステムでは、マスターブートレコード/パーティションテーブル、パーティションブートセクタ、ファイルアロケーションテーブル1、ファイルアロケーションテーブル2、ルートディレクトリが書き込まれ、データ領域が作成される。記憶手段160は、外部記憶再生装置からアドレスを指定してデータを読み出したり、アドレスとデータを指定してデータを書き込んだりできる。   The storage means 160 is composed of one or more storage areas. FIG. 3 is a diagram showing the configuration of the storage means 160 in the first embodiment of the present invention. FIG. 3 shows an example in which the storage unit 160 having a capacity of 8 GB is configured by four storage areas (first storage area 161 to fourth storage area 164) having a capacity of 2 GB. FIG. 3 shows an example in which the first storage area 161 is formatted in the FAT16 file system. In the FAT16 file system, a master boot record / partition table, a partition boot sector, a file allocation table 1, a file allocation table 2, and a root directory are written to create a data area. The storage means 160 can read data by designating an address from an external storage / reproduction device, and can write data by designating the address and data.

アクティブ領域指定レジスタ140は、複数の記憶領域の中からアクティブ領域を指定する。アクティブ領域とは、記録再生装置に認識されている領域である。アクティブ領域指定レジスタ140は、記憶領域ごとにアクティブかどうかを表現する1ビットフラグの集合である。各記憶領域に対応したフラグは、1の時にその記憶領域がアクティブ領域であることを意味し、0の時にその記憶領域が非アクティブであることを意味する。このフラグは、記憶領域の数に対応したビット数分存在するので、アクティブ領域指定レジスタ140のビット数も、記憶領域の数に対応したビット数になる。例えば、図3のように記憶手段160が4個の記憶領域から構成される場合は、アクティブ領域指定レジスタ140は4ビットのレジスタになる。   The active area designation register 140 designates an active area from among a plurality of storage areas. The active area is an area recognized by the recording / reproducing apparatus. The active area designation register 140 is a set of 1-bit flags expressing whether each storage area is active. The flag corresponding to each storage area means that the storage area is an active area when it is 1, and means that the storage area is inactive when it is 0. Since this flag exists for the number of bits corresponding to the number of storage areas, the number of bits of the active area designation register 140 also becomes the number of bits corresponding to the number of storage areas. For example, when the storage unit 160 is composed of four storage areas as shown in FIG. 3, the active area designation register 140 is a 4-bit register.

図4は、本発明の第1の実施例における記憶領域の切り替え及びアクティブ領域指定レジスタ140の値を示す図である。図4において、点線で描いた記憶領域は非アクティブ領域を示す。   FIG. 4 is a diagram showing storage area switching and the value of the active area designation register 140 in the first embodiment of the present invention. In FIG. 4, the storage area drawn with a dotted line indicates an inactive area.

図4(a)は、第一の記憶領域161がアクティブになっている様子を示しており、この時、アクティブ領域指定レジスタ140の値は0001b(以下、最後のbは二進数を表す)である。すなわち、第一の記憶領域161に対応するアクティブ領域指定レジスタ140のビット0(最下位ビットをビット0とする)が1になっている。   FIG. 4A shows a state in which the first storage area 161 is active. At this time, the value of the active area designation register 140 is 0001b (hereinafter, the last b represents a binary number). is there. That is, bit 0 (the least significant bit is bit 0) of the active area designation register 140 corresponding to the first storage area 161 is 1.

同様に、図4(b)は第二の記憶領域162、図4(c)は第三の記憶領域163、図4(d)は第四の記憶領域164がアクティブになっており、アクティブ領域指定レジスタ140の値は、それぞれ0010b、0100b、1000bとなる。   Similarly, FIG. 4B shows the second storage area 162, FIG. 4C shows the third storage area 163, and FIG. 4D shows the fourth storage area 164 active. The values of the designation register 140 are 0010b, 0100b, and 1000b, respectively.

図4(e)は、アクティブ領域指定レジスタ140の値が1111bであり、全ての記憶領域がアクティブ領域であることを示している。この場合は、記憶手段160全体が一つの記憶領域として記録再生装置に認識される。記録再生装置が、大容量に対応したファイルシステムを利用可能な場合(FAT16ファイルシステムではなく、例えばFAT32ファイルシステム)、記録再生装置は8GBの大容量SDメモリカードとして記録媒体100にアクセスできる。なお、この機能(記憶手段160全体を一つの記憶領域とする機能)は、オプションであり実装しなくても良い。   FIG. 4E shows that the value of the active area designation register 140 is 1111b and all the storage areas are active areas. In this case, the entire storage unit 160 is recognized by the recording / reproducing apparatus as one storage area. When the recording / reproducing apparatus can use a file system corresponding to a large capacity (for example, FAT32 file system instead of FAT16 file system), the recording / reproducing apparatus can access the recording medium 100 as an 8 GB large capacity SD memory card. Note that this function (a function of using the entire storage unit 160 as one storage area) is an option and may not be implemented.

アクティブ領域切り替え手段150は、アクティブ領域の残量に基づいてアクティブ領域を切り替えるとともに、疑似的にカードの挿抜を発生する。図5は、本発明の第1の実施例におけるアクティブ領域切り替え手段150のブロック図を示す。図5に示すように、アクティブ領域切り替え手段150は、残量算出手段630、アクティブ領域切り替え判定手段660、アクティブ領域指定レジスタ更新手段680、疑似挿抜手段700から構成される。   The active area switching means 150 switches the active area based on the remaining amount of the active area and generates a card insertion / removal in a pseudo manner. FIG. 5 shows a block diagram of the active area switching means 150 in the first embodiment of the present invention. As shown in FIG. 5, the active area switching unit 150 includes a remaining amount calculation unit 630, an active area switching determination unit 660, an active area designation register update unit 680, and a pseudo insertion / extraction unit 700.

残量算出手段630は、コントローラ120が蓄積したファイルシステムからファイルアロケーションテーブルを読み出す(コントローラ120がファイルシステムを蓄積する動作の詳細は後述)。ファイルシステムは、図3で説明したように、マスターブートレコード/パーティションテーブル、パーティションブートセクタ、ファイルアロケーションテーブル1、ファイルアロケーションテーブル2、ルートディレクトリ、データ領域から構成される。残量算出手段630は、コントローラ120からパーティションテーブル内に格納されているパーティションタイプの情報を読み出し、ファイルシステムの種類を識別する。もし未知のファイルシステムであれば、以降の処理は行わない。既知のファイルシステムであれば、ファイルアロケーションテーブル1及びファイルアロケーションテーブル2が格納されている先頭アドレスを読み出す。ファイルアロケーションテーブルは、ファイルアロケーションテーブル1の領域とファイルアロケーションテーブル2の領域に同じ内容が格納されている。これは、ファイルアロケーションテーブルが、ファイルのつながりを保持する重要なデータであり、内容が二重化されているためである。残量算出手段630は、ファイルアロケーションテーブル1またはファイルアロケーションテーブル2をFAT620として読み出す。   The remaining amount calculation unit 630 reads the file allocation table from the file system accumulated by the controller 120 (details of the operation of the controller 120 accumulating the file system will be described later). As described with reference to FIG. 3, the file system includes a master boot record / partition table, a partition boot sector, a file allocation table 1, a file allocation table 2, a root directory, and a data area. The remaining amount calculation unit 630 reads the partition type information stored in the partition table from the controller 120 and identifies the type of the file system. If the file system is unknown, no further processing is performed. If the file system is a known file system, the head addresses at which the file allocation table 1 and the file allocation table 2 are stored are read out. In the file allocation table, the same contents are stored in the area of the file allocation table 1 and the area of the file allocation table 2. This is because the file allocation table is important data for maintaining the connection of files, and the contents are duplicated. The remaining amount calculation unit 630 reads the file allocation table 1 or the file allocation table 2 as the FAT 620.

さらに、残量算出手段630は、FAT620を基にアクティブ領域の残量を算出する。FAT620は、クラスタ毎の状態、すなわち、対応するクラスタが使用中か未使用か、使用中であればどのクラスタと接続するか、という情報を記憶している。ここで、クラスタとは、連続する複数のセクタ(1セクタは512バイト)を一つの単位とした領域であり、FAT16ファイルシステムでは、クラスタサイズとして32KBが選択される。残量算出手段630は、FAT620からクラスタが使用中か未使用かという情報を読み出し、未使用クラスタの数をカウントして、アクティブ領域の残量640として出力する。   Further, the remaining amount calculating unit 630 calculates the remaining amount of the active area based on the FAT 620. The FAT 620 stores information on the state of each cluster, that is, whether the corresponding cluster is in use or unused, and which cluster to connect to if it is in use. Here, the cluster is an area having a plurality of consecutive sectors (one sector is 512 bytes) as one unit. In the FAT16 file system, 32 KB is selected as the cluster size. The remaining amount calculation means 630 reads information indicating whether the cluster is in use or not used from the FAT 620, counts the number of unused clusters, and outputs it as the remaining amount 640 of the active area.

アクティブ領域切り替え判定手段660は、残量算出手段630が算出した残量640と予め定めた所定の切り替え残量650とを比較し、アクティブ領域切り替えの有無を判定して、アクティブ領域切り替え制御信号670を出力する。すなわち、アクティブ領域の残量640が切り替え残量650よりも大きい場合は、アクティブ領域の切り替え無しと判定しアクティブ領域切り替え制御信号670を0とし、アクティブ領域の残量640が切り替え残量650よりも小さい場合は、アクティブ領域の切り替え有りと判定しアクティブ領域切り替え制御信号670を1とし、その後0に戻す。アクティブ領域切り替え制御信号670を1にすることによって、アクティブ領域指定レジスタ更新手段680がアクティブ領域指定レジスタ140の値を更新したり、疑似挿抜手段700がインターフェース110を制御して疑似的にカードの挿抜を発生したりする。なお、アクティブ領域切り替え制御信号670の初期値(電源投入時の値)は、0である。   The active region switching determination unit 660 compares the remaining amount 640 calculated by the remaining amount calculation unit 630 with a predetermined switching remaining amount 650, determines whether or not there is active region switching, and determines an active region switching control signal 670. Is output. That is, when the active area remaining amount 640 is larger than the switching remaining amount 650, it is determined that there is no switching of the active region, the active region switching control signal 670 is set to 0, and the active region remaining amount 640 is larger than the switching remaining amount 650. If it is smaller, it is determined that the active area has been switched, and the active area switching control signal 670 is set to 1 and then returned to 0. By setting the active area switching control signal 670 to 1, the active area designation register updating means 680 updates the value of the active area designation register 140, or the pseudo insertion / removal means 700 controls the interface 110 to artificially insert / remove the card. Is generated. Note that the initial value of the active region switching control signal 670 (the value when the power is turned on) is zero.

アクティブ領域指定レジスタ更新手段680は、アクティブ領域切り替え制御信号670に従い、アクティブ領域指定レジスタ140に設定する値REG690を求める。すなわち、アクティブ領域切り替え制御信号670の値が0の場合は現在のREG690の値を保持し、1の場合は以下に示すアクティブ領域指定レジスタ更新手段680の詳細フローに従ってREG690の値を更新する。   The active area designation register updating unit 680 obtains a value REG 690 to be set in the active area designation register 140 in accordance with the active area switching control signal 670. That is, when the value of the active region switching control signal 670 is 0, the current value of the REG 690 is held, and when the value is 1, the value of the REG 690 is updated according to the detailed flow of the active region designation register update unit 680 shown below.

図7は、本発明の第1の実施例におけるアクティブ領域指定レジスタ更新手段680の第1の詳細フローを示す図である。まず、現在のアクティブ領域指定レジスタ140の値REGを1ビット左シフトしてREGに格納するステップ740を実行し、次に、そのREGと1111bの論理積をREGに格納するステップ750を実行する。ここで、REGと論理積する1111bは、図4のように記憶手段160が4個の記憶領域から構成されている場合の例であり、記憶領域の数に対応するビット数で決まる。ステップ750の結果のREGが0かどうか判断するステップ760において、REGが0以外の場合は、全体の処理を終了する。すなわち、図4の(a)→(b)、(b)→(c)、(c)→(d)の場合であり、REGの値が、0001b→0010b、0010b→0100b、0100b→1000bと変化する場合である。ステップ760において、REGが0の場合は、REGを0001bとするステップ770を実行して全体の処理を終了する。すなわち、図4の(d)→(a)の場合であり、REGの値が、1000b→0001bと変化する場合である。図7で示すアクティブ領域の切り替えは、アクティブ領域指定レジスタ140の値が1111bとなるオプション、すなわち、全ての記憶領域をアクティブ領域とするオプションを実装しない場合のフローを示している。   FIG. 7 is a diagram showing a first detailed flow of the active area designation register updating means 680 in the first embodiment of the present invention. First, step 740 is executed in which the value REG of the current active area designation register 140 is shifted to the left by 1 bit and stored in REG. Next, step 750 in which the logical product of the REG and 1111b is stored in REG is executed. Here, 1111b logically ANDed with REG is an example in the case where the storage unit 160 is composed of four storage areas as shown in FIG. 4, and is determined by the number of bits corresponding to the number of storage areas. In step 760 in which it is determined whether or not REG as a result of step 750 is 0. If REG is other than 0, the entire process is terminated. That is, it is the case of (a) → (b), (b) → (c), (c) → (d) in FIG. 4, and the REG values are 0001b → 0010b, 0010b → 0100b, 0100b → 1000b. This is the case when it changes. In step 760, if REG is 0, step 770 is executed in which REG is set to 0001b, and the entire process is terminated. That is, it is the case of (d) → (a) in FIG. 4, and the value of REG changes from 1000b → 0001b. The switching of the active area shown in FIG. 7 shows a flow in the case where the option in which the value of the active area specifying register 140 is 1111b, that is, the option in which all the storage areas are active areas is not implemented.

図8は、本発明の第1の実施例におけるアクティブ領域指定レジスタ更新手段680の第2の詳細フローを示す図である。図8は、前記オプションを実装する場合のフローである。まず、REGの値が1111bかどうか判断するステップ780を実行する。REGが1111bの場合は、REGを0001bとするステップ770を実行して全体の処理を終了する。すなわち、図4の(e)→(a)の場合であり、REGの値が、1111b→0001bと変化する場合である。REGが1111b以外の場合は、図7と同様、REGを1ビット左シフトして1111bと論理積を取りREGに格納するステップ740、ステップ750を実行する。そして、ステップ750の結果のREGが0かどうか判断するステップ760において、REGが0以外の場合は、全体の処理を終了する。ステップ760において、REGが0の場合は、REGを1111bとするステップ790を実行して全体の処理を終了する。すなわち、図4の(d)→(e)の場合であり、REGの値が、1000b→1111bと変化する場合である。   FIG. 8 is a diagram showing a second detailed flow of the active area designation register updating means 680 in the first embodiment of the present invention. FIG. 8 is a flow for implementing the option. First, step 780 is executed to determine whether the value of REG is 1111b. If REG is 1111b, step 770 in which REG is set to 0001b is executed, and the entire process is terminated. That is, it is the case of (e) → (a) in FIG. 4, and the value of REG changes from 1111b → 0001b. If REG is other than 1111b, Step 740 and Step 750 are executed, as in FIG. 7, where REG is shifted left by 1 bit, ANDed with 1111b, and stored in REG. Then, in step 760 for determining whether or not REG as a result of step 750 is 0, if REG is other than 0, the entire process is terminated. In step 760, when REG is 0, step 790 which sets REG to 1111b is executed, and the whole processing is ended. That is, it is the case of (d) → (e) in FIG. 4, and the value of REG changes from 1000b → 1111b.

以上のように、アクティブ領域切り替え手段150は、REG690の値を計算して、アクティブ領域指定レジスタ140の値を書き換える。なお、アクティブ領域指定レジスタ140の初期状態(工場出荷時)の値は、0001bである。   As described above, the active area switching unit 150 calculates the value of REG 690 and rewrites the value of the active area designation register 140. Note that the value of the active area designation register 140 in the initial state (at the time of factory shipment) is 0001b.

疑似挿抜手段700は、アクティブ領域切り替え制御信号670に従い、インターフェース110を制御して疑似的にカードの挿抜を制御する。すなわち、アクティブ領域切り替え制御信号670の値が1の場合はカードの抜き出し状態を疑似的に発生し、0の場合はカードの挿入状態を疑似的に発生する。図6は、本発明の第1の実施例における疑似挿抜手段700のブロック図及び記録再生装置との接続を示す図である。図6において、疑似挿抜手段700のスイッチ500は、VDD520から抵抗値R1を持つ抵抗器510を介した信号とカード検出信号710とを接続しており、アクティブ領域切り替え制御信号670により制御される。スイッチ500は、アクティブ領域切り替え制御信号670が0の時に導通し、1の時に切断するスイッチである。カード検出信号710は、図2の端子CDと接続され、記録再生装置のDET信号530として出力される。DET信号530は、VSS540と抵抗値R2を持つ抵抗器550を介して接続されている。すなわち、DET信号530は、プルダウンされた状態であり、アクティブ領域切り替え制御信号670が1の時に0、0の時に1となる。記録再生装置は、DET信号530を監視することにより、カードの挿抜状態を認識することができる。なお、抵抗値R2は抵抗値R1に比べて十分大きな値を持つ。   The pseudo insertion / extraction means 700 controls the interface 110 in accordance with the active area switching control signal 670 to control the card insertion / removal in a pseudo manner. That is, when the value of the active area switching control signal 670 is 1, a card removal state is generated in a pseudo manner, and when the value is 0, a card insertion state is generated in a pseudo manner. FIG. 6 is a block diagram of the pseudo insertion / extraction means 700 in the first embodiment of the present invention and a diagram showing the connection with the recording / reproducing apparatus. In FIG. 6, the switch 500 of the pseudo insertion / extraction means 700 connects a signal from the VDD 520 via the resistor 510 having the resistance value R1 and the card detection signal 710, and is controlled by the active area switching control signal 670. The switch 500 is a switch that is turned on when the active area switching control signal 670 is 0, and is turned off when the signal is 1. The card detection signal 710 is connected to the terminal CD in FIG. 2 and is output as the DET signal 530 of the recording / reproducing apparatus. The DET signal 530 is connected to the VSS 540 via a resistor 550 having a resistance value R2. That is, the DET signal 530 is pulled down, and is 0 when the active area switching control signal 670 is 1 and 1 when 0. The recording / reproducing apparatus can recognize the card insertion / removal state by monitoring the DET signal 530. The resistance value R2 has a sufficiently large value compared to the resistance value R1.

以上のように、アクティブ領域切り替え手段150は、アクティブ領域の残量に基づいてアクティブ領域切り替え制御信号670を生成し、アクティブ領域を切り替えるとともに、疑似的にカードの挿抜を発生する。   As described above, the active area switching unit 150 generates the active area switching control signal 670 based on the remaining amount of the active area, switches the active area, and artificially inserts / removes the card.

コントローラ120は、SDメモリカードの規格に従って、記録再生装置と通信を行う手段である。図9は、本発明の第1の実施例におけるコントローラ120のブロック図を示す。コントローラ120は、インターフェース110経由で記録再生装置から受信したコマンド800とデータ820をコマンドデコーダ830により解釈して、記録再生装置にレスポンス810やデータ820をインターフェース110経由で送信する。コントローラ120は、コマンド800に基づいて記憶手段160に記録再生装置からのデータ820を書き込み、記録再生装置へデータ820を読み出す。また、内部レジスタ130の値を記録再生装置へデータ820として読み出す。   The controller 120 is means for communicating with the recording / reproducing apparatus in accordance with the SD memory card standard. FIG. 9 shows a block diagram of the controller 120 in the first embodiment of the present invention. The controller 120 interprets the command 800 and data 820 received from the recording / reproducing apparatus via the interface 110 by the command decoder 830 and transmits a response 810 and data 820 to the recording / reproducing apparatus via the interface 110. Based on the command 800, the controller 120 writes the data 820 from the recording / reproducing apparatus in the storage unit 160 and reads the data 820 to the recording / reproducing apparatus. Further, the value of the internal register 130 is read as data 820 to the recording / reproducing apparatus.

以下では、コントローラ120におけるSDメモリカードの規格と異なる三つの動作について説明する。第一の動作は、アクティブ領域指定レジスタ140の値によって、記憶手段160へのアドレスにオフセットを加算する動作である。第二の動作は、記録再生装置が記憶手段160から読み出したり、記憶手段160に書き込んだりするファイルシステムを蓄積する動作である。第三の動作は、アクティブ領域指定レジスタ140の値によって、内部レジスタ130から読み出したデータを変換する動作である。   In the following, three operations different from the SD memory card standard in the controller 120 will be described. The first operation is an operation of adding an offset to the address to the storage means 160 according to the value of the active area designation register 140. The second operation is an operation of accumulating a file system that the recording / reproducing apparatus reads from the storage unit 160 and writes to the storage unit 160. The third operation is an operation for converting the data read from the internal register 130 according to the value of the active area designation register 140.

第一の動作では、記録再生装置は記憶手段160に対してアクセス(読み出しまたは書き込み)する。コマンド800とデータ820は、インターフェース110からコマンドデコーダ830へ入力される。コマンドデコーダ830は、コマンド800が記憶手段160に対するアクセスである場合、アドレス取得手段860を作用させてデータ820を論理アドレス870として取得する。また、オフセット計算手段840を作用させてアクティブ領域指定レジスタ140を基にオフセット850を計算する(計算方法の詳細は後述)。さらに、論理アドレス870とオフセット850を加算器880により足し合わせて、物理アドレス890に変換する。コントローラ120は、物理アドレス890によって、記憶手段160からデータ820を読み出したり、データ820を書き込んだりする。   In the first operation, the recording / reproducing apparatus accesses (reads or writes) the storage unit 160. The command 800 and data 820 are input from the interface 110 to the command decoder 830. When the command 800 is an access to the storage unit 160, the command decoder 830 operates the address acquisition unit 860 to acquire the data 820 as the logical address 870. Further, the offset calculation means 840 is operated to calculate the offset 850 based on the active area designation register 140 (details of the calculation method will be described later). Further, the logical address 870 and the offset 850 are added together by an adder 880 to be converted into a physical address 890. The controller 120 reads data 820 from the storage unit 160 and writes data 820 by the physical address 890.

オフセット850は、現在のアクティブ領域の先頭アドレスが論理アドレスの0番地になるように、アクティブ領域指定レジスタ140を基に計算する。すなわち、アクティブ領域指定レジスタ140の値が1のビットのうち、一番下位にあるビットをビットN(最下位ビットが0)とし、それぞれの記憶領域のブロック数をBとすると、N×Bで計算できる。ただし、ブロック数Bは、それぞれの記憶領域の容量、クラスタごとのバイト数によって、予め決められている。例えば、それぞれの記憶領域が2GB、クラスタごとのセクタ数が32KBであれば、B=2GB/32KB=65536となる。この時、アクティブ領域指定レジスタ140の値が0100bであれば、オフセット850は、2×65536=0x20000(16進数)となる。   The offset 850 is calculated based on the active area designation register 140 so that the head address of the current active area becomes the logical address 0. That is, among the bits having the value of the active area designation register 140 of 1, the lowest bit is bit N (the least significant bit is 0), and the number of blocks in each storage area is B, N × B. Can be calculated. However, the block number B is determined in advance depending on the capacity of each storage area and the number of bytes for each cluster. For example, if each storage area is 2 GB and the number of sectors per cluster is 32 KB, B = 2 GB / 32 KB = 65536. At this time, if the value of the active area designation register 140 is 0100b, the offset 850 is 2 × 65536 = 0x20000 (hexadecimal number).

第二の動作では、記録再生装置は第一の動作と同様に、記憶手段160に対してアクセスする。ファイルシステムバッファ610は、記録再生装置のアクセスにより生成される物理アドレス890とデータ820を監視して、アクティブ領域のファイルシステムを蓄積する。すなわち、記憶手段160から読み出されるファイルシステムのデータと記憶手段160へ書き込まれるファイルシステムのデータをバッファ内に格納し、アクティブ領域のファイルシステムと同じデータを保持する。ファイルシステムのデータかどうかは、物理アドレス890の値がアクティブ領域の先頭セクタかどうかによって識別できる。ファイルシステムバッファ610に蓄積されたファイルシステムは、アクティブ領域切り替え手段150においてアクティブ領域の残量を算出するために利用される。なお、本実施例では記録再生装置のアクセスを監視してファイルシステムを蓄積する方法を説明したが、コントローラ120自身が能動的に記憶手段160からファイルシステムを読み出す方法も容易に考えられる。   In the second operation, the recording / reproducing apparatus accesses the storage unit 160 as in the first operation. The file system buffer 610 monitors the physical address 890 and data 820 generated by the access of the recording / reproducing apparatus, and accumulates the file system of the active area. That is, the file system data read from the storage unit 160 and the file system data written to the storage unit 160 are stored in the buffer, and the same data as the file system of the active area is held. Whether the data is file system data can be identified by whether the value of the physical address 890 is the first sector of the active area. The file system stored in the file system buffer 610 is used by the active area switching means 150 to calculate the remaining active area. In the present embodiment, the method of monitoring the access of the recording / reproducing apparatus and accumulating the file system has been described. However, a method in which the controller 120 itself actively reads out the file system from the storage unit 160 can be easily considered.

第三の動作では、記録再生装置は内部レジスタ130に対して値を読み出す。コマンド800とデータ820は、インターフェース110からコマンドデコーダ830へ入力される。コマンドデコーダ830は、コマンド800が内部レジスタ130に対する読み出しである場合、アクティブ領域容量計算手段900を作用させてアクティブ領域指定レジスタ140を基にアクティブ領域の最大バイト数910を計算し、内部レジスタ130を内部レジスタ変換手段920によって変換する。アクティブ領域容量計算手段900は、アクティブ領域指定レジスタ140の値が1のビット数をM、それぞれの記憶領域の容量をDとすると、最大バイト数910をM×Dで計算する。アクティブ領域指定レジスタ140の値が0010b、D=2GBであれば、最大バイト数910は、1×2GB=2GBとなる。内部レジスタ変換手段920は、内部レジスタ130のうち、アクティブ領域の最大バイト数が記録されているレジスタだけを変換する。最大バイト数910は、SDメモリカードの規格に従って、内部レジスタ130と同じ書式でデータ820として読み出される。これ以外のレジスタは変換されず、読み出した内部レジスタ130の値がそのままデータ820として読み出される。   In the third operation, the recording / reproducing apparatus reads a value from the internal register 130. The command 800 and data 820 are input from the interface 110 to the command decoder 830. When the command 800 is a read from the internal register 130, the command decoder 830 operates the active area capacity calculation unit 900 to calculate the maximum number of bytes 910 of the active area based on the active area designation register 140, and sets the internal register 130. The internal register conversion means 920 performs conversion. The active area capacity calculation means 900 calculates the maximum number of bytes 910 as M × D, where M is the number of bits whose active area designation register 140 is 1 and D is the capacity of each storage area. If the value of the active area designation register 140 is 0010b and D = 2 GB, the maximum number of bytes 910 is 1 × 2 GB = 2 GB. The internal register conversion means 920 converts only the register in which the maximum number of bytes in the active area is recorded among the internal registers 130. The maximum number of bytes 910 is read as data 820 in the same format as the internal register 130 in accordance with the SD memory card standard. Other registers are not converted, and the read value of the internal register 130 is read as data 820 as it is.

以上のように構成された記録媒体について、以下、記録再生装置に接続された時の動作を説明する。また、記憶領域の切り替え方法ついても説明する。   The operation of the recording medium configured as described above when connected to the recording / reproducing apparatus will be described below. A method for switching storage areas will also be described.

まず、記録再生装置の利用者は、記録再生装置に本発明の記録媒体を挿入し、記録再生装置の電源をオンにする。アクティブ領域切り替え制御信号670の初期値は0なので、カード検出信号710には1が出力されDET信号530も1になる。すなわち、記録再生装置は、カードの挿入を検出する。記録再生装置は、その初期化手順の中で、記録媒体の各仕様を記録媒体から読み出す。記録媒体の各仕様は、記録媒体の内部レジスタに格納されており、記録再生装置の動作に影響する。また、記録装置に記録されたファイルフォーマット(ファイルシステム)も、記録再生装置の動作に影響を及ぼす。   First, the user of the recording / reproducing apparatus inserts the recording medium of the present invention into the recording / reproducing apparatus and turns on the power of the recording / reproducing apparatus. Since the initial value of the active area switching control signal 670 is 0, 1 is output to the card detection signal 710 and the DET signal 530 is also 1. That is, the recording / reproducing apparatus detects insertion of a card. The recording / reproducing apparatus reads each specification of the recording medium from the recording medium in the initialization procedure. Each specification of the recording medium is stored in an internal register of the recording medium and affects the operation of the recording / reproducing apparatus. Further, the file format (file system) recorded in the recording apparatus also affects the operation of the recording / reproducing apparatus.

記録媒体がフォーマット済みの場合、記録再生装置は、論理アドレスの0番地から記録媒体のフォーマット情報を読み出して、記録媒体にアクセスしようとする。この時、本発明の記録媒体は、コントローラ120の第一の動作で説明したように、オフセット計算手段840によって計算されたオフセットを論理アドレスに加算して物理アドレスに変換し、記憶手段へアクセスする。すなわち、記録再生装置は、記憶領域が複数あることを認識しないまま、記録媒体のアクティブ領域が論理アドレス0番地にあるように、記録媒体にアクセスすることになる。   When the recording medium has been formatted, the recording / reproducing apparatus reads the format information of the recording medium from address 0 of the logical address and tries to access the recording medium. At this time, as described in the first operation of the controller 120, the recording medium of the present invention adds the offset calculated by the offset calculation means 840 to the logical address to convert it into a physical address, and accesses the storage means. . That is, the recording / reproducing apparatus accesses the recording medium so that the active area of the recording medium is at logical address 0 without recognizing that there are a plurality of storage areas.

記録媒体が未フォーマットの場合、記録再生装置は、記録媒体の内部レジスタから最大バイト数を読み出して、記録再生装置が取り扱えるファイルシステムで記録媒体をフォーマットしようとする。この時、本発明の記録媒体は、コントローラ120の第二の動作で説明したように、内部レジスタに格納された最大バイト数の代わりに、アクティブ領域容量計算手段900によって計算された最大バイト数を、記録再生装置へ出力する。すなわち、記録再生装置は、記憶媒体の実際の記憶容量を認識しないまま、記録媒体がアクティブ領域分の記憶容量しかないものとして、記録媒体をフォーマットすることになる。   When the recording medium is unformatted, the recording / reproducing apparatus reads the maximum number of bytes from the internal register of the recording medium and attempts to format the recording medium with a file system that can be handled by the recording / reproducing apparatus. At this time, as described in the second operation of the controller 120, the recording medium of the present invention uses the maximum number of bytes calculated by the active area capacity calculation unit 900 instead of the maximum number of bytes stored in the internal register. To the recording / reproducing apparatus. That is, the recording / reproducing apparatus formats the recording medium on the assumption that the recording medium has only the storage capacity for the active area without recognizing the actual storage capacity of the storage medium.

次に、記録再生装置の利用者は、記録再生装置の機能を用いて、記録媒体へ各種データを格納していく。例えば、デジタルカメラの静止画データであったり、オーディオプレーヤーの音楽データであったりする。利用者による利用が進むと、記憶媒体は次第に残り容量が少なくなっていく。この時、本発明の記録媒体では、記録媒体がアクティブ領域の残量を監視し、自動的にアクティブ領域を切り替えることができる。記録再生装置では、カードが抜き出されて新たに空き容量の大きいカードが挿入されたように認識する。   Next, the user of the recording / reproducing apparatus stores various data on the recording medium using the function of the recording / reproducing apparatus. For example, it may be still image data of a digital camera or music data of an audio player. As usage by the user progresses, the remaining capacity of the storage medium gradually decreases. At this time, in the recording medium of the present invention, the recording medium can monitor the remaining amount of the active area and automatically switch the active area. In the recording / reproducing apparatus, it is recognized that the card has been removed and a new card with a large free space has been inserted.

以上のように、本発明の第1の実施例においては、アクティブ領域指定レジスタとアクティブ領域切り替え手段を設けることにより、アクティブ領域の残量が少なくなった場合に、アクティブ領域を自動的に切り替えることができ、複数の記憶領域の中からアクティブ領域を指定することができる。同時に、疑似的にカードの挿抜を発生して記録再生装置にカードの挿抜を検知させることができる。   As described above, in the first embodiment of the present invention, the active region is automatically switched when the remaining amount of the active region is reduced by providing the active region designation register and the active region switching means. The active area can be designated from a plurality of storage areas. At the same time, it is possible to cause the recording / reproducing apparatus to detect the insertion / removal of the card by pseudo-insertion / removal.

なお、本発明の第1の実施例では、DET信号530は単純にプルダウンされていると説明した。しかし、市販のカードソケットには、カードの挿入状態をメカ的に認識するメカニカルスイッチを具備してDET信号530と接続しているものがある。すなわち、メカニカルスイッチがオンの時に、DET信号530をプルアップする構成となっている。この場合は、本発明の記録媒体でカードの挿抜を疑似的に発生させても、記録再生装置にカードの挿抜を認識させることができない。本発明の記録媒体を利用して記憶領域の切り替えをするためには、記録再生装置側で、カードソケットのメカニカルスイッチを無効にするか、メカニカルスイッチを持たないカードソケットを利用する必要がある。   In the first embodiment of the present invention, it has been described that the DET signal 530 is simply pulled down. However, some commercially available card sockets include a mechanical switch that mechanically recognizes the insertion state of the card and is connected to the DET signal 530. That is, the DET signal 530 is pulled up when the mechanical switch is on. In this case, even if the card insertion / removal is artificially generated in the recording medium of the present invention, the recording / reproducing apparatus cannot recognize the card insertion / removal. In order to switch the storage area using the recording medium of the present invention, it is necessary to invalidate the mechanical switch of the card socket on the recording / reproducing apparatus side or to use a card socket having no mechanical switch.

また、本発明の第1の実施例では、記憶領域の分割をすべて同じ容量で説明したが、記憶領域の分割を記憶領域ごとに異なる容量とすることにより、記録再生装置に応じた容量の記録媒体として取り扱うことができる。   Further, in the first embodiment of the present invention, the division of the storage area has been described with the same capacity. However, by dividing the storage area into different capacities for each storage area, the capacity can be recorded according to the recording / reproducing apparatus. It can be handled as a medium.

また、本発明の第1の実施例では、記録媒体としてSDメモリカードを想定したが、コンパクトフラッシュ(登録商標)やメモリースティック(登録商標)であっても良い。   In the first embodiment of the present invention, an SD memory card is assumed as a recording medium. However, a compact flash (registered trademark) or a memory stick (registered trademark) may be used.

なお、本発明は、規格で定められた形状の変更を伴わずに、複数の記憶領域の中から一つを選択することができる記録媒体及び記憶領域切り替え方法を提供することを目的としているが、利用者の利便性を考慮して、現在アクティブな記憶領域を表示できるようにしても良い。図10を用いて具体例を説明する。図10は、本発明の第1の実施例における記録媒体の外観を示している。図10では、記録媒体の背面部に複数のLED950を具備している。LED950は、アクティブ領域指定レジスタの各ビットの値に対応して、1の時に点灯、0の時に消灯させる。これにより、記録媒体を記録再生装置に接続して利用中でも、利用者は、アクティブな記録領域を識別することができる。ただし、具備するLEDの個数やLEDの点灯方法は、上記の例に限定するものではない。   It is to be noted that the present invention has an object to provide a recording medium and a storage area switching method capable of selecting one of a plurality of storage areas without changing the shape defined by the standard. In consideration of the convenience of the user, the currently active storage area may be displayed. A specific example will be described with reference to FIG. FIG. 10 shows the appearance of the recording medium in the first embodiment of the present invention. In FIG. 10, a plurality of LEDs 950 are provided on the back surface of the recording medium. The LED 950 is turned on when it is 1 and turned off when it is 0, corresponding to the value of each bit of the active area designation register. Thereby, even when the recording medium is connected to the recording / reproducing apparatus and used, the user can identify the active recording area. However, the number of LEDs provided and the lighting method of the LEDs are not limited to the above example.

また、アクティブな記憶領域が切り替わったことを利用者へ伝達する手段を装備しても良い。例えば、記録媒体内部に音源を具備して音で伝達したり、LEDを具備してLEDを点滅させたりして伝達する手段が考えられる。   Further, a means for transmitting to the user that the active storage area has been switched may be provided. For example, there may be a means for transmitting a sound by providing a sound source inside the recording medium, or by transmitting an LED by blinking the LED.

本発明にかかる記録媒体は、アクティブ領域切り替え手段を有し、記録媒体内にある複数の記憶領域の中から一つを選択することができ、記録再生装置において大容量の記録媒体を扱う際に有用である。特に、デジタルカメラ等の記録再生装置に接続されるメモリカードに好適に利用できるものである。   The recording medium according to the present invention has an active area switching means, and can select one of a plurality of storage areas in the recording medium. When handling a large capacity recording medium in the recording / reproducing apparatus, Useful. In particular, it can be suitably used for a memory card connected to a recording / reproducing apparatus such as a digital camera.

本発明の第1の実施例における記録媒体のブロック図1 is a block diagram of a recording medium in a first embodiment of the present invention. 本発明の第1の実施例におけるインターフェースの詳細を示す図The figure which shows the detail of the interface in 1st Example of this invention 本発明の第1の実施例における記憶手段の構成を示す図The figure which shows the structure of the memory | storage means in 1st Example of this invention. 本発明の第1の実施例における記憶領域の切り替え及びアクティブ領域指定レジスタの値を示す図The figure which shows the value of the switching of a storage area and the active area designation | designated register in 1st Example of this invention 本発明の第1の実施例におけるアクティブ領域切り替え手段のブロック図Block diagram of active area switching means in the first embodiment of the present invention 本発明の第1の実施例における疑似挿抜手段のブロック図及び記録再生装置との接続を示す図The block diagram of the pseudo insertion / extraction means in the 1st Example of this invention, and the figure which shows the connection with a recording / reproducing apparatus 本発明の第1の実施例におけるアクティブ領域指定レジスタ更新手段の第1の詳細フローを示す図The figure which shows the 1st detailed flow of the active area designation | designated register update means in 1st Example of this invention. 本発明の第1の実施例におけるアクティブ領域指定レジスタ更新手段の第2の詳細フローを示す図The figure which shows the 2nd detailed flow of the active area designation register update means in 1st Example of this invention. 本発明の第1の実施例におけるコントローラのブロック図Block diagram of the controller in the first embodiment of the present invention 本発明の第1の実施例における記録媒体の外観図1 is an external view of a recording medium according to a first embodiment of the present invention.

符号の説明Explanation of symbols

100 記録媒体
110 インターフェース
120 コントローラ
130 内部レジスタ
140 アクティブ領域指定レジスタ
150 アクティブ領域切り替え手段
160 記憶手段
161 第一の記憶領域
162 第二の記憶領域
163 第三の記憶領域
164 第四の記憶領域
200 インターフェースドライバ
500 スイッチ
510 抵抗器
520 VDD
530 DET信号
540 VSS
550 抵抗器
610 ファイルシステムバッファ
620 FAT
630 残量検出手段
640 残量
650 切り替え残量
660 アクティブ領域切り替え判定手段
670 アクティブ領域切り替え制御信号
680 アクティブ領域指定レジスタ更新手段
690 REG
700 疑似挿抜手段
710 カード検出信号
800 コマンド
810 レスポンス
820 データ
830 コマンドデコーダ
840 オフセット計算手段
850 オフセット
860 アドレス取得手段
870 論理アドレス
880 加算器
890 物理アドレス
900 アクティブ領域容量計算手段
910 最大バイト数
920 内部レジスタ変換手段
950 LED
DESCRIPTION OF SYMBOLS 100 Recording medium 110 Interface 120 Controller 130 Internal register 140 Active area designation register 150 Active area switching means 160 Storage means 161 First storage area 162 Second storage area 163 Third storage area 164 Fourth storage area 200 Interface driver 500 switch 510 resistor 520 VDD
530 DET signal 540 VSS
550 Resistor 610 File System Buffer 620 FAT
630 Remaining capacity detecting means 640 Remaining capacity 650 Switching remaining capacity 660 Active area switching determining means 670 Active area switching control signal 680 Active area specifying register updating means 690 REG
700 pseudo insertion / extraction means 710 card detection signal 800 command 810 response 820 data 830 command decoder 840 offset calculation means 850 offset 860 address acquisition means 870 logical address 880 adder 890 physical address 900 active area capacity calculation means 910 maximum number of bytes 920 internal register conversion Means 950 LED

Claims (8)

外部の記録再生装置に接続して使用する読み書き可能な記録媒体において、
前記記録再生装置と接続されるインターフェースと、
複数の記憶領域を持つ記憶手段と、
記録媒体固有の特性値を保持する内部レジスタと、
前記記録再生装置の指示もしくは前記内部レジスタの値に基づいて前記記憶手段を制御するコントローラと、
前記複数の記憶領域の中の一つの領域をアクティブ領域として指定するアクティブ領域指定レジスタと、
前記アクティブ領域指定レジスタに前記アクティブ領域の切り替えを指示するとともに、前記記録再生装置に切り替えた新たなアクティブ領域を認識させるアクティブ領域切り替え手段とからなり、
前記アクティブ領域切り替え手段は、前記アクティブ領域の残記憶容量に基づいてアクティブ領域を切り替えるか否かを判断する
ことを特徴とする記録媒体。
In a readable / writable recording medium used by connecting to an external recording / reproducing device,
An interface connected to the recording / reproducing apparatus;
Storage means having a plurality of storage areas;
An internal register that holds characteristic values specific to the recording medium;
A controller for controlling the storage means based on an instruction of the recording / reproducing apparatus or a value of the internal register;
An active area designation register for designating one area of the plurality of storage areas as an active area;
The active area designation register is instructed to switch the active area, and comprises an active area switching means for recognizing the new active area switched to the recording / reproducing apparatus,
The recording medium according to claim 1, wherein the active area switching means determines whether to switch the active area based on a remaining storage capacity of the active area.
前記アクティブ領域切り替え手段は、
前記コントローラからファイルシステムを受け取り前記アクティブ領域の残量を算出する残量算出手段と、
前記残量と予め定めた閾値とを比較し前記アクティブ領域の切り替えを判定するアクティブ領域切り替え判定手段と、
前記アクティブ領域切り替え判定手段によって前記アクティブ領域を切り替える判定がなされた場合に、前記アクティブ領域指定レジスタの値を更新するアクティブ領域指定レジスタ更新手段と、
前記インターフェースを制御してカードの挿抜信号を発生し、前記記録再生装置にカードの挿抜を行ったと検知させる挿抜制御手段とからなる
ことを特徴とする請求項1に記載の記録媒体。
The active area switching means includes
A remaining amount calculating means for receiving a file system from the controller and calculating the remaining amount of the active area;
An active region switching determination unit that compares the remaining amount with a predetermined threshold and determines switching of the active region;
An active area designation register updating means for updating a value of the active area designation register when the active area switching judgment means determines to switch the active area;
2. The recording medium according to claim 1, further comprising insertion / removal control means for controlling the interface to generate a card insertion / removal signal and causing the recording / reproducing apparatus to detect that the card has been inserted / removed.
前記コントローラは、
前記アクティブ領域指定レジスタからアクティブ領域の容量を計算するアクティブ領域容量計算手段と、
前記アクティブ領域容量計算手段の計算結果を基に前記内部レジスタの一部を置換する内部レジスタ変換手段とを含む
ことを特徴とする請求項1に記載の記録媒体。
The controller is
Active area capacity calculating means for calculating the capacity of the active area from the active area designation register;
The recording medium according to claim 1, further comprising an internal register conversion unit that replaces a part of the internal register based on a calculation result of the active area capacity calculation unit.
前記コントローラは、
前記アクティブ領域指定レジスタからアドレスのオフセットを計算するオフセット計算手段と、
前記オフセット計算手段の計算結果と前記記録再生装置から送信されたアドレスを加算する加算器とを含む
ことを特徴とする請求項1に記載の記録媒体。
The controller is
Offset calculating means for calculating an offset of an address from the active area designation register;
The recording medium according to claim 1, further comprising: an adder that adds a calculation result of the offset calculation means and an address transmitted from the recording / reproducing apparatus.
前記コントローラは、
前記記録再生装置が読み書きするファイルシステムを蓄積する手段を含む
ことを特徴とする請求項1に記載の記録媒体。
The controller is
2. The recording medium according to claim 1, further comprising means for storing a file system that is read and written by the recording / reproducing apparatus.
前記アクティブ領域指定レジスタが指定する記憶領域を外部から認識できる表示手段を備える
ことを特徴とする請求項1に記載の記録媒体。
2. The recording medium according to claim 1, further comprising display means for recognizing a storage area designated by the active area designation register from outside.
前記アクティブ領域指定レジスタが指定する記憶領域が切り替わったことを外部から認識できる表示手段を備える
ことを特徴とする請求項1に記載の記録媒体。
2. The recording medium according to claim 1, further comprising display means for recognizing from the outside that the storage area designated by the active area designation register has been switched.
外部の記録再生装置に接続して使用する読み書き可能であり、
前記記録再生装置と接続されるインターフェースと、
複数の記憶領域を持つ記憶手段と、
記録媒体固有の特性値を保持する内部レジスタと、
前記記録再生装置の指示や前記内部レジスタの値に基づいて前記記憶手段を制御するコントローラと、
前記複数の記憶領域の中からアクティブ領域を指定するアクティブ領域指定レジスタと、
前記アクティブ領域の残量に基づいて前記アクティブ領域を切り替えるアクティブ領域切り替え手段とからなる記録媒体において、
前記アクティブ領域のファイルシステムを読み出すステップと、
前記ファイルシステムを基に前記アクティブ領域の残量を算出するステップと、
前記残量と予め定めた閾値とを比較し前記アクティブ領域の切り替えを判定するステップと、
前記アクティブ領域を切り替える判定がなされた場合に、前記アクティブ領域指定レジスタの値を更新するステップと、
前記アクティブ領域を切り替える判定がなされた場合に、前記インターフェースを制御して疑似的にカードの挿抜を発生して前記記録再生装置にカードの挿抜を検知させるステップからなる
ことを特徴とする記憶領域切り替え方法。
Read / write for use by connecting to an external recording / playback device.
An interface connected to the recording / reproducing apparatus;
Storage means having a plurality of storage areas;
An internal register that holds characteristic values specific to the recording medium;
A controller for controlling the storage means based on an instruction of the recording / reproducing apparatus or a value of the internal register;
An active area designation register for designating an active area from the plurality of storage areas;
In a recording medium comprising active area switching means for switching the active area based on the remaining amount of the active area,
Reading the file system of the active area;
Calculating the remaining amount of the active area based on the file system;
Comparing the remaining amount with a predetermined threshold and determining switching of the active region;
When it is determined to switch the active area, updating the value of the active area designation register; and
Storage area switching comprising the step of controlling the interface to generate a pseudo card insertion / removal and causing the recording / reproducing device to detect the card insertion / removal when it is determined to switch the active area Method.
JP2004334140A 2004-11-18 2004-11-18 Recording medium and storage area changing method Pending JP2006146467A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP2004334140A JP2006146467A (en) 2004-11-18 2004-11-18 Recording medium and storage area changing method

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP2004334140A JP2006146467A (en) 2004-11-18 2004-11-18 Recording medium and storage area changing method

Publications (1)

Publication Number Publication Date
JP2006146467A true JP2006146467A (en) 2006-06-08

Family

ID=36626088

Family Applications (1)

Application Number Title Priority Date Filing Date
JP2004334140A Pending JP2006146467A (en) 2004-11-18 2004-11-18 Recording medium and storage area changing method

Country Status (1)

Country Link
JP (1) JP2006146467A (en)

Cited By (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2010049530A (en) * 2008-08-22 2010-03-04 Buffalo Inc Memory card, memory card control device and memory card control method
US10868924B2 (en) 2018-03-29 2020-12-15 Ricoh Company, Ltd. Information processing apparatus and image forming apparatus
CN113056711A (en) * 2018-11-22 2021-06-29 三菱电机株式会社 Data control device, programmable logic controller and data control method

Cited By (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2010049530A (en) * 2008-08-22 2010-03-04 Buffalo Inc Memory card, memory card control device and memory card control method
US10868924B2 (en) 2018-03-29 2020-12-15 Ricoh Company, Ltd. Information processing apparatus and image forming apparatus
CN113056711A (en) * 2018-11-22 2021-06-29 三菱电机株式会社 Data control device, programmable logic controller and data control method
CN113056711B (en) * 2018-11-22 2022-04-15 三菱电机株式会社 Input/output control unit, PLC, and data control method

Similar Documents

Publication Publication Date Title
CN102063943B (en) Nand flash memory parameter automatic detecting system
JP5129156B2 (en) Access device and write-once recording system
US20070183179A1 (en) Semiconductor memory card, access device and method
JP2000047932A (en) Storage medium and electronic equipment system
JP3866635B2 (en) Memory card and storage area switching method
CN100545917C (en) The recording medium and the heavy method and apparatus of formatted record medium
JP2006146467A (en) Recording medium and storage area changing method
JP4732218B2 (en) Playback device
JP2006139550A (en) Recording medium
US20030007783A1 (en) Recording/reproducingdisk control device and disc apparatus comprising the same
JP2005339622A (en) Record management information recording method , information recording apparatus, and information recording medium
JP2010055139A (en) Memory controller, non-volatile storage device, access device, and non-volatile memory system
JP2006146466A (en) Recording medium and method for managing file system
US20100165503A1 (en) Method and apparatus for recording and reading information
US8321641B2 (en) Data access method and data access device
JP2006209562A (en) Storage medium and storage area switching method
CN110286855A (en) A kind of devices and methods therefor of the automatic assorted cold dishes of multiple TF cards
KR20060006978A (en) Flexible formatting for universal storage device
KR101339429B1 (en) Optical disc drive and driving method thereof
JP4586533B2 (en) Recording apparatus, address conversion apparatus, recording control method, and recording control program
KR100457694B1 (en) Hard disk servo information recording device and method
JP2001056777A (en) Digital data recording and reproducing device
JPS58219658A (en) Magnetic disk controller
JP2006128822A (en) Information storage device
KR200329876Y1 (en) Flash memory cartridge