JP2004094494A - Storage medium processing device and control method therefor - Google Patents
Storage medium processing device and control method therefor Download PDFInfo
- Publication number
- JP2004094494A JP2004094494A JP2002253370A JP2002253370A JP2004094494A JP 2004094494 A JP2004094494 A JP 2004094494A JP 2002253370 A JP2002253370 A JP 2002253370A JP 2002253370 A JP2002253370 A JP 2002253370A JP 2004094494 A JP2004094494 A JP 2004094494A
- Authority
- JP
- Japan
- Prior art keywords
- storage medium
- power
- processing device
- medium processing
- writing
- 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
Links
Images
Landscapes
- Techniques For Improving Reliability Of Storages (AREA)
Abstract
【課題】ユーザがメモリカードを抜きたいと思ったときに、メモリカードを抜く操作が自然で理解し易く、しかも、メモリカードを安全に抜くことができる記憶媒体処理装置を提供することを目的とするものである。
【解決手段】所定の記憶媒体を読み書きする記憶媒体読み書き手段と、記憶媒体処理装置の電源オンと電源断とを、利用者が指示する電源スイッチ手段と、この電源スイッチ手段を介して、電源断の指示を受けたときおよびそれ以降に、所定の条件を満たしている間は、上記電源断の指示を保留し、上記所定の条件を満たさなければ、上記記憶媒体処理装置の電源を断する電源制御手段とを有する記憶媒体処理装置である。
【選択図】 図1An object of the present invention is to provide a storage medium processing device that allows a user to easily remove a memory card when the user wishes to remove the memory card, which is natural and easy to understand, and that allows the user to safely remove the memory card. Is what you do.
A storage medium reading / writing means for reading / writing a predetermined storage medium, a power switch means for instructing a user to turn on and off the power of the storage medium processing device, and a power supply cutoff via the power switch means. The power-off instruction is suspended when the predetermined condition is satisfied after receiving the instruction and after that, and when the predetermined condition is not satisfied, the power supply for turning off the power of the storage medium processing device is held. A storage medium processing device having a control unit.
[Selection diagram] Fig. 1
Description
【0001】
【発明の属する技術分野】
本発明は、半導体メモリカード等の記憶媒体を処理する記憶媒体処理装置およびその制御方法に関する。
【0002】
【従来の技術】
近年デジタルカメラ等の記憶媒体として半導体メモリカードが注目を浴び、これに伴い、PC(パーソナルコンピュータ)によって、メモリカードを読み書きすることが求められている。これを背景に、メモリカードをPCで読み書きするためのメモリカードリーダ・ライタを、各社が開発している。
【0003】
また、プリンタ、コピー、ファクシミリ等にも、デジカメの画像を出力する要求があり、メモリカードリーダを具備するプリンタ、コピー、ファクシミリ等が増えつつある。
【0004】
メモリカードリーダを用いて、PCから、メモリカードにデータを書き込む場合、PCの処理速度に比べると、メモリカードに内蔵されている不揮発性のメモリの処理速度が低速である。そこで、最近のオペレーティングシステム(以下OS)では、メモリカードへの書き込みを、所定のアプリケーションに代行させ、時間が経ってから書き込み、実際にメモリカードへの書き込みが終了する前に終了したものとして、OSがアプリケーションに通知する。
【0005】
このようにすることによって、上記アプリケーションは、低速な記憶媒体に足を引っ張られることなく、高速に動作することが可能である。
【0006】
上記の場合、ユーザから見れば、書き込みが既に終了したように見えるが、実際にはOSがまだ書き込んでいない。したがって、上記のように、ユーザから見て、書き込みが既に終了したように見えたときに、メモリカードを抜いたり、カードリーダの電源を切ると、書き込みが完了していない場合がある。
【0007】
この場合、PCからメモリカードへ、「ファイルの移動」を行うと、移動元からファイルが削除され、移動先にはファイルが書き込まれず、したがって、ファイルが消失する。
【0008】
また、書き込み途中で、メモリカードをPCから抜くと、書き込み内容とファイルアロケーションテーブルとが矛盾し、メモリカード全体のデータが、ソフトウェア的に破壊される。
【0009】
さらに、給電中に、メモリカードをPCから抜くと、最悪の場合、物理的に破壊されることがある。
【0010】
そこで、従来の製品では、添付の説明書等で、PC上のOSからメモリカードを安全に抜く手順を踏むことによって、OSでの遅延書き込みが完了することを待ち、その後に、メモリカードへの給電を中止し、この後に、メモリカードを抜くことを義務付けている。
【0011】
【発明が解決しようとする課題】
しかし、上記のように、PC上のOSでメモリカードを安全に抜く手順は、そもそも余り知られていない手順であり、また、分かり難い操作でもある。さらに、OSによって、その操作方法が異なり、将来のOSがどう対応するかは不明である。
【0012】
従来は、PCで所定の作業を実行中に、メモリカードを抜く必要が生じると、デバイスに注意が向き、PCで終了処理を実行し、デバイスでメモリカードを抜くというように、行ったり来たりする作業が必要であり、この作業が煩雑であるという問題がある。
【0013】
また、初心者が起こしやすい問題であるにもかかわらず、メモリカードがソフトウェア的、またはハードウェア的に壊れ、この結果、読み出すことができず、初心者に解決できない状態になるという問題がある。
【0014】
本発明は、ユーザがメモリカードを抜きたいと思ったときに、メモリカードを抜く操作が自然で理解し易く、しかも、メモリカードを安全に抜くことができる記憶媒体処理装置を提供することを目的とするものである。
【0015】
【課題を解決するための手段】
本発明は、所定の記憶媒体を読み書きする記憶媒体読み書き手段と、記憶媒体処理装置の電源オンと電源断とを、利用者が指示する電源スイッチ手段と、この電源スイッチ手段を介して、電源断の指示を受けたときおよびそれ以降に、所定の条件を満たしている間は、上記電源断の指示を保留し、上記所定の条件を満たさなければ、上記記憶媒体処理装置の電源を断する電源制御手段とを有する記憶媒体処理装置である。
【0016】
【発明の実施の形態および実施例】
図1は、本発明の一実施例である記憶媒体処理装置10の概略構成を示すブロック図である。
【0017】
記憶媒体処理装置10は、CPU11と、ROM12と、RAM13と、電源制御部14と、電源スイッチ15と、表示部16と、カードリーダ部17と、USBファンクション制御部18と、CPUバス19とを有する。
【0018】
CPU11は、システム制御部であり、記憶媒体処理装置10の全体を制御する。
【0019】
ROM12は、CPU11が実行する制御プログラムや組み込みオペレーティングシステム(OS)プログラム等を格納する。上記実施例では、ROM12に格納されている各制御プログラムは、ROM12に格納されている組み込みOSの管理下で、スケジューリングやタスクスイッチ等のソフトウェア制御を行う。
【0020】
RAM13は、DRAM(dynamic RAM)等で構成され、プログラム制御変数等を格納し、また、設定値や記憶媒体処理装置10の管理データ等を格納し、各種ワーク用バッファ領域が設けられている。
【0021】
電源制御部14は、電源Bが各部に電力を供給することを制御する。
【0022】
電源スイッチ15は、単純なスイッチであり、ユーザにスイッチが押されたことを、電源制御部14に通知するだけで、電源Bを直接制御するものではない。電源を切ることをユーザが望む場合、CPU11が後述の各条件を判断した後、電源制御部14を介して、電源Bを制御し、記憶媒体処理装置10の全体の電源を切る。
【0023】
つまり、電源スイッチ15は、記憶媒体処理装置の電源オンと電源断とを、利用者が指示する電源スイッチ手段の例である。
電源制御部14は、電源スイッチ手段を介して、電源断の指示を受けたときおよびそれ以降に、所定の条件を満たしている間は、上記電源断の指示を保留し、上記所定の条件を満たさなければ、上記記憶媒体処理装置の電源を断する電源制御手段の例である。
【0024】
表示部16は、LED(発光ダイオード)、LCD(液晶ディスプレイ)等によって構成され、記憶媒体処理装置10の電源オン、電源断を含む動作状況、ステータス状況、カードリーダの状態を表示する。
【0025】
カードリーダ部17は、各種メモリカードのインタフェースを有し、それぞれのメモリカードの規格に沿ったデータ入出力制御を実行する。
【0026】
つまり、カードリーダ部17は、所定の記憶媒体を読み書きする記憶媒体読み書き手段の例である。
【0027】
USBファンクション制御部18は、USBインタフェース50の通信制御を行い、USB通信規格に従って、プロトコル制御を行い、CPU11が実行するUSB制御タスクからのデータを、パケットに変換し、後述の外部処理装置20に、USBパケット送信を行い、逆に、外部処理装置20からのUSBパケットを、データに変換し、CPU11に送信する。
【0028】
電源Bは、家庭用電源等を、本システム内各機器に合う電圧に変換し、供給する。電源Bは、各部分に個別に電力を供給することができ、また、その供給を停止することができる。
【0029】
ただし、ROM12〜USBファンクション制御部18は、CPUバス19に接続され、省電力モードにおいて、CPUだけ停止状態で、その他の部分は電源が供給されていない。
【0030】
上記ROM12〜USBファンクション制御部18は、CPU11が管理するCPUバス19を介して、相互に接続されている。
【0031】
次に、外部処理装置20について、詳細に説明する。
【0032】
図2は、外部処理装置20の概略構成を示すブロック図である。
【0033】
外部処理装置20は、PCで構成され、カードリーダを介して、メモリカードに接続され、メモリカードを読み書きする.また、外部処理装置に0は、CPU21と、ROM22と、RAM23と、内部記憶装置24と、外部記憶装置25と、外部記憶ディスク26と、操作部27と、表示部28と、通信部29と、USBホスト制御部30と、CPUバス31とを有する。
【0034】
CPU21は、ROM22、RAM23、または、内部記憶装置24、外部記憶装置25に記憶されているプログラムから読み出されたプログラムに従って、システムバス31を介して、外部処理装置20の全体の動作を制御する。
【0035】
ROM22は、CPU21の制御プログラム等を格納している。
【0036】
RAM23は、プログラムや画像データを一時的に記憶し、外部処理装置20の処理を高速に動作させるためのものである。
【0037】
内部記憶装置24は、オペレーティングシステム、各種アプリケーションプログラム、画像データ等を格納するメモリである。内部記憶装置24には、記憶媒体処理装置10に対する各種制御命令や、データの送受信を行うためのアプリケーションソフト、プリンタドライバソフト、スキャナドライバソフト、ファクシミリドライバソフト、各機能毎のUSBクラスドライバソフト、USBバスドライバソフト等がインストールされている。
【0038】
通常、上記アプリケーションソフト、ドライバソフトが記憶されている外部記憶ディスク26(フロッピー(登録商標)ディスク、CD−ROMメディア)から、外部記憶装置25を制御することによって、上記アプリケーションソフト、ドライバソフトがインストールされる。
【0039】
また、通信回線Lによって通信部29(ネットワークやモデム)でアプリケーションソフトとドライバソフトとを受け取り、内部記憶装置24にインストールするようにしてもよい。
【0040】
操作部27は、オペレータが指示入力するキーボードやマウス(不図示)を制御するものである。印刷を実行起動する場合、通常、操作部27のキーボードやマウスが使用される。
【0041】
表示部28は、オペレータに各種表示を行うものである。外部処理端末20で印刷の実行起動をかける場合は、確認ダイヤログ等を表示部28に表示し、オペレータに入力を促す。また印刷動作の実行中は、印刷状況を示す情報をオペレータに提供する。
【0042】
通信部29は、図示しないネットワークに接続し、通信回線を介して、インターネットプロバイダへ接続し、相手通信装置との間で、データや、画像情報等を通信する。
【0043】
ネットワークや通信回線への接続に関しては、公知の方法を使用し、詳述はしない。
【0044】
USBホスト制御部30は、USBインタフェース50の通信制御を行うものであり、USB通信規格に従って、CPU21からのデータを、パケットに変換し、記憶媒体処理装置10に、USBパケットを送信し、逆に、記憶媒体処理装置10からのUSBパケットを、データに変換し、CPU21に送信する。通信制御方法に関しては、公知の方法を使用し、詳述はしない。
【0045】
次に、上記実施例の動作について説明する。
【0046】
上記実施例において、記憶媒体処理装置10をカードリーダとし、PCからメモリカードをアクセスする手順として、マス・ストレージクラスに準じた公知の方法を使用するので、以下では、電源断の手順に必要な電源断不可フラグの処理についてのみ説明する。
【0047】
本実施例では、マス・ストレージクラスで、Protocol CodeをBulk−Only Trnsportとし、Subclass CodeをSCSI transparent commannd setに指定している。
【0048】
マス・ストレージクラスのコマンドは、CBWという命令がPCからカードリーダに送信され、コマンドに応じた書き込み命令であれば、この後に書き込むべきデータが、PCからカードリーダ(記憶媒体処理装置10)に送られる。また、読み込み命令やステータスを問い合わせるコマンドであれば、要求されたデータを、カードリーダ(記憶媒体処理装置10)からPCへ送信する。またTest Unit Ready等の状態を問い合わせるだけのコマンドであれば、データのやりとりはない。これらの処理の後に、コマンドが正常に終了したか否かを示すエラーフラグを持つCSW命令を、カードリーダ(記憶媒体処理装置10)からPCへ送信する。
【0049】
これらの手続の中で、CBW命令を、PCから受信した時点で、電源断不可フラグを立てる。そして、CSW命令を、USBファンクション制御部18に転送し、USBファンクション制御部18の割り込み等を利用して、PCへの送信が完了した時点で、電源断不可フラグを落とす。
【0050】
次に、上記実施例における書き込みについて説明する。
【0051】
Subclass Code宣言によって、SCSIのコマンドがPCから用いられるので、書き込みに際しては、write(6)がwrite(10)が用いられる。なお、write(6)、write(10)は、scsiで規定されているコマンドの中に存在するものである( HYPERLINK ”http://www.t10.org/scsi−3.htm” http://www.t10.org/scsi−3.htm 参照)。
【0052】
これらのコマンドが発行されると、電源断不可のフラグを立て、本実施例では、10秒のタイマを起動する。上記電源断不可のフラグについては、後述する。タイマは、定期的な割込などを利用し、10秒を減算する。途中でwriteコマンドが再発行されれば、タイマの値を10秒に戻す。タイマの値が0になると、電源断不可のフラグを落とし、書き込みを許可する。
【0053】
次に、上記実施例において、記憶媒体処理装置10から、メモリカードを抜く手順について説明する。
【0054】
利用者が、電源スイッチ15をオフすることによって、電源断を指示すると、電源断不可フラグを参照する。この電源断不可フラグが立っていれば、電源スイッチ15による電源断を示すキー入力を無視し、処理中である旨を、表示部16に表示する。電源断不可フラグが落ちていれば、メモリカード内の各種終了処理を行い、電源制御部14を介して、電源Bによる給電を停止し、記憶媒体処理装置10の電源を落とす。
【0055】
つまり、上記実施例において、カードリーダ部17からメモリカードを抜く操作が簡素であるので、ユーザがメモリカードを抜く場合、カードリーダの電源スイッチ15を押し、電源をオフしてから、メモリカードを抜く。
【0056】
電源スイッチ15は、ソフトウェア的なもので、以下に挙げるいくつかの条件を満たしたときに、カードリーダ本体の電源Bを落とすか、または、省電力なモードに入り休止状態とする。
【0057】
電源オフの条件の1つ目の条件は、USB接続でマス・ストレージクラスを満たすメモリカードの場合、コマンドは、PCからCBW、どちらかから、DATA、メモリカードからCSWを送るシーケンスで行われるが、この1組のコマンドが終了するまでは、電源を切ることができないようにする。これは、コマンドと中の状態で通信できなくなると、次回接続したときにPC側のドライバがエラーになることが多いからである。
【0058】
また、PCからの書き込みは、データをいくつかに分けて書き込んだ後、FATを書き込んで終了する。その一連の書き込みの最中に電源を落とすと、メモリカードのデータが不完全に消失する。
【0059】
そこで、2つ目の条件は、CBW命令が、メモリカードへの書き込みコマンドである場合、最後の書き込みコマンドから一定期間内であるという条件であり、この条件下では、電源を切れないものとする。
【0060】
上記実施例によれば、ユーザがメモリカードを抜きたいと思ったときには、電源スイッチ15を押し、電源が落ちてからメモリカードを抜くようにし、このように自然で理解し易い操作をすれば、メモリカードを安全に抜くことができる。
【0061】
また、上記実施例によれば、メモリカード抜く操作、処理が、PCデバイス側で完結し、PC側のOSに依存しないので、どのOSでも安全にカードを抜くことができ、将来OSの仕様変更を考慮する必要がない。
【0062】
上記実施例において、電源が落ちていれば、PCからの書き込みが完全に終了しているので、書き込みの途中で、メモリカードを抜き取ることによるデータの破壊が発生する可能性がなく、またメモリカードへの給電を停止しているので、電気的に破壊する可能性もない。
【0063】
さらに、上記実施例によれば、遅延書き込みが安全に行われるので、OSのデフォルトが遅延書き込みでない場合でも、遅延書き込みを利用することによって、PCのパフォーマンスが向上する。
【0064】
【発明の効果】
本願発明によれば、ユーザがメモリカードを抜きたいと思ったときには、電源スイッチを押し、電源が落ちてからメモリカードを抜くようにするので、メモリカードを抜く操作が自然で理解し易く、しかも、メモリカードを安全に抜くことができるという効果を奏する。
【図面の簡単な説明】
【図1】本発明の一実施例である記憶媒体処理装置10の概略構成を示すブロック図である。
【図2】外部処理装置20の概略構成を示すブロック図である。
【符号の説明】
10…記憶媒体処理装置、
11…CPU、
12…ROM、
13…RAM、
14…電源制御部、
15…電源スイッチ、
17…カードリーダ部、
18…USBファンクション制御部、
20…外部処理装置、
21…CPU、
22…ROM、
23…RAM、
24…内部記憶装置、
25…外部記憶装置、
27…操作部、
30…USBホスト制御部、
50…USBインタフェース、
B…電源。[0001]
TECHNICAL FIELD OF THE INVENTION
The present invention relates to a storage medium processing apparatus for processing a storage medium such as a semiconductor memory card and a control method thereof.
[0002]
[Prior art]
In recent years, semiconductor memory cards have attracted attention as storage media for digital cameras and the like, and accordingly, reading and writing of memory cards by a PC (personal computer) is required. Against this background, each company has developed a memory card reader / writer for reading and writing a memory card with a PC.
[0003]
There is also a demand for printers, copiers, facsimile machines, etc. to output digital camera images, and printers, copiers, facsimile machines, etc. having a memory card reader are increasing.
[0004]
When writing data from a PC to a memory card using a memory card reader, the processing speed of a nonvolatile memory built in the memory card is lower than the processing speed of the PC. Therefore, in a recent operating system (hereinafter referred to as OS), writing to a memory card is performed by a predetermined application, writing is performed after a lapse of time, and it is assumed that the writing is completed before the writing to the memory card is actually completed. The OS notifies the application.
[0005]
By doing so, the application can operate at high speed without being pulled by a low-speed storage medium.
[0006]
In the above case, from the user's point of view, it seems that the writing has already been completed, but the OS has not actually written yet. Therefore, as described above, if the memory card is removed or the power of the card reader is turned off when it appears to the user that the writing has already been completed, the writing may not be completed.
[0007]
In this case, when "file transfer" is performed from the PC to the memory card, the file is deleted from the transfer source, the file is not written to the transfer destination, and the file is lost.
[0008]
If the memory card is removed from the PC during writing, the written contents and the file allocation table are inconsistent, and the data of the entire memory card is destroyed by software.
[0009]
Furthermore, if the memory card is removed from the PC during power supply, in the worst case, it may be physically destroyed.
[0010]
Therefore, in the conventional product, by following the procedure for safely removing the memory card from the OS on the PC using the attached manual or the like, it is necessary to wait for the completion of the delayed writing in the OS, and then, Power supply is stopped, and after that, the memory card must be removed.
[0011]
[Problems to be solved by the invention]
However, as described above, the procedure for safely removing the memory card with the OS on the PC is a procedure that is not well known in the first place, and is also an opaque operation. Furthermore, the operating method differs depending on the OS, and it is unclear how the future OS will respond.
[0012]
Conventionally, when it is necessary to remove a memory card while a predetermined operation is being performed on a PC, attention is paid to the device, the end process is performed on the PC, and the memory card is removed from the device. Work is required, and there is a problem that this work is complicated.
[0013]
In addition, although the problem is likely to occur for beginners, there is a problem that the memory card is broken by software or hardware, and as a result, cannot be read out and cannot be solved by beginners.
[0014]
An object of the present invention is to provide a storage medium processing device that allows a user to easily remove a memory card when the user wants to remove the memory card, which is natural and easy to understand, and that can safely remove the memory card. It is assumed that.
[0015]
[Means for Solving the Problems]
The present invention provides a storage medium reading / writing means for reading / writing a predetermined storage medium, a power supply switch means for instructing a user to turn on and off the power of the storage medium processing device, and a power supply cutoff via the power supply switch means. The power-off instruction is suspended when the predetermined condition is satisfied after receiving the instruction and after that, and when the predetermined condition is not satisfied, the power supply for turning off the power of the storage medium processing device is held. A storage medium processing device having a control unit.
[0016]
Embodiments and Examples of the Invention
FIG. 1 is a block diagram showing a schematic configuration of a storage medium processing device 10 according to one embodiment of the present invention.
[0017]
The storage medium processing device 10 includes a CPU 11, a
[0018]
The CPU 11 is a system control unit, and controls the entire storage medium processing device 10.
[0019]
The
[0020]
The
[0021]
The power control unit 14 controls the power supply B to supply power to each unit.
[0022]
The power switch 15 is a simple switch, and only notifies the power control unit 14 that the user has pressed the switch, but does not directly control the power B. When the user desires to turn off the power, the CPU 11 determines the conditions described below, and then controls the power supply B via the power supply control unit 14 to turn off the power of the entire storage medium processing device 10.
[0023]
In other words, the power switch 15 is an example of a power switch unit that instructs the user to turn on and off the power of the storage medium processing device.
The power control unit 14 suspends the power-off instruction when the power-off instruction is received via the power switch means and thereafter while the predetermined condition is satisfied, and This is an example of a power supply control unit that cuts off the power supply of the storage medium processing device if the condition is not satisfied.
[0024]
The
[0025]
The
[0026]
That is, the
[0027]
The USB
[0028]
The power supply B converts a household power supply or the like into a voltage suitable for each device in the present system and supplies it. The power supply B can individually supply power to each part, and can stop the supply.
[0029]
However, the
[0030]
The
[0031]
Next, the external processing device 20 will be described in detail.
[0032]
FIG. 2 is a block diagram illustrating a schematic configuration of the external processing device 20.
[0033]
The external processing device 20 is composed of a PC, is connected to a memory card via a card reader, and reads and writes the memory card. The external processing device 0 includes
[0034]
The
[0035]
The
[0036]
The RAM 23 temporarily stores programs and image data, and operates the external processing device 20 at high speed.
[0037]
The
[0038]
Usually, by controlling the
[0039]
Alternatively, the application unit and the driver software may be received by the communication unit 29 (network or modem) via the communication line L and installed in the
[0040]
The
[0041]
The
[0042]
The
[0043]
A known method is used for connection to a network or a communication line, and will not be described in detail.
[0044]
The USB
[0045]
Next, the operation of the above embodiment will be described.
[0046]
In the above embodiment, the storage medium processing device 10 is a card reader, and a known method conforming to the mass storage class is used as a procedure for accessing a memory card from a PC. Only the processing of the power-off disable flag will be described.
[0047]
In this embodiment, in the mass storage class, the Protocol Code is set to Bulk-Only Transport and the Subclass Code is specified to the SCSI transparent command set.
[0048]
In the command of the mass storage class, the command CBW is transmitted from the PC to the card reader, and if the command is a write command corresponding to the command, the data to be subsequently written is transmitted from the PC to the card reader (storage medium processing device 10). Can be If the command is a read command or a command for inquiring the status, the requested data is transmitted from the card reader (storage medium processing device 10) to the PC. If the command is only for inquiring the status such as Test Unit Ready, there is no data exchange. After these processes, the card reader (storage medium processing device 10) transmits a CSW instruction having an error flag indicating whether or not the command has been normally completed to the PC.
[0049]
In these procedures, when the CBW command is received from the PC, the power-off disable flag is set. Then, the CSW instruction is transferred to the USB
[0050]
Next, writing in the above embodiment will be described.
[0051]
Since the SCSI command is used from the PC by the Subclass Code declaration, write (6) is used as write (10) at the time of writing. Note that write (6) and write (10) are present in the command specified by scsi (HYPERLINK "http://www.t10.org/scsi-3.htm" http: // /Www.t10.org/scsi-3.htm).
[0052]
When these commands are issued, a flag indicating that power cannot be turned off is set, and in this embodiment, a 10-second timer is started. The flag indicating that the power cannot be turned off will be described later. The timer subtracts 10 seconds using a periodic interrupt or the like. If the write command is reissued halfway, the timer value is returned to 10 seconds. When the value of the timer becomes 0, the power-off impossible flag is dropped and writing is permitted.
[0053]
Next, a procedure for removing the memory card from the storage medium processing device 10 in the above embodiment will be described.
[0054]
When the user gives an instruction to turn off the power by turning off the power switch 15, the power-off disable flag is referred to. If the power-off disable flag is set, the key input indicating power-off by the power switch 15 is ignored, and a message indicating that processing is being performed is displayed on the
[0055]
That is, in the above embodiment, since the operation of removing the memory card from the
[0056]
The power switch 15 is software-based, and turns off the power B of the card reader main body or enters a power saving mode to be in a sleep state when some of the following conditions are satisfied.
[0057]
The first condition of the power-off condition is that, in the case of a memory card that satisfies the mass storage class by USB connection, the command is performed in a sequence of sending CBW from the PC, DATA from either, and sending CSW from the memory card. The power cannot be turned off until this set of commands is completed. This is because, if communication with the command cannot be performed in the middle state, the driver on the PC side often causes an error at the next connection.
[0058]
Further, the writing from the PC ends after writing the data in several parts and then writing the FAT. If the power is turned off during the series of writing, data in the memory card is incompletely lost.
[0059]
Therefore, the second condition is that when the CBW instruction is a write command to the memory card, the condition is within a certain period from the last write command, and it is assumed that the power is not turned off under this condition. .
[0060]
According to the above embodiment, when the user wants to remove the memory card, the user presses the power switch 15 so that the memory card is removed after the power is turned off. The memory card can be safely removed.
[0061]
Further, according to the above embodiment, since the operation and processing for removing the memory card are completed on the PC device side and do not depend on the OS on the PC side, the card can be safely removed by any OS, and the specifications of the OS will be changed in the future. Need not be considered.
[0062]
In the above embodiment, if the power is turned off, the writing from the PC has been completely completed, so there is no possibility that data may be destroyed by removing the memory card during the writing. Since the power supply to the power supply is stopped, there is no possibility of electrical breakdown.
[0063]
Furthermore, according to the above embodiment, since the delayed writing is performed safely, even when the default of the OS is not the delayed writing, the performance of the PC is improved by using the delayed writing.
[0064]
【The invention's effect】
According to the present invention, when the user wants to remove the memory card, the user presses the power switch to remove the memory card after the power is turned off, so that the operation of removing the memory card is natural and easy to understand, and This has the effect that the memory card can be safely removed.
[Brief description of the drawings]
FIG. 1 is a block diagram showing a schematic configuration of a storage medium processing device 10 according to an embodiment of the present invention.
FIG. 2 is a block diagram illustrating a schematic configuration of an external processing device 20.
[Explanation of symbols]
10 ... storage medium processing device,
11 ... CPU,
12 ... ROM,
13 ... RAM,
14 power supply control unit,
15. Power switch,
17 Card reader part,
18. USB function control unit
20 external processing device,
21 ... CPU,
22 ... ROM,
23 ... RAM,
24 ... internal storage device,
25 external storage device,
27 ... Operation unit,
30 ... USB host control unit,
50 ... USB interface,
B: Power supply.
Claims (11)
所定の記憶媒体を読み書きする記憶媒体読み書き手段と;
上記記憶媒体処理装置の電源オンと電源断とを、利用者が指示する電源スイッチ手段と;
上記電源スイッチ手段を介して、電源断の指示を受けたときおよびそれ以降に、所定の条件を満たしている間は、上記電源断の指示を保留し、上記所定の条件を満たさなければ、上記記憶媒体処理装置の電源を断する電源制御手段と;
を有することを特徴とする記憶媒体処理装置。In the storage medium processing device,
Storage medium reading / writing means for reading / writing a predetermined storage medium;
Power switch means for instructing a user to power on and power off the storage medium processing device;
Via the power switch means, when a power-off instruction is received and thereafter, while the predetermined condition is satisfied, the power-off instruction is suspended, and if the predetermined condition is not satisfied, Power control means for turning off the power of the storage medium processing device;
A storage medium processing device comprising:
上記電源スイッチ手段によって電源断の指示を受けていても、上記所定の条件を満たしている間は、その指示を無視し、上記所定の条件を満たさないときに電源断の指示を受けたときにだけ、上記電源制御手段によって装置の電源を落とすことを特徴とする記憶媒体処理装置。In claim 1,
Even if a power-off instruction is received by the power switch means, while the predetermined condition is satisfied, the instruction is ignored, and when the power-off instruction is received when the predetermined condition is not satisfied. A storage medium processing apparatus characterized in that the power of the apparatus is turned off by the power control means.
上記所定の条件は、外部情報処理装置と上記制御手段とを接続するインタフェースを介して、上記外部情報処理装置から、データが送受信されているという条件であることを特徴とする記憶媒体処理装置。In claim 1 or claim 2,
The storage medium processing device, wherein the predetermined condition is a condition that data is transmitted and received from the external information processing device via an interface connecting the external information processing device and the control means.
上記所定の条件は、外部情報処理装置と上記制御手段とを接続するインタフェースを介して、上記外部情報処理装置から、一連のシーケンスの最中であるという条件であることを特徴とする記憶媒体処理装置。In any one of claims 1 to 3,
The storage medium processing, wherein the predetermined condition is a condition that the external information processing device is in the middle of a series of sequences via an interface connecting the external information processing device and the control means. apparatus.
上記所定の条件は、上記インタフェース手段のうちでバルク転送のエンドポイントを介して、上記外部情報処理装置から、最後に受け取ったデータがマス・ストレージクラスのCSWでない状態であることを特徴とする記憶媒体処理装置。In any one of claims 1 to 4,
The predetermined condition is that the last data received from the external information processing device via the bulk transfer endpoint in the interface means is not a mass storage class CSW. Media processing device.
上記所定の条件は、外部情報処理装置と上記制御手段とを接続するインタフェースを介して、上記外部情報処理装置から、上記記憶媒体へ書き込み中であるという条件であることを特徴とする記憶媒体処理装置。In any one of claims 1 to 5,
The storage medium processing, wherein the predetermined condition is a condition that the external information processing apparatus is writing to the storage medium via an interface connecting the external information processing apparatus and the control unit. apparatus.
上記所定の条件は、外部情報処理装置と上記制御手段とを接続するインタフェースを介して、上記外部情報処理装置から、上記記憶媒体へ書き込み中であるという条件、または、上記記憶媒体へ書き込みが終了してから所定期間内であるという条件であることを特徴とする記憶媒体処理装置。In any one of claims 1 to 5,
The predetermined condition is a condition that the external information processing device is writing to the storage medium via the interface connecting the external information processing device and the control unit, or the writing to the storage medium is completed. A storage medium processing device, wherein the condition is within a predetermined period of time.
上記所定の条件は、上記記憶媒体処理装置内部で、上記記憶媒体を処理中であるという条件であることを特徴とする記憶媒体処理装置。In any one of claims 1 to 7,
The storage medium processing device, wherein the predetermined condition is a condition that the storage medium is being processed inside the storage medium processing device.
上記電源制御手段によって行われる電源断は、上記記憶媒体処理装置全体への電源の供給の停止であることを特徴とする記憶媒体処理装置。In any one of claims 1 to 8,
The storage medium processing device according to claim 1, wherein the power cutoff performed by the power supply control means is a stoppage of power supply to the entire storage medium processing device.
上記電源制御手段によって行われる電源断は、上記記憶媒体処理装置の一部への電源の供給の停止であるが、見かけ上は電源が切れているように利用者から見える電源断であることを特徴とする記憶媒体処理装置。In any one of claims 1 to 9,
The power cutoff performed by the power control means is a stoppage of power supply to a part of the storage medium processing device, but it is apparently a power cutoff that is seen by a user as if the power was turned off. Characteristic storage medium processing device.
所定の記憶媒体を読み書きする記憶媒体読み書き段階と;
上記記憶媒体処理装置の電源オンと電源断とを、利用者が指示する電源スイッチ手段を介して、電源断の指示を受けたときおよびそれ以降に、所定の条件を満たしている間は、上記電源断の指示を保留し、上記所定の条件を満たさなければ、上記記憶媒体処理装置の電源を断する電源制御段階と;
を有することを特徴とする記憶媒体処理装置の制御方法。In the control method of the storage medium processing device,
A storage medium reading / writing step for reading / writing a predetermined storage medium;
The power-on and power-off of the storage medium processing device are performed when the power-off instruction is received via the power switch means instructed by the user and thereafter, while the predetermined condition is satisfied, while the power-off instruction is received. Suspending the power-off instruction and, if the predetermined condition is not satisfied, power-off the storage medium processing device;
A method for controlling a storage medium processing device, comprising:
Priority Applications (1)
| Application Number | Priority Date | Filing Date | Title |
|---|---|---|---|
| JP2002253370A JP2004094494A (en) | 2002-08-30 | 2002-08-30 | Storage medium processing device and control method therefor |
Applications Claiming Priority (1)
| Application Number | Priority Date | Filing Date | Title |
|---|---|---|---|
| JP2002253370A JP2004094494A (en) | 2002-08-30 | 2002-08-30 | Storage medium processing device and control method therefor |
Publications (1)
| Publication Number | Publication Date |
|---|---|
| JP2004094494A true JP2004094494A (en) | 2004-03-25 |
Family
ID=32059392
Family Applications (1)
| Application Number | Title | Priority Date | Filing Date |
|---|---|---|---|
| JP2002253370A Pending JP2004094494A (en) | 2002-08-30 | 2002-08-30 | Storage medium processing device and control method therefor |
Country Status (1)
| Country | Link |
|---|---|
| JP (1) | JP2004094494A (en) |
Cited By (3)
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| JP2006062156A (en) * | 2004-08-26 | 2006-03-09 | Canon Inc | Printing apparatus, printing apparatus control method, and printing apparatus control program |
| GB2425379A (en) * | 2005-04-20 | 2006-10-25 | Hewlett Packard Development Co | External storage device with user activated disconnect request component. |
| JP2007233449A (en) * | 2006-02-27 | 2007-09-13 | Canon Inc | Image processing apparatus and image data transmission method |
-
2002
- 2002-08-30 JP JP2002253370A patent/JP2004094494A/en active Pending
Cited By (6)
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| JP2006062156A (en) * | 2004-08-26 | 2006-03-09 | Canon Inc | Printing apparatus, printing apparatus control method, and printing apparatus control program |
| GB2425379A (en) * | 2005-04-20 | 2006-10-25 | Hewlett Packard Development Co | External storage device with user activated disconnect request component. |
| GB2425379B (en) * | 2005-04-20 | 2009-09-16 | Hewlett Packard Development Co | Method and apparatus for disconnecting an external data storage device from a computer |
| JP2007233449A (en) * | 2006-02-27 | 2007-09-13 | Canon Inc | Image processing apparatus and image data transmission method |
| US8479280B2 (en) | 2006-02-27 | 2013-07-02 | Canon Kabushiki Kaisha | Image processing device and image data transmission method |
| US9621351B2 (en) | 2006-02-27 | 2017-04-11 | Canon Kabushiki Kaisha | Image processing device and image data transmission method |
Similar Documents
| Publication | Publication Date | Title |
|---|---|---|
| US9952966B2 (en) | Control apparatus and control method therefor | |
| JP2007296723A (en) | Control device having power switching function, image forming apparatus, and image reading apparatus | |
| JPH10143340A (en) | Printer | |
| JP5790007B2 (en) | Information processing apparatus, information processing apparatus control method, and program | |
| US8166290B2 (en) | Information processing apparatus and information processing method | |
| JP3769449B2 (en) | Capture controller and image capture processing method | |
| JP2005094679A (en) | Image processing device with energy saving mode function connected to network | |
| JP6141240B2 (en) | Printing apparatus, storage control apparatus connected to printing apparatus, printing apparatus control method and program | |
| JP4577162B2 (en) | Updating printer system control software | |
| JP2007296796A (en) | Image forming apparatus, image forming method, and image forming program | |
| JP4028811B2 (en) | Image forming apparatus | |
| JP2004094494A (en) | Storage medium processing device and control method therefor | |
| JP6590722B2 (en) | Electronic device, control method thereof, and program | |
| CN117742625A (en) | Printer job processing method, device, computer equipment and storage medium | |
| JP2012006389A (en) | Image forming apparatus, and writing control method | |
| JP5636653B2 (en) | Semiconductor integrated circuit and power saving control method | |
| JP2015112818A (en) | Image forming apparatus, control method, and program | |
| JP5011780B2 (en) | Information processing apparatus and activation method thereof | |
| JP2004094493A (en) | Storage medium processing device and control method therefor | |
| JP2004110622A (en) | Storage medium writer and control method of storage medium writer | |
| JP5899790B2 (en) | Information processing apparatus and power saving mode management method | |
| JP7651999B2 (en) | Information processing apparatus and image forming apparatus | |
| JP6415633B2 (en) | Information processing apparatus and control method thereof | |
| JP7095505B2 (en) | Information processing systems, information processing devices and programs | |
| JP5071744B2 (en) | Printing apparatus, printing system, and printer driver |