ST25R3916B NFC Detection
Hello,
I am currently trying to port the ST25R3916B driver to a platform that uses the ThreadX RTOS, but I am encountering some issues. I have previously ported it to a platform using Zephyr, and that process went smoothly.
I have already implemented the platform-specific files responsible for I2C communication, IRQ handling, and software timers. The initialization process completes without any errors. However, in the main thread—where I call rfalWorker()—the NFC tag is not detected.
Below are some relevant code snippets:
Init()
{
/* Initialize RFAL platform */
rc_st = rfalNfcInitialize();
}Discover()
{
/* Retrieve default discovery parameters */
rfalNfcDefaultDiscParams(&m_discParam);
m_discParam.notifyCb = m_fncPollNotification;
m_discParam.p2pNfcaPrio = true;
m_discParam.totalDuration = 1000;
m_discParam.techs2Find = flags;
m_pollDuration = duration;
ReturnCode rc = rfalNfcDiscover(&m_discParam);
}
while (1)
{
rfalNfcWorker();
state = rfalNfcGetState();
/* Verify if a device was detected */
if (rfalNfcIsDevActivated(state))
{
LOG_MESSAGE("NFC dev detected\n");
m_pollingActive = false;
}
_sleep(10);
}
I printed the IRQ status values on both boards, and they are the same while RFAL is running in the idle state. However, when I tap the phone, the values become different.
I will attach screenshots of the logs (values shown in hexadecimal):
Bbb

