Hello all,
I am trying the get working the example project nfc_writable_ndef_msg on a nRF52832 with the nRF5 SDK.
I have tried the others NFC examples were most are based on the type 2 tag and all worked, but with this specify example using the type 4 tag I could not read the sample message on my poller device( an android smartphone and NFC tools app).
With the help of the debbuger I have found a reinitilization of the NFCT module as the logs show:
<info> NFCT: Tx start <info> TIMER: Disabled instance: 0. <info> NFCT: Reinitialize <info> TIMER: Enabled instance: 0. <info> TIMER: Disabled instance: 0. <info> NFCT: Reinitialize <info> TIMER: Enabled instance: 0. <info> TIMER: Disabled instance: 0. <info> NFCT: Reinitialize <info> TIMER: Enabled instance: 0. <info> NFCT: Tx start <info> NFCT: Tx start <info> TIMER: Disabled instance: 0. <info> NFCT: Reinitialize <info> TIMER: Enabled instance: 0. <info> TIMER: Disabled instance: 0. <info> NFCT: Reinitialize
What I could track about this reinitialization is the workaround 116 on the nrfx_nfct.c file, descript as:
* If you are using the nRF52832 chip, the workarounds for the following anomalies are applied:
* - 79. NFCT: A false EVENTS_FIELDDETECTED event occurs after the field is lost.
* - 116. NFCT does not release HFCLK when switching from ACTIVATED to SENSE mode.
* To implement the first workaround, an instance of NRF_TIMER is used. After the NFC field is detected,
* the timing module periodically polls its state to determine when the field is turned off.
* To implement the second workaround, power reset is used to release the clock acquired by NFCT
* after the field is turned off. Note that the NFCT register configuration is restored to defaults.
I see that the function nrfx_nfct_field_poll() is called periodically but is detects field off very often, even when the polling device is still close to the nrf52832 NFC antenna. I don't know if the workaround is not working or if I am not understanding what is happening.
Can anyone help me to get the example working? For now I just wish to read the examples default message on my smartphone.