JPH07296124A - Ic card applying device - Google Patents
Ic card applying deviceInfo
- Publication number
- JPH07296124A JPH07296124A JP6112177A JP11217794A JPH07296124A JP H07296124 A JPH07296124 A JP H07296124A JP 6112177 A JP6112177 A JP 6112177A JP 11217794 A JP11217794 A JP 11217794A JP H07296124 A JPH07296124 A JP H07296124A
- Authority
- JP
- Japan
- Prior art keywords
- command
- card
- cpu
- processor
- format
- 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
- 238000006243 chemical reaction Methods 0.000 claims abstract description 45
- 238000000034 method Methods 0.000 claims abstract description 26
- 238000012545 processing Methods 0.000 claims abstract description 24
- 230000004044 response Effects 0.000 claims description 21
- 230000008569 process Effects 0.000 claims description 2
- 230000002194 synthesizing effect Effects 0.000 abstract 1
- 230000005540 biological transmission Effects 0.000 description 8
- 238000010586 diagram Methods 0.000 description 6
- 238000004891 communication Methods 0.000 description 4
- 238000011161 development Methods 0.000 description 4
- 238000012795 verification Methods 0.000 description 4
- 230000009471 action Effects 0.000 description 1
- 230000008859 change Effects 0.000 description 1
- 238000007796 conventional method Methods 0.000 description 1
- 230000006870 function Effects 0.000 description 1
- 238000012986 modification Methods 0.000 description 1
- 230000004048 modification Effects 0.000 description 1
Abstract
Description
【0001】[0001]
【産業上の利用分野】本発明は、ICカードをリード/
ライトできる機能を備えたICカード応用装置に関する
ものである。BACKGROUND OF THE INVENTION The present invention is for reading / reading an IC card.
The present invention relates to an IC card application device having a write function.
【0002】[0002]
【従来の技術】従来、各種のデータをリード/ライトで
きるICカードが存在する。この種のICカードは、専
用の仕様で決められたコマンド/レスポンス仕様に基づ
いて行なわれる。そして、そのコマンド/レスポンス制
御は、ICカードをリード/ライトするための装置によ
って行なわれる。2. Description of the Related Art Conventionally, there are IC cards capable of reading / writing various data. This type of IC card is carried out based on command / response specifications determined by dedicated specifications. Then, the command / response control is performed by a device for reading / writing the IC card.
【0003】[0003]
【発明が解決しようとする課題】しかしながら、上述し
た従来の技術には、次のような課題があった。即ち、I
Cカードのリード/ライトの制御のための複雑な規則を
ICカード応用装置のシステムアプリケーション開発者
が熟知している必要があり、ICカード応用装置の開発
効率を向上させることができないという課題があった。However, the above-mentioned conventional techniques have the following problems. That is, I
It is necessary for the system application developer of the IC card application device to be familiar with the complicated rules for controlling the read / write of the C card, and there is a problem that the development efficiency of the IC card application device cannot be improved. It was
【0004】[0004]
【課題を解決するための手段】本発明のICカード応用
装置は、上述した課題を解決するため、以下の点を特徴
とするものである。 (1) 装置本体のCPUで使用される所定の形式のコマンド
をICカードの仕様に対応した形式のコマンドに変換す
るための処理手順を格納したコマンド変換部を備える。 当該コマンド変換部の処理を実行することにより、装
置本体のCPUから送られたコマンドをICカードの仕
様に対応した形式のコマンドに変換してICカードに送
出し、ICカードからの応答を装置本体の形式に変換し
てCPUに送出するプロセッサを備える。In order to solve the above-mentioned problems, the IC card application device of the present invention is characterized by the following points. (1) A command conversion unit that stores a processing procedure for converting a command in a predetermined format used in the CPU of the apparatus body into a command in a format corresponding to the specifications of the IC card is provided. By executing the processing of the command conversion unit, the command sent from the CPU of the device body is converted into a command of a format corresponding to the specifications of the IC card and sent to the IC card, and the response from the IC card is sent to the device body. It has a processor for converting to the format and sending it to the CPU.
【0005】(2) (1)において、コマンド変換部に、装置本体で使用さ
れる所定の形式の1つのコマンドをICカードの仕様に
対応した形式の複数のコマンドに変換するための処理手
順を格納する。 (3) (1)又は(2)において、コマンド変換部に格納され
る処理手順を装置本体側から所定時に入力する。 (4) (1)、(2)又は(3)において、コマンド変換部を
複数設け、プロセッサはICカードからの応答の内容に
応じていずれかのコマンド変換部を選択して処理を実行
する。(2) In (1), the command conversion unit has a processing procedure for converting one command of a predetermined format used in the apparatus main body into a plurality of commands of a format corresponding to the specifications of the IC card. Store. (3) In (1) or (2), the processing procedure stored in the command conversion unit is input from the apparatus body side at a predetermined time. (4) In (1), (2), or (3), a plurality of command conversion units are provided, and the processor selects one of the command conversion units according to the content of the response from the IC card and executes the process.
【0006】[0006]
(1)本体装置のCPUで使用される所定の形式をコマ
ンドをICカードの仕様に対応した形式のコマンドに変
換する変換処理手段を格納するコマンド変換部を備えた
結果、本体装置側でICカードを直接リード/ライトす
る処理を行なわずに済む。そして、コマンド変換部に格
納された変換処理手順を本体装置のCPUと別個のプロ
セッサで実行してICカードをリード/ライトするよう
にした結果、本体装置の開発をする際に、ICカードの
仕様やリード/ライト手順を開発者が熟知する必要がな
くなる。 (2)コマンド変換部で複数のコマンドを1つにまとめ
たコマンドを本体装置に提供するようにした結果、本体
装置ではICカードの複雑な制御も簡単に行なうことが
できる。(1) As a result of including a command conversion unit that stores conversion processing means for converting a predetermined format used in the CPU of the main body device into a command of a format corresponding to the specifications of the IC card, the main body device side has an IC card Need not be directly read / written. Then, the conversion processing procedure stored in the command conversion unit is executed by a processor different from the CPU of the main body device to read / write the IC card. As a result, when developing the main body device, the specifications of the IC card are specified. Developers no longer need to be familiar with read / write procedures. (2) As a result of providing the main body device with a command that combines a plurality of commands into one by the command conversion unit, the main body device can easily perform complicated control of the IC card.
【0007】(3)コマンド変換部に格納される変換処
理手順を外部から入力できるようにした結果、ICカー
ドの仕様が変更された場合に容易に対応することがで
き、本体装置側のプログラムを修正する必要がなくな
る。 (4)コマンド変換部に複数種類の変換処理手順を格納
し、ICカードからの応答の内容に応じていずれかの変
換処理手順を選択するようにした結果、複数の種類のI
Cカードが使用される場合にも各種類のICカードに対
しそれぞれリード/ライト制御することが可能となり、
本体装置側のプログラムでは複数の種類を考慮する必要
がないようにできる。(3) As a result of allowing the conversion processing procedure stored in the command conversion unit to be input from the outside, it is possible to easily cope with a change in the specifications of the IC card, and to save the program on the main unit side. No need to fix. (4) A plurality of types of conversion processing procedures are stored in the command conversion unit, and one of the conversion processing procedures is selected according to the content of the response from the IC card.
Even when the C card is used, read / write control can be performed for each type of IC card,
It is possible to avoid having to consider a plurality of types in the program on the main device side.
【0008】[0008]
【実施例】以下、本発明の実施例を図面を参照して詳細
に説明する。図1は、本発明のICカード応用装置の一
実施例のブロック図である。図示の装置には、ICカー
ド2に対するデータの入出力を目的とする所定の形式の
コマンドを、ICカード2の仕様に対応した形式のコマ
ンドに変換する専用モジュール部1が備えられている。
この専用モジュール部1以外の部分は、ICカード応用
装置の本体の部分である。装置本体におけるCPU3
は、ICカード応用装置全体を制御し、コードメモリ
4、データメモリ5、補助記憶装置6、ディスプレイ
7、キーボード8、外部通信I/O9等を制御してい
る。Embodiments of the present invention will now be described in detail with reference to the drawings. FIG. 1 is a block diagram of an embodiment of an IC card application device of the present invention. The illustrated apparatus is provided with a dedicated module unit 1 for converting a command in a predetermined format for inputting / outputting data to / from the IC card 2 into a command in a format corresponding to the specifications of the IC card 2.
The parts other than the dedicated module part 1 are parts of the main body of the IC card application device. CPU3 in the device body
Controls the entire IC card application device, and controls the code memory 4, the data memory 5, the auxiliary storage device 6, the display 7, the keyboard 8, the external communication I / O 9, and the like.
【0009】一方、専用モジュール1内には、プロセッ
サ11、ROM12、不揮発性メモリ13、バッファ1
4等が設けられている。プロセッサ11は、ICカード
2との通信を制御する。即ち、プロセッサ11は、IC
カード2との伝送プロトコル制御及びコマンド/レスポ
ンス制御を行なう。これらのうち、伝送プロトコル制御
については、専用モジュール1内のROM12の伝送プ
ロトコル制御部20に格納されたプログラムで実行され
る。尚、伝送プロトコルのタイプには、ISOで定義さ
れているように、非同期半二重バイト伝送方式(T=
0)及び非同期半二重ブロック伝送方式(T=1又はT
=14)等がある。On the other hand, in the dedicated module 1, the processor 11, the ROM 12, the non-volatile memory 13 and the buffer 1 are provided.
4 etc. are provided. The processor 11 controls communication with the IC card 2. That is, the processor 11 is an IC
The transmission protocol control and the command / response control with the card 2 are performed. Among these, the transmission protocol control is executed by a program stored in the transmission protocol control unit 20 of the ROM 12 in the dedicated module 1. Note that the transmission protocol type includes an asynchronous half-duplex byte transmission method (T =
0) and asynchronous half-duplex block transmission scheme (T = 1 or T
= 14) and so on.
【0010】CPU3は、ICカード2とのコマンド/
レスポンス制御に関し、ICカード2の仕様に対応した
制御と、ICカード2の仕様に拘束されない独自のコマ
ンド/レスポンス制御の双方を行なうことができる。こ
こに、ICカードの仕様に対応した制御モードを透過モ
ードといい、ICカードの仕様に拘束されない制御モー
ドを非透過モードという。CPU3は、プロセッサ11
に対して、透過モード又は非透過モードをCPU−プロ
セッサ間のコマンドによる設定で指定する。透過モード
の場合、ICカード2のコマンド/レスポンスはプロセ
ッサ11で加工することなく、CPU3とICカード2
との間でそのままやり取りされる。この場合、ICカー
ド応用装置の開発者は、ICカード2の仕様について熟
知している必要があり、開発作業の負担も大きいが、I
Cカード2の利用に関しての自由度は大きい。The CPU 3 sends / receives commands to / from the IC card 2.
Regarding response control, both control corresponding to the specifications of the IC card 2 and unique command / response control not restricted by the specifications of the IC card 2 can be performed. Here, the control mode corresponding to the specifications of the IC card is called a transparent mode, and the control mode not restricted by the specifications of the IC card is called a non-transparent mode. The CPU 3 is the processor 11
On the other hand, the transparent mode or the non-transparent mode is designated by the setting by the command between the CPU and the processor. In the transparent mode, the command / response of the IC card 2 is not processed by the processor 11 and the CPU 3 and the IC card 2 are not processed.
It is exchanged as it is with. In this case, the developer of the IC card application device needs to be familiar with the specifications of the IC card 2, and the burden of development work is heavy, but I
The degree of freedom in using the C card 2 is great.
【0011】非透過モードの場合、CPU3とプロセッ
サ11との間は、ICカード2の仕様に基づくコマンド
/レスポンスセットとは無関係なプロトコルとなる。図
2は、ICカードの仕様に対応したコマンド形式の一例
を示す。図2のコマンドは、カレントファイルのあるレ
コードを書き換えるためのコマンドフォーマットの一例
であり、透過モードの時は、このデータをそのままプロ
セッサ11に渡すことになる。ところが、図2(a)及
び(b)に示すように、同じ目的のコマンドフォーマッ
トであっても、ICカードの種類により形式が異なる場
合がある。図2(a)及び(b)では、1バイト目〜2
バイト目がコマンドヘッダであるが、3バイト目がレコ
ードIDとファイルIDである点で異なっている。従っ
て、これらを統一的に取扱うため、非透過モードの場
合、CPU3とプロセッサ11のインタフェースは図3
の形式とし、プロセッサ11がICカード2の仕様に対
応したフォーマットに変換する。In the non-transparent mode, the protocol between the CPU 3 and the processor 11 is unrelated to the command / response set based on the specifications of the IC card 2. FIG. 2 shows an example of a command format corresponding to the specifications of the IC card. The command of FIG. 2 is an example of a command format for rewriting a certain record in the current file, and in the transparent mode, this data is passed to the processor 11 as it is. However, as shown in FIGS. 2 (a) and 2 (b), even if the command format has the same purpose, the format may differ depending on the type of IC card. In FIGS. 2A and 2B, the first byte to 2
The third byte is a command header, but the third byte is a record ID and a file ID. Therefore, in order to handle them uniformly, in the non-transparent mode, the interface between the CPU 3 and the processor 11 is as shown in FIG.
Format, and the processor 11 converts it into a format corresponding to the specifications of the IC card 2.
【0012】以上の図2に示す例は、レコードの書き換
えの例であるが、CPU3とプロセッサ11のインタフ
ェースは、この他にレコードの読み出し、ファイルの読
み出し、ファイルの選択(セレクト)、その他ICカー
ドにおいて一般的に必要なコマンドに対して図3のよう
な仕様で行なう。即ち、図3において、コマンドヘッダ
等をレコード読み出し等を指示するものに変更したもの
を用いる。これにより、図2(a)及び(b)に示す各
ICカードの相異は、プロセッサ11で実行される変換
処理手順で吸収され、装置本体のCPU3とICカード
2のインタフェースはICカードの仕様に依存しなくな
る。The above-described example shown in FIG. 2 is an example of rewriting a record. In addition to this, the interface between the CPU 3 and the processor 11 reads a record, a file, a file selection (selection), and other IC cards. In FIG. 3, the command generally required is specified as shown in FIG. That is, in FIG. 3, the command header and the like are changed to those for instructing record reading and the like. As a result, the difference between the IC cards shown in FIGS. 2A and 2B is absorbed by the conversion processing procedure executed by the processor 11, and the interface between the CPU 3 of the apparatus main body and the IC card 2 is the IC card specification. No longer depends on.
【0013】更に、以上の例では、CPU3とプロセッ
サ11のインタフェースは1つのコマンドであるが、プ
ロセッサ11とICカード2の間で複数のコマンド/レ
スポンスが実行されるようにしてもよい。即ち、専用モ
ジュール部1により、ICカード応用装置が1つのコマ
ンドの実行することでICカード2に対して複数のコマ
ンドを実行できるようにすることもできる。例えば、I
Cカード2に機密データを暗号化して書き込む場合、パ
スワードの照合、データの暗号化、データの書き込みと
いう形でICカードへの実際のコマンドは複数になる
が、プロセッサ11がCPU3からの1つのコマンドで
これらの一連の動作を実行することができる。このよう
なCPU−プロセッサ間のコマンドインタフェースを専
用モジュールが装置本体に提供できるようにするため、
専用モジュール部1の標準コマンド変換部21にそのよ
うなプログラムを内蔵する。これにより、ICカード応
用装置のアプリケーション開発の負担を軽減することが
できる。Further, in the above example, the interface between the CPU 3 and the processor 11 is one command, but a plurality of commands / responses may be executed between the processor 11 and the IC card 2. In other words, the dedicated module unit 1 can allow the IC card application device to execute a plurality of commands by executing one command. For example, I
When the confidential data is encrypted and written in the C card 2, there are a plurality of actual commands to the IC card in the form of password verification, data encryption, and data writing, but the processor 11 uses one command from the CPU 3. Can perform these series of operations. In order to enable the dedicated module to provide such a command interface between the CPU and the processor to the apparatus main body,
Such a program is built in the standard command conversion unit 21 of the dedicated module unit 1. As a result, the burden of application development of the IC card application device can be reduced.
【0014】以上のような標準コマンド変換部21は、
専用モジュール部1内のROM12に格納されている。
即ち、標準コマンド変換部21は、ICカード2の仕様
に基づいて作られた標準のコマンド変換プログラムとし
て格納されている。この他、専用モジュール部1は、C
PU3から不揮発性メモリ13に標準のコマンド変換プ
ログラム以外のプログラムをダウンロードでき、これに
より、標準のコマンド変換プログラムの代わりに違うコ
マンド変換プログラムを実行できる。即ち、プロセッサ
11は、CPU3からダウンロード命令を受け取ると、
CPU動作を停止させるストップモードに移行する。ス
トップモードでは、外部書き込みが入るまでCPU3の
内部のレジスタ等を保持し、動作を停止する。このよう
なレジスタは、例えば、沖電気MSM65516等で構
成できる。プロセッサ11のストップモードの途中でC
PU3は専用モジュール部1内の不揮発性メモリ13に
コマンド変換プログラムを書き込む。このコマンド変換
プログラムは、CPU3に接続されている補助記憶装置
6又は外部通信I/O9から読み込んだものを書き込
む。The standard command converter 21 as described above is
It is stored in the ROM 12 in the dedicated module unit 1.
That is, the standard command conversion unit 21 is stored as a standard command conversion program created based on the specifications of the IC card 2. In addition, the dedicated module unit 1 is C
A program other than the standard command conversion program can be downloaded from the PU 3 to the nonvolatile memory 13, whereby a different command conversion program can be executed instead of the standard command conversion program. That is, when the processor 11 receives the download command from the CPU 3,
The mode shifts to the stop mode in which the CPU operation is stopped. In the stop mode, the internal registers and the like of the CPU 3 are held and the operation is stopped until external writing is input. Such a register can be composed of, for example, Oki Electric MSM65516 or the like. C in the middle of the processor 11 stop mode
The PU 3 writes the command conversion program in the non-volatile memory 13 in the dedicated module unit 1. This command conversion program writes what is read from the auxiliary storage device 6 connected to the CPU 3 or the external communication I / O 9.
【0015】以上の書き込みが終了したら、CPU3は
専用モジュール部1に対して外部割込み信号を出力し、
プロセッサ11をストップモードから解除する。CPU
3は、ICカード2へのコマンドの実行の前に標準コマ
ンド変換部21を使用するか、オプションコマンド変換
部31を実行するかの設定コマンドを専用モジュール部
1に対して設定しておく。このようなダウンロードは、
電源投入後の初期設定時に行なってもよいが、ICカー
ド2からのリセット応答(アンサートウリセット)でI
Cカード2が何であるか識別してから行なってもよい。
そのようにすることにより、ICカード応用装置は、異
なる仕様のカードに柔軟に対応できるようになる。When the above writing is completed, the CPU 3 outputs an external interrupt signal to the dedicated module section 1,
The processor 11 is released from the stop mode. CPU
3 sets a setting command for the dedicated module unit 1 to use the standard command conversion unit 21 or the option command conversion unit 31 before executing the command to the IC card 2. Such downloads
This may be done at the time of initial setting after the power is turned on, but the IC card 2 resets the response (answer toe reset).
It may be performed after identifying what the C card 2 is.
By doing so, the IC card application device can flexibly deal with cards having different specifications.
【0016】次に、上述した装置の動作を説明する。図
4に、図3に示すライトレコードのコマンドを図2
(b)に示すライトレコードのコマンドに変換する動作
を示す。まず、ステップS1では、CPU3から受信さ
れた図3に示すコマンドのコマンドヘッダがライトレコ
ードであるか否かを判別し、そうである場合にステップ
S2以下を実行する。即ち、ステップS2で図3のコマ
ンドヘッダを図2(b)のコマンドヘッダにセットし、
ステップS3で図3のファイルIDを図2(b)のファ
イルIDにセットし、ステップS4で図3のレコードI
Dを図2(b)のレコードIDにセットする。また、ス
テップS5で図3のコマンドのデータの部分からデータ
長を求めて図2(b)のデータ長にセットする。そし
て、ステップS6で図3のデータを図2(b)のデータ
の部分にセットする。これにより、図2(b)のコマン
ドのセットがすべて終了する。この後、ステップS7で
図2(b)のコマンドを発行する。Next, the operation of the above-mentioned device will be described. FIG. 4 shows the write record command shown in FIG.
The operation of converting to the command of the write record shown in (b) is shown. First, in step S1, it is determined whether the command header of the command shown in FIG. 3 received from the CPU 3 is a write record, and if so, step S2 and subsequent steps are executed. That is, in step S2, the command header of FIG. 3 is set in the command header of FIG.
The file ID of FIG. 3 is set to the file ID of FIG. 2B in step S3, and the record I of FIG. 3 is set in step S4.
Set D to the record ID in FIG. Further, in step S5, the data length is obtained from the data portion of the command of FIG. 3 and set to the data length of FIG. 2 (b). Then, in step S6, the data of FIG. 3 is set in the data portion of FIG. This completes the set of commands in FIG. 2 (b). Then, in step S7, the command of FIG. 2B is issued.
【0017】このように、ICカード応用装置で使用す
る図3に示すコマンドが自動的に図2(b)に示すIC
カードの仕様に対応したコマンドに変換されて発行され
るので、ICカード応用装置においてはICカードの仕
様がどのようなものかを知っている必要はない。従っ
て、ICカード応用装置の開発者は、図3に示すような
図2(b)に示すものよりも比較的簡単なコマンド形式
のみを理解していればよい。次に、ICカード応用装置
で発行された1つのコマンドにより、ICカードに対
し、複数のコマンドが発行される場合の動作を説明す
る。このようなコマンドの一例として機密データライト
コマンドがある。As described above, the command shown in FIG. 3 used in the IC card application device automatically changes to the IC shown in FIG.
Since the command is converted into a command and issued, the IC card application device does not need to know what the IC card specifications are. Therefore, the developer of the IC card application device needs to understand only the command format which is relatively simpler than that shown in FIG. 2B as shown in FIG. Next, the operation when a plurality of commands are issued to the IC card by one command issued by the IC card application device will be described. An example of such a command is a confidential data write command.
【0018】図5に、専用モジュール部1における機密
データライトコマンドの変換手順を示す。まず、ステッ
プS11では、機密データライトコマンドが受信された
か否かを判別する。機密データライトコマンドは、図6
に示すような形式であり、データを書き込むべきファイ
ルに対するアクセスの許可を受けるためのパスワードを
伴なっている。プロセッサ11はこの機密データライト
コマンドを受信した場合には、ライトレコードコマンド
の発行に先立ち、ステップS12〜S15で図7に示す
パスワード照合コマンドをICカード2に対して発行す
る。即ち、ステップS12では、図7においてパスワー
ド照合コマンドのヘッダをセットし、ステップS13で
はアクセスの許可を受けるべきファイルのIDを図6の
ファイルIDからセットし、ステップS14では、その
ファイルIDのファイルをアクセスするためのパスワー
ドを図6からセットする。その後、ステップS15で図
7のパスワード照合コマンドをICカード2に対して発
行し、ステップS16でICカード2からの許可を待
つ。FIG. 5 shows a procedure for converting the confidential data write command in the dedicated module section 1. First, in step S11, it is determined whether or not a confidential data write command has been received. The confidential data write command is shown in Fig. 6.
The format is as shown in, and is accompanied by a password for receiving permission to access the file in which the data should be written. When the processor 11 receives this confidential data write command, it issues the password verification command shown in FIG. 7 to the IC card 2 in steps S12 to S15 before issuing the write record command. That is, in step S12, the header of the password verification command in FIG. 7 is set, in step S13 the ID of the file to be permitted access is set from the file ID in FIG. 6, and in step S14, the file with that file ID is set. The password for access is set from FIG. After that, the password collation command of FIG. 7 is issued to the IC card 2 in step S15, and the permission from the IC card 2 is waited for in step S16.
【0019】ステップS16でICカード2からファイ
ルIDのファイルのアクセス許可を受けると、図4のス
テップS2以下と同様に、ステップS17〜S22で図
6のコマンドから図2(a)の形式のコマンドを生成
し、ICカード2に対して発行する。一方、パスワード
の不一致等によりICカード2からファイルアクセスの
許可がされなかった場合は、ステップS23でCPU3
に対して異常通知を行なう。このように、CPU3から
図6に示す1つのコマンドを発行することにより、専用
モジュール部1を介してICカード2に対しては図7及
び図2(b)に示す2つのコマンドが発行される。従っ
て、ICカード2に対する複雑な処理もCPU3では簡
単に取扱うことができ、ICカード応用装置の開発者の
負担を軽減することができる。When access permission for the file with the file ID is received from the IC card 2 in step S16, the commands in the format of FIG. 2A are changed from the command of FIG. 6 in steps S17 to S22, as in step S2 and subsequent steps of FIG. Is generated and issued to the IC card 2. On the other hand, if the IC card 2 does not permit the file access due to a password mismatch or the like, the CPU 3 in step S23.
Issue an error notification to. In this way, by issuing one command shown in FIG. 6 from the CPU 3, the two commands shown in FIG. 7 and FIG. 2B are issued to the IC card 2 via the dedicated module unit 1. . Therefore, complicated processing for the IC card 2 can be easily handled by the CPU 3, and the burden on the developer of the IC card application device can be reduced.
【0020】以上は、ICカード2へのデータの書き込
みのコマンド形式が図2(b)の形式になっている場合
の動作であるが、以下に、そのようなコマンド形式が図
2(a)のようになっている場合の動作を説明する。図
8に、この場合のライトレコードコマンドの変換手順を
示す。まず、ステップS31で、図3のコマンドヘッダ
がライトレコードを示していることを判別すると、ステ
ップS32〜S32でICカード2内で図3のファイル
IDで指定されたファイルをカレントファイルにセット
させるためのコマンドを発行する。即ち、ステップS3
2では、カレントファイルをセットするためのコマンド
のヘッダをセットし、ステップS33では、そのコマン
ドのIDをセットし、その後、ステップS34でそのコ
マンドを発行する。これにより、ICカード2内でファ
イルIDのファイルがカレントファイルにセットされ
る。The above is the operation when the command format for writing data to the IC card 2 is the format shown in FIG. 2B. Below, such a command format is shown in FIG. The operation in the case of the above will be described. FIG. 8 shows a write record command conversion procedure in this case. First, when it is determined in step S31 that the command header of FIG. 3 indicates a write record, in order to set the file designated by the file ID of FIG. 3 in the IC card 2 to the current file in steps S32 to S32. Issue the command. That is, step S3
In 2, the header of the command for setting the current file is set, in step S33, the ID of the command is set, and then in step S34, the command is issued. As a result, the file having the file ID is set in the IC card 2 as the current file.
【0021】ステップS35で、カレントファイルのセ
ットが完了すると、ステップS36〜S39で図2
(a)に示すコマンドが生成される。即ち、ステップS
36で図3のコマンドヘッダを図2(a)のコマンドヘ
ッダにセットし、ステップS37で図3のレコードID
を図2(a)のレコードIDにセットする。また、ステ
ップS38で図3のコマンドのデータの部分からデータ
長を求めて図2(a)のデータ長にセットする。そし
て、ステップS39で図3のデータを図2(a)のデー
タの部分にセットする。これにより、図2(a)のコマ
ンドのセットがすべて終了する。この後、ステップS4
0で図2(a)のコマンドを発行する。When the setting of the current file is completed in step S35, steps S36 to S39 shown in FIG.
The command shown in (a) is generated. That is, step S
The command header of FIG. 3 is set in the command header of FIG. 2A in 36, and the record ID of FIG. 3 is set in step S37.
Is set to the record ID in FIG. Further, in step S38, the data length is obtained from the data portion of the command of FIG. 3 and set to the data length of FIG. Then, in step S39, the data of FIG. 3 is set in the data portion of FIG. This completes the set of commands in FIG. After this, step S4
At 0, the command of FIG. 2A is issued.
【0022】このように、ICカード2に対するコマン
ドの形式が図2(a)及び(b)に示すように異なる場
合も、ICカード応用装置では同一の形式の図3のコマ
ンドを使用することができる。このようなコマンド変換
の切替は、標準コマンド変換部21に図4に示すような
処理手順を格納し、オプションコマンド変換部31に図
8に示すような処理手順を格納し、ICカードの初期設
定時にCPU3からの所定のコマンドにより標準コマン
ド変換部21及びオプションコマンド変換部31のいず
れをプロセッサ11で実行するかを決定することにより
行なう。As described above, even when the command formats for the IC card 2 are different as shown in FIGS. 2A and 2B, the IC card application apparatus can use the same command of FIG. it can. For such command conversion switching, the standard command conversion unit 21 stores the processing procedure as shown in FIG. 4, the option command conversion unit 31 stores the processing procedure as shown in FIG. This is sometimes done by determining which of the standard command conversion unit 21 and the option command conversion unit 31 is to be executed by the processor 11 according to a predetermined command from the CPU 3.
【0023】図9に、ICカード2からの応答内容によ
り、標準コマンド変換部21とオプションコマンド変換
部31とを切り替える場合の動作を説明する。まず、ス
テップS41では、CPU3からコマンドを受信する
と、そのコマンドを変換するのに先立ち、ステップS4
2でICカード2に対し、リセットコマンドを発行す
る。このリセットコマンドは、ICカードの仕様によら
ず共通の形式のもので、ICカード2からはリセット終
了後に応答が返される。その応答電文にはICカードの
仕様が示されている。ステップS43でICカード2か
らのリセット応答を受信すると、ステップS43でIC
カードの種類に応じたコマンドを生成し、発行する。即
ち、例えば、図4又は図8に示すいずれかのコマンド変
換を行なう。FIG. 9 illustrates the operation when switching between the standard command conversion unit 21 and the option command conversion unit 31 according to the response contents from the IC card 2. First, in step S41, when a command is received from the CPU 3, prior to converting the command, step S4 is performed.
At step 2, a reset command is issued to the IC card 2. This reset command has a common format regardless of the specifications of the IC card, and the IC card 2 returns a response after the reset is completed. The response message shows the specifications of the IC card. When the reset response from the IC card 2 is received in step S43, the IC is received in step S43.
Generates and issues commands according to the card type. That is, for example, either command conversion shown in FIG. 4 or FIG. 8 is performed.
【0024】このようにして、ICカード応用装置にお
いて、複数の種類のICカードを使用する場合にも、各
種類についてのICカード応用装置の開発者が知識を持
っている必要がなく、図3に示すような形式のみを理解
していればよい。尚、本発明は上述した実施例に限定さ
れるものではなく、種々の変形が可能である。例えば、
上述した実施例の装置は、各種の動作を行なうことが可
能なものであるが、例えば、図4に示す変換処理のみを
行なうものでもその他の変換処理のみを行なうものでも
差し支えない。In this way, even when a plurality of types of IC cards are used in the IC card application device, it is not necessary for the developer of the IC card application device for each type to have knowledge, and FIG. You only need to understand the format shown in. It should be noted that the present invention is not limited to the above-described embodiments, and various modifications can be made. For example,
The apparatus of the above-described embodiment is capable of performing various operations, but it does not matter whether it performs only the conversion processing shown in FIG. 4 or other conversion processing.
【0025】[0025]
【発明の効果】以上説明したように、本発明のICカー
ド応用装置によれば、ICカード応用装置のCPUとは
別のプロセッサで所定の形式のコマンドをICカードの
形式に変換し、ICカードとの通信に必要な伝送プロト
コル、コマンド/レスポンス制御を行なうようにしたの
で、ICカード応用装置の開発者がICカードの伝送プ
ロトコル、コマンド/レスポンス制御の詳細を熟知して
いなくても開発を行なうことができる。従って、ICカ
ード応用装置の開発効率の向上を図り、様々な分野にお
いてICカードを応用することを容易とし、ICカード
の利用の拡大を図ることができる。As described above, according to the IC card application apparatus of the present invention, the command of a predetermined format is converted into the IC card format by a processor other than the CPU of the IC card application apparatus, and the IC card is converted into the IC card format. Since the transmission protocol and command / response control required for communication with the IC card are controlled, the IC card application device can be developed even if the developer of the IC card is not familiar with the details of the IC card transmission protocol and command / response control. be able to. Therefore, it is possible to improve the development efficiency of the IC card application device, facilitate the application of the IC card in various fields, and expand the use of the IC card.
【図1】本発明のICカード応用装置の一実施例のブロ
ック図である。FIG. 1 is a block diagram of an embodiment of an IC card application device of the present invention.
【図2】ICカードのコマンド形式の一例の説明図であ
る。FIG. 2 is an explanatory diagram of an example of a command format of an IC card.
【図3】CPUでのコマンド形式の一例の説明図であ
る。FIG. 3 is an explanatory diagram of an example of a command format in the CPU.
【図4】ライトレコードコマンドの変換手順(その1)
を説明するフローチャートである。FIG. 4 is a write record command conversion procedure (1).
It is a flowchart explaining.
【図5】機密データライトコマンドの変換手順を説明す
るフローチャートである。FIG. 5 is a flowchart illustrating a procedure for converting a confidential data write command.
【図6】CPUでの機密データライトコマンド形式の説
明図である。FIG. 6 is an explanatory diagram of a confidential data write command format in the CPU.
【図7】ICカードのパスワード照合コマンド形式の説
明図である。FIG. 7 is an explanatory diagram of a password verification command format of an IC card.
【図8】ライトレコードコマンドの変換手順(その2)
を説明するフローチャートである。FIG. 8: Write Record Command Conversion Procedure (Part 2)
It is a flowchart explaining.
【図9】コマンド応答による変換処理手順の設定を説明
するフローチャートである。FIG. 9 is a flowchart illustrating setting of a conversion processing procedure based on a command response.
1 専用モジュール部 2 ICカード 3 CPU 11 プロセッサ 21 標準コマンド変換部 31 オプションコマンド変換部 1 Dedicated Module 2 IC Card 3 CPU 11 Processor 21 Standard Command Converter 31 Option Command Converter
Claims (4)
ンドをICカードの仕様に対応した形式のコマンドに変
換するための処理手順を格納したコマンド変換部と、 当該コマンド変換部の処理を実行することにより、前記
装置本体のCPUから送られたコマンドをICカードの
仕様に対応した形式のコマンドに変換してICカードに
送出し、ICカードからの応答を前記装置本体の形式に
変換して前記CPUに送出するプロセッサとを備えたこ
とを特徴とするICカード応用装置。1. A command conversion unit that stores a processing procedure for converting a command in a predetermined format used in the apparatus main body into a command in a format corresponding to the specifications of an IC card, and executes processing of the command conversion unit. By doing so, the command sent from the CPU of the device body is converted into a command of a format corresponding to the specifications of the IC card and sent to the IC card, and the response from the IC card is converted into the format of the device body. An IC card application device comprising a processor for sending to the CPU.
使用される所定の形式の1つのコマンドをICカードの
仕様に対応した形式の複数のコマンドに変換するための
処理手順を格納したことを特徴とする請求項1記載のI
Cカード応用装置。2. The command conversion unit stores a processing procedure for converting one command of a predetermined format used in the apparatus main body into a plurality of commands of a format corresponding to the specifications of the IC card. I according to claim 1, characterized in that
C card application device.
に格納される処理手順を前記装置本体側から所定時に入
力することを特徴とする請求項1又は請求項2記載のI
Cカード応用装置。3. The I according to claim 1, wherein the processor inputs a processing procedure stored in the command conversion unit from the apparatus main body side at a predetermined time.
C card application device.
前記プロセッサは、前記ICカードからの応答の内容に
応じていずれかのコマンド変換部を選択して処理を実行
することを特徴とする請求項1乃至請求項3のいずれか
1の項記載のICカード応用装置。4. A plurality of command conversion units are provided,
4. The IC according to claim 1, wherein the processor executes a process by selecting one of the command conversion units according to the content of the response from the IC card. Card application device.
Priority Applications (1)
| Application Number | Priority Date | Filing Date | Title |
|---|---|---|---|
| JP6112177A JPH07296124A (en) | 1994-04-27 | 1994-04-27 | Ic card applying device |
Applications Claiming Priority (1)
| Application Number | Priority Date | Filing Date | Title |
|---|---|---|---|
| JP6112177A JPH07296124A (en) | 1994-04-27 | 1994-04-27 | Ic card applying device |
Publications (1)
| Publication Number | Publication Date |
|---|---|
| JPH07296124A true JPH07296124A (en) | 1995-11-10 |
Family
ID=14580187
Family Applications (1)
| Application Number | Title | Priority Date | Filing Date |
|---|---|---|---|
| JP6112177A Pending JPH07296124A (en) | 1994-04-27 | 1994-04-27 | Ic card applying device |
Country Status (1)
| Country | Link |
|---|---|
| JP (1) | JPH07296124A (en) |
Cited By (3)
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| JP2005196629A (en) * | 2004-01-09 | 2005-07-21 | Sony Corp | Information processing apparatus and method, recording medium, and program |
| JP2006072974A (en) * | 2004-09-01 | 2006-03-16 | Microsoft Corp | Device service provider interface |
| JP2007094885A (en) * | 2005-09-29 | 2007-04-12 | Keyence Corp | Radio tag reader/writer, and radio tag read/write method |
-
1994
- 1994-04-27 JP JP6112177A patent/JPH07296124A/en active Pending
Cited By (3)
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| JP2005196629A (en) * | 2004-01-09 | 2005-07-21 | Sony Corp | Information processing apparatus and method, recording medium, and program |
| JP2006072974A (en) * | 2004-09-01 | 2006-03-16 | Microsoft Corp | Device service provider interface |
| JP2007094885A (en) * | 2005-09-29 | 2007-04-12 | Keyence Corp | Radio tag reader/writer, and radio tag read/write method |
Similar Documents
| Publication | Publication Date | Title |
|---|---|---|
| US6205580B1 (en) | Method for loading a program | |
| US20040064267A1 (en) | Method and apparatus for testing microarchitectural features by using tests written in microcode | |
| JPH07296124A (en) | Ic card applying device | |
| JPH0935018A (en) | Portable information recording medium and access method thereof | |
| JPS5928300A (en) | Semiconductor device | |
| JP2731047B2 (en) | Program operand check method | |
| JPH07295802A (en) | Program card and computer using the same | |
| JP3576232B2 (en) | Information storage medium issuance processing data creation device and creation method | |
| JP3788886B2 (en) | IC card and IC card using device | |
| JPH11167525A (en) | Non-volatile memory embedded microcomputer, nonvolatile memory rewriting method thereof, and recording medium storing nonvolatile memory rewriting program of nonvolatile memory embedded microcomputer | |
| JP2002008382A (en) | Memory writing device | |
| JP3730684B2 (en) | Display device for programmable controller and display information writing method thereof | |
| JPH10312307A (en) | Emulator applied to computer system | |
| JP2883489B2 (en) | Instruction processing unit | |
| JPH04130949A (en) | Simple method for starting system | |
| JPH03160524A (en) | information processing equipment | |
| JPH0636161B2 (en) | Information processing equipment | |
| JPH0738157B2 (en) | Register selection method | |
| JP2001297014A (en) | Signal processing apparatus and method | |
| JPS6175449A (en) | Internal configuration control data variable method for input/output control device | |
| JPH10187913A (en) | Ic chip for ic card | |
| JPH01260554A (en) | File transfer completion notification method | |
| JPH05100901A (en) | Microcomputer | |
| JPH01270154A (en) | File converter | |
| JPH0330029A (en) | Input/output simulation device of computer |