2016-10-20 06:55 PM
Hi Sir / Madam,
After ST95HF has read its peer NFC device, ST95HF RF field is automatically shut down. I have to initialise it again using the following functions:
ISO14443A_Init( );
ISO14443A_IsPresent(); ISO14443A_Anticollision();May I know how can I prohibit this to happen. Because when this happens, where the RF field provide by ST95HF is not stable, peer NFC device is unable to smoothly read by ST95HF. May I know how can I make ST95HF RF field is constantly switch ON when even I have finished reading and writing to peer NFC RF interface ?
Thank you for your advice.
Please reply soon.
Thank you.
Cheers,
KF
#nfc-transceiver-ics---xx95hf #nfc #nfc-transceiver-ics---xx95hfSolved! Go to Solution.
2016-11-15 02:55 AM
Hello,
Sorry for the late reply, we experience troubles with the forum notifications currently...Thanks for the additional information you provided.My understanding of your setup is the following:1. ST95HF successfully reads the NXP NTAG.2. You attempt an additional read from the ST95HF right after, which fails because the ST95HF RF field has been shut down.If you are using the ST demo function TagReading() without any modification, this function shut down the RF field before exiting: PCD_FieldOff();However, if you re-attempt a read using the TagReading() function, it should work as the RF field is switched ON again by the ConfigManager_TagHunting(TRACK_ALL) procedure.If you are not using the TagReading() function for the second read, then you have to re-do the init process as mentionned in your very first message.If you are not using the TagReading() function at all, here is the code that you can use:ISO14443A_Init( );
if(ISO14443A_IsPresent() == RESULTOK) { if(ISO14443A_Anticollision() == RESULTOK) { if (((ISO14443A_Card.SAK&0x60) == 0x00)) /* TT2 */ TagType = TRACK_NFCTYPE2; } }/* This is the first read */PCDNFCT2_ReadNDEF()
delay_ms(3000);
/* This is the second read after a 3s delay */PCDNFCT2_ReadNDEF()
If you're not formating your message as a NDEF, you can use the PCDNFCT2_Read() function instead.Please let me know if this is of any help with your issue.Regards.2016-11-02 03:40 AM
Hello,
We need more details on your setup to help you.1. Which Firmware are you using on the ST95HF?2. What is the peer device? Another ST95HF, a Smartphone?> If you are using a smartphone, what application do you use?3. Do you know if you are using the ST proprietary implementation of the peer to peer?Thanks & regards.2016-11-07 05:24 PM
HI SIr / Madam,
Please see my reply as attached.
Thank you and please advice soon.
Cheers,
KF
2016-11-14 05:48 PM
Hello ST Support,
May I know what happen to ST95HF after ST95HF read data from its Peer NFC device ?
May I know what has shut off ST95HF RF Field after ST95HF has done the read action ?
After ST95HF read data from its peer NFC, is ST95HF still in ready state and in reader role ? In my code, provide by ST, I do not turn off the RF field after read function. But I have to turn it ON before every Read statement, or I will get a timeout (0x87).
Please help soon.
Thank you very much. Your help is very much appreciated.
Cheers,
KF
Please see the following for the answers. Thank you.
1. Which Firmware are you using on the ST95HF?May I know what is the firmware information you need ?, I am using ST95HF attached to ST M3 microcontroller.
The ST95HF software is downloaded from internet.
For example: drv_95HF.c ----> author is MMY Application Team
----> version V4.0.0
----> date is 02/06/2014
----> brief : This file provides set of driver functions to manage communication between MCU and xx95HF chip (RX95HF, CR95HF or ST95HF)
<h2><center>© COPYRIGHT 2014 STMicroelectronics</center></h2> * * Licensed under MMY-ST Liberty SW License Agreement V2, (the ''License''); * You may not use this file except in compliance with the License. * You may obtain a copy of the License at: * *http://www.st.com/software_license_agreement_liberty_v2
* * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an ''AS IS'' BASIS, * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. * See the License for the specific language governing permissions and * limitations under the License. 2. What is the peer device? Another ST95HF, a Smartphone?My peer device is NXP NTAG 1K which is attached to a ST M3 microcontroller.
> If you are using a smartphone, what application do you use? 3. Do you know if you are using the ST proprietary implementation of the peer to peer? No, I have not touch anything on ST proprietary because I have not use anything from the file lib_proprietaryP2P.c .Thanks & regards.
2016-11-15 02:55 AM
Hello,
Sorry for the late reply, we experience troubles with the forum notifications currently...Thanks for the additional information you provided.My understanding of your setup is the following:1. ST95HF successfully reads the NXP NTAG.2. You attempt an additional read from the ST95HF right after, which fails because the ST95HF RF field has been shut down.If you are using the ST demo function TagReading() without any modification, this function shut down the RF field before exiting: PCD_FieldOff();However, if you re-attempt a read using the TagReading() function, it should work as the RF field is switched ON again by the ConfigManager_TagHunting(TRACK_ALL) procedure.If you are not using the TagReading() function for the second read, then you have to re-do the init process as mentionned in your very first message.If you are not using the TagReading() function at all, here is the code that you can use:ISO14443A_Init( );
if(ISO14443A_IsPresent() == RESULTOK) { if(ISO14443A_Anticollision() == RESULTOK) { if (((ISO14443A_Card.SAK&0x60) == 0x00)) /* TT2 */ TagType = TRACK_NFCTYPE2; } }/* This is the first read */PCDNFCT2_ReadNDEF()
delay_ms(3000);
/* This is the second read after a 3s delay */PCDNFCT2_ReadNDEF()
If you're not formating your message as a NDEF, you can use the PCDNFCT2_Read() function instead.Please let me know if this is of any help with your issue.Regards.2016-12-20 09:08 PM
Hi ST Support,
I have another problem. I need your help. Please help me
(1) I am struggling on why ST95 is unable read the session register the second time without doing another round of ISO14443A_Init( ), ISO14443A_IsPresent() , and ISO14443A_Anticollision(). There is no response from NTAG.
(2) Even though I redo ISO14443A_Init( ), ISO14443A_IsPresent() , and ISO14443A_Anticollision(). or collectively called it RF field ON, It will fail at ISO14443A_IsPresent(). It will fail at REQ A (0x2607) , timeout while waiting for NTAG response. But if I do it this way : ISO14443A_Init( ), ISO14443A_IsPresent() , ISO14443A_IsPresent() , and ISO14443A_Anticollision(). , it will success. The reason is that : The errchk(ISO14443A_REQA(pDataRead)); will only receive data from NTAG the second time if send out twice to NTAG. The first time of REQA can be a wrong value, example 0x0000. But the second time must be a correct value 0x2607. Only by this way, it will make REQA a success.
(3) According to NFC resource, the REQA is actually 0x26, only. May I know what is mean by 0x07, following 0x26.
(4) I have raise this question because : Every time, while doing Pass through communication between NTAG and ST95, I need to do the following:
(a) Field ON after read session register.
(b) Field ON before and after reading NTAG mapped SRAM.
(c) Field ON before and after writing NTAG mapped SRAM.
I have also apply the same method for read / write NTAG Mirror SRAM.
Without this method, NTAG RF interface (ST95) will behave abnormaly.
Please reply soon.
Thank you very much.
Cheers,
KF
2016-12-20 09:31 PM
/* NfcApp__ISO14443AFieldOn */
ISO14443A_Init();
ISO14443A_IsPresent(); ISO14443A_Anticollision(); delay_ms(10);/* ---------------------------------------------------------------------------------------------------------*/
/* NfcApp__ReadNtagSessionRegister - first read after Field ON */
/* Select Sector */
PCDNFCT2_SectorSelect(0x03);/* Start reading */
PCDNFCT2_Read(0xF8,session_0xF8); /* 0xF8 is NXP NTAG Session Register from RF Interface *//* The above read success */
/* ---------------------------------------------------------------------------------------------------------*/
/* NfcApp__ReadNtagSessionRegister - second read without Field ON */
/* Select Sector */
PCDNFCT2_SectorSelect(0x03);/* Start reading */
PCDNFCT2_Read(0xF8,session_0xF8); /* 0xF8 is NXP NTAG Session Register from RF Interface *//* The above read fail. It needs to field ON again in order to read success */
/* ---------------------------------------------------------------------------------------------------------*/
return;
2017-01-03 08:31 AM
Hi KF,
Thanks for your update!
Please find below my answers for the points you raised:
(1) The session register is a competitor specific register, on which I can't provide any support. Could you do the same test with a memory area behaving as described by an ISO/NFC standard? On my side, I tried the above code, reading a Type2 Tag data memory, and both reads were successful. Please let me know the status on your side.
(2) The REQA command is not supposed to be called twice in the ISO14443A anticollision process (unless the field has been switched off), that may explain why your tag is not responding when you recall the
ISO14443A_
IsPresent() function. And also, the ISO14443A defines a Request Guard Time (7000/fc) between 2 REQA commands, but from what you described, I suppose this timing is met.(3) The additional 0x07 is the Transmission Flag which is not transmitted on RF but provides additional information to the CR95HF on the command beeing sent. This byte is described in the CR95HF datasheet, Table 14: Transmission Flags Bits [3:0]: Number of significant bits in last byte.
(4) The feature you describe is not covered by the ISO14443A, and thus may lead to interoperability issues. If your point in using this feature is to get rid of eeprom write delays, I may suggest you trying this new ST product:
This dynamic tag provides an efficient Fast Transfer Mode for quick and easy data exchange between a reader and a Host.
Best regards.
2017-01-06 12:39 AM
Hi ST Support 7,
Many thanks for your help. Really appreciate it very much.
I have check and check my code again and discover a minor mistake which has cause this weird symptom.
I have miss out a statement to select the correct sector when reading NTAG as I thought it will automatically change to the correct sector after reading is done. By correcting this mistake, I have solve my main problem although the are still some minor issues pending. Project is consider done for now.
Once again, thank you very much for your help.
Happy New Year 2017 to the Team. May 2017 be a great year for you all !
Cheers !
KF