|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectandroid.device.MagManager
public class MagManager
The MagManager class is used to initialize and control the MSR card reader.
To control the MSR card reader with this class, use the following steps:
MagManager manager = new MagManager();
open()
.
checkCard()
.
getAllStripInfo(byte[] )
.
close()
to close the slot for MSR card reader.
Constructor Summary | |
---|---|
MagManager()
|
Method Summary | |
---|---|
int |
checkCard()
check if a card swipe action has taken place |
int |
close()
Close the MSR reader |
int |
getAllStripInfo(byte[] info)
Get information on all 3 strips |
int |
getSingleStripInfo(int strip,
byte[] info)
Get specific strip information |
int |
open()
Open the MSR reader |
Methods inherited from class java.lang.Object |
---|
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public MagManager()
Method Detail |
---|
public int open()
public int close()
public int checkCard()
public int getAllStripInfo(byte[] info)
info
- to store the information.
The information is organized in TLV (tag length value) format.
tag is 1 byte, with the following meaning.
01 - strip 1, 02 - strip 2, 03 - strip 3
public int getSingleStripInfo(int strip, byte[] info)
strip
- number, could be 1 or 2 or 3info
- to store the strip information
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |