cancel
Showing results for 
Search instead for 
Did you mean: 

Problem implementing STM32CubeExpansion_NFC5_V2.0.0's Nucleo_PollingTagDetect on NUCLEO-F303RE

JRacz.1
Associate

As the title suggests, I'm trying to implement on of the example applications that come with the cube expansion NFC5 for the NUCLEO-F303RE. The example application is called "Nucleo_PollingTagDetect".

Hardware setup:

-NUCLEO-F303RE

-X-NUCLEO-NFC505A1

What I've done so far:

-Started a new project and set it up using CUBEMX. I made sure to setup the SPI, LED pin and IRQ pins so they were routed to the correct Arduino headers (i can give specific set up if needed).

-edited Platform.h for my setup.

-included the Middleware packages "ndef" and "rfal".

-included the STR3911 drivers.

What works:

-The project gets to the demo loop of the sample application fine. I can push the blue, user button to toggle between "wake up mode on" and "wake up mode off".

What doesn't work:

-The RF field never seems to turn on and the reader never detects and tags I place near it.

-It seems like the function "rfalRunWakeUpModeWorker()" in "rfal_rfst25r911.c" should eventually set "gFRAL.wum.state" to "RFAL_WUM_STATE_ENABLED_WOKE". This never happens. "st25r3911GetInterrupt()" never returns any interrupts. It appears an interrupt must be present in order for "gFRAL.wum.state" to be set to "RFAL_WUM_STATE_ENABLED_WOKE. The program just loops, waiting for the interrupt to occur.

-While the program was looping, the same thing is being repeated on the SPI line. I attached this in the file "spi.xlsx". I couldn't figure out what the commands were doing from the datasheet. I'm pretty sure I have my SPI set up correctly, I don't think the program would get to the demo loop without it. (e.g. the demoini() function checks the chipID using a command over SPI and it returns a valid ID).

I attached my project too. I'm just branching out from the Arduino dev. boards, so I'm used to everything being overly simplified by libraries. Any hints on what to try would be greatly appreciated! Let me know if any additional information would help.

Thanks!

1 ACCEPTED SOLUTION

Accepted Solutions
Brian TIDAL
ST Employee

Hi,

make sure to call  st25r3911Isr(); in EXTI0_IRQHandler() in stm32f3xx_it.c:

/**
  * @brief This function handles EXTI line0 interrupt.
  */
void EXTI0_IRQHandler(void)
{
  /* USER CODE BEGIN EXTI0_IRQn 0 */
 
  /* USER CODE END EXTI0_IRQn 0 */
  HAL_GPIO_EXTI_IRQHandler(GPIO_PIN_0);
  /* USER CODE BEGIN EXTI0_IRQn 1 */
  st25r3911Isr(); /* <-----------------ST25R3911 ISR needed here */
  /* USER CODE END EXTI0_IRQn 1 */
}

Rgds

BT

In order to give better visibility on the answered topics, please click on Accept as Solution on the reply which solved your issue or answered your question.

View solution in original post

1 REPLY 1
Brian TIDAL
ST Employee

Hi,

make sure to call  st25r3911Isr(); in EXTI0_IRQHandler() in stm32f3xx_it.c:

/**
  * @brief This function handles EXTI line0 interrupt.
  */
void EXTI0_IRQHandler(void)
{
  /* USER CODE BEGIN EXTI0_IRQn 0 */
 
  /* USER CODE END EXTI0_IRQn 0 */
  HAL_GPIO_EXTI_IRQHandler(GPIO_PIN_0);
  /* USER CODE BEGIN EXTI0_IRQn 1 */
  st25r3911Isr(); /* <-----------------ST25R3911 ISR needed here */
  /* USER CODE END EXTI0_IRQn 1 */
}

Rgds

BT

In order to give better visibility on the answered topics, please click on Accept as Solution on the reply which solved your issue or answered your question.