Skip to content

Commit

Permalink
formatting
Browse files Browse the repository at this point in the history
  • Loading branch information
ljos committed Sep 25, 2013
1 parent e82bb96 commit fa83ee7
Showing 1 changed file with 8 additions and 13 deletions.
21 changes: 8 additions & 13 deletions MFRC522.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -182,23 +182,18 @@ int MFRC522::commandTag(byte cmd, byte *data, int dlen, byte *result, int *rlen)
int status = MI_ERR;
byte irqEn = 0x00;
byte waitIRq = 0x00;
byte lastBits;
byte n;
byte lastBits, n;
int i;

switch (cmd) {
case MFRC522_AUTHENT:
{
irqEn = 0x12;
waitIRq = 0x10;
break;
}
irqEn = 0x12;
waitIRq = 0x10;
break;
case MFRC522_TRANSCEIVE:
{
irqEn = 0x77;
waitIRq = 0x30;
break;
}
irqEn = 0x77;
waitIRq = 0x30;
break;
default:
break;
}
Expand Down Expand Up @@ -232,7 +227,7 @@ int MFRC522::commandTag(byte cmd, byte *data, int dlen, byte *result, int *rlen)

clearBitMask(BitFramingReg, 0x80); // StartSend=0

if (i != 0) {
if (i != 0) { // Request did not time out.
if(!(readFromRegister(ErrorReg) & 0x1B)) { // BufferOvfl Collerr CRCErr ProtocolErr
status = MI_OK;
if (n & irqEn & 0x01) {
Expand Down

0 comments on commit fa83ee7

Please sign in to comment.