Skip to main content
Visitor II
May 27, 2021
Solved

ST25DV NFC Android App fastReadMailboxMessage and hasHostPutMsg Problems

  • May 27, 2021
  • 3 replies
  • 991 views

Hi,

I am building an android app to read mailbox with fastReadMailboxMessage() function. I have already had problems with that function and read somewhere on community.st that this function doesn't work and I should just use readMailboxMessage() instead.

So Question 1:

Does fastReadMailboxMessage() really not work on android java application?

Q2:

If I use readMailboxMessage() instead does it use the fast read or it's already a slower access? (slower than 53kbps)

I also encountered problems with hasHostPutMsg register read through RF. After a successful mailbox read with a phone (all bytes available) hasHostPutMsg register should go back to 0 but for me it stays 1 till I reset the MB. Why could it happen like this?

I send 250bytes of data through I2C once, then read with RF and HostPutMsg is still 1

I appreciate Your quick help!

    This topic has been closed for replies.
    Best answer by Olivier L

    Good! "true" is indeed needed otherwise you read the result from Cache.

    Best regards!

    3 replies

    ST Employee
    May 27, 2021

    Hi,

    "Fast" functions are indeed not supported by the NFC controller present on Android phones. So this is indeed readMailboxMessage() that you should use. I confirm that it is slower than fastReadMailboxMessage(). The data rate of Type V NFC RF command is 26kbps.

    Concerning HostPutMsg (bit 1 of register MB_CTRL_Dyn), it is automatically reset to 0 when RF has read the last byte of the mailbox. If you miss one or more bytes, it will remain to 1 because there are still some data to read. Maybe that it is the reason of you problem?

    Regards

    MP.5Author
    Visitor II
    May 27, 2021

    Thanks for a quick response!

    I actually was missing "true" in the refresh field -> hasHostPutMsg(true);

    Previously had false.

    Best regards!

    Olivier LAnswer
    ST Employee
    May 28, 2021

    Good! "true" is indeed needed otherwise you read the result from Cache.

    Best regards!