This post is older than 2 years and might not be relevant anymore
More Info: Consider searching for newer posts

NFC code not working

Hi,

I'm trying to get NFC working on a PCA10040 dev board. Using the nfc/record_url hex file it works fine, so the hardware is obviously ok.

However, when I use the exact same code as in the record_url example from my software, it doesn't do anything. All functions execute without errors, but then log_uart_printf gets called with:

[NFC_HAL]: initialize
[NFC_HAL]: start
// ------------- put NFC device near 
[NFC_HAL]: fielddetected
[NFC_HAL]: reinitialize
[NFC_HAL]: fielddetected
[NFC_HAL]: fielddetected
[NFC_HAL]: reinitialize
[NFC_HAL]: fielddetected
[NFC_HAL]: reinitialize
[NFC_HAL]: fielddetected
[NFC_HAL]: reinitialize
[NFC_HAL]: fielddetected
[NFC_HAL]: fielddetected
[NFC_HAL]: fielddetected
[NFC_HAL]: fielddetected
[NFC_HAL]: reinitialize
[NFC_HAL]: fielddetected
[NFC_HAL]: reinitialize

Also, will the NFC code ever be distributed as something that's not a binary blob? I'm using a language interpreter (Espruino), and it expects functions to be compiled without hardware floating point (the call style is different). Currently the only way I can use NFC is to recompile with VFP, which means I'm then unable to pass floating point values into any functions!

Parents
  • Hi Gordon,

    Attached is an example to use record_url in other example (ble_app_hrm). I don't see any issue. Could you try ?

    ble_app_hrs_URL_nfc - Copy.zip

  • @Gordon: It's as expected that the new kit won't fix the issue with NFC as nothing changed regarding NFC on Engineering B and Production revision.

    I'm afraid that I have little or no experience with Espruino JS. But what you can do is to send me the hex file and I can test on my PCA10040 and my phone. Make sure you remove all dependencies (peripheral for example) and let me know the UART configuration.

    You are not putting the CPU to sleep in the mainloop, but do you have any other activity such as timer, data sampling, interrupt handler also running ? You mentioned that it's a big project. Any BLE activity ?

    I'm still not sure why you can't disable some code/functions to strip down the project and get the NFC to work (as it worked with the record_url example ).

Reply
  • @Gordon: It's as expected that the new kit won't fix the issue with NFC as nothing changed regarding NFC on Engineering B and Production revision.

    I'm afraid that I have little or no experience with Espruino JS. But what you can do is to send me the hex file and I can test on my PCA10040 and my phone. Make sure you remove all dependencies (peripheral for example) and let me know the UART configuration.

    You are not putting the CPU to sleep in the mainloop, but do you have any other activity such as timer, data sampling, interrupt handler also running ? You mentioned that it's a big project. Any BLE activity ?

    I'm still not sure why you can't disable some code/functions to strip down the project and get the NFC to work (as it worked with the record_url example ).

Children
No Data
Related