Basic ISO 7816 Project 1.4

Purpose

This application enables the user to perform basic ISO 7816-4 commands with a smartcard connected to the evaluation kit.

Hardware Requirements

This package can be used with any Atmel AT91 Evaluation Kit.

This application requires particular external components to work as intended. Here are several examples for connecting a card reader to some AT91 boards:

Card Reader Pin SAM7SE-EK SAM7X-EK SAM9263
7816_3v5v PA9 PA27 PC30
7816_irq PA8 PA4 PA29
7816_io PA6 PA1 PA26
7816_clk PB2 PA2 PA30
7816_rst PA29 PA29 PA29

Description

Upon startup, the example resets the smartcard and fetches its Answer To Reset (ATR). It then enables the user to send three commands to the card (Case 1, Case 2 and Case 3). The answer given by the smartcard to each command is output after the command is executed.

Usage

  1. Build the program and download it inside the evaluation board. Please refer to the SAM-BA User Guide, the GNU-Based Software Development application note or to the IAR EWARM User Guide, depending on your chosen solution.
  2. On the computer, open the DBGU port with a terminal application (e.g. HyperTerminal on Microsoft Windows).
  3. Connect the card reader on the board as described above.
  4. Insert a card that can answer commands (Case 1, Case 2 and Case 3).
  5. Start the application.
  6. Upon startup, the application will output the following line on the DBGU:
    -- Basic ISO7816 Project 1.4 --
  7. The program then tries to reset the smartcard and fetch its ATR. The command result is output on the DBGU. The ATR is decoded.
  8. A menu is displayed to let the user send several commands to the board. Choosing options 1.4 executes the corresponding command and shows the result on the DBGU.
Atmel Corporation ©2008