Class RPRfid
- java.lang.Object
-
- RPRfid
-
public class RPRfid extends java.lang.ObjectKlasse zum Anschluss eines RFID-Empfängers an den Raspberry Pi. Der Anschluss erfolgt ueber SPI. Original aus Python MFRC522
-
-
Field Summary
Fields Modifier and Type Field Description static byteBitFramingRegstatic byteCommandRegstatic byteCommIEnRegstatic byteCommIrqRegstatic byteControlRegstatic byteErrorRegstatic byteFIFODataRegstatic byteFIFOLevelRegstatic intMI_ERRstatic intMI_NOTAGERRstatic intMI_OKstatic byteModeRegstatic bytePCD_AUTHENTstatic bytePCD_IDLEstatic bytePCD_RESETPHASEstatic bytePCD_TRANSCEIVEstatic bytePICC_ANTICOLLstatic bytePICC_REQIDLstatic byteTModeRegstatic byteTPrescalerRegstatic byteTReloadRegHstatic byteTReloadRegLstatic byteTxAutoRegstatic byteTxControlReg
-
Constructor Summary
Constructors Constructor Description RPRfid()Liefert ein Objekt zum Benutzen eines RFID-Lesers.
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description byte[]getCardID()Liefert die ID der vorgelegten Karte als Byte-Arrayint[]getCardIDAsIntArray()Liefert die ID der vorgelegten Karte als Int-Arrayjava.lang.StringgetCardIDAsString()Liefert die ID der vorgelegten Karte als Zeichenkettestatic voidmain(java.lang.String[] args)Test-Methode
-
-
-
Field Detail
-
PCD_IDLE
public static final byte PCD_IDLE
- See Also:
- Constant Field Values
-
PCD_TRANSCEIVE
public static final byte PCD_TRANSCEIVE
- See Also:
- Constant Field Values
-
PCD_AUTHENT
public static final byte PCD_AUTHENT
- See Also:
- Constant Field Values
-
PCD_RESETPHASE
public static final byte PCD_RESETPHASE
- See Also:
- Constant Field Values
-
PICC_REQIDL
public static final byte PICC_REQIDL
- See Also:
- Constant Field Values
-
PICC_ANTICOLL
public static final byte PICC_ANTICOLL
- See Also:
- Constant Field Values
-
MI_OK
public static final int MI_OK
- See Also:
- Constant Field Values
-
MI_NOTAGERR
public static final int MI_NOTAGERR
- See Also:
- Constant Field Values
-
MI_ERR
public static final int MI_ERR
- See Also:
- Constant Field Values
-
CommandReg
public static final byte CommandReg
- See Also:
- Constant Field Values
-
CommIEnReg
public static final byte CommIEnReg
- See Also:
- Constant Field Values
-
CommIrqReg
public static final byte CommIrqReg
- See Also:
- Constant Field Values
-
ErrorReg
public static final byte ErrorReg
- See Also:
- Constant Field Values
-
FIFODataReg
public static final byte FIFODataReg
- See Also:
- Constant Field Values
-
FIFOLevelReg
public static final byte FIFOLevelReg
- See Also:
- Constant Field Values
-
ControlReg
public static final byte ControlReg
- See Also:
- Constant Field Values
-
BitFramingReg
public static final byte BitFramingReg
- See Also:
- Constant Field Values
-
ModeReg
public static final byte ModeReg
- See Also:
- Constant Field Values
-
TxControlReg
public static final byte TxControlReg
- See Also:
- Constant Field Values
-
TxAutoReg
public static final byte TxAutoReg
- See Also:
- Constant Field Values
-
TModeReg
public static final byte TModeReg
- See Also:
- Constant Field Values
-
TPrescalerReg
public static final byte TPrescalerReg
- See Also:
- Constant Field Values
-
TReloadRegH
public static final byte TReloadRegH
- See Also:
- Constant Field Values
-
TReloadRegL
public static final byte TReloadRegL
- See Also:
- Constant Field Values
-
-
Method Detail
-
getCardID
public byte[] getCardID()
Liefert die ID der vorgelegten Karte als Byte-Array
-
getCardIDAsIntArray
public int[] getCardIDAsIntArray()
Liefert die ID der vorgelegten Karte als Int-Array
-
getCardIDAsString
public java.lang.String getCardIDAsString()
Liefert die ID der vorgelegten Karte als Zeichenkette
-
main
public static void main(java.lang.String[] args)
Test-Methode
-
-