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

nrf52 NFC Read / Write Application

SDK - 15.0.0

IDE - Segger Embedded Studio

Computer Platform - Windows 7 - 64 Bit

Hi,

I am using an android phone to write a 32 byte array to the nrf52 device which is running the Type 4 Tag (Read/Write) NFC example. Now, once the 32 byte array is written to the device, I need to use the same to create an ecdsa signature which is then written back to the FDS and loaded to the NDEF message buffer so that the android phone can read the signature from the device.

Now, the problem that I am facing is, where should I pick the 32 byte array in the application to use it for further processing.

I tried fetching the value from the ndef_message_buff variable, which stores the updated ndef message and generating the signature here, but I'm guessing this interrupts the write process to the fds and hence I receive an error.

I also tried fetching the value from the FDS once the FDS Update Success event is called, and generating the signature from here, but this results in a recursive loop, since I'm performing an update to the fds right after generating the signature.

The generate_signature() method is defined in the file "ndef_file_m.c" at line no. 227. As of now, I'm feeding hard coded values of the 32 byte array, to check if the signature is being successfully written to the fds after an nfc write event. Once this works, I plan to fetch the values for the variable, m_hash from the fds.

Here is the download link to my project.

To build it, you will have to place the nRF5_SDK_15.0.0 folder at the same level as the project folder, as shown in the image below.

Regards,

Varun

Parents Reply Children
No Data
Related