Skip to content

Commit

Permalink
Move the interrupt management inside the ST25R3911B library
Browse files Browse the repository at this point in the history
  • Loading branch information
cparata committed Oct 15, 2021
1 parent eea88bd commit d40d379
Show file tree
Hide file tree
Showing 2 changed files with 1 addition and 11 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,6 @@
* INCLUDES
******************************************************************************
*/
#include "SPI.h"
#include "nfc_utils.h"
#include "rfal_nfc.h"
#include "rfal_rfst25r3911.h"
Expand Down Expand Up @@ -225,7 +224,6 @@ static const ndefTypeDumpTable typeDumpTable[] = {
};

static char *hex2Str(unsigned char *data, size_t dataLen);
void IRQCallback();


/*!
Expand Down Expand Up @@ -296,14 +294,11 @@ void setup()
pinMode(LED_V_PIN, OUTPUT);
pinMode(LED_AP2P_PIN, OUTPUT);
pinMode(LED_FIELD_PIN, OUTPUT);
pinMode(IRQ_PIN, INPUT);
pinMode(USER_BTN, INPUT);

/* Check what is the Push Button State when the button is not pressed. It can change across families */
PushButtonState = (digitalRead(USER_BTN)) ? 0 : 1;

attachInterrupt(IRQ_PIN, IRQCallback, RISING);

Serial.println("Welcome to X-NUCLEO-NFC05A1");

ndefShowDemoUsage();
Expand Down Expand Up @@ -1797,9 +1792,4 @@ char *hex2Str(unsigned char *data, size_t dataLen)
return hexStr[idx];
}

void IRQCallback()
{
rfst25r3911b.st25r3911Isr();
}

/************************ (C) COPYRIGHT STMicroelectronics *****END OF FILE****/
2 changes: 1 addition & 1 deletion library.properties
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
name=STM32duino X-NUCLEO-NFC05A1
version=1.0.0
version=1.0.1
author=STMicroelectronics
maintainer=stm32duino
sentence=Allows controlling the ST X-NUCLEO-NFC05A1 expansion board
Expand Down

0 comments on commit d40d379

Please sign in to comment.