Integration of NFC forum and HCE T4T

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

Integration of NFC forum and HCE T4T

469 Views
cesarP
Contributor II

Chip: PN7642
HW: PNEV7642A REV B

I am attempting to develop a device that operates in both reader mode and emulation mode using the PN7642. To achieve this, I have tried switching between POLL and LISTEN modes in the example code pnev7642fama_NfcrdlibEx3_NFCForum_Freertos_Ecp. Additionally, I integrated the emulator from example pnev7642fama_NfcrdlibEx8_HCE_T4T_Freertos_Full into the forum example in Listen mode.

When I set the forum example only in Listen mode, the emulator works correctly. Similarly, when I set the forum only in Poll mode, the reader functions properly. However, when I switch between Poll and Listen modes, the emulator fails to work. Specifically, the issue lies in the even wait functionality:

status = phhalHw_EventConsume(pHal);
CHECK_STATUS(status);

status = phhalHw_SetConfig(pHal, PHHAL_HW_CONFIG_RFON_INTERRUPT, PH_ON);
CHECK_STATUS(status);

status = phhalHw_EventWait(pHal, LISTEN_PHASE_TIME_MS); <-- only detects 1 out of 10 attempts

In this scenario, the event wait only detects 1 out of 10 attempts, even when the iphone is left on the antenna. If I increase the LISTEN_PHASE_TIME_MS parameter from 300 to 500 or 1000, then it detects 4 out of 10 attempts, but I still cannot achieve a consistent detection rate of 10 out of 10

Question: Is there any way to make this work, or is it impossible?

0 Kudos
Reply
0 Replies