This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

Trying to communicate PN532 with TI dynamic tag

Other Parts Discussed in Thread: TRF7970A, RF430CL330H, DLP-7970ABP
Following is the code for arduino connected with RF430CL330H dynamic tag

#if ARDUINO >= 100
 #include "Arduino.h"
#else
 #include "WProgram.h"
#endif
#include <Wire.h>
#include <RF430CL330H_Shield.h>

#define IRQ   (3)
#define RESET (4)  
int led = 13;
RF430CL330H_Shield nfc(IRQ, RESET);

unsigned char NDEF_Application_Data[] = RF430_DEFAULT_DATA;
volatile byte into_fired = 0;
uint16_t flags = 0;
byte ndefdata[1024];
uint16_t Tag4Length = 0;

void setup(void) 
{
    Serial.begin(9600);    
    
    pinMode(led, OUTPUT); 
    digitalWrite(led, HIGH);
    //reset RF430
    nfc.begin();
    delay(1000);
}

void loop(void) 
{
  
    while(!(nfc.Read_Register(STATUS_REG) & READY)); //wait until READY bit has been set
    Serial.print("Fireware Version:"); Serial.println(nfc.Read_Register(VERSION_REG), HEX);    

    //write NDEF memory with Capability Container + NDEF message
    nfc.Write_Continuous(0, NDEF_Application_Data, sizeof(NDEF_Application_Data));

    //Enable interrupts for End of Read and End of Write
    nfc.Write_Register(INT_ENABLE_REG, EOW_INT_ENABLE + EOR_INT_ENABLE);

    //Configure INTO pin for active low and enable RF
    nfc.Write_Register(CONTROL_REG, INT_ENABLE + INTO_DRIVE + RF_ENABLE );


  Serial.println(nfc.Read_Register(CONTROL_REG)); //prints 22
  

while(1){
  
  
}


}








Following is the code for arduino connected with PN532 nfc reader/writer.



/**************************************************************************/
#include <Wire.h>
#include <Adafruit_NFCShield_I2C.h>

#define IRQ   (2)
#define RESET (3)  // Not connected by default on the NFC Shield

Adafruit_NFCShield_I2C nfc(IRQ, RESET);

void setup(void) {
  Serial.begin(9600);
  Serial.println("Hello!");

  nfc.begin();

  uint32_t versiondata = nfc.getFirmwareVersion();
  if (! versiondata) {
    Serial.print("Didn't find PN53x board");
    while (1); // halt
  }
  // Got ok data, print it out!
  Serial.print("Found chip PN5"); Serial.println((versiondata>>24) & 0xFF, HEX); 
  Serial.print("Firmware ver. "); Serial.print((versiondata>>16) & 0xFF, DEC); 
  Serial.print('.'); Serial.println((versiondata>>8) & 0xFF, DEC);
  
  // configure board to read RFID tags
  nfc.SAMConfig();
  
  Serial.println("Waiting for an ISO14443A Card ...");
}


void loop(void) {
  uint8_t success;
  uint8_t uid[] = { 0, 0, 0, 0, 0, 0, 0 };  // Buffer to store the returned UID
  uint8_t uidLength;                        // Length of the UID (4 or 7 bytes depending on ISO14443A card type)
    
  // Wait for an ISO14443A type cards (Mifare, etc.).  When one is found
  // 'uid' will be populated with the UID, and uidLength will indicate
  // if the uid is 4 bytes (Mifare Classic) or 7 bytes (Mifare Ultralight)
  success = nfc.readPassiveTargetID(PN532_MIFARE_ISO14443A, uid, &uidLength);
  
  if (success) {
    // Display some basic information about the card
    Serial.println("Found an ISO14443A card");
    Serial.print("  UID Length: ");Serial.print(uidLength, DEC);Serial.println(" bytes");
    Serial.print("  UID Value: ");
    nfc.PrintHex(uid, uidLength);
    Serial.println("");
    
    if (uidLength == 4)
    {
      // We probably have a Mifare Classic card ... 
      Serial.println("Seems to be a Mifare Classic card (4 byte UID)");
    
      // Now we need to try to authenticate it for read/write access
      // Try with the factory default KeyA: 0xFF 0xFF 0xFF 0xFF 0xFF 0xFF
      Serial.println("Trying to authenticate block 4 with default KEYA value");
      uint8_t keya[6] = { 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF };
    
      // Start with block 4 (the first block of sector 1) since sector 0
      // contains the manufacturer data and it's probably better just
      // to leave it alone unless you know what you're doing
      success = nfc.mifareclassic_AuthenticateBlock(uid, uidLength, 4, 0, keya);
    
      if (success)
      {
        Serial.println("Sector 1 (Blocks 4..7) has been authenticated");
        uint8_t data[16];
    
        // If you want to write something to block 4 to test with, uncomment
        // the following line and this text should be read back in a minute
        //memcpy(data, (const uint8_t[]){ 'a', 'd', 'a', 'f', 'r', 'u', 'i', 't', '.', 'c', 'o', 'm', 0, 0, 0, 0 }, sizeof data);
        //success = nfc.mifareclassic_WriteDataBlock (4, data);

        // Try to read the contents of block 4
        success = nfc.mifareclassic_ReadDataBlock(4, data);
    
        if (success)
        {
          // Data seems to have been read ... spit it out
          Serial.println("Reading Block 4:");
          nfc.PrintHexChar(data, 16);
          Serial.println("");
      
          // Wait a bit before reading the card again
          delay(1000);
        }
        else
        {
          Serial.println("Ooops ... unable to read the requested block.  Try another key?");
        }
      }
      else
      {
        Serial.println("Ooops ... authentication failed: Try another key?");
      }
    }
    
    if (uidLength == 7)
    {
      // We probably have a Mifare Ultralight card ...
      Serial.println("Seems to be a Mifare Ultralight tag (7 byte UID)");
    
      // Try to read the first general-purpose user page (#4)
      Serial.println("Reading page 4");
      uint8_t data[32];
      success = nfc.mifareultralight_ReadPage (4, data);
      if (success)
      {
        // Data seems to have been read ... spit it out
        nfc.PrintHexChar(data, 4);
        Serial.println("");
    
        // Wait a bit before reading the card again
        delay(1000);
      }
      else
      {
        Serial.println("Ooops ... unable to read the requested page!?");
      }
    }
  }
}

And the modification i made in the library is as follows:

boolean Adafruit_NFCShield_I2C::readPassiveTargetID(uint8_t cardbaudrate, uint8_t * uid, uint8_t * uidLength) {

  pn532_packetbuffer[0] = PN532_COMMAND_INLISTPASSIVETARGET; //4A
  pn532_packetbuffer[1] = 1;  // max 1 cards at once (we can set this to 2 later)
  pn532_packetbuffer[2] = 0x03; //This is for type B card according to manual
  pn532_packetbuffer[3] = 0x00; //AFI is set to 0x00
  
  if (! sendCommandCheckAck(pn532_packetbuffer, 4))
  {
    #ifdef PN532DEBUG
	Serial.println("No card(s) read");
	#endif
    return 0x0;  // no cards read
  }
  
  // Wait for a card to enter the field
  uint8_t status = PN532_I2C_BUSY;
  #ifdef PN532DEBUG
  Serial.println("Waiting for IRQ (indicates card presence)");
  #endif
  while (wirereadstatus() != PN532_I2C_READY)
  {
	delay(10);
  }

  Serial.println("Found a card"); 

It should print Found a card when the dynamic tag is brought close to the PN532 reader writer but it doesnt detect the tag. I am pretty sure i have connected the circuit correctly as i can write to the control register correctly and PN532 can detect mifare cards but not TI dynamic tag. Is there anything else that i have to take care of in order to make this communication a success? Thanks for the help!

  • Sanjay Giri said:
    
    
    void loop(void) {
      uint8_t success;
      uint8_t uid[] = { 0, 0, 0, 0, 0, 0, 0 };  // Buffer to store the returned UID
      uint8_t uidLength;                        // Length of the UID (4 or 7 bytes depending on ISO14443A card type)
        
      // Wait for an ISO14443A type cards (Mifare, etc.).  When one is found
      // 'uid' will be populated with the UID, and uidLength will indicate
      // if the uid is 4 bytes (Mifare Classic) or 7 bytes (Mifare Ultralight)
      success = nfc.readPassiveTargetID(PN532_MIFARE_ISO14443A, uid, &uidLength);

    Hey Sanjay,

    I don't have all the code here, but It looks like this Reader code is only looking for ISO14443A Tags (which includes Mifare).  

    The RF430 is an ISO14443B tag.  The commands structure for each are similar, but the commands them selves do vary.  Basically, an ISO14443B tag is not going to respond to ISO14443A Commands.  

    This is why the Mifare tag works, while the RF430 does not.  

    Does nfc.readPassiveTargetID(PN532_MIFARE_ISO14443A, uid, &uidLength); possibly support any different technologies already?  

    We have example code that can do ISO14443B for our NFC Transceiver (TRF7970A) on an MSP430 here: http://www.ti.com/lit/zip/sloc297 .  You may be able to atleast follow the flow there if you need to implement the code.

    Thanks,

    JD 

  • hi JD,

    Thank you for the reply. If you look closely at the following code i have not used cardbaudrate which was PN532_MIFARE_ISO14443A passed to the function. Instead i have hardcoded the value for type B tag which is 0x03. PN532_MIFARE_ISO14443A  translates to 0x00. So, i dont think that is the problem.  

    boolean Adafruit_NFCShield_I2C::readPassiveTargetID(uint8_t cardbaudrate, uint8_t * uid, uint8_t * uidLength) {
      pn532_packetbuffer[0] = PN532_COMMAND_INLISTPASSIVETARGET; //4A
      pn532_packetbuffer[1] = 1;  // max 1 cards at once (we can set this to 2 later)
      pn532_packetbuffer[2] = 0x03; //This is for type B card according to manual
      pn532_packetbuffer[3] = 0x00; //AFI is set to 0x00
  • Sanjay,

    I am not very familiar with the PN532 14443B operation.  Can you confirm what commands the reader is actually sending out?  It must start with a REQB or WUPB followed by an ATTRIB.  Con you provide the entire command string going out over the air? 

    Also, are you able to read the RF430CL330H with an NFC enabled phone or tablet to confirm that the tag is actually responding to RF commands?

  • Sanjay,

    I also posted to the Adafruit forums to see if they have any example code for reading type B.  Please do confirm whether you can read the RF430CL with a known good NFC phone or tablet first though. 

  • hi Eddie,

    According to this manual in page 118

    http://www.nxp.com/documents/user_manual/141520.pdf

    pn532 sends reqb followed by attrib like you said on InlistPassiveTarget command that i am using in the code.

    I havent checked with smartphone but i will try today to read the tag from my phone and let you know if it works or not. Is it correct that in order for the nfc tag reader app in my phone to detect the tag the following code should suffice to configure the dynamic tag

    #if ARDUINO >= 100
     #include "Arduino.h"
    #else
     #include "WProgram.h"
    #endif
    #include <Wire.h>
    #include <RF430CL330H_Shield.h>
    #define IRQ   (3)
    #define RESET (4) 
    int led = 13;
    RF430CL330H_Shield nfc(IRQ, RESET);
    unsigned char NDEF_Application_Data[] = RF430_DEFAULT_DATA;
    volatile byte into_fired = 0;
    uint16_t flags = 0;
    byte ndefdata[1024];
    uint16_t Tag4Length = 0;
    void setup(void)
    {
        Serial.begin(9600);   
        
        pinMode(led, OUTPUT);
        digitalWrite(led, HIGH);
        //reset RF430
        nfc.begin();
        delay(1000);
    }
    void loop(void)
    {
      
        while(!(nfc.Read_Register(STATUS_REG) & READY)); //wait until READY bit has been set
        Serial.print("Fireware Version:"); Serial.println(nfc.Read_Register(VERSION_REG), HEX);   
        //write NDEF memory with Capability Container + NDEF message
        nfc.Write_Continuous(0, NDEF_Application_Data, sizeof(NDEF_Application_Data));
        //Enable interrupts for End of Read and End of Write
        nfc.Write_Register(INT_ENABLE_REG, EOW_INT_ENABLE + EOR_INT_ENABLE);
        //Configure INTO pin for active low and enable RF
        nfc.Write_Register(CONTROL_REG, INT_ENABLE + INTO_DRIVE + RF_ENABLE );
      Serial.println(nfc.Read_Register(CONTROL_REG)); //prints 22
      
    while(1){
      
      
    }
    }

  • Sanjay,

    I am looking for the actual bytes sent out for the REQB and ATTRIB commands.  This would be helpful if you know.

    It looks like your code for the RF430CL330H should work.  If you want to do a bare minimum test, all you need to do is enable RF in the control register.  This will load a default NDEF message of ti.com/nfc. 

    Also, are you using the RF430CL330HTB board?  I just want to make sure you have something with a good antenna and proper components too. 

  • yes i am using that target board. I had to solder the header pins.

  • Sanjay,

    From a high level the code looks like it should set-up the RF430 to be read.  I would recommend getting the RF430 working with a smart phone first, then figure out the NXP chip.

    As far as the NXP chip goes, we are not familiar with it or it's operation, so we won't be able to help on the low level code.  If we know the exact commands being send out over the air, we could assist in point out errors where you are not following the ISO14443B spec.  

    Let us know if it's working with the smart phone.

    Thanks,

    JD 

  • Good News!! I just tested with my smartphone and it can detect the tag. So, that means the dynamic tag circuit is working correctly which is a very good news. Now, i can just focus on the pn532 side which for some reason is not succeeding.

  • Sanjay - 

    hey i spent a few moments reading the PN532 user manual. Maybe these points might help.

    if you look here http://www.nxp.com/documents/user_manual/141520.pdf on page 105 it lists the configuration setting for using TypeB card. (if you have not done this detail, maybe it will not work)

    then it looks like (on page 115) if you send it a 0xD4, 0x4A, 0x02 (max value here), 0x03, and the AFI and polling method (this last field is optional), you should get a response. (?)

    let us know how that works out. Good job on getting this far - it'll be great if you can get one more step further.

  • Thank you Josh! I will try those and report to you. 

  • Josh, I already did this part

    "then it looks like (on page 115) if you send it a 0xD4, 0x4A, 0x02 (max value here), 0x03, and the AFI and polling method (this last field is optional), you should get a response. (?)"

    as you can see in the following code. So i think the issue is with the first point you made. I will try that.

    boolean Adafruit_NFCShield_I2C::readPassiveTargetID(uint8_t cardbaudrate, uint8_t * uid, uint8_t * uidLength) {
      pn532_packetbuffer[0] = PN532_COMMAND_INLISTPASSIVETARGET; //4A
      pn532_packetbuffer[1] = 1;  // max 1 cards at once (we can set this to 2 later)
      pn532_packetbuffer[2] = 0x03; //This is for type B card according to manual
      pn532_packetbuffer[3] = 0x00; //AFI is set to 0x00
  • hey Josh,

    I tried it and unfortunately it didnt work. Here is what i did. I added a new function that sent the  RF configuration command. Also, i would like to point out that the manual said "Except for these two specific settings, 8 remaining settings are same as type A". So, i tried both first just using those three bytes and then including all 11 and neither worked. I have set the code so that when it detects a card it should print "Found a card" as you can see in the inlistpassivetarget function below. This works well when i configure it to detect mifare card but the dynamic tag is still not being detectable.

    boolean Adafruit_NFCShield_I2C::configure(){
    
    /*
    0x32
    0x0C
    
    0x59
    0xFF
    0x3F
    0x17
    0x4D
    0x85
    0x61
    0x6F
    0x26
    0x62
    0x87
    */
    
    
      pn532_packetbuffer[0] = 0x32; //4A
      pn532_packetbuffer[1] = 0x0C;  // max 1 cards at once (we can set this to 2 later)
      
      pn532_packetbuffer[2] = 0x59; //cardbaudrate;
      pn532_packetbuffer[3] = 0xFF; //cardbaudrate;
      pn532_packetbuffer[4] = 0x3F; //cardbaudrate;
      pn532_packetbuffer[5] = 0x17; //cardbaudrate;
      pn532_packetbuffer[6] = 0x4D; //cardbaudrate;
      pn532_packetbuffer[7] = 0x85; //cardbaudrate;
      pn532_packetbuffer[8] = 0x61; //cardbaudrate;
      pn532_packetbuffer[9] = 0x6F; //cardbaudrate;
      pn532_packetbuffer[10] = 0x26; //cardbaudrate;
      pn532_packetbuffer[11] = 0x62; //cardbaudrate;
      pn532_packetbuffer[12] = 0x87; //cardbaudrate;
      
      if (! sendCommandCheckAck(pn532_packetbuffer, 13))
      {
        #ifdef PN532DEBUG
    	Serial.println("No card(s) read");
    	#endif
        return 0x0;  // no cards read
      }
      
    return 1;
    
    }
    
    
    
    /***** ISO14443A Commands ******/
    
    /**************************************************************************/
    /*! 
        Waits for an ISO14443A target to enter the field
        
        @param  cardBaudRate  Baud rate of the card
        @param  uid           Pointer to the array that will be populated
                              with the card's UID (up to 7 bytes)
        @param  uidLength     Pointer to the variable that will hold the
                              length of the card's UID.
        
        @returns 1 if everything executed properly, 0 for an error
    */
    /**************************************************************************/
    boolean Adafruit_NFCShield_I2C::readPassiveTargetID(uint8_t cardbaudrate, uint8_t * uid, uint8_t * uidLength) {
    
      pn532_packetbuffer[0] = PN532_COMMAND_INLISTPASSIVETARGET; //4A
      pn532_packetbuffer[1] = 2;  // max 1 cards at once (we can set this to 2 later)
      pn532_packetbuffer[2] = 0x03; //cardbaudrate;
      pn532_packetbuffer[3] = 0x00; //cardbaudrate;
      pn532_packetbuffer[4] = 0x00; //cardbaudrate;
      
      if (! sendCommandCheckAck(pn532_packetbuffer, 5))
      {
        #ifdef PN532DEBUG
    	Serial.println("No card(s) read");
    	#endif
        return 0x0;  // no cards read
      }
      
      // Wait for a card to enter the field
      uint8_t status = PN532_I2C_BUSY;
      #ifdef PN532DEBUG
      Serial.println("Waiting for IRQ (indicates card presence)");
      #endif
      while (wirereadstatus() != PN532_I2C_READY)
      {
    	delay(10);
    	Serial.println("waiting");
      }
    
      Serial.println("Found a card"); 
      
     

    and i call configure first and then readPassiveTarget.

  • Sanjay,

    We really want to help you out here, but it is fairly difficult for us since this shield uses an NXP chip which we are not deeply familiar with.  Have you contacted NXP for support yet?  Another option could be to use our TRF7970A boosterpack + MSP430 Launchpad.  They are fairly inexpensive($35 for both boards) and already have software support for ISO 14443A/B, ISO 15693, and FeliCa.  The launchpad is a great microcontroller platform and even offers on board emulation, which the Arduino does not.  I recommend checking it out at least! 

    http://www.ti.com/tool/dlp-7970abp

    http://www.ti.com/tool/msp-exp430g2

  • Sanjay - 

    looks like the configuration form is: 

    D4 32 CfgItem ConfigurationData [ ] //see page 101

    for Type B it should (it looks to me like) be: 0xD4 0x32 0x0C 0xFF 0x17 0x85

    where: 

    0xD4 is for commands coming from host to reader

    0x32 is set value. 

    0x0C = ISO14443B // page 105

    Config Item is three bytes: 

    Byte #  Register                    Default values
    Byte 1  CIU_GsNOn               0xFF
    Byte 2  CIU_ModGsP             0x17
    Byte 3  CIU_RxThreshold      0x85

    then you should follow the form shown in the manual for sending out the command...starting with 0xD4....

    and as Eddie said, hopefully its obvious we do want you to succeed, but most likely it would be faster to ask adafruit or NXP directly how to do it. 

    other thing you can do is put a near field loop on top of your reader antenna...if its working correctly, you will see something like this...

    if it looks like this, on the other hand...then you are still looking for Type A tags

  • ok. Thank you! I am waiting from the adafruit people to respond. If i dont get any help then i might buy TI's NFC reader/writer.

  • does TI have NFC reader writer that can read and write wirelessly to the TI NFC dynamic tag?

  • yes sir. the DLP-7970A BoosterPack + MSP-EXP430G2 launchpad...i have completed the code which reads out this tag (plus Type 2, ISO15693, FeliCa and Type 4A) automatically and sends back to serial port....

    let me know what you are doing and we can support you.

  • can you provide me with link to product page for both of these?

  • http://www.digikey.com/product-detail/en/DLP-7970ABP/813-1039-ND/4333457

    http://www.mouser.com/ProductDetail/DLP-Design/DLP-7970ABP/?qs=Dogq6BmZmk7hpqHVEZYI9g==

    http://www.ti.com/tool/msp-exp430g2

  • Thanks! Just to make sure can this boosterpack also act as NFC writer. I only saw NFC reader in the manual so was confused.

    http://www.digikey.com/product-detail/en/DLP-7970ABP/813-1039-ND/4333457

  • Sure, the device can be writer, and a target, too.

  • hey Eddie,

    You said"

    Sanjay,

    I am not very familiar with the PN532 14443B operation.  Can you confirm what commands the reader is actually sending out?  It must start with a REQB or WUPB followed by an ATTRIB.  Con you provide the entire command string going out over the air? 

    Also, are you able to read the RF430CL330H with an NFC enabled phone or tablet to confirm that the tag is actually responding to RF commands?"

    I had to stay with pn532 and TI dynamic tag for some other reasons. Can i get some more help on this? So, i have decided to use logic analyzer to check the commands sent out. Where should i hook my logic analyzer pins? Did you want me to check what commands are sent by my arduino to the PN532 and make sure that arduino is sending REQB command followed by an ATTRIB. If so, is there an easier way to catch that command  because if i just hook my the logic analyser to the tx pins and upload the code and run it then it might record not just those instructions but a whole bunch of instructions. I haven't used logic analyzer a lot, just one or two occasion for class. So please guide me on this. Thank you!

  • Sanjay,

    The PN532 is manufactured by NXP and the Arduino Shield is designed and sold by Adafruit.   I have to recommend that you work with these companies to ensure that you are properly setting up the PN532 for typeB.  The logic analyzer probably will not help you here.  If you are unsure of the commands going out, you need to sniff the over the air communication and determine which commands are being sent.  Frontline test equipment offers such a tool, but may be too costly for your needs.  You could create a pickup loop with an oscope probe by connecting the ground and signal connectors together and then manually decode the signals.  For type B, you should see ~10% modulation depth.  For type A, you should see 100% modulation depth.

  • As I just found this post and having the same experience:
    I weren't able to communicate with the RF430 tags together with an PN532 as long I had used tags with Revision C or lower. I got some new ones with Rev D, they could be found by the PN532. Still having problems to read the content, but "InListPassiveTarget" now works well. 
    My question: Is there maybe another bug inside the chipset still preventing to read the content?

    EDIT: The workaround from the errata is already implemented into the tag startup software.

  • hi Elmar,

    I am using 

    http://www.ti.com/tool/rf430cl330htb

    and

    http://www.adafruit.com/products/364

    with arduino uno.

    I have tried all configurations and have failed to make the nfc detect TI tag. Did you use the same tags and nfc as above and make it work? Please let me know if you used the same tag or different one. 

  • hey Elmar,

    Also, you said you were able to make it work with revision c or lower. How do i check the revision of my TI tag? Is it the last alphabet of the name which in my case is H?

    http://www.ti.com/tool/rf430cl330htb

  • Sanjay,

    The chip revision is found in the lower right corner of the IC.  If you are using the TB board, this is populated with revision C.

    Elmar,

    Can you please provide a list of the commands you are sending?  The command/response sequence should like the attached.  Double check your commands with this and see if anything is different.  You can also check with the NFC Forum tag type 4 specification to ensure it matches up.  This sequence was captured using a Nexus 4 phone and rev C RF430CL.

    Hello_World.csv
  • hello Elmar,

    Did you get it to work with revision C? If so, can you please tell me what configuration did you set for pn532? I followed the manual and set necessary configuration bits in inlistpassivetarget but failed to make pn532 detect the TI tag, if you can shed some light on this, that will be of immense help. Thank you!

  • Elmar,

    Please note that the .csv file does not show the PCB(protocol control byte) on the 7816-4 commands(select, read binary, update binary).  The PCB should alternate between 02 and 03 for each command though.  See updated strings with PCB included.

    Hello_World.xlsx
  • Sanjay/Others

    I am working on a project with  arduino + PN532 to read 14443 TypeB cards. After spending weeks I am still unable to find a right lib to ready typeB cards.

    Can any one in this forum help on this regards.

    Thanks

    Srijith

  • Srijith -

    not sure why you stick with Arduino or the PN532 - but that is a different debate altogether.

    What i would recommend here is that since the PN532, according to the NXP website "supports layers 2 and 3 of the ISO/IEC 14443 B Reader/Writer communication scheme, except anticollision. This must be implemented in firmware as well as upper layers."

    what you need to do next is break out an oscilloscope and see exactly what is being sent over the air. What you would expect to see is the something similar to the following for REQB or WupB, just to get the ATQB (the most basic response)

    You may also need to check and adjust (hopefully with a register setting of the PN532) the modulation depth of the air interface with an oscilloscope. (as Type A uses 100% mod depth on the downlink and expects anASK response and Type B requires 8-14% mod depth on the downlink and expects BPSK response)

    here is a shot of REQA (for Type A), just to give you a feel for the difference for the air interface to the tag, to start with.