Multiple RFID read with Access Sequence on Android RFD8500

Hi,

I have some trouble getting this use case working on. I'd like to perform an Inventory, reading multiple memory banks and display them to the end user.

In order to do that, I use an Access Sequence with multiple READ operations (one on each bank), following the developer guide. However, when I try to retrieve the readresult:

for (int i = 0; i < nRead; i++)

     reader.Actions.getReadTags(100).get(i)

I only get the latest read in the sequence. Is there a way to get all of them? Or is it a limitation of the SDK?

Any hint is welcome,

Regards,

Jean-Guillaume

Guillermo Perez
i don't know if this helps,

i don't know if this helps, or if you have already include this part. You need to pass the inventory information to an TagData array and after that you will can access to the information of each inventoried tag :

TagData[] myTags = myReader.Actions.getReadTags(100);

if (myTags != null)

{

     for (int index = 0; index < myTags.length; index++)

     {

          System.out.println("Tag ID " + myTags[index].getTagID());

          if (myTags[index].getOpCode() ==ACCESS_OPERATION_CODE.ACCESS_OPERATION_READ &&

               myTags[index].getOpStatus() ==ACCESS_OPERATION_STATUS.ACCESS_SUCCESS){

                    if (myTags[index].getMemoryBankData().length() > 0) {

                                   System.out.println(" Mem Bank Data " + myTags[index].getMemoryBankData());

                    }

          }

     }

}

Vote: 
Vote up!
Vote down!

Points: 1

You voted ‘up’


Jean-Guillaume Louis
Yes indeed, this works.I was

Yes indeed, this works.

I was reading n tags (with n being the number of memory bank I need to access), and not 100 like in your answer For some reason I am getting duplicates in the getReadTags so I was effectively reading the same data. I had to go further in the array.

I am curious however, as to why 100? This could lead to a perf problem because of the loop. Especially of you need to apply some logic other than printing the results to the console.

Anyway, it works ok for now.

Thank you,

Vote: 
Vote up!
Vote down!

Points: 0

You voted ‘up’


Guillermo Perez
Hi, I´m glad to know it was

Hi, I´m glad to know it was useful for you and in fact, maybe is not  useful in some cases "getReadTags(100)" (I used this function only with 10 tags in an app), but that is the way that Zebra applies this function in the Android Demo App, and they even use a function to eliminate duplicate tags in the array after the inventory.

Vote: 
Vote up!
Vote down!

Points: 0

You voted ‘up’


Log in to post comments