Skip to content

Commit

Permalink
Merge pull request #123 from caternuson/iss121
Browse files Browse the repository at this point in the history
Update IRQ example
  • Loading branch information
caternuson authored Nov 17, 2023
2 parents e1c80d7 + 0463d4b commit dca85bd
Showing 1 changed file with 7 additions and 2 deletions.
9 changes: 7 additions & 2 deletions examples/readMifareClassicIrq/readMifareClassicIrq.ino
Original file line number Diff line number Diff line change
Expand Up @@ -108,8 +108,13 @@ void startListeningToNFC() {
// Reset our IRQ indicators
irqPrev = irqCurr = HIGH;

Serial.println("Waiting for an ISO14443A Card ...");
nfc.startPassiveTargetIDDetection(PN532_MIFARE_ISO14443A);
Serial.println("Starting passive read for an ISO14443A Card ...");
if (!nfc.startPassiveTargetIDDetection(PN532_MIFARE_ISO14443A)) {
Serial.println("No card found. Waiting...");
} else {
Serial.println("Card already present.");
handleCardDetected();
}
}

void handleCardDetected() {
Expand Down

0 comments on commit dca85bd

Please sign in to comment.