JP2003030595A - IC card reader / writer and control method thereof - Google Patents
IC card reader / writer and control method thereofInfo
- Publication number
- JP2003030595A JP2003030595A JP2001212372A JP2001212372A JP2003030595A JP 2003030595 A JP2003030595 A JP 2003030595A JP 2001212372 A JP2001212372 A JP 2001212372A JP 2001212372 A JP2001212372 A JP 2001212372A JP 2003030595 A JP2003030595 A JP 2003030595A
- Authority
- JP
- Japan
- Prior art keywords
- card
- request
- received
- host computer
- writer
- 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
Landscapes
- Credit Cards Or The Like (AREA)
Abstract
(57)【要約】
【課題】 非接触型ICカードシステムにおいて通信エ
ラーが発生した場合に発生し得るハングアップを回避で
きるとともに、正常な通信状態に迅速に復帰可能なIC
カードリーダライタおよびその制御方法を実現する。
【解決手段】 ケーブル5を介してホストコンピュータ
3に接続される非接触型のICカードリーダライタ1に
おいて、コマンドをICカード2へ送信したにもかかわ
らず当該コマンドに対応するデータ通信を確立できなか
った場合に否定応答を送信したが何らレスポンスを受信
できない場合、実行中の処理の初期化を指示する初期化
要求をICカード2へ送信する送信手段11と、初期化
要求に対応する確認応答を受信したかを判定する判定手
段12と、初期化要求に対応する確認応答を受信した場
合、ホストコンピュータ3から受信していた当該コマン
ドをICカード2へ再送する再送手段13と、を備え
る。
(57) [Summary] An IC that can avoid a hang-up that can occur when a communication error occurs in a non-contact type IC card system and can quickly return to a normal communication state.
A card reader / writer and a control method thereof are realized. SOLUTION: Although a command is transmitted to an IC card 2 in a non-contact type IC card reader / writer 1 connected to a host computer 3 via a cable 5, data communication corresponding to the command cannot be established. If a negative response is transmitted but no response can be received, the transmitting unit 11 that transmits to the IC card 2 an initialization request instructing the initialization of the process being executed, and a confirmation response corresponding to the initialization request. There are provided a determination unit 12 for determining whether the command has been received, and a retransmission unit 13 for retransmitting the command received from the host computer 3 to the IC card 2 when a confirmation response corresponding to the initialization request is received.
Description
【0001】[0001]
【発明の属する技術分野】本発明は、非接触型のICカ
ードに対し情報の読出しもしくは書込みを行うICカー
ドリーダライタおよびその制御方法に関し、特に、IC
カードシステム内で通信エラーが発生した場合に的確に
対応可能なICカードリーダライタおよびその制御方法
に関する。BACKGROUND OF THE INVENTION 1. Field of the Invention The present invention relates to an IC card reader / writer for reading or writing information from a non-contact type IC card and a control method thereof, and more particularly to an IC
The present invention relates to an IC card reader / writer and a control method for the IC card reader / writer, which can accurately cope with a communication error in the card system.
【0002】[0002]
【従来の技術】ICカードに記憶されたデータの読出し
およびICカードへのデータの書込みは、ICカードリ
ーダライタを介して行われる。また、ICカードのIC
チップは通常電池を内蔵していないので、ICカードリ
ーダライタは、ICカードへ電力を供給する役割も担
う。ICカードリーダライタは、その上位装置であるホ
ストコンピュータに接続されており、各種メイン処理は
このホストコンピュータで実行される。2. Description of the Related Art Reading of data stored in an IC card and writing of data in the IC card are performed via an IC card reader / writer. In addition, IC of IC card
Since the chip usually does not have a built-in battery, the IC card reader / writer also plays a role of supplying electric power to the IC card. The IC card reader / writer is connected to a host computer, which is a higher-level device thereof, and various main processes are executed by this host computer.
【0003】非接触型のICカードでは、ICカード内
のコイルとICカードリーダライタに設けられたアンテ
ナとの間の電磁誘導現象を利用してデータ通信を行う。
つまり。非接触型のICカードにおいては、ICカード
リーダライタの通信圏内になければデータ通信が行えな
い。In a non-contact type IC card, data communication is performed by utilizing an electromagnetic induction phenomenon between a coil in the IC card and an antenna provided in the IC card reader / writer.
That is. In the non-contact type IC card, data communication cannot be performed unless it is within the communication range of the IC card reader / writer.
【0004】図7は、非接触型ICカードシステムの概
略図である。FIG. 7 is a schematic diagram of a non-contact type IC card system.
【0005】ICカードリーダライタ1とホストコンピ
ュータ3とは、シリアルケーブル5を介して接続され
る。The IC card reader / writer 1 and the host computer 3 are connected via a serial cable 5.
【0006】ICカードリーダライタ1は、該ICカー
ドリーダライタ1に設けられたアンテナ4から絶えず電
波を送っており、通信可能なICカード2がICカード
リーダライタ1の通信圏内に存在するか否かを判定して
いる。The IC card reader / writer 1 constantly sends radio waves from the antenna 4 provided in the IC card reader / writer 1, and determines whether or not the communicable IC card 2 exists within the communication range of the IC card reader / writer 1. Is being determined.
【0007】非接触型のICカード2がICカードリー
ダライタ1のアンテナ4の通信圏内に入ると、ICカー
ドリーダライタ1は、通信可能なICカードであるか否
かを判定する。When the non-contact type IC card 2 enters the communication area of the antenna 4 of the IC card reader / writer 1, the IC card reader / writer 1 determines whether or not the IC card is a communicable IC card.
【0008】ここで通信可能であると判別されると、当
該ICカード2は活性化され、ICカードリーダライタ
1とICカード2との間の通信が確立され、これ以後、
ICカードリーダライタ1を介したホストコンピュータ
3とICカード2との間のデータ通信が可能となる。I
Cカードリーダライタ1は、活性化されたICカード2
に対して、シリアルケーブル5を介してホストコンピュ
ータ3から受信したコマンドの指示に基づいたデータ通
信を行う。If it is determined that communication is possible, the IC card 2 is activated, communication between the IC card reader / writer 1 and the IC card 2 is established, and thereafter,
Data communication between the host computer 3 and the IC card 2 via the IC card reader / writer 1 becomes possible. I
C card reader / writer 1 is an activated IC card 2
On the other hand, data communication is performed based on the instruction of the command received from the host computer 3 via the serial cable 5.
【0009】[0009]
【発明が解決しようとする課題】非接触型ICカードシ
ステムにおいては、ICカードがICカードリーダライ
タの通信圏内にあって活性化されて通信状態が確立され
ていたときに通信エラーが発生してしまう可能性が、接
触型ICカードシステムに比べて高い。In the non-contact type IC card system, a communication error occurs when the IC card is activated within the communication range of the IC card reader / writer and the communication state is established. There is a higher possibility that it will happen than in the contact type IC card system.
【0010】なぜならば、非接触型ICカードシステム
においては、データ通信の途中に、例えばICカードリ
ーダライタの通信圏外になり通信不能となってしまうエ
ラーが発生する場合があるからである。This is because, in a non-contact type IC card system, an error may occur during data communication, for example, being out of the communication range of the IC card reader / writer and making communication impossible.
【0011】もちろん、接触型ICカードシステムの場
合と同様に、ICカードが通信圏内に常に入っていたと
しても、パリティーエラー、フレーミングエラー(同期
ずれ)あるいは文字化けといったエラーが発生する可能
性もある。Of course, as in the case of the contact type IC card system, even if the IC card is always in the communication range, an error such as a parity error, a framing error (synchronization deviation) or a garbled character may occur. .
【0012】ICカードがICカードリーダライタの通
信圏外になり通信不能になった場合、あるいは、ICカ
ードとICカードリーダライタとの間のパリティーエラ
ー(同期ずれ)が発生した場合、ホストコンピュータ側
からしてみれば、ICカードリーダライタがハングアッ
プしてしまうように見えてしまう場合がある。When the IC card is out of communication range of the IC card reader / writer and cannot communicate, or when a parity error (synchronization shift) between the IC card and the IC card reader / writer occurs, the host computer side Then, the IC card reader / writer may appear to hang up.
【0013】一般に、PC/SC(Personal
Computer/Smart Card)ワーキング
グループの規約を用いたICカードシステムにおいて
は、ICカードリーダライタは、ICカードリーダライ
タとホストコンピュータとを接続するシリアルケーブル
内のCTS(Clear to Send)信号線の信号
を、通信可能なICカードが存在する場合はオンにし、
存在しない場合はオフにしている。そして、ホストコン
ピュータは、CTS信号線の信号のオン/オフから、I
Cカードリーダライタに通信可能なICカードが存在す
るか否かを判断している。Generally, PC / SC (Personal)
In an IC card system that uses the rules of the Computer / Smart Card) working group, the IC card reader / writer sends signals from a CTS (Clear to Send) signal line in a serial cable that connects the IC card reader / writer and the host computer. If there is an IC card that can communicate, turn it on,
If it does not exist, it is turned off. Then, the host computer turns on / off the signal on the CTS signal line,
It is determined whether or not there is a communicable IC card in the C card reader / writer.
【0014】ホストコンピュータは、オン信号を受信し
たときはICカードが存在するということなので上述の
処理を経てデータ通信を行う。オフ信号を受信したとき
はICカードが存在しないということなので、ホストコ
ンピュータのこれまでの処理をリセットし、次なるIC
カードが検出されるまでいかなるコマンドをも発生しな
い状態に入る。Since the host computer means that the IC card is present when the ON signal is received, the host computer performs the data communication through the above processing. When the off signal is received, it means that the IC card does not exist, so the previous processing of the host computer is reset and the next IC
Enter a state where no command is issued until the card is detected.
【0015】従来の非接触型ICカードシステムにおい
ては、通信不能となるようなエラーが発生した場合、I
CカードリーダライタからシリアルケーブルのCTS信
号線を介して出力される信号はオンのままであるので、
ホストコンピュータは、未だICカードが存在するもの
と誤認識してしまい、ICカードリーダライタからのI
Cカードとの通信結果を待ち続け、以後の処理動作がハ
ングアップしてしまうことがあった。In the conventional non-contact type IC card system, when an error that makes communication impossible occurs, I
Since the signal output from the C card reader / writer via the CTS signal line of the serial cable remains ON,
The host computer mistakenly recognizes that an IC card still exists, and the I from the IC card reader / writer
In some cases, the subsequent processing operation may hang up while waiting for the result of communication with the C card.
【0016】また、何らかの方法で、データ通信途中に
ICカードがICカードリーダライタの通信圏内から通
信圏外に移ったことを検知し、上記ハングアップを回避
できたとしても、当該ICカードがICカードリーダラ
イタの通信圏内に再度入ってきた場合、あるいは、当該
カードとは異なる別のカードがICカードリーダライタ
の通信圏内に再度入ってきた場合、従来の方法では、当
該ICカードが活性状態にあるのか非活性状態にあるの
かまでは判断できない。したがって、従来例において
は、通信圏内に再度入ってきたICカードは全て非活性
状態にあるものとし、当時実行中であった処理を完全に
中止し、アンチコリジョン処理まで遡って実行し直さな
ければならず、通信状態の復帰には時間がかかってい
た。Further, even if the IC card is moved from the communication area of the IC card reader / writer to the outside of the communication area during the data communication by some method and the above hang-up can be avoided, the IC card is still the IC card. When the card enters the communication range of the reader / writer again or another card different from the card enters the communication range of the IC card reader / writer again, the IC card is in the active state by the conventional method. It is not possible to judge whether it is inactive or inactive. Therefore, in the conventional example, it is assumed that all the IC cards that have reentered the communication area are in the inactive state, the processing that was being executed at that time must be completely stopped, and the anti-collision processing must be performed again. And it took time to restore the communication status.
【0017】また、ICカードリーダライタとICカー
ドとの間で通信エラーが発生した場合だけではなく、ホ
ストコンピュータとICカードとの間で通信エラーが発
生した場合においてもハングアップが発生することがあ
り、さらには通信状態の復帰にも時間がかかっていた。Further, not only when a communication error occurs between the IC card reader / writer and the IC card, but also when a communication error occurs between the host computer and the IC card, a hang-up may occur. Yes, and it took time to restore the communication status.
【0018】従って本発明の目的は、上記問題に鑑み、
非接触型ICカードシステムにおいて通信エラーが発生
した場合に発生し得るハングアップを回避するととも
に、正常な通信状態に迅速に復帰可能なICカードリー
ダライタおよびその制御方法を提供することにある。Therefore, in view of the above problems, it is an object of the present invention.
An object of the present invention is to provide an IC card reader / writer capable of avoiding a hang-up which may occur when a communication error occurs in a non-contact type IC card system and quickly returning to a normal communication state, and a control method thereof.
【0019】[0019]
【課題を解決するための手段】上記目的を実現するため
に、本発明においては、通信状態が既に確立されていた
にもかかわらず通信不能になった場合、すなわち、ホス
トコンピュータから受信したコマンドをICカードへ送
信したにもかかわらず当該コマンドに対応するデータ通
信を確立できなかった場合は、初期化要求をICカード
へ送信する。In order to achieve the above object, in the present invention, when communication is disabled even though the communication state has already been established, that is, the command received from the host computer is If the data communication corresponding to the command cannot be established despite the transmission to the IC card, the initialization request is transmitted to the IC card.
【0020】そして、当該初期化要求に対応する確認応
答があった場合は、迅速に初期状態に移行して、データ
通信を再開する。当該初期化要求に対応する確認応答が
無かった場合は、所定の期間中にICカードから受信す
るデータに関しては無効化し、所定の期間経過後は、ホ
ストコンピュータへ異常終了を通知する。Then, when there is a confirmation response corresponding to the initialization request, the state is quickly shifted to the initial state and the data communication is restarted. If there is no confirmation response corresponding to the initialization request, the data received from the IC card during the predetermined period is invalidated, and after the lapse of the predetermined period, the host computer is notified of the abnormal termination.
【0021】上述の初期化要求は、現在実行中の処理を
初期化するための要求である。通常の使用においては、
この初期化要求は、複数のプロトコルを有する無線通信
システムにおいて各プロトコル間に同期ずれが生じたと
きに、同期を取ることを目的として発行されるコマンド
である。具体的には、例えば、JICSAP(Japa
n IC Card System Applicat
ion Council:ICカードシステム利用促進
協議会)によるISO/IEC7816規格(JIS
X 6304に相当)で提供されているRESYNCH
要求あるいはABORT要求である。The above initialization request is a request for initializing the process currently being executed. In normal use,
This initialization request is a command issued for the purpose of establishing synchronization when there is a synchronization deviation between the protocols in a wireless communication system having a plurality of protocols. Specifically, for example, JICASAP (Japan
n IC Card System Applicat
Ion Council: ISO / IEC7816 standard (JIS)
Equivalent to X 6304)
Request or ABORT request.
【0022】図1は、本発明のICカードリーダライタ
の機能ブロック図である。FIG. 1 is a functional block diagram of the IC card reader / writer of the present invention.
【0023】本発明によれば、シリアルインタフェース
5を介してホストコンピュータ3に接続され、ホストコ
ンピュータ3から受信したコマンドを非接触型のICカ
ード2へアンテナ4を介して送信し、コマンドに基づく
データ通信をICカード2との間で行うICカードリー
ダライタ1であって、コマンドをICカード2へ送信し
たにもかかわらず、当該コマンドに対応するデータ通信
を確立できなかった場合は、否定応答をICカード2へ
所定の回数だけ送信するICカードリーダライタ1にお
いて、否定応答を送信したにもかかわらず何らレスポン
スを受信できない場合、実行中の処理の初期化を指示す
る初期化要求をICカード2へ送信する送信手段11
と、初期化要求に対応する確認応答を受信したか否かを
判定する判定手段12と、初期化要求に対応する確認応
答を受信した場合、ホストコンピュータ3から受信して
いた当該コマンドを、ICカード2へ再送する再送手段
13と、初期化要求に対応する確認応答を受信しない場
合、所定の期間中にICカード2から受信するデータは
すべて無効化する無効化手段14と、所定の期間経過
後、ホストコンピュータ2へ異常終了を通知する通知手
段15と、を備える。According to the present invention, the command received from the host computer 3 is connected to the host computer 3 via the serial interface 5 and is transmitted to the non-contact type IC card 2 via the antenna 4, and the data based on the command is transmitted. When the IC card reader / writer 1 performs communication with the IC card 2 and the command is transmitted to the IC card 2 but the data communication corresponding to the command cannot be established, a negative response is given. In the IC card reader / writer 1 that transmits a predetermined number of times to the IC card 2, if no response is received even though the negative response is transmitted, the IC card 2 issues an initialization request for instructing initialization of the process being executed. Sending means 11 for sending to
And a determination means 12 for determining whether or not a confirmation response corresponding to the initialization request is received, and when the confirmation response corresponding to the initialization request is received, the command received from the host computer 3 The resending means 13 for resending to the card 2, the invalidating means 14 for invalidating all the data received from the IC card 2 during a predetermined period when the confirmation response corresponding to the initialization request is not received, and the predetermined period elapses. After that, the notification means 15 for notifying the host computer 2 of the abnormal end is provided.
【0024】図2は、ICカードリーダライタとICカ
ードとの間で発生し得る通信不能を説明する図である。FIG. 2 is a diagram for explaining incommunicability that may occur between the IC card reader / writer and the IC card.
【0025】一般に、ICカードリーダライタ1からI
Cカード2への電波送信可能距離x 2は、ICカードリ
ーダライタ1のICカード2からのデータ受信可能距離
x1よりも長い。これは、自己電源を有しないICカー
ド2がICカードリーダライタ1から供給された磁気エ
ネルギーを利用して内部CPUを動作させて所定の通信
データをキャリアで送信するのに必要なエネルギーより
も、ICカードリーダライタ1がICカード2へ供給す
る磁気エネルギーのほうが大きいことにも起因する。Generally, the IC card reader / writer 1 to I
Radio wave transmission distance to C card 2 x 2Is an IC card
-Receivable distance from the IC card 2 of the writer / writer 1
x1Longer than. This is an IC car that does not have its own power source
Card 2 is supplied from the IC card reader / writer 1.
Prescribed communication by operating the internal CPU using energy
Than the energy required to transmit the data on the carrier
Also, the IC card reader / writer 1 supplies the IC card 2
It is also due to the larger magnetic energy.
【0026】したがって、ICカードリーダライタ1と
ICカード2との間の通信が既に確立されたにもかかわ
らず、通信不能になってしまうのは、(1)ICカード
2がICカードリーダライタ1の電波送信可能距離x2
外になった場合、および(2)ICカード2がICカー
ドリーダライタ1のデータ受信可能距離x1外になった
が、ICカードリーダライタ1の電波送信可能距離x2
内になった場合、の2通り考えられる。Therefore, even though the communication between the IC card reader / writer 1 and the IC card 2 is already established, the communication becomes impossible because (1) the IC card 2 is the IC card reader / writer 1. Radio wave transmittable distance x 2
When the IC card 2 is outside, and (2) the IC card 2 is outside the data receivable distance x 1 of the IC card reader / writer 1, but the radio wave transmittable distance x 2 of the IC card reader / writer 1 is
There are two possibilities when it comes to inside.
【0027】つまり、(1)の場合では、ICカードリ
ーダライタ1がICカード2へ各種コマンドを送信した
にもかかわらずICカード2はこれを受信することがで
きず、ICカード2が非活性状態になってしまう。That is, in the case of (1), although the IC card reader / writer 1 sends various commands to the IC card 2, the IC card 2 cannot receive them and the IC card 2 is inactive. It will be in a state.
【0028】また、(2)の場合では、ICカードリー
ダライタ1から送信された各種コマンドをICカード2
は受信し、ICカード2は各種コマンドに対するレスポ
ンスを送信することはできる。しかし、ICカード2か
ら送信されたレスポンスは、ICカードリーダライタ1
には到達しない。このとき、ICカード2は、ICカー
ドリーダライタ1から各種コマンドを受信することはで
きるので、活性状態のままである。In the case of (2), various commands transmitted from the IC card reader / writer 1 are sent to the IC card 2
Can be received, and the IC card 2 can send responses to various commands. However, the response sent from the IC card 2 is the IC card reader / writer 1
Does not reach. At this time, since the IC card 2 can receive various commands from the IC card reader / writer 1, it remains in the active state.
【0029】ICカードリーダライタ1からしてみれ
ば、通信不能の原因が上記2つの場合のどちらであるか
区別することができない。また、上記(1)の場合では
ICカード2は非活性状態にあり、上記(2)の場合で
はICカード2は活性状態にあるが、これらについても
区別はつかない。From the viewpoint of the IC card reader / writer 1, it is impossible to distinguish which of the above two cases causes the communication failure. Further, although the IC card 2 is in the inactive state in the case of the above (1) and the IC card 2 is in the active state in the above (2), it is not possible to distinguish between them.
【0030】したがって従来例においては、既に説明し
たように、上記(1)および(2)の場合の両方とも、
通信不能後に通信圏内に再度入ってきたICカードは全
て非活性状態にあるものと想定し、当時実行中であった
処理を完全に中止して、アンチコリジョン処理まで遡っ
て実行し直さなければならず、結果的に通信状態の復帰
には時間がかかっていた。Therefore, in the conventional example, as described above, both of the cases (1) and (2) above
It is assumed that all IC cards that have re-entered the communication area after communication failure are in the inactive state, so the processing that was being executed at that time must be completely stopped and the anti-collision processing must be performed again. As a result, it took time to restore the communication state.
【0031】これに対し、本発明によれば、通信状態を
確立していたにもかかわらず通信不能になった場合は、
送信手段11は初期化要求をICカードへ送信する。On the other hand, according to the present invention, when communication is disabled even though the communication state has been established,
The transmitting means 11 transmits the initialization request to the IC card.
【0032】そして、当該初期化要求に対応する確認応
答があった場合は、ICカードがICカードリーダライ
タの通信圏内にあって活性状態にあるということがわか
るので、再送手段13は、ホストコンピュータ3から受
信していた当該コマンドをICカード2へ再送する。つ
まり、迅速に初期状態に移行して、データ通信を再開す
るので、正常な通信状態に早期に復帰できすることがで
きる。Then, when there is a confirmation response corresponding to the initialization request, it is understood that the IC card is in the communication area of the IC card reader / writer and is in an active state. The command received from 3 is retransmitted to the IC card 2. That is, since the initial state is quickly changed and the data communication is restarted, it is possible to quickly return to the normal communication state.
【0033】また一方で、当該初期化要求に対応する確
認応答が無かった場合は、ICカードが活性状態にある
か非活性状態にあるかについてはわからないが、無効化
手段14は、所定の期間中にICカード2から受信する
データは念のためすべて無効化して処理の誤動作を防止
し、そして通知手段15は、この所定の期間経過後、ホ
ストコンピュータ2へ異常終了を通知する。つまり、所
定の期間中にICカードから受信するデータに関しては
無効化し、所定の期間経過後は、ホストコンピュータへ
異常終了を通知するので、従来あったハングアップを回
避することができると共に、処理の誤動作も防止するこ
とができる。On the other hand, if there is no confirmation response corresponding to the initialization request, it is not known whether the IC card is in the active state or the inactive state, but the invalidation means 14 does not operate for a predetermined period. All the data received from the IC card 2 is invalidated to prevent a malfunction of the process just in case, and the notification means 15 notifies the host computer 2 of the abnormal end after the lapse of the predetermined period. In other words, the data received from the IC card is invalidated during the predetermined period, and after the predetermined period has elapsed, the host computer is notified of the abnormal end, so that it is possible to avoid the hang-up that has been present in the past, and to perform Malfunctions can also be prevented.
【0034】すなわち、本発明によれば、ICカードリ
ーダライタ1の通信圏内に入って通信状態が確立した非
接触型のICカードが、ICカードリーダライタの通信
圏外になったり同期ずれが発生したような場合でも、I
Cカードシステムのハングアップを回避できるととも
に、正常な通信状態に迅速に復帰することができる。That is, according to the present invention, the non-contact type IC card, which has entered the communication area of the IC card reader / writer 1 and has established the communication state, is out of the communication area of the IC card reader / writer or is out of synchronization. Even in such cases, I
It is possible to avoid a hang-up of the C card system and quickly return to a normal communication state.
【0035】[0035]
【発明の実施の形態】ここでは、JICSAPによるI
SO/IEC7816規格(JIS X 6304に相
当)準拠のICカードシステムに本発明を適用した実施
例を説明する。BEST MODE FOR CARRYING OUT THE INVENTION Here, I according to JISSAP
An embodiment in which the present invention is applied to an IC card system conforming to the SO / IEC7816 standard (corresponding to JIS X 6304) will be described.
【0036】ISO/IEC7816規格では、上述の
初期化要求に相当するものとしてRESYNCH要求も
しくはABORT要求が提供されている。In the ISO / IEC7816 standard, a RESYNC request or an ABORT request is provided as a counterpart of the above-mentioned initialization request.
【0037】RESYNCH要求は、現在実行中の処理
を初期化する初期化要求であって、現在実行中の処理を
記憶しておき、当該処理の前の状態に戻ることを指示す
る要求である。The RESYNC request is an initialization request for initializing the currently executing process, and is a request for storing the currently executing process and instructing to return to the state before the process.
【0038】また、ABORT要求は、同じく現在実行
中の処理を初期化する初期化要求であるが、現在実行中
の処理を記憶せずに廃棄し、当該処理の前の状態に戻る
ことを指示する要求である。The ABORT request is also an initialization request for initializing the process currently being executed. However, the process currently being executed is discarded without being stored, and an instruction to return to the state before the process is given. Is a request to do.
【0039】本実施例では、上述の初期化要求として、
RESYNCH要求またはABORT要求のいずれかを
用いる。In this embodiment, as the above initialization request,
Use either RESYNC request or ABORT request.
【0040】なお、図1を参照して説明した本発明のI
Cカードリーダライタの上述の各手段は、ICカードリ
ーダライタ内に、CPUおよび接続インタフェースなど
を含むファームウェア形式で実現される。The I of the present invention described with reference to FIG.
The above-described respective means of the C card reader / writer are realized in the IC card reader / writer in a firmware format including a CPU and a connection interface.
【0041】図3および4は、本発明の実施例によるI
Cカードリーダライタの動作を示すフローチャートであ
る。3 and 4 show I according to an embodiment of the present invention.
It is a flow chart which shows operation of a C card reader writer.
【0042】ここでは、ホストコンピュータに接続さ
れ、ホストコンピュータから受信したコマンドを非接触
型のICカードへ送信し、コマンドに基づくデータ通信
をICカードとの間で行うICカードリーダライタにお
いて、通信状態が確立されていたにもかかわらず、何ら
かの原因で通信不能になった場合のICカードリーダラ
イタの動作フローについて説明する。Here, in the IC card reader / writer connected to the host computer, the command received from the host computer is transmitted to the non-contact type IC card, and the data communication based on the command is performed with the IC card. An operation flow of the IC card reader / writer in the case where communication is disabled for some reason even though the above has been established will be described.
【0043】図3において、ICカードリーダライタと
ICカードとの間の通信状態が現在まで確立されていた
ときに、まずステップS101において、ICカードリ
ーダライタは、ホストコンピュータからコマンドを受信
する。In FIG. 3, when the communication state between the IC card reader / writer and the IC card has been established up to now, first, in step S101, the IC card reader / writer receives a command from the host computer.
【0044】なお、ホストコンピュータから受信するコ
マンドとしては、ホストコンピュータがICカードリー
ダライタに所定の処理を指示するコマンドと、ホストコ
ンピュータがICカードリーダライタを介してICカー
ドに所定の処理を指示するコマンドの2種類がある。受
信したコマンドがこれらのうちどちらのコマンドである
かは、コマンド内の所定のビットに記述されたアドレス
に基づいてICカードリーダライタが判断する。As commands received from the host computer, the host computer instructs the IC card reader / writer to perform a predetermined process, and the host computer instructs the IC card to perform a predetermined process via the IC card reader / writer. There are two types of commands. The IC card reader / writer determines which of these commands the received command is based on the address described in a predetermined bit in the command.
【0045】ステップS102において、受信したコマ
ンドをICカードへ送信する。このコマンドは、上述し
たようなホストコンピュータから受信する2種類のコマ
ンドのうち、ホストコンピュータがICカードリーダラ
イタを介してICカードに所定の処理を指示するコマン
ドである。In step S102, the received command is transmitted to the IC card. This command is a command for instructing the IC card to perform a predetermined process through the IC card reader / writer from the two types of commands received from the host computer as described above.
【0046】次いで、ステップS103において、IC
カードリーダライタは、ステップS102で送信したコ
マンドに対応するレスポンスを、ICカードから正常に
受信できたか否かを判定する。正常に受信できたか否か
判断は、パリティーチェック、および、予め決められた
レスポンス待ち時間がタイムアウトしたか否かのチェッ
クによりなされる。Then, in step S103, the IC
The card reader / writer determines whether the response corresponding to the command transmitted in step S102 has been successfully received from the IC card. Whether or not the reception is normally performed is determined by a parity check and whether or not a predetermined response waiting time has timed out.
【0047】ステップS103において、ICカードか
らのレスポンスを正常に受信できたと判定された場合、
すなわち、送信したコマンドに対応するレスポンスを受
信した場合は、ステップS104へ進む。When it is determined in step S103 that the response from the IC card has been normally received,
That is, when the response corresponding to the transmitted command is received, the process proceeds to step S104.
【0048】ステップS103において、ICカードか
らのレスポンスを正常に受信できなかったと判定された
場合、すなわち所定のレスポンス待ち時間内に何らレス
ポンスを受信しない場合、また送信したコマンドに対応
しないレスポンスを受信したとパリティーチェックにお
いて判断された場合はステップS105へ進む。In step S103, when it is determined that the response from the IC card cannot be normally received, that is, no response is received within the predetermined response waiting time, and a response not corresponding to the transmitted command is received. If it is determined in the parity check, the process proceeds to step S105.
【0049】ステップS104では、JICSAP仕様
の伝送プロトコルに従い、ICカードから受信したレス
ポンスをホストコンピュータへ送信する。したがって、
上述のステップS101〜S104を経ることにより、
ICカードリーダライタを介したホストコンピュータと
ICカードとのデータ通信が正常に実行されたことにな
る。In step S104, the response received from the IC card is transmitted to the host computer according to the transmission protocol of the JIS SAP specification. Therefore,
By going through the above steps S101 to S104,
Data communication between the host computer and the IC card via the IC card reader / writer has been normally executed.
【0050】ステップS105では、JICSAP仕様
の伝送プロトコルに従い、ICカードに否定応答を所定
の回数送信し、ステップS106では、ステップS10
5におけるICカードへの否定応答の送信回数が、所定
のリトライ回数を越えたか否かが判定される。In step S105, a negative response is transmitted to the IC card a predetermined number of times in accordance with the transmission protocol of the JIS SAP specification, and in step S106, step S10.
It is determined whether or not the number of transmissions of the negative response to the IC card in 5 exceeds the predetermined number of retries.
【0051】JICSAPの規定するところによれば、
ICカードリーダライタがホストコンピュータからコマ
ンドを受信したにもかかわらず、ICカードリーダライ
タがICカードと正常に通信することができなかった場
合には、否定応答が所定の回数ICカードへ送信され
る。According to the specifications of JISSAP,
When the IC card reader / writer cannot receive the command from the host computer but the IC card reader / writer cannot normally communicate with the IC card, a negative response is transmitted to the IC card a predetermined number of times. .
【0052】この所定の回数否定応答が送信されている
間に、当該否定応答のレスポンスを1度でもICカード
リーダライタが受信した場合は、ICカードがICカー
ドリーダライタの通信圏内にあり活性状態にある可能性
が高いので、ステップS102へ戻る。規定の送信回数
を越えてもなお当該否定応答のレスポンスを受信しない
場合は、ステップS107へ進む。換言すれば、ステッ
プS106において、ステップS105におけるICカ
ードへの否定応答の送信回数が、所定のリトライ回数を
越えない場合はステップS102へ進み、所定のリトラ
イ回数を越えた場合はステップS107へ進む。When the IC card reader / writer receives the response of the negative response even once while the negative responses are transmitted for the predetermined number of times, the IC card is in the communication range of the IC card reader / writer and is in the active state. Since there is a high possibility that it is present in step S102, the process returns to step S102. When the response of the negative response is not received even after the specified number of transmissions is exceeded, the process proceeds to step S107. In other words, in step S106, if the number of negative response transmissions to the IC card in step S105 does not exceed the predetermined number of retries, the process proceeds to step S102, and if it exceeds the predetermined number of retries, the process proceeds to step S107.
【0053】ステップS107において、ICカードリ
ーダライタは、RESYNCH要求もしくはABORT
要求をICカードへ送信し、そしてステップS108に
おいて、「ホストコンピュータから受信したコマンドを
ICカードに送信することによって発生し得る、ICカ
ードからのレスポンス」は受け付けない状態に入る。こ
れは、仮にICカードが、ICカードリーダライタの通
信圏内にあって活性状態にあるときは、当該コマンドに
対するレスポンスを返してくる可能性があるが、このよ
うなレスポンスは、エラーである可能性が高いからであ
る。In step S107, the IC card reader / writer makes a RESYNC request or ABORT.
The request is transmitted to the IC card, and in step S108, "a response from the IC card that can occur by transmitting a command received from the host computer to the IC card" is not accepted. This means that if the IC card is in the communication area of the IC card reader / writer and is in an active state, a response to the command may be returned, but such a response may be an error. Is high.
【0054】次いでステップS109において、送信し
たRESYNCH要求もしくはABORT要求に関する
確認応答を受信したか否かが判定される。Then, in step S109, it is determined whether or not the confirmation response for the transmitted RESYNC request or ABORT request has been received.
【0055】ステップS109においてRESYNCH
要求もしくはABORT要求に関する確認応答を受信し
たと判定された場合は、ICカードは通信圏内にあって
活性状態にあるということなのでステップS102へ戻
る。すなわち、ステップS102において、ホストコン
ピュータから受信したコマンドをICカードに再送す
る。したがって、再送した当該コマンドに対応するレス
ポンスをICカードから正常に受信した場合、ステップ
S104では当該レスポンスをホストコンピュータへ送
信するので、結果的には通信不能状態から速く復帰でき
たことになる。In step S109, RESYNCH
If it is determined that the request or the confirmation response related to the ABORT request is received, it means that the IC card is in the communication area and in the active state, and thus the process returns to step S102. That is, in step S102, the command received from the host computer is retransmitted to the IC card. Therefore, when the response corresponding to the retransmitted command is normally received from the IC card, the response is transmitted to the host computer in step S104, and as a result, the incommunicable state can be quickly recovered.
【0056】ステップS109においてRESYNCH
要求もしくはABORT要求に関する確認応答を受信し
なかったと判定された場合は、ステップS110へ進
む。At step S109, RESYNCH
When it is determined that the request or the acknowledgment regarding the ABORT request has not been received, the process proceeds to step S110.
【0057】ステップS110では、所定の期間中にI
Cカードからデータを受信した場合は当該データを無効
化する。In step S110, I
When the data is received from the C card, the data is invalidated.
【0058】図2を参照して説明したように、例えば、
ICカード2がICカードリーダライタ1の電波送信可
能距離x2外にある場合、ICカードリーダライタ1が
ICカード2へ各種コマンドを送信したにもかかわらず
ICカード2はこれを受信することができず、既にIC
カード2が通信圏外にあり非活性になってしまってい
る。As described with reference to FIG. 2, for example,
When the IC card 2 is outside the radio wave transmittable distance x 2 of the IC card reader / writer 1, the IC card 2 may receive various commands even though the IC card reader / writer 1 has sent various commands to the IC card 2. I can't do it already
Card 2 is out of communication range and is inactive.
【0059】また、例えば、ICカードICカード2が
ICカードリーダライタ1のデータ受信可能距離x1外
にあるが、ICカードリーダライタ1の電波送信可能距
離x2内にある場合、ICカードリーダライタ1から送
信された各種コマンドをICカード2は受信し、かつI
Cカード2は各種コマンドに対するレスポンスを送信す
ることはできるが、送信されたレスポンスは、ICカー
ドリーダライタ1に到達しない。Further, for example, when the IC card IC card 2 is outside the data receivable distance x 1 of the IC card reader / writer 1 but within the radio wave transmittable distance x 2 of the IC card reader / writer 1, the IC card reader The IC card 2 receives various commands transmitted from the writer 1, and I
The C card 2 can send responses to various commands, but the sent responses do not reach the IC card reader / writer 1.
【0060】ICカードリーダライタ1からしてみれ
ば、通信不能の原因が上記2つの場合の区別はつかな
い。しかし、ICカードICカード2がICカードリー
ダライタ1のデータ受信可能距離x1外にあるが、IC
カードリーダライタ1の電波送信可能距離x2内にある
ような場合では、ICカード2は活性化されたままであ
るので、ICカードはICカードリーダライタに対して
何らかのデータを送信しつづけている可能性もある。例
えばICカードに記憶されていたデータを、何回かに分
割してICカードリーダライタに送信していることも考
えられる。しかし、この場合は、分割されたデータ群の
一部が欠落していたりエラーを含んでいたりする可能性
が非常に高い。そこで、ICカードが、所定の送信間隔
でデータを送信する回数を考慮し、所定の待機期間を設
ける。この待機期間は、データ送信間隔にデータ送信回
数を乗算したものである。この所定の待機期間中にIC
カードリーダライタがICカードから受信したデータ
は、全て無効化し廃棄する。これにより誤動作を回避で
きる。From the viewpoint of the IC card reader / writer 1, it is impossible to distinguish between the above two cases where the cause of the communication failure is. However, if the IC card IC card 2 is outside the data receivable distance x 1 of the IC card reader / writer 1,
In the case where it is within the radio wave transmittable distance x 2 of the card reader / writer 1, since the IC card 2 remains activated, the IC card may continue to transmit some data to the IC card reader / writer. There is also a nature. For example, the data stored in the IC card may be divided into several times and transmitted to the IC card reader / writer. However, in this case, there is a high possibility that a part of the divided data group is missing or contains an error. Therefore, a predetermined waiting period is provided in consideration of the number of times the IC card transmits data at a predetermined transmission interval. This waiting period is the data transmission interval multiplied by the number of data transmissions. IC during this prescribed waiting period
All data received by the card reader / writer from the IC card is invalidated and discarded. As a result, malfunction can be avoided.
【0061】ステップS111では、上記所定の待機期
間経過後、ICカードリーダライタはホストコンピュー
タに対し、通信の異常終了を通知する。これによりホス
トコンピュータは、当該通信が異常なものであったこと
を認識することができるので、その後の対処を迅速に行
うことが可能である。In step S111, after the lapse of the predetermined waiting period, the IC card reader / writer notifies the host computer of abnormal termination of communication. As a result, the host computer can recognize that the communication was abnormal, so that it is possible to promptly take a subsequent action.
【0062】本実施例では、ステップS111により当
該通信の異常終了をホストコンピュータが認識したとき
は、通信不能状態であるか否かを確認するために、図4
のステップS201へ進む。これ以降のステップの基本
的な原理は上述したステップS101〜S111と同じ
であるので、ここでは簡単に説明する。In the present embodiment, when the host computer recognizes the abnormal end of the communication in step S111, in order to confirm whether or not the communication is impossible, as shown in FIG.
To step S201. Since the basic principle of the subsequent steps is the same as the above-described steps S101 to S111, a brief description will be given here.
【0063】ホストコンピュータは、ステップS111
により当該通信の異常終了を認識したとき、通信不能状
態であるか否かを確認するために、チェックコマンドを
送信する。The host computer executes step S111.
When the abnormal termination of the communication is recognized by, the check command is transmitted to confirm whether or not the communication is impossible.
【0064】すると、図4のステップS201に示すよ
うに、ICカードリーダライタは、ホストコンピュータ
からチェックコマンドを受信する。Then, as shown in step S201 of FIG. 4, the IC card reader / writer receives the check command from the host computer.
【0065】ステップS202において、受信したチェ
ックコマンドをICカードへ送信する。In step S202, the received check command is transmitted to the IC card.
【0066】次いで、ステップS203において、IC
カードリーダライタは、ステップS202で送信したチ
ェックコマンドに対応するレスポンスを、ICカードか
ら正常に受信できたか否かを判定する。正常に受信でき
たか否か判断は、パリティーチェック、および、予め決
められたレスポンス待ち時間がタイムアウトしたか否か
のチェックによりなされる。Then, in step S203, the IC
The card reader / writer determines whether the response corresponding to the check command transmitted in step S202 has been successfully received from the IC card. Whether or not the reception is normally performed is determined by a parity check and whether or not a predetermined response waiting time has timed out.
【0067】ステップS203において、送信したチェ
ックコマンドに対応するレスポンスを受信した場合は、
ステップS204へ進む。When the response corresponding to the transmitted check command is received in step S203,
It proceeds to step S204.
【0068】ステップS203において、ICカードか
らのレスポンスを正常に受信できなかったと判定された
場合は、ステップS205へ進む。If it is determined in step S203 that the response from the IC card could not be properly received, the process proceeds to step S205.
【0069】ステップS204では、ICカードから受
信したレスポンスをホストコンピュータへ送信する。し
たがって、ステップS201〜S204を経ることによ
り、ホストコンピュータは、ICカードがICカードリ
ーダライタの通信圏内にあって活性化されていることを
認識することができるので、その後の処理に迅速に移る
ことができる。具体的には、現在行っていた処理をリセ
ットしてアンチコリジョン処理に戻るか、あるいは、図
3のステップS102に戻って当該データ通信に必要な
コマンドをICカードに再送してもよい。In step S204, the response received from the IC card is transmitted to the host computer. Therefore, by going through steps S201 to S204, the host computer can recognize that the IC card is within the communication range of the IC card reader / writer and activated, so that the process can be swiftly proceeded to. You can Specifically, the process currently being performed may be reset to return to the anti-collision process, or the process may return to step S102 in FIG. 3 to retransmit the command required for the data communication to the IC card.
【0070】ステップS205では、ICカードに否定
応答を所定の回数送信し、ステップS206では、ステ
ップS205におけるICカードへの否定応答の送信回
数が、所定のリトライ回数を越えたか否かが判定され
る。In step S205, a negative response is transmitted to the IC card a predetermined number of times. In step S206, it is determined whether or not the number of negative response transmissions to the IC card in step S205 exceeds a predetermined number of retries. .
【0071】ステップS206において、ステップS2
05におけるICカードへの否定応答の送信回数が、所
定のリトライ回数を越えない場合はステップS202へ
進み、所定のリトライ回数を越えた場合はステップS2
07へ進む。In step S206, step S2
If the number of transmissions of the negative response to the IC card in 05 does not exceed the predetermined number of retries, the process proceeds to step S202, and if it exceeds the predetermined number of retries, the step S2.
Proceed to 07.
【0072】ステップS207において、ICカードリ
ーダライタは、RESYNCH要求もしくはABORT
要求をICカードへ送信し、そしてステップS208に
おいて、「ホストコンピュータから受信したコマンドを
ICカードに送信することによって発生し得る、ICカ
ードからのレスポンス」は受け付けない状態に入る。In step S207, the IC card reader / writer makes a RESYNC request or ABORT.
The request is transmitted to the IC card, and in step S208, "a response from the IC card that can occur by transmitting a command received from the host computer to the IC card" is not accepted.
【0073】次いでステップS209において、送信し
たRESYNCH要求もしくはABORT要求に関する
確認応答を受信したか否かが判定される。Then, in step S209, it is determined whether or not the confirmation response relating to the transmitted RESYNC request or ABORT request has been received.
【0074】ステップS209において、RESYNC
H要求もしくはABORT要求に関する確認応答を受信
したと判定された場合は、ICカードは通信圏内にあっ
て活性状態にあるということなのでステップS202へ
戻る。In step S209, RESYNC
If it is determined that the confirmation response related to the H request or the ABORT request is received, it means that the IC card is in the communication area and in the active state, and the process returns to step S202.
【0075】ステップS209において、RESYNC
H要求もしくはABORT要求に関する確認応答を受信
しなかったと判定された場合は、ステップS210へ進
む。In step S209, RESYNC
When it is determined that the confirmation response regarding the H request or the ABORT request has not been received, the process proceeds to step S210.
【0076】ステップS210では、所定の期間中にI
Cカードからデータを受信した場合は当該データを無効
化する。In step S210, the I
When the data is received from the C card, the data is invalidated.
【0077】この所定の待機期間はステップS110に
関して既に説明したとおりである。この所定の待機期間
中にICカードリーダライタがICカードから受信した
データは、全て無効化し廃棄する。This predetermined waiting period is as described above with respect to step S110. All data received by the IC card reader / writer from the IC card during this predetermined waiting period is invalidated and discarded.
【0078】ステップS211では、上記所定の待機期
間経過後、ICカードリーダライタはホストコンピュー
タに対し、通信の異常終了を通知する。すなわち、IC
カードリーダライタからシリアルケーブルのCTS信号
線を介して出力される信号をオンからオフに切り換え
る。これにより従来例において生じていたハングアップ
を回避することができる。In step S211, after the lapse of the predetermined waiting period, the IC card reader / writer notifies the host computer of abnormal termination of communication. That is, IC
The signal output from the card reader / writer via the CTS signal line of the serial cable is switched from on to off. As a result, the hang-up that has occurred in the conventional example can be avoided.
【0079】以上のステップS201〜S211によ
り、ホストコンピュータは、当該通信が異常なものであ
ったことを確認することができるので、その後の対処を
迅速に行うことが可能である。具体的には、現在行って
いた処理をリセットしてアンチコリジョン処理に戻る
か、あるいは、図3のステップS102に戻って当該デ
ータ通信に必要なコマンドをICカードに再送してもよ
い。Since the host computer can confirm that the communication is abnormal by the above steps S201 to S211, it is possible to promptly take a subsequent action. Specifically, the process currently being performed may be reset to return to the anti-collision process, or the process may return to step S102 in FIG. 3 to retransmit the command required for the data communication to the IC card.
【0080】また、ステップS103、S106、S1
09、S203、S206、およびS209のうちいず
れかにおいて、ICカードリーダライタの通信圏内にI
Cカードが存在し、当該ICカードが活性化されている
かの認識が可能であるので、データ通信の迅速な復帰が
可能となる。Further, steps S103, S106, S1
09, S203, S206, or S209, the IC card reader / writer is placed within the communication range.
Since the C card exists and it is possible to recognize whether the IC card is activated, it is possible to quickly restore the data communication.
【0081】以上説明したように、本発明の実施例によ
れば、通信状態を確立していたにもかかわらず通信不能
になった場合は、ICカードリーダライタは、RESY
NCH要求もしくはABORT要求をICカードへ送信
する。As described above, according to the embodiment of the present invention, when communication is disabled even though the communication state has been established, the IC card reader / writer makes RESY
Send the NCH request or ABORT request to the IC card.
【0082】このとき、送信したRESYNCH要求も
しくはABORT要求に対応する確認応答があった場合
は、ICカードがICカードリーダライタの通信圏内に
あって活性状態にあるということがわかるので、ホスト
コンピュータから受信していた当該コマンドをICカー
ドへ再送する。これにより、迅速に初期状態に移行し
て、データ通信を再開するので、正常な通信状態に早期
に復帰できすることができる。At this time, if there is a confirmation response corresponding to the transmitted RESYNC request or ABORT request, it is understood that the IC card is within the communication range of the IC card reader / writer and is in an active state. The received command is retransmitted to the IC card. As a result, the initial state is quickly changed and the data communication is resumed, so that the normal communication state can be quickly returned.
【0083】また一方で、送信したRESYNCH要求
もしくはABORT要求に対応する確認応答が無かった
場合は、所定の期間中にICカードから受信するデータ
はすべて無効化して処理の誤動作を防止し、この所定の
期間経過後は、ホストコンピュータへ異常終了を通知す
る。つまり、所定の期間中にICカードから受信するデ
ータに関しては無効化し、所定の期間経過後は、ホスト
コンピュータへ異常終了を通知するので、従来あったハ
ングアップを回避することができる。On the other hand, if there is no confirmation response corresponding to the transmitted RESYNC request or ABORT request, all the data received from the IC card during the predetermined period is invalidated to prevent malfunction of the process. After the lapse of the period, the abnormal termination is notified to the host computer. In other words, the data received from the IC card is invalidated during a predetermined period, and after the lapse of the predetermined period, the host computer is notified of the abnormal termination, so that it is possible to avoid the hang-up that has been present in the past.
【0084】以上をまとめると、本発明によれば、IC
カードリーダライタの通信圏内に入って通信状態が確立
した非接触型のICカードが、ICカードリーダライタ
の通信圏外になったり同期ずれが発生したような場合で
も、ICカードシステムのハングアップを回避できると
ともに、正常な通信状態に迅速に復帰することができ
る。In summary, according to the present invention, an IC
Avoids hang-up of the IC card system even when a contactless IC card that has entered the communication area of the card reader / writer and has established a communication state is out of the communication area of the IC card reader / writer or if synchronization is lost. In addition, it is possible to quickly return to the normal communication state.
【0085】続いて、本発明の応用例について説明す
る。Next, an application example of the present invention will be described.
【0086】上述した本発明の実施例においては、IC
カードリーダライタとICカードとの間のワイヤレス通
信にエラーが発生した場合に対処するものを示したが、
本発明を、ICカードリーダライタとホストコンピュー
タとの間の有線通信にエラーが発生した場合にも応用す
ることができる。In the embodiment of the present invention described above, the IC
Although what was dealt with when an error occurred in the wireless communication between the card reader / writer and the IC card was shown,
The present invention can be applied even when an error occurs in wired communication between the IC card reader / writer and the host computer.
【0087】図5は、本発明の応用例におけるICカー
ドリーダライタの機能ブロック図である。FIG. 5 is a functional block diagram of an IC card reader / writer in an application example of the present invention.
【0088】本発明の応用例では、シリアルインタフェ
ース5を介してホストコンピュータ3に接続され、ホス
トコンピュータ3から受信したコマンドを非接触型のI
Cカード2へアンテナ4を介して送信し、コマンドに基
づくデータ通信をICカード2との間で行うICカード
リーダライタ1において、実行中の処理の初期化を指示
する初期化要求をホストコンピュータ3から受信したと
き、初期化要求をICカード2へ送信する送信手段21
と、送信した初期化要求に対応する確認応答を受信した
か否かを判定する判定手段22と、送信した初期化要求
に対応する確認応答を受信した場合、初期化要求の肯定
応答を、ホストコンピュータ3へ送信する返答手段23
と、送信した初期化要求に対応する確認応答を受信しな
い場合、所定の期間中にICカード2から受信するデー
タはすべて無効化する無効化手段24と、所定の期間経
過後、ホストコンピュータ3へ肯定応答を通知する通知
手段25と、を備える。In the application example of the present invention, the command received from the host computer 3 is connected to the host computer 3 via the serial interface 5 and the non-contact type I command is transmitted.
In the IC card reader / writer 1 which transmits to the C card 2 via the antenna 4 and performs data communication based on a command with the IC card 2, an initialization request for instructing initialization of the process being executed is issued by the host computer 3 When it is received from, the sending means 21 for sending the initialization request to the IC card 2
And a determination means 22 for determining whether or not the confirmation response corresponding to the transmitted initialization request is received, and when the confirmation response corresponding to the transmitted initialization request is received, an affirmative response of the initialization request is sent to the host. Response means 23 for transmitting to the computer 3
Then, when the confirmation response corresponding to the transmitted initialization request is not received, the invalidating means 24 for invalidating all the data received from the IC card 2 during the predetermined period, and the host computer 3 after the predetermined period elapses. The notification means 25 which notifies an affirmative response.
【0089】なお、図5に示した上述の各手段は、IC
カードリーダライタ内に、CPUおよび接続インタフェ
ースなどを含むファームウェア形式で実現される。The above-mentioned means shown in FIG.
It is implemented in a firmware format including a CPU and a connection interface in the card reader / writer.
【0090】また、上述の本発明の実施例の場合と同様
に、この応用例におけるICカードシステムは、JIC
SAPによるISO/IEC7816規格(JIS X
6304に相当)準拠するものとする。本応用例で
も、上述の初期化要求として、RESYNCH要求また
はABORT要求のどちらかを用いる。Further, as in the case of the above-described embodiment of the present invention, the IC card system in this application example is a
ISO / IEC7816 standard (JIS X
(Corresponding to 6304). Also in this application example, either the RESYNC request or the ABORT request is used as the initialization request.
【0091】図6は、本発明の応用例におけるICカー
ドリーダライタの動作を示すフローチャートである。FIG. 6 is a flowchart showing the operation of the IC card reader / writer in the application example of the present invention.
【0092】データ通信をICカードとの間で行うIC
カードリーダライタにおいて、通信状態が既に確立され
ていたにもかかわらず、ホストコンピュータとICカー
ドリーダライタとの間で通信エラーが発生した場合につ
いて説明する。IC for performing data communication with an IC card
A case will be described in which a communication error has occurred between the host computer and the IC card reader / writer even though the communication state has already been established in the card reader / writer.
【0093】ホストコンピュータとICカードリーダラ
イタとの間で発生し得る通信エラーとしてはパリティー
エラーとフレーミングエラーとがあるが、ホストコンピ
ュータが、ICカードリーダライタとの通信においてこ
れらのエラーを検知したときは、RESYNCH要求ま
たはABORT要求をICカードリーダライタに送信す
るものとする。Communication errors that may occur between the host computer and the IC card reader / writer include a parity error and a framing error. When the host computer detects these errors in communication with the IC card reader / writer. Shall send a RESYNC request or an ABORT request to the IC card reader / writer.
【0094】まずステップS301において、ICカー
ドリーダライタは、ホストコンピュータからRESYN
CH要求またはABORT要求を受信する。First, in step S301, the IC card reader / writer sends a RESYN signal from the host computer.
Receive CH or ABORT request.
【0095】既に説明したように、RESYNCH要求
は、現在実行中の処理を初期化する初期化要求であっ
て、現在実行中の処理を記憶しておき、当該処理の前の
状態に戻ることを指示する要求である。As described above, the RESYNC request is an initialization request for initializing the process currently being executed, and stores the process currently being executed, and returns to the state before the process. It is a request to instruct.
【0096】また、ABORT要求は、現在実行中の処
理を初期化する初期化要求であって、現在実行中の処理
を記憶せずに廃棄し、当該処理の前の状態に戻ることを
指示する要求である。The ABORT request is an initialization request for initializing the process currently being executed, and indicates that the process currently being executed is discarded without being stored and the state before the process is returned to. It is a request.
【0097】したがって、ステップS301においてI
CカードリーダライタがRESYNCH要求またはAB
ORT要求を受信すると、ICカードリーダライタで実
行されていた処理は初期化されることになる。Therefore, in step S301, I
C card reader / writer requests RESYNC or AB
When the ORT request is received, the processing executed by the IC card reader / writer is initialized.
【0098】次に、ステップS302において、ICカ
ードリーダライタは、受信したRESYNCH要求また
はABORT要求をICカードへ送信する。Next, in step S302, the IC card reader / writer transmits the received RESYNC request or ABORT request to the IC card.
【0099】次いで、ステップS303において、IC
カードリーダライタは、送信したRESYNCH要求も
しくはABORT要求に関する確認応答を受信したか否
かを判定する。Then, in step S303, the IC
The card reader / writer determines whether or not it has received the confirmation response regarding the transmitted RESYNC request or ABORT request.
【0100】ステップS303においてRESYNCH
要求もしくはABORT要求に関する確認応答を受信し
たと判定された場合は、ステップS304へ進む。この
場合は、ICカードは通信圏内にあり活性化されていた
ということであり、ICカードは、RESYNCH要求
またはABORT要求を受信することにより、実行され
ていた処理は初期化されることになる。At step S303, RESYNCH
When it is determined that the request or the confirmation response regarding the ABORT request is received, the process proceeds to step S304. In this case, it means that the IC card is in the communication area and has been activated, and the IC card receives the RESYNC request or the ABORT request, whereby the processing being executed is initialized.
【0101】ステップS304では、ICカードリーダ
ライタはホストコンピュータへ肯定応答を通知する。し
たがって、ステップS301〜S304を経た場合は、
ICカードリーダライタおよびICカードを初期化でき
ると共に、ホストコンピュータについても肯定応答を受
信したことをトリガとすれば初期化することができるの
で、システム全体がハングアップすることは無く、また
結果的には、通信状態を早急に復旧させることもでき
る。In step S304, the IC card reader / writer notifies the host computer of an affirmative response. Therefore, when steps S301 to S304 are performed,
The IC card reader / writer and the IC card can be initialized, and the host computer can also be initialized by receiving a positive response as a trigger, so that the entire system does not hang up, and as a result, Can also quickly restore the communication status.
【0102】ステップS303においてRESYNCH
要求もしくはABORT要求に関する確認応答を受信し
なかったと判定された場合は、ステップS305へ進
む。この場合は、ホストコンピュータとICカードリー
ダライタとの間のみならず、上述の理由からICカード
リーダライタとICカードとの間においても通信エラー
が発生したということである。In step S303, RESYNCH
When it is determined that the request or the acknowledgment regarding the ABORT request has not been received, the process proceeds to step S305. In this case, a communication error has occurred not only between the host computer and the IC card reader / writer, but also between the IC card reader / writer and the IC card for the above reason.
【0103】したがってステップS305において、図
3のステップS110もしくは図4のステップS210
において説明したことと同じように、所定の期間中にI
Cカードからデータを受信した場合は当該データを無効
化し、処理の誤動作を防止する。Therefore, in step S305, step S110 of FIG. 3 or step S210 of FIG.
As described above in I
When the data is received from the C card, the data is invalidated and the malfunction of the process is prevented.
【0104】次いでステップS306において、上記所
定の待機期間経過後、ICカードリーダライタは、ホス
トコンピュータに対し、肯定応答を送信する。これによ
り、ホストコンピュータについては肯定応答を受信した
ことをトリガとすれば初期化することができる。したが
って、ホストコンピュータとICカードリーダライタと
の間のみならず、ICカードリーダライタとICカード
との間においても通信エラーが発生したとしても、シス
テム全体がハングアップすることは無く、また結果的に
は、通信状態を早急に復旧させることもできる。Next, in step S306, after the lapse of the predetermined waiting period, the IC card reader / writer sends an affirmative response to the host computer. As a result, the host computer can be initialized by receiving a positive response as a trigger. Therefore, even if a communication error occurs not only between the host computer and the IC card reader / writer but also between the IC card reader / writer and the IC card, the entire system does not hang up, and as a result, Can also quickly restore the communication status.
【0105】以上説明したように、本発明の応用例によ
れば、データ通信をICカードとの間の通信状態が確立
されていたにもかかわらず、ホストコンピュータとIC
カードリーダライタとの間においてパリティーエラーも
しくはフレーミングエラーなどの通信エラーが発生した
としても、システム全体がハングアップすることは無
く、また結果的には、通信状態を早急に復旧させること
もできる。As described above, according to the application example of the present invention, although the communication state between the IC card and the data communication is established, the host computer and the IC
Even if a communication error such as a parity error or a framing error occurs with the card reader / writer, the entire system does not hang up, and as a result, the communication state can be promptly restored.
【0106】なお、上述の本発明の実施例と応用例とを
同時に実現することも可能であり、これによりICカー
ドシステムの信頼性、利便性はさらに向上する。It is also possible to simultaneously realize the above-described embodiment of the present invention and the application example, which further improves the reliability and convenience of the IC card system.
【0107】[0107]
【発明の効果】以上説明したように、本発明によれば、
非接触型ICカードシステムにおいて、既に通信状態を
確立していたにもかかわらず通信不能になった場合は、
ICカードリーダライタは、まず初期化要求をICカー
ドへ送信する。このとき、送信した初期化要求に対応す
る確認応答があった場合は、ホストコンピュータから受
信していた当該コマンドをICカードへ再送する。つま
り、迅速に初期状態に移行して、データ通信を再開する
ので、正常な通信状態に迅速に復帰することができる。
送信した初期化要求に対応する確認応答が無かった場合
は、所定の期間中にICカードから受信するデータはす
べて無効化して処理の誤動作を防止し、この所定の期間
経過後、ホストコンピュータへ異常終了を通知する。つ
まり、所定の期間中にICカードから受信するデータに
関しては無効化し、所定の期間経過後は、ホストコンピ
ュータへ異常終了を通知するので、従来あったハングア
ップを回避し、かつ誤動作も回避することができ、正常
な通信状態に迅速に復帰することができる。As described above, according to the present invention,
In the non-contact type IC card system, if communication is impossible even though the communication state has already been established,
The IC card reader / writer first sends an initialization request to the IC card. At this time, if there is a confirmation response corresponding to the transmitted initialization request, the command received from the host computer is retransmitted to the IC card. That is, since the initial state is quickly changed and the data communication is restarted, it is possible to quickly return to the normal communication state.
If there is no confirmation response corresponding to the transmitted initialization request, all the data received from the IC card is invalidated within a predetermined period to prevent processing malfunction, and after this predetermined period has passed, an error is sent to the host computer. Notify the end. In other words, the data received from the IC card is invalidated during the predetermined period, and after the predetermined period has elapsed, the host computer is notified of the abnormal termination, so that the conventional hang-up is avoided and malfunction is avoided. It is possible to quickly return to a normal communication state.
【0108】すなわち、本発明によれば、ICカードリ
ーダライタの通信圏内に入って通信状態が確立した非接
触型のICカードが、ICカードリーダライタの通信圏
外になったり同期ずれが発生したような場合でも、IC
カードシステムのハングアップを回避できるとともに、
正常な通信状態に迅速に復帰することができる。That is, according to the present invention, a non-contact type IC card, which has entered the communication area of the IC card reader / writer and has established the communication state, is out of the communication area of the IC card reader / writer or out of synchronization. IC
You can avoid hanging up the card system,
It is possible to quickly return to the normal communication state.
【0109】また、本発明によれば、ICカードが活性
状態もしくは非活性状態のどちらにあったとしても、I
Cカードシステムのハングアップを回避できるととも
に、正常な通信状態に迅速に復帰することができる。According to the present invention, whether the IC card is in the active state or the inactive state, I
It is possible to avoid a hang-up of the C card system and quickly return to a normal communication state.
【0110】さらに、本発明は、ホストコンピュータと
ICカードリーダライタとの間に発生し得る通信エラー
についても対応することができる。すなわち、データ通
信をICカードとの間の通信状態が確立されていたにも
かかわらず、ホストコンピュータとICカードリーダラ
イタとの間においてパリティーエラーもしくはフレーミ
ングエラーなどの通信エラーが発生したとしても、本発
明を用いれば、システム全体がハングアップすることは
無く、また結果的には、通信状態を早急に復旧させるこ
ともできる。Furthermore, the present invention can deal with a communication error that may occur between the host computer and the IC card reader / writer. That is, even if a communication error such as a parity error or a framing error occurs between the host computer and the IC card reader / writer, even if the communication state between the IC card and the data communication is established, According to the invention, the entire system does not hang up, and as a result, the communication state can be quickly restored.
【0111】なお、上述の本発明の実施例と応用例とを
同時に実現することも可能であり、これによりICカー
ドシステムの信頼性、利便性はさらに向上するIt is also possible to simultaneously realize the above-described embodiment of the present invention and the application example thereof, which further improves the reliability and convenience of the IC card system.
【図1】本発明のICカードリーダライタの機能ブロッ
ク図である。FIG. 1 is a functional block diagram of an IC card reader / writer according to the present invention.
【図2】ICカードリーダライタとICカードとの間で
発生し得る通信不能を説明する図である。FIG. 2 is a diagram illustrating a communication failure that may occur between an IC card reader / writer and an IC card.
【図3】本発明の実施例によるICカードリーダライタ
の動作を示すフローチャート(その1)である。FIG. 3 is a flowchart (part 1) showing the operation of the IC card reader / writer according to the embodiment of the present invention.
【図4】本発明の実施例によるICカードリーダライタ
の動作を示すフローチャート(その2)である。FIG. 4 is a flowchart (No. 2) showing the operation of the IC card reader / writer according to the embodiment of the present invention.
【図5】本発明の応用例におけるICカードリーダライ
タの機能ブロック図である。FIG. 5 is a functional block diagram of an IC card reader / writer in an application example of the present invention.
【図6】本発明の応用例におけるICカードリーダライ
タの動作を示すフローチャートである。FIG. 6 is a flowchart showing the operation of an IC card reader / writer in an application example of the present invention.
【図7】非接触型ICカードシステムの概略図である。FIG. 7 is a schematic diagram of a non-contact type IC card system.
1…ICカードリーダライタ 2…ICカード 3…ホストコンピュータ 4…アンテナ 5…シリアルインタフェース 11…送信手段 12…判定手段 13…再送手段 14…無効化手段 15…通知手段 1 ... IC card reader / writer 2 ... IC card 3 ... Host computer 4 ... antenna 5 ... Serial interface 11 ... Transmission means 12 ... Judgment means 13 ... Retransmission means 14 ... Invalidation means 15 ... Notification means
───────────────────────────────────────────────────── フロントページの続き (72)発明者 竹内 浩文 長野県長野市大字栗田字舎利田711番地 新光電気工業株式会社内 Fターム(参考) 2C005 MA25 TA22 TA40 5B058 CA23 KA02 KA04 KA08 KA27 YA20 ─────────────────────────────────────────────────── ─── Continued front page (72) Inventor Hirofumi Takeuchi 711 Toshida, Kurita, Oita, Nagano City, Nagano Prefecture Shinko Electric Industry Co., Ltd. F-term (reference) 2C005 MA25 TA22 TA40 5B058 CA23 KA02 KA04 KA08 KA27 YA20
Claims (20)
接続され、前記ホストコンピュータから受信したコマン
ドを非接触型のICカードへ送信し、前記コマンドに基
づくデータ通信を前記ICカードとの間で行うICカー
ドリーダライタの制御方法であって、 前記ホストコンピュータから受信した前記コマンドを前
記ICカードへ送信したにもかかわらず、当該コマンド
に対応するデータ通信を確立できなかった場合は、否定
応答を前記ICカードへ所定の回数だけ送信するICカ
ードリーダライタの制御方法において、 前記否定応答を送信したにもかかわらず何らレスポンス
を受信できない場合、実行中の処理の初期化を指示する
初期化要求をICカードへ送信する送信ステップと、 前記初期化要求に対応する確認応答を受信したか否かを
判定する判定ステップと、 前記初期化要求に対応する確認応答を受信した場合、前
記ホストコンピュータから受信していた当該コマンド
を、前記ICカードへ再送する再送ステップと、を備え
ることを特徴とするICカードリーダライタの制御方
法。1. An IC card connected to a host computer via a cable, transmitting a command received from the host computer to a non-contact type IC card, and performing data communication based on the command with the IC card. A method of controlling a reader / writer, wherein when the command received from the host computer is transmitted to the IC card, but data communication corresponding to the command cannot be established, a negative response is returned to the IC card. In a method of controlling an IC card reader / writer that transmits a predetermined number of times to the IC card, if no response is received despite transmitting the negative response, an initialization request for instructing initialization of the process being executed is sent to the IC card. A sending step of sending, and whether or not an acknowledgment corresponding to the initialization request has been received And a resending step of resending the command received from the host computer to the IC card when a confirmation response corresponding to the initialization request is received. Control method of IC card reader / writer.
信しない場合、所定の期間中に前記ICカードから受信
するデータはすべて無効化する無効化ステップと、 前記所定の期間経過後、前記ホストコンピュータへ異常
終了を通知する通知ステップと、を備える請求項1に記
載のICカードリーダライタの制御方法。2. An invalidation step of invalidating all data received from the IC card during a predetermined period when the confirmation response corresponding to the initialization request is not received, and the host after the predetermined period has elapsed. The method of controlling an IC card reader / writer according to claim 1, further comprising a notification step of notifying a computer of abnormal termination.
信した場合、前記ホストコンピュータから受信していた
当該コマンドを、前記ICカードへ再送するさらなる再
送ステップを備える請求項1または2に記載のICカー
ドリーダライタの制御方法。3. The method according to claim 1, further comprising a step of retransmitting the command, which has been received from the host computer, to the IC card when the confirmation response corresponding to the initialization request is received. Control method of IC card reader / writer.
接続され、前記ホストコンピュータから受信したコマン
ドを非接触型のICカードへ送信し、前記コマンドに基
づくデータ通信を前記ICカードとの間で行うICカー
ドリーダライタの制御方法であって、 実行中の処理の初期化を指示する初期化要求を前記ホス
トコンピュータから受信したとき、前記初期化要求をI
Cカードへ送信する送信ステップと、 送信した前記初期化要求に対応する確認応答を受信した
か否かを判定する判定ステップと、 送信した前記初期化要求に対応する確認応答を受信した
場合、前記初期化要求の肯定応答を、前記ホストコンピ
ュータへ送信する返答ステップと、を備えることを特徴
とするICカードリーダライタの制御方法。4. An IC card connected to a host computer via a cable, transmitting a command received from the host computer to a non-contact type IC card, and performing data communication based on the command with the IC card. A method of controlling a reader / writer, wherein when an initialization request for instructing initialization of a process being executed is received from the host computer, the initialization request is I
A transmitting step of transmitting to the C card; a determining step of determining whether or not a confirmation response corresponding to the transmitted initialization request is received; and a case of receiving a confirmation response corresponding to the transmitted initialization request, A response step of transmitting an affirmative response to the initialization request to the host computer, the method of controlling the IC card reader / writer.
応答を受信しない場合、所定の期間中に前記ICカード
から受信するデータはすべて無効化する無効化ステップ
と、 前記所定の期間経過後、前記ホストコンピュータへ肯定
応答を通知する通知ステップと、を備える請求項4に記
載のICカードリーダライタの制御方法。5. An invalidation step of invalidating all data received from the IC card during a predetermined period when a confirmation response corresponding to the transmitted initialization request is not received, and after the predetermined period has elapsed, The control method of the IC card reader / writer according to claim 4, further comprising a notification step of notifying the host computer of a positive response.
接続され、前記ホストコンピュータから受信したコマン
ドを非接触型のICカードへ送信し、前記コマンドに基
づくデータ通信を前記ICカードとの間で行う、JIS
X 6304規格準拠のICカードリーダライタの制
御方法であって、 前記ホストコンピュータから受信した前記コマンドを前
記ICカードへ送信したにもかかわらず、当該コマンド
に対応するデータ通信を確立できなかった場合は、否定
応答を前記ICカードへ所定の回数だけ送信するICカ
ードリーダライタの制御方法において、 前記否定応答を送信したにもかかわらず何らレスポンス
を受信できない場合、RESYNCH要求もしくはAB
ORT要求をICカードへ送信する送信ステップと、 送信した前記RESYNCH要求もしくはABORT要
求に対応する確認応答を受信したか否かを判定する判定
ステップと、 送信した前記RESYNCH要求コマンドもしくはAB
ORT要求に対応する確認応答を受信した場合、前記ホ
ストコンピュータから受信していた当該コマンドを、前
記ICカードへ再送する再送ステップと、を備えること
を特徴とするICカードリーダライタの制御方法。6. A JIS, which is connected to a host computer via a cable, transmits a command received from the host computer to a non-contact type IC card, and performs data communication based on the command with the IC card.
A method for controlling an IC card reader / writer conforming to the X 6304 standard, wherein the command received from the host computer is transmitted to the IC card, but data communication corresponding to the command cannot be established. In a control method of an IC card reader / writer that transmits a negative response to the IC card a predetermined number of times, if no response can be received despite transmitting the negative response, a RESYNC request or AB
A transmission step of transmitting an ORT request to the IC card, a determination step of determining whether or not an acknowledgment corresponding to the transmitted RESYNCH request or ABORT request has been received, and the transmitted RESYNCH request command or AB
A method of controlling an IC card reader / writer, comprising: a resending step of resending the command received from the host computer to the IC card when an confirmation response corresponding to the ORT request is received.
はABORT要求に対応する確認応答を受信しない場
合、所定の期間中に前記ICカードから受信するデータ
はすべて無効化する無効化ステップと、 前記所定の期間経過後、前記ホストコンピュータへ異常
終了を通知する通知ステップと、を備える請求項6に記
載のICカードリーダライタの制御方法。7. An invalidation step of invalidating all data received from the IC card during a predetermined period when the confirmation response corresponding to the RESYNCH request or ABORT request transmitted is not received, and the predetermined period elapses. 7. A control method of the IC card reader / writer according to claim 6, further comprising a notification step of notifying the host computer of abnormal termination.
RT要求に対応する確認応答を受信した場合、前記ホス
トコンピュータから受信していた当該コマンドを、前記
ICカードへ再送するさらなる再送ステップを備える請
求項6または7に記載のICカードリーダライタの制御
方法。8. The RESYNC request or ABO
8. The control method for an IC card reader / writer according to claim 6, further comprising a further step of retransmitting the command received from the host computer to the IC card when an acknowledgment response corresponding to the RT request is received. .
接続され、前記ホストコンピュータから受信したコマン
ドを非接触型のICカードへ送信し、前記コマンドに基
づくデータ通信を前記ICカードとの間で行う、ISO
7816規格準拠のICカードリーダライタの制御方法
であって、 RESYNCH要求もしくはABORT要求を前記ホス
トコンピュータから受信したとき、当該RESYNCH
要求もしくはABORT要求をICカードへ送信する送
信ステップと、 送信した前記RESYNCH要求もしくはABORT要
求に対応する確認応答を受信したか否かを判定する判定
ステップと、 送信した前記RESYNCH要求もしくはABORT要
求に対応する確認応答を受信した場合、前記RESYN
CH要求もしくはABORT要求の肯定応答を、前記ホ
ストコンピュータへ送信する返答ステップと、を備える
ことを特徴とするICカードリーダライタの制御方法。9. An ISO, which is connected to a host computer via a cable, transmits a command received from the host computer to a non-contact type IC card, and performs data communication based on the command with the IC card.
A method of controlling an IC card reader / writer conforming to the 7816 standard, wherein when a RESYNC request or an ABORT request is received from the host computer, the RESYNCCH
Request or ABORT request is transmitted to the IC card, a determination step is performed to determine whether or not a confirmation response corresponding to the transmitted RESYNCH request or ABORT request has been received, and the transmitted RESYNCH request or ABORT request is handled. When the confirmation response to
And a reply step of transmitting an affirmative response of the CH request or the ABORT request to the host computer.
くはABORT要求に対応する確認応答を受信しない場
合、所定の期間中に前記ICカードから受信するデータ
はすべて無効化する無効化ステップと、 前記所定の期間経過後、前記ホストコンピュータへ肯定
応答を通知する通知ステップと、を備える請求項9に記
載のICカードリーダライタの制御方法。10. An invalidation step of invalidating all data received from the IC card during a predetermined period when a confirmation response corresponding to the RESYNC request or ABORT request transmitted is not received, and the predetermined period elapses. 10. A method of controlling the IC card reader / writer according to claim 9, further comprising a notification step of notifying the host computer of a positive response.
に接続され、前記ホストコンピュータから受信したコマ
ンドを非接触型のICカードへ送信し、前記コマンドに
基づくデータ通信を前記ICカードとの間で行うICカ
ードリーダライタであって、 前記コマンドを前記ICカードへ送信したにもかかわら
ず、当該コマンドに対応するデータ通信を確立できなか
った場合は、否定応答を前記ICカードへ所定の回数だ
け送信するICカードリーダライタにおいて、 前記否定応答を送信したにもかかわらず何らレスポンス
を受信できない場合、実行中の処理の初期化を指示する
初期化要求をICカードへ送信する送信手段と、 前記初期化要求に対応する確認応答を受信したか否かを
判定する判定手段と、 前記初期化要求に対応する確認応答を受信した場合、前
記ホストコンピュータから受信していた当該コマンド
を、前記ICカードへ再送する再送手段と、を備えるこ
とを特徴とするICカードリーダライタ。11. An IC card connected to a host computer via a cable, transmitting a command received from the host computer to a non-contact type IC card, and performing data communication based on the command with the IC card. An IC card which is a reader / writer and which transmits a negative response to the IC card a predetermined number of times when the command is transmitted to the IC card but the data communication corresponding to the command cannot be established. In the reader / writer, if no response is received even though the negative response is transmitted, a transmitting unit that transmits an initialization request for instructing the initialization of the process being executed to the IC card, and corresponds to the initialization request. And a confirmation response corresponding to the initialization request When receiving, the IC card reader-writer, characterized in that it comprises, retransmission means for the command which has been received from the host computer, and retransmits to the IC card.
受信しない場合、所定の期間中に前記ICカードから受
信するデータはすべて無効化する無効化手段と、 前記所定の期間経過後、前記ホストコンピュータへ異常
終了を通知する通知手段と、を備える請求項11に記載
のICカードリーダライタ。12. An invalidation unit for invalidating all data received from the IC card during a predetermined period when the confirmation response corresponding to the initialization request is not received, and the host after the predetermined period. The IC card reader / writer according to claim 11, further comprising: a notification unit that notifies the computer of abnormal termination.
受信した場合、前記ホストコンピュータから受信してい
た当該コマンドを、前記ICカードへ再送するさらなる
再送手段を備える請求項11または12に記載のICカ
ードリーダライタ。13. The method according to claim 11, further comprising: a further resending unit that resends the command received from the host computer to the IC card when the confirmation response corresponding to the initialization request is received. IC card reader / writer.
に接続され、前記ホストコンピュータから受信したコマ
ンドを非接触型のICカードへ送信し、前記コマンドに
基づくデータ通信を前記ICカードとの間で行うICカ
ードリーダライタであって、 実行中の処理の初期化を指示する初期化要求を前記ホス
トコンピュータから受信したとき、前記初期化要求をI
Cカードへ送信する送信手段と、 送信した前記初期化要求に対応する確認応答を受信した
か否かを判定する判定手段と、 送信した前記初期化要求に対応する確認応答を受信した
場合、前記初期化コマンドの肯定応答を、前記ホストコ
ンピュータへ送信する返答手段と、を備えることを特徴
とするICカードリーダライタ。14. An IC card connected to a host computer via a cable, transmitting a command received from the host computer to a non-contact type IC card, and performing data communication based on the command with the IC card. The reader / writer receives the initialization request from the host computer when the initialization request is issued from the host computer.
Transmitting means for transmitting to the C card; determining means for determining whether or not a confirmation response corresponding to the transmitted initialization request has been received; and, when a confirmation response corresponding to the transmitted initialization request has been received, An IC card reader / writer, comprising: a reply means for transmitting an affirmative response to an initialization command to the host computer.
認応答を受信しない場合、所定の期間中に前記ICカー
ドから受信するデータはすべて無効化する無効化手段
と、 前記所定の期間経過後、前記ホストコンピュータへ肯定
応答を通知する通知手段と、を備える請求項14に記載
のICカードリーダライタ。15. An invalidation unit for invalidating all data received from the IC card during a predetermined period when the confirmation response corresponding to the transmitted initialization request is not received, and after the predetermined period has elapsed, 15. The IC card reader / writer according to claim 14, further comprising: notifying means for notifying the host computer of a positive response.
に接続され、前記ホストコンピュータから受信したコマ
ンドを非接触型のICカードへ送信し、前記コマンドに
基づくデータ通信を前記ICカードとの間で行う、JI
S X 6304規格準拠のICカードリーダライタで
あって、 前記コマンドを前記ICカードへ送信したにもかかわら
ず、当該コマンドに対応するデータ通信を確立できなか
った場合は、否定応答を前記ICカードへ所定の回数だ
け送信するICカードリーダライタにおいて、 前記否定応答を送信したにもかかわらず何らレスポンス
を受信できない場合、RESYNCH要求もしくはAB
ORT要求をICカードへ送信する送信手段と、 送信した前記RESYNCH要求もしくはABORT要
求に対応する確認応答を受信したか否かを判定する判定
手段と、 送信した前記RESYNCH要求もしくはABORT要
求に対応する確認応答を受信した場合、前記ホストコン
ピュータから受信していた当該コマンドを、前記ICカ
ードへ再送する再送手段と、を備えることを特徴とする
ICカードリーダライタ。16. A JI, which is connected to a host computer via a cable, transmits a command received from the host computer to a non-contact type IC card, and performs data communication based on the command with the IC card.
An IC card reader / writer conforming to the SX 6304 standard, and when the data communication corresponding to the command cannot be established even though the command is transmitted to the IC card, a negative response is sent to the IC card. In an IC card reader / writer that transmits a predetermined number of times, if no response is received despite transmitting the negative response, a RESYNC request or AB
Transmitting means for transmitting an ORT request to an IC card, determining means for determining whether or not a confirmation response corresponding to the transmitted RESYNCH request or ABORT request is received, and confirmation corresponding to the transmitted RESYNCH request or ABORT request An IC card reader / writer comprising: a resending unit that resends the command received from the host computer to the IC card when a response is received.
くはABORT要求に対応する確認応答を受信しない場
合、所定の期間中に前記ICカードから受信するデータ
はすべて無効化する無効化手段と、 前記所定の期間経過後、前記ホストコンピュータへ異常
終了を通知する通知手段と、を備える請求項16に記載
のICカードリーダライタ。17. Invalidating means for invalidating all data received from the IC card during a predetermined period when the confirmation response corresponding to the RESYNC request or ABORT request transmitted is not received, and the predetermined period elapses. The IC card reader / writer according to claim 16, further comprising a notification unit that notifies the host computer of abnormal termination.
ORT要求に対応する確認応答を受信した場合、前記ホ
ストコンピュータから受信していた当該コマンドを、前
記ICカードへ再送するさらなる再送手段を備える請求
項16または17に記載のICカードリーダライタ。18. The RESYNC request or AB
The IC card reader / writer according to claim 16 or 17, further comprising: a further resending unit that resends the command received from the host computer to the IC card when an acknowledgment response corresponding to the ORT request is received.
に接続され、前記ホストコンピュータから受信したコマ
ンドを非接触型のICカードへ送信し、前記コマンドに
基づくデータ通信を前記ICカードとの間で行う、IS
O7816規格準拠のICカードリーダライタであっ
て、 RESYNCH要求もしくはABORT要求を前記ホス
トコンピュータから受信したとき、当該RESYNCH
要求もしくはABORT要求をICカードへ送信する送
信手段と、 送信した前記RESYNCH要求もしくはABORT要
求に対応する確認応答を受信したか否かを判定する判定
手段と、 送信した前記RESYNCH要求もしくはABORT要
求に対応する確認応答を受信した場合、前記RESYN
CH要求もしくはABORT要求の肯定応答を、前記ホ
ストコンピュータへ送信する返答手段と、を備えること
を特徴とするICカードリーダライタ。19. An IS, which is connected to a host computer via a cable, transmits a command received from the host computer to a non-contact type IC card, and performs data communication based on the command with the IC card.
An IC card reader / writer that complies with the O7816 standard, and when a RESYNC request or an ABORT request is received from the host computer, the RESYNCCH
A request or an ABORT request to the IC card, a determining means for determining whether or not a confirmation response corresponding to the RESYNCH request or the ABORT request has been received, and a corresponding RESYNCH request or an ABORT request When the confirmation response to
An IC card reader / writer, comprising: reply means for transmitting an affirmative response to a CH request or an ABORT request to the host computer.
くはABORT要求に対応する確認応答を受信しない場
合、所定の期間中に前記ICカードから受信するデータ
はすべて無効化する無効化手段と、 前記所定の期間経過後、前記ホストコンピュータへ肯定
応答を通知する通知手段と、を備える請求項19に記載
のICカードリーダライタ。20. Invalidating means for invalidating all data received from the IC card during a predetermined period when the confirmation response corresponding to the transmitted RESYNC request or ABORT request is not received, and the predetermined period elapses. The IC card reader / writer according to claim 19, further comprising: a notification unit that notifies the host computer of a positive response.
Priority Applications (1)
| Application Number | Priority Date | Filing Date | Title |
|---|---|---|---|
| JP2001212372A JP2003030595A (en) | 2001-07-12 | 2001-07-12 | IC card reader / writer and control method thereof |
Applications Claiming Priority (1)
| Application Number | Priority Date | Filing Date | Title |
|---|---|---|---|
| JP2001212372A JP2003030595A (en) | 2001-07-12 | 2001-07-12 | IC card reader / writer and control method thereof |
Publications (1)
| Publication Number | Publication Date |
|---|---|
| JP2003030595A true JP2003030595A (en) | 2003-01-31 |
Family
ID=19047542
Family Applications (1)
| Application Number | Title | Priority Date | Filing Date |
|---|---|---|---|
| JP2001212372A Pending JP2003030595A (en) | 2001-07-12 | 2001-07-12 | IC card reader / writer and control method thereof |
Country Status (1)
| Country | Link |
|---|---|
| JP (1) | JP2003030595A (en) |
Cited By (1)
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| US8985451B2 (en) | 2005-01-31 | 2015-03-24 | Sony Corporation | Communication apparatus, communication method, and program |
-
2001
- 2001-07-12 JP JP2001212372A patent/JP2003030595A/en active Pending
Cited By (1)
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| US8985451B2 (en) | 2005-01-31 | 2015-03-24 | Sony Corporation | Communication apparatus, communication method, and program |
Similar Documents
| Publication | Publication Date | Title |
|---|---|---|
| US8504105B2 (en) | Simultaneous interface use | |
| CN101315673B (en) | IC card comprising main device and an additonal device | |
| EP1172755B1 (en) | Reading protocol for transponders of electronic identification system | |
| JP4661952B2 (en) | COMMUNICATION DEVICE AND COMMUNICATION METHOD, COMPUTER PROGRAM, AND COMMUNICATION SYSTEM | |
| US8811364B2 (en) | Method for controlling a control station, a method for controlling terminal station, a control station, a terminal station, and a computer readable storage medium | |
| EP3379854B1 (en) | Communication device | |
| EP3139667A1 (en) | Hybrid rf polling loop for nfc device and retry mechanism | |
| EP1845475A1 (en) | Communication medium, communication medium processing apparatus, and communication medium processing system | |
| US8985451B2 (en) | Communication apparatus, communication method, and program | |
| EP0886410A2 (en) | Data communication method, data communication apparatus, and data communication program recording medium | |
| CN113098567B (en) | Method for configuring non-contact communication equipment and electronic equipment | |
| JP2003030595A (en) | IC card reader / writer and control method thereof | |
| JP7468754B1 (en) | ELECTRONIC INFORMATION STORAGE MEDIUM, IC CHIP, IC CARD, RECEPTION BLOCK PROCESSING METHOD, AND PROGRAM | |
| CN102882661A (en) | Data transferring method | |
| US20070069865A1 (en) | IC tag, IC tag system, and data communicating method for the IC tag | |
| CN113392667B (en) | Data transmission method of reader-writer, data receiver and storage medium | |
| US6067626A (en) | Method of processing externally supplied data by CPU in non-operating state and portable terminal device for the same | |
| KR20080042021A (en) | Wireless communication systems, information and communication terminals, mobile phones, readers / writers, communication methods and computer programs | |
| JP2007199895A (en) | Proximity communication data processing device | |
| CN102904695B (en) | A kind of transmission method of radio frequency link data and system | |
| JP2011150597A (en) | Communication apparatus, medium and method | |
| JP2009277172A (en) | Reader/writer and non-contact ic module | |
| US11677444B2 (en) | Contactless transponder and method | |
| JP3362121B2 (en) | Frame collision control system and terminal device | |
| CN111417116B (en) | Communication methods and systems adapted through ATT, reading and writing, and exception handling |