Hello,

You can get the size of a memory card from the second byte of its ATR.
According to ISO 7816-3, the 3 LSB of this byte define the length of data 
units (in bits), and its 4 next bits, the number of data units as :

0000 = No size specified
0001 = 128 data units
0010 = 256
0011 = 512
0100 = 1024
0101 = ???
...



Example :
ATR = 92 23 10 91
23 -> 0 0100 011  ->    0100 data units ,  011 bits per data unit

This card is a 1 kb memorycard...


Regards.

Guillaume.


_________________________________

Guillaume LAISNEY
REALTRONIC  - service R&D logiciel

email: [EMAIL PROTECTED]

tel:    +33 (0) 2 33 50 98 00
fax:    +33 (0) 2 33 50 98 49

REALTRONIC
Z.I. Conillot
50400 Granville
FRANCE



***************************************************************
Linux Smart Card Developers - M.U.S.C.L.E.
(Movement for the Use of Smart Cards in a Linux Environment)
http://www.linuxnet.com/smartcard/index.html
***************************************************************

Reply via email to