JP2547795B2 - Portable electronic devices - Google Patents

Portable electronic devices

Info

Publication number
JP2547795B2
JP2547795B2 JP62273089A JP27308987A JP2547795B2 JP 2547795 B2 JP2547795 B2 JP 2547795B2 JP 62273089 A JP62273089 A JP 62273089A JP 27308987 A JP27308987 A JP 27308987A JP 2547795 B2 JP2547795 B2 JP 2547795B2
Authority
JP
Japan
Prior art keywords
data
card
electronic device
command data
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.)
Expired - Lifetime
Application number
JP62273089A
Other languages
Japanese (ja)
Other versions
JPH01116783A (en
Inventor
康雄 飯島
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Toshiba Corp
Original Assignee
Tokyo Shibaura Electric Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Tokyo Shibaura Electric Co Ltd filed Critical Tokyo Shibaura Electric Co Ltd
Priority to JP62273089A priority Critical patent/JP2547795B2/en
Publication of JPH01116783A publication Critical patent/JPH01116783A/en
Application granted granted Critical
Publication of JP2547795B2 publication Critical patent/JP2547795B2/en
Anticipated expiration legal-status Critical
Expired - Lifetime legal-status Critical Current

Links

Description

【発明の詳細な説明】 〔発明の目的〕 (産業上の利用分野) 本発明は、たとえばカードリーダ・ライタ(第1の電
子装置)から入力される命令データをICカード(携帯可
能電子装置)が受取り、上記命令データ中に含まれる機
能コードを解読し、これに対応する一連の処理を実行し
た後その処理結果を応答データとしてカードリーダ・ラ
イタに出力する処理方式に係り、特にカードリーダ・ラ
イタからの応答データの再送要求をICカードに対してう
ながすことが可能な処理方式に関する。
DETAILED DESCRIPTION OF THE INVENTION [Object of the Invention] (Industrial field of application) The present invention relates to an IC card (portable electronic device) that receives command data input from, for example, a card reader / writer (first electronic device). Received, the function code included in the above instruction data is decoded, a series of processes corresponding to this is executed, and then the processing result is output as response data to the card reader / writer, particularly the card reader / writer. The present invention relates to a processing method capable of prompting an IC card to resend a response data from a writer.

(従来の技術) 最近、新たな携帯可能なデータ記憶媒体として、不揮
発性のデータメモリおよびCPU(セントラル・プロセツ
シング・ユニツト)などの制御素子を有するICチツプを
内蔵したICカードが開発されている。この種のICカード
は、通常、カードリーダ・ライタを用いて稼働させるよ
うになつていて、その稼働の際、命令データを用いるの
が一般的である。ICカードは、受取つた命令データ中の
機能コードを解読し、これに対応する一連の処理を実行
し、その処理結果を応答データとしてカードリーダ・ラ
イタに出力する。すなわち、1つの命令データに対して
1つの応答データを出力する。この場合、たとえばカー
ドリーダ・ライタとICカードとの間の通信路に異常があ
り、カードリーダ・ライタがICカードからの応答データ
を正しく受取れなかつた場合には、カードリーダ・ライ
タはICカードに対して応答データの再送要求を行なう。
このとき、カードリーダ・ライタからの再送要求命令デ
ータに異常をきたし、IDカードがこの再送要求命令デー
タを正常に受取れなかつた場合、ICカードはその旨をカ
ードリーダ・ライタに応答データとして通知しなければ
ならない。しかし、ICカードのデータ出力用の出力バツ
フアが単一であつた場合、この通知のために出力バツフ
アを用いると、以降正常に再送要求命令データを受取つ
ても、出力バツフアには上記通知用データしか残つてお
らず、カードリーダ・ライタが再送要求している応答デ
ータが破壊されてしまう。この場合、正規の要求する応
答データをカードリーダ・ライタへ再送できないばかり
か、それ以降のカードリーダ・ライタとの間のシーケン
スが乱れてしまう。
(Prior Art) Recently, as a new portable data storage medium, an IC card having a built-in IC chip having a nonvolatile data memory and a control element such as a CPU (Central Processing Unit) has been developed. This type of IC card is normally operated by using a card reader / writer, and command data is generally used during the operation. The IC card decodes the function code in the received instruction data, executes a series of processes corresponding to the function code, and outputs the process result to the card reader / writer as response data. That is, one response data is output for one command data. In this case, for example, if the communication path between the card reader / writer and the IC card is abnormal and the card reader / writer cannot receive the response data from the IC card correctly, the card reader / writer will A response data resend request is issued.
At this time, if the resend request command data from the card reader / writer becomes abnormal and the ID card cannot normally receive the resend request command data, the IC card notifies the card reader / writer of that fact as response data. There must be. However, if there is a single output buffer for data output of the IC card, if the output buffer is used for this notification, even if the resend request command data is normally received after that, the above notification data will be sent to the output buffer. However, the response data requested by the card reader / writer for resending is destroyed. In this case, not only the normally requested response data cannot be retransmitted to the card reader / writer, but also the subsequent sequence with the card reader / writer is disturbed.

(発明が解決しようとする問題点) 本発明は、上記したように第1の電子装置からの再送
要求命令データに異常をきたし、第2の電子装置がこの
再送要求命令データを正常に受取れなかつた場合の問題
点を解決すべくなされたもので、第1の電子装置からの
再送要求命令テータに異常をきたした以降でも、第2の
電子装置が正常な再送要求命令データを受取ることによ
り、正規の要求する応答データを第1の電子装置へ再送
でき、第1の電子装置と第2の電子装置との間のシーケ
ンスの乱れが生じない処理方式を提供することを目的と
する。
(Problems to be Solved by the Invention) In the present invention, as described above, the retransmission request command data from the first electronic device is abnormal, and the second electronic device cannot normally receive the retransmission request command data. In order to solve the problem in the case of, the second electronic device receives the normal resend request command data even after the resend request command data from the first electronic device becomes abnormal. It is an object of the present invention to provide a processing method in which response data that is normally requested can be retransmitted to a first electronic device and a sequence disorder between the first electronic device and the second electronic device does not occur.

〔発明の構成〕[Structure of Invention]

(問題点を解決するための手段) 本発明は、第1の電子装置から入力される命令データ
及び再送要求命令データを受取り応答データを前記第1
の電子装置に出力する携帯可能電子装置において、前記
第1の電子装置から受取った命令データが前記処理結果
の再送要求命令であるか再送要求以外の命令データであ
るのかを識別する識別手段と、この識別手段による識別
の結果、再送要求以外の命令データの場合この命令デー
タに対応した処理を行う処理手段と、この処理手段によ
る命令の処理結果がセットされこのデータを応答データ
として前記第1の電子装置に出力する第1の出力バッフ
ァと、前記識別手段による識別の結果前記第1の電子装
置から受取った命令データが前記処理結果の再送要求命
令であった場合に前記処理手段による処理結果がセット
されこのデータを応答データとして前記第1の電子装置
に出力する第2の出力バッファとを有することを特徴と
するものである。
(Means for Solving Problems) The present invention receives command data and resend request command data input from a first electronic device, and receives response data as the first response data.
In the portable electronic device for outputting to the electronic device, the identification means for identifying whether the command data received from the first electronic device is a resend request command of the processing result or command data other than the resend request, As a result of the identification by the identification means, in the case of command data other than the resend request, processing means for performing processing corresponding to this command data, and a processing result of the command by this processing means are set, and this data is used as response data. When the command data received from the first electronic device as a result of identification by the first output buffer for outputting to the electronic device and the identification unit is a resend request command of the processing result, the processing result by the processing unit is A second output buffer which is set and outputs this data as response data to the first electronic device is provided.

(作用) 第1の電子装置からの命令データの種類に応じて携帯
可能電子装置自身で出力バツフアの切換えが行なえる。
たとえば再送要求命令データに対する応答データの通知
の際には第2の出力バツフアを用い、それ以外の通知に
は第1の出力バツフアを用いる。これにより、例えば第
1の電子装置からの再送要求命令データに異常をきたし
た以降でも、第2の電子装置が正常な再送要求命令デー
タを受取ることにより、正規の要求する応答データを第
1の電子装置へ再送でき、第1の電子装置と第2の電子
装置との間のシーケンスの乱れが生じない。
(Operation) The output buffer can be switched by the portable electronic device itself according to the type of command data from the first electronic device.
For example, the second output buffer is used when the response data for the resend request command data is notified, and the first output buffer is used for the other notifications. Thereby, for example, even after the abnormality has occurred in the resend request command data from the first electronic device, the second electronic device receives the normal resend request command data, so that the response data normally requested by the first electronic device can be transmitted. It can be retransmitted to the electronic device, and the sequence disorder between the first electronic device and the second electronic device does not occur.

(実施例) 以下、本発明の一実施例について図面を参照して説明
する。
(Example) Hereinafter, one example of the present invention will be described with reference to the drawings.

第10図は本発明の携帯可能電子装置に係るICカードが
適用される、たとえばホームバンキングシステムあるい
はシヨツピングシステムなどの端末装置として用いられ
るカード取扱装置の構成例を示すものである。すなわ
ち、この装置は、ICカード1をカード処理装置としての
カードリーダ・ライタ2を介してCPUなどからなる制御
部3と接続可能にするとともに、制御部3にキーボード
4、CRTデイスプレイ装置5、プリンタ6およびフロツ
ピイデイスク装置7を接続して構成される。
FIG. 10 shows a configuration example of a card handling device to which the IC card according to the portable electronic device of the present invention is applied, which is used as a terminal device such as a home banking system or a shopping system. That is, this device enables the IC card 1 to be connected to a control unit 3 including a CPU via a card reader / writer 2 as a card processing device, and the control unit 3 includes a keyboard 4, a CRT display device 5, and a printer. 6 and the floppy disk device 7 are connected.

ICカード1は、ユーザが保持し、たとえば商品購入な
どの際にユーザのみが知得している暗証番号の参照や必
要データの蓄積などを行なうもので、第8図にその機能
ブロツクを示すように、リード・ライト部11、暗証設定
・暗証照合部12、および暗号化・復号化部13などの基本
機能を実行する部分と、これらの基本機能を管理するス
ーパバイザ1とで構成されている。リード・ライト部11
は、データメモリ16との間でデータを読出し、書込み、
あるいは消去を行なう機能である。暗証設定・暗証照合
部12は、ユーザが設定した暗証番号の記憶および読出禁
止処理を行なうとともに、暗証番号の設定後にその暗証
番号の照合を行ない、以後の処理の許可を与える機能で
ある。暗号化・復号化部13は、たとえば通信回路を介し
て制御部3から他の端末装置へデータを送信する場合の
通信データの漏洩、偽造を防止するための暗号化や暗号
化されたデータの復号化を行なうものであり、たとえば
DES(Data Encryption Standard)など、充分な暗号強
度を有する暗号化アルゴリズムにしたがつてデータ処理
を行なう機能である。スーパバイサ14は、カードリーダ
・ライタ2から入力された機能コードもしくはデータの
付加された機能コードを解読し、前記基本機能のうち必
要な機能を選択して実行させる機能である。
The IC card 1 is held by the user and refers to a personal identification number known only to the user, for example, when the user purchases a product, or stores necessary data. The function block is shown in FIG. In addition, it is composed of a portion for executing basic functions such as a read / write unit 11, a password setting / password collating unit 12, and an encryption / decryption unit 13, and a supervisor 1 for managing these basic functions. Read / write section 11
Reads and writes data to and from the data memory 16,
Alternatively, it is a function of erasing. The password setting / password collating unit 12 has a function of storing and reading out the password set by the user, verifying the password after setting the password, and permitting subsequent processing. The encryption / decryption unit 13 is used to prevent communication data from leaking or forgering when transmitting data from the control unit 3 to another terminal device via a communication circuit. Decryption is performed, for example
This function performs data processing according to an encryption algorithm having sufficient encryption strength such as DES (Data Encryption Standard). The supervisor 14 is a function that decodes the function code or the function code added with data input from the card reader / writer 2 and selects and executes a necessary function from the basic functions.

これらの諸機能を発揮させるために、ICカード1は例
えば第7図に示すように、制御素子(たとえばCPU)1
5、記憶内容が消去可能な不揮発性のデータメモリ16、
プログラムメモリ17、およびカードリーダ・ライタ2と
の電気的接触を得るためのコンタクト部18によつて構成
されており、これらのうち破線内の部分(制御素子15、
データメモリ16、プログラムメモリ17)は1つのICチツ
プで構成されている。ここに、制御素子15は、少なくと
も2つ以上のデータ出力用の出力バツフア、例えば第1
の出力バツフア19および第2の出力バツフア20を備えて
いる。プログラムメモリ17は、たとえばマスクROMで構
成されており、前記各基本機能を実現するサブルーチン
を備えた制御素子15の制御プログラムを記憶するもので
ある。データメモリ16は各種データの記憶に使用され、
たとえばEEPROMで構成されている。
In order to exert these various functions, the IC card 1 has a control element (for example, CPU) 1 as shown in FIG.
5, non-volatile data memory 16 that can erase the stored contents,
It is configured by a program memory 17 and a contact portion 18 for making electrical contact with the card reader / writer 2, and a portion within these broken lines (control element 15,
The data memory 16 and the program memory 17) are composed of one IC chip. Here, the control element 15 includes at least two or more output buffers for outputting data, such as the first buffer.
Output buffer 19 and a second output buffer 20. The program memory 17 is composed of, for example, a mask ROM, and stores a control program of the control element 15 including a subroutine that realizes each of the basic functions. The data memory 16 is used for storing various data,
For example, it consists of EEPROM.

カードリーダ・ライタ2は、ICカード1と制御部3と
の間で機能コードやデータの授受を行なうものであり、
制御部3からのマクロ命令に基づいてICカード1に対し
て1命令1応答動作を行なう機能をも有している。具体
的には、第9図に示すように、図示しないカード挿入口
に挿入されたICカード1を所定の位置まで搬送する搬送
機構21、所定の位置にセツトされたICカード1のコンタ
クト部18に電気的に接触されるコンタクト部22、全体の
制御を司るCPUなどからなる制御回路23、制御回路23と
制御部3との間で命令データや応答データの授受を行な
うための入出力インタフエイス回路24、およびデータを
記憶するデータメモリ25などから構成されている。
The card reader / writer 2 exchanges function codes and data between the IC card 1 and the control unit 3,
It also has a function of performing a one-instruction-one response operation to the IC card 1 based on a macro instruction from the control unit 3. Specifically, as shown in FIG. 9, a transport mechanism 21 for transporting the IC card 1 inserted into a card insertion slot (not shown) to a predetermined position, and a contact portion 18 of the IC card 1 set at the predetermined position. A contact portion 22 electrically connected to the control circuit 23, a control circuit 23 including a CPU for controlling the entire control, and an input / output interface for exchanging command data and response data between the control circuit 23 and the control portion 3. It is composed of a circuit 24, a data memory 25 for storing data, and the like.

次に、このような構成において動作を説明する。ま
ず、カードリーダ・ライタ2は第3図に示すフローチヤ
ートにしたがつて動作する。すなわち、定常状態におい
ては制御部3からの命令データ待ち状態となつている。
制御部3から命令データが入力されると、制御回路23は
ICカード1が実行中であるか否かを確認し、実行中であ
る場合には多重命令データエラーを意味する応答データ
を制御部3に出力し、再び命令データ待ち状態に戻る。
ICカード1が実行中でない場合には、制御回路23はICカ
ード1に命令データを出力し、ICカード1からの応答デ
ータ待ち状態となる。ICカード1からの応答データがあ
ると、制御回路23は制御部3に応答データを出力し、再
び命令データ待ち状態に戻る。
Next, the operation in such a configuration will be described. First, the card reader / writer 2 operates according to the flow chart shown in FIG. That is, in the steady state, it is in a state of waiting for command data from the control unit 3.
When command data is input from the control unit 3, the control circuit 23
Whether or not the IC card 1 is being executed is checked, and if it is being executed, response data indicating a multiple command data error is output to the control unit 3, and the process returns to the command data waiting state.
When the IC card 1 is not being executed, the control circuit 23 outputs command data to the IC card 1 and waits for response data from the IC card 1. When there is response data from the IC card 1, the control circuit 23 outputs the response data to the control unit 3 and returns to the command data waiting state again.

なお、カードリーダ・ライタ2からICカード1に出力
される命令データは、たとえば第4図に示すようなフオ
ーマツトであり、同図(a)に示すように逐次番号情報
と機能コードのみの形態、または同図(b)に示すよう
に逐次番号情報および機能コードにデータを付加した形
態がある。
The command data output from the card reader / writer 2 to the IC card 1 is, for example, a format as shown in FIG. 4, and as shown in FIG. Alternatively, there is a form in which data is added to the serial number information and the function code as shown in FIG.

ICカード1は第1図に示すフローチヤートにしたがつ
て動作する。すなわち、定常状態においてはカードリー
ダ・ライタ2からの命令データ待ち状態となつている。
カードリーダ・ライタ2から命令データが入力される
と、制御素子15はその入力された命令データ再送要求命
令データであるか否かを判断する。再送要求命令データ
でなければ、制御素子15は命令データの正常性を判断し
正常であると判断されれば入力された命令データに基づ
く処理を実行し、その処理結果を示す応答データを第1
の出力バツフア19にセツトする。また、異常であると判
断されれば、電文エラを意味する応答データを第1の出
力バツフアにセツトする。そして、制御素子15はこの第
1の出力バツフア19の内容をカードリーダ・ライタ2に
出力し、再び命令データ待ち状態に戻る。この場合の応
答データは、たとえば第2図に示すようなフオーマツト
であり、処理結果を示す情報に入力された命令データ中
に付加されていた逐次番号情報および機能コードを付加
し、カードリーダ・ライタ2との間のシーケンスが乱れ
た場合の防護措置を講じる。
The IC card 1 operates according to the flow chart shown in FIG. That is, in the steady state, it is in a state of waiting for command data from the card reader / writer 2.
When the command data is input from the card reader / writer 2, the control element 15 determines whether or not the input command data resend request command data. If it is not the resend request command data, the control element 15 determines the normality of the command data, and if it is determined to be normal, it executes the process based on the input command data, and returns the response data indicating the process result as the first item.
Set to output buffer 19 of. If it is determined to be abnormal, the response data indicating a message error is set in the first output buffer. Then, the control element 15 outputs the contents of the first output buffer 19 to the card reader / writer 2 and returns to the instruction data waiting state. The response data in this case is, for example, a format as shown in FIG. 2, and the serial number information and the function code added to the input instruction data are added to the information indicating the processing result, and the card reader / writer is added. Take protective measures in case the sequence between 2 and is disturbed.

入力された命令データが再送要求命令であつた場合に
は制御素子15はその命令データの正常性を判断する。電
文が正常でなければ制御素子15は第2の出力バツフア19
に電文異常を意味する応答データをセツトし、この第2
の出力バツフア19の内容をカードリーダ・ライタ2に出
力し、再び命令データ待ち状態に戻る。また電文が正常
であれば、制御素子15は第2の出力バツフア20に第1の
バツフアに入つている応答データをセツトし、この第2
の出力バツフア20の内容をカードリーダ・ライタ2に出
力し、再び命令データ待ち状態に戻る。
When the input command data is a resend request command, the control element 15 determines the normality of the command data. If the message is not normal, the control element 15 will output the second output buffer 19
Set the response data that means an abnormal message to
The contents of the output buffer 19 are output to the card reader / writer 2 to return to the instruction data waiting state. If the message is normal, the control element 15 sets the second output buffer 20 to the response data contained in the first buffer, and the second output buffer 20
The contents of the output buffer 20 of are output to the card reader / writer 2, and the state returns to the instruction data waiting state again.

すなわち、ICカード1内には出力バツフアが2つあ
り、命令データが再送要求命令データであると判断した
場合には第2の出力バツフア20を用い、それ以外の処理
結果などの出力は第1の出力バツフア19を用いるもので
ある。これは、もし出力バツフアが1つだとした場合、
再送要求命令データが電文異常であると判断し、この出
力バツフアに判断結果を格納した後その内容を出力する
ことになり、以降、再送要求命令データを正常に受取つ
た場合、出力バツフアには前回の電文異常を示す応答デ
ータのみが格納されているので、カードリーダ・ライタ
2が要求している再送データの内容が破壊されてしまう
からである。この場合、それ以降のシーケンスが乱れて
しまう。
That is, there are two output buffers in the IC card 1, and when it is determined that the command data is the resend request command data, the second output buffer 20 is used, and the other output such as the processing result is the first. The output buffer 19 of is used. This means that if there is only one output buffer,
If it is judged that the resend request command data is a message error, the judgment result will be stored in this output buffer and then the content will be output.After that, if the resend request command data is normally received, the previous output will be displayed in the output buffer. This is because only the response data indicating the abnormal message is stored, so that the content of the resend data requested by the card reader / writer 2 is destroyed. In this case, the subsequent sequence is disturbed.

次に、カードリーダ・ライタ2の具体的な動作につい
て第5図に示すフローチヤートを参照して説明する。ま
ず、制御回路23は逐次番号情報を初期化した後、制御部
3からの命令データ待ち状態になる。このとき、制御部
3から命令データが入力されると、制御回路23はICカー
ド1が実行中であるか否かを確認し、実行中である場合
には多重命令データエラーを意味する応答データを制御
部3に出力し、再び命令データ待ち状態に戻る。ICカー
ド1が実行中でない場合には、制御回路23は逐次番号情
報を付加し、ICカード1に命令データを出力し、ICカー
ド1からの応答データ待ち状態となる。このとき、あら
かじめ定められたタイムアウト値をオーバする前に応答
データが受信されなければ、再送要求をICカード1に促
す。このとき、制御回路23は再送要求カウンタをカウン
トアップすることにより、あらかじめ定められた回数だ
け再送要求を行ない、その回数に達するとタイムアウト
を意味する応答データを制御部3に出力し、再び命令デ
ータ待ち状態に戻る。
Next, a specific operation of the card reader / writer 2 will be described with reference to the flow chart shown in FIG. First, the control circuit 23 initializes the serial number information and then waits for command data from the control unit 3. At this time, when command data is input from the control unit 3, the control circuit 23 confirms whether or not the IC card 1 is under execution, and if it is under execution, response data indicating a multiple command data error. Is output to the control unit 3, and the state returns to the instruction data waiting state. When the IC card 1 is not being executed, the control circuit 23 adds serial number information, outputs command data to the IC card 1, and waits for the response data from the IC card 1. At this time, if the response data is not received before the predetermined time-out value is exceeded, the IC card 1 is prompted to resend. At this time, the control circuit 23 counts up the retransmission request counter to make a retransmission request a predetermined number of times, and when the number of times is reached, outputs response data indicating a time-out to the control unit 3 and again outputs the command data. Return to the waiting state.

ICカード1からの応答データを受信すると、制御回路
23はその応答データが再送要求に対するものか否かを判
断し、再送要求のものであれば第5図(a)のに移
る。再送要求のものでなければ、制御回路23は再送要求
カウンタをクリアし、制御部3からの命令データがマク
ロ命令であるか否かを判断する。マクロ命令であつた場
合には、ICカード1からの応答データ中の逐次番号情報
をカウントアツプし、次回送出する命令データに付加す
る。そして、マクロ命令が終了したなら応答データを制
御部3に出力し、再び命令データ待ち状態に戻る。マク
ロ命令でなければ、直ちに応答データを制御部3に出力
し、再び命令データ待ち状態に戻る。
When the response data from the IC card 1 is received, the control circuit
23 determines whether or not the response data is for the resend request, and if it is for the resend request, the process moves to (a) of FIG. If it is not a retransmission request, the control circuit 23 clears the retransmission request counter and determines whether the instruction data from the control unit 3 is a macro instruction. If it is a macro command, the serial number information in the response data from the IC card 1 is counted up and added to the command data to be transmitted next time. When the macro command is completed, the response data is output to the control unit 3 and the command data waiting state is returned again. If it is not a macro command, the response data is immediately output to the control unit 3, and the process returns to the command data waiting state again.

第6図はカードリーダ・ライタ2のICカード1との具
体的な送信手順を示すもので、たとえば機能コード
(A)という命令データを2回続けて出力した場合にお
ける具体列を示している。第1回目送出分の命令データ
については逐次番号情報は「1」、このときの応答デー
タの逐次番号情報も「1」である。次に、第2回目送出
分の命令データがICカード1に認識されなかつたとす
る。このとき、応答データが出力されないので、カード
リーダ・ライタ2は第3回目送出分として再送要求を行
なう。このときの逐次番号情報は「3」である。このと
き、ICカード1が再送要求命令データを受取つた際、電
文異常と判断したとすると、それを応答データとして出
力する。カードリーダ・ライタ2はそれを受取ると、第
4回目送出分として再度、再送要求を行なう。このとき
の逐次番号情報は「4」である。ICカード1は正常にこ
れを受取ると、第1回目送出分の応答データを出力す
る。カードリーダ・ライタ2はこれを受取ると、それに
付加されている逐次番号情報「1」をカウントアツプし
たものを第5回目送出時に付加する。
FIG. 6 shows a specific transmission procedure of the card reader / writer 2 with the IC card 1, and shows a specific sequence when, for example, the command data of the function code (A) is output twice in succession. Regarding the command data for the first transmission, the serial number information is "1", and the serial number information of the response data at this time is also "1". Next, it is assumed that the command data for the second transmission is not recognized by the IC card 1. At this time, since the response data is not output, the card reader / writer 2 makes a retransmission request as the third transmission. The serial number information at this time is "3". At this time, when the IC card 1 receives the resend-request command data and determines that the message is abnormal, it outputs it as response data. When the card reader / writer 2 receives the card, the card reader / writer 2 requests the retransmission again as the fourth transmission. The serial number information at this time is "4". When the IC card 1 receives this normally, it outputs the response data for the first transmission. When the card reader / writer 2 receives this, the card reader / writer 2 counts up the serial number information "1" added thereto and adds it at the time of the fifth transmission.

このように、ICカードに出力バツフアを2つ備え、再
送要求命令データ異常の通知の際には第2の出力バツフ
アを用い、それ以外の通知には第1の出力バツフアを用
いるようにバツフア切換えを行なうことにより、カード
リーダ・ライタからの再送要求命令データに異常をきた
した以降でも、ICカードが正常な再送要求命令データを
受取ることにより、正規の要求する応答データをカード
リーダ・ライタへ再送でき、カードリーダ・ライタとIC
カードとの間のシーケンスの乱れが生じない。
In this way, the IC card is provided with two output buffers, and the second output buffer is used for notification of a resend request command data abnormality, and the first output buffer is used for other notifications. By doing so, even if the resend request command data from the card reader / writer becomes abnormal, the IC card receives the normal resend request command data and resends the normally requested response data to the card reader / writer. Yes, card reader / writer and IC
The sequence is not disturbed with the card.

なお、前記実施例は、第1の電子装置をカードリーダ
・ライタ2に、携帯可能電子装置をICカード1とした例
であるが、たとえば第1の電子装置を制御部3に、携帯
可能電子装置をカードリーダ・ライタ2としてもよい。
要するに、第1の電子装置から入力される命令データを
携帯可能電子装置が受取り、上記命令データ中に含まれ
る機能コードを解読し、これに対応する一連の処理を実
行した後その処理結果を応答データとして上記第1の電
子装置に出力する処理方式であれば適用可能である。
In the above embodiment, the card reader / writer 2 is used as the first electronic device and the IC card 1 is used as the portable electronic device. For example, the first electronic device is used as the control unit 3 and the portable electronic device is used. The device may be the card reader / writer 2.
In short, the portable electronic device receives the command data input from the first electronic device, decodes the function code included in the command data, executes a series of processes corresponding thereto, and then returns the processing result. Any processing method that outputs as data to the first electronic device can be applied.

〔発明の効果〕〔The invention's effect〕

以上詳述したように本発明によれば、第1の電子装置
からの再送要求命令データに異常をきたした以降でも、
携帯可能電子装置が正常な再送要求命令データを受取る
ことにより、正規の要求する応答データを第1の電子装
置へ再送でき、第1の電子装置と携帯可能電子装置との
間のシーケンスの乱れが生じない処理方式を提供でき
る。
As described in detail above, according to the present invention, even after the abnormality has occurred in the retransmission request command data from the first electronic device,
When the portable electronic device receives the normal resend-request command data, the normally requested response data can be resent to the first electronic device, and the sequence disorder between the first electronic device and the portable electronic device occurs. A processing method that does not occur can be provided.

【図面の簡単な説明】[Brief description of drawings]

図は本発明の一実施例を説明するためのもので、第1図
はICカードの動作を説明するフローチヤート、第2図は
ICカードから出力される応答データのフオーマツトを示
す図、第3図はカードリーダ・ライタの動作を説明する
フローチヤート、第4図はカードリーダ・ライタから出
力される命令データのフオーマツトを示す図、第5図は
カードリーダ・ライタの具体的な動作を説明するフロー
チヤート、第6図はカードリーダ・ライタとICカードと
の具体的な送信手順を示す図、第7図はICカードに内蔵
するICチツプの構成を示すブロツク図、第8図はICカー
ドの可能ブロツクを示す図、第9図はカードリーダ・ラ
イタの構成を示すブロツク図、第10図はカード取扱装置
の構成を示すブロツク図である。 1……ICカード(第2の電子装置)、2……カードリー
ダ・ライタ(第1の電子装置)、15……制御素子(CP
U)、16……データメモリ、17……プログラムメモリ、1
9,20……出力バツフア、23……制御回路。
The drawings are for explaining one embodiment of the present invention. FIG. 1 is a flow chart for explaining the operation of an IC card, and FIG.
FIG. 3 is a diagram showing the format of response data output from the IC card, FIG. 3 is a flow chart explaining the operation of the card reader / writer, and FIG. 4 is a diagram showing the format of command data output from the card reader / writer. FIG. 5 is a flow chart for explaining the concrete operation of the card reader / writer, FIG. 6 is a diagram showing a concrete transmission procedure between the card reader / writer and the IC card, and FIG. 7 is built in the IC card. Block diagram showing the configuration of the IC chip, FIG. 8 is a diagram showing possible blocks of the IC card, FIG. 9 is a block diagram showing the configuration of the card reader / writer, and FIG. 10 is a block diagram showing the configuration of the card handling device. Is. 1 ... IC card (second electronic device), 2 ... Card reader / writer (first electronic device), 15 ... Control element (CP)
U), 16 …… Data memory, 17 …… Program memory, 1
9,20 …… Output buffer, 23 …… Control circuit.

Claims (1)

(57)【特許請求の範囲】(57) [Claims] 【請求項1】第1の電子装置から入力される命令データ
及び再送要求命令データを受取り応答データを前記第1
の電子装置に出力する携帯可能電子装置において、 前記第1の電子装置から受取った命令データが前記処理
結果の再送要求命令であるか再送要求以外の命令データ
であるのかを識別する識別手段と、 この識別手段による識別の結果、再送要求以外の命令デ
ータの場合この命令データに対応した処理を行う処理手
段と、 この処理手段による命令の処理結果がセットされこのデ
ータを応答データとして前記第1の電子装置に出力する
第1の出力バッファと、 前記識別手段による識別の結果前記第1の電子装置から
受取った命令データが前記処理結果の再送要求命令であ
った場合に前記処理手段による処理結果がセットされこ
のデータを応答データとして前記第1の電子装置に出力
する第2の出力バッファとを有することを特徴とする携
帯可能電子装置。
1. Command data and resend request command data input from a first electronic device are received, and response data is received by the first electronic device.
In the portable electronic device for outputting to the electronic device, the identification means for identifying whether the command data received from the first electronic device is a resend request command of the processing result or command data other than the resend request, As a result of the identification by the identification means, in the case of command data other than the resend request, processing means for carrying out processing corresponding to this command data, and a processing result of the command by this processing means are set, and this data is used as response data. A first output buffer for outputting to an electronic device; and, when the instruction data received from the first electronic device as a result of identification by the identification means is a resend request instruction of the processing result, the processing result by the processing means is A second output buffer which is set and outputs this data as response data to the first electronic device. Child device.
JP62273089A 1987-10-30 1987-10-30 Portable electronic devices Expired - Lifetime JP2547795B2 (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP62273089A JP2547795B2 (en) 1987-10-30 1987-10-30 Portable electronic devices

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP62273089A JP2547795B2 (en) 1987-10-30 1987-10-30 Portable electronic devices

Publications (2)

Publication Number Publication Date
JPH01116783A JPH01116783A (en) 1989-05-09
JP2547795B2 true JP2547795B2 (en) 1996-10-23

Family

ID=17522987

Family Applications (1)

Application Number Title Priority Date Filing Date
JP62273089A Expired - Lifetime JP2547795B2 (en) 1987-10-30 1987-10-30 Portable electronic devices

Country Status (1)

Country Link
JP (1) JP2547795B2 (en)

Also Published As

Publication number Publication date
JPH01116783A (en) 1989-05-09

Similar Documents

Publication Publication Date Title
US4939353A (en) Processing system for enabling data communication with a self-diagnose device
US5161231A (en) Processing system which transmits a predetermined error code upon detection of an incorrect transmission code
US5414835A (en) IC card processing system capable of determing send timing between an IC card and an accepting device
JPH05250523A (en) Processing system
JP3522882B2 (en) Protocol switching method
JP3028815B2 (en) Transmission method of portable electronic device and portable electronic device
JPH0746378B2 (en) IC card
WO2006075576A1 (en) Secure device and system for issuing ic cards
EP1615164B1 (en) IC card with self-diagnostic function
JP2547795B2 (en) Portable electronic devices
JPH11353425A (en) Ic card terminal device
US6866192B2 (en) IC card terminal
JPH01213774A (en) Portable storage medium processor
JPH01255990A (en) Ic card data transmitting system
JPH0772891B2 (en) Data transmission method
JPS60207986A (en) Data processing system
JP2577370B2 (en) Portable electronic devices
JP2618953B2 (en) Transmission processing method, data storage medium and IC chip
JP2577369B2 (en) IC card
JP2004185419A (en) Portable electronic medium, issuing system of portable electronic medium, processing method, and issuing method
JPH01116784A (en) Processing system
JP3048550B2 (en) IC chip for IC card
JPS63126084A (en) Processing system
JP2543861B2 (en) Data transmission method
JPS6383894A (en) Portable electronic device

Legal Events

Date Code Title Description
FPAY Renewal fee payment (event date is renewal date of database)

Free format text: PAYMENT UNTIL: 20070808

Year of fee payment: 11

FPAY Renewal fee payment (event date is renewal date of database)

Free format text: PAYMENT UNTIL: 20080808

Year of fee payment: 12

EXPY Cancellation because of completion of term
FPAY Renewal fee payment (event date is renewal date of database)

Free format text: PAYMENT UNTIL: 20080808

Year of fee payment: 12