<?xml version="1.0" encoding="UTF-8" ?>
<?xml-stylesheet type="text/xsl" href="https://devzone.nordicsemi.com/cfs-file/__key/system/syndication/rss.xsl" media="screen"?><rss version="2.0" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:slash="http://purl.org/rss/1.0/modules/slash/" xmlns:wfw="http://wellformedweb.org/CommentAPI/" xmlns:atom="http://www.w3.org/2005/Atom"><channel><title>NFC lib restart bug</title><link>https://devzone.nordicsemi.com/f/nordic-q-a/73232/nfc-lib-restart-bug</link><description>Hi, 
 In my application, I&amp;#39;m trying to restart emulation because I want to switch from the NDEF static payload mode to ISO-DEP mode. The problem is that when I stop emulation and call nfc_t4t_done(), I get an invalid state error when I&amp;#39;m trying to set</description><dc:language>en-US</dc:language><generator>Telligent Community 13</generator><lastBuildDate>Thu, 25 Mar 2021 11:32:42 GMT</lastBuildDate><atom:link rel="self" type="application/rss+xml" href="https://devzone.nordicsemi.com/f/nordic-q-a/73232/nfc-lib-restart-bug" /><item><title>RE: NFC lib restart bug</title><link>https://devzone.nordicsemi.com/thread/301876?ContentTypeID=1</link><pubDate>Thu, 25 Mar 2021 11:32:42 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:d98c1dc6-028a-41d9-81e5-55e8ca8f8d30</guid><dc:creator>TSonono</dc:creator><description>&lt;p&gt;Hi Simon,&lt;/p&gt;
&lt;p&gt;Thanks for the swift reply!&lt;/p&gt;
&lt;p&gt;In my code, I was checking the returns with APP_ERROR_CHECK but I did not include it in the code I attached to my question. Regarding calling emulation_stop before done, I&amp;#39;ve tried that too.&lt;/p&gt;
&lt;p&gt;However, calling&amp;nbsp;&lt;span&gt;nrfx_nfct_uninit() did the trick! Thanks for that. FYI, it seems like&amp;nbsp;this problem is still present in SDK 17.0.2 (which is what I&amp;#39;m using).&lt;br /&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span&gt;&lt;br /&gt;Thanks,&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span&gt;Tofik&lt;/span&gt;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: NFC lib restart bug</title><link>https://devzone.nordicsemi.com/thread/301873?ContentTypeID=1</link><pubDate>Thu, 25 Mar 2021 11:24:24 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:cfa2c4cc-1a1d-4304-961c-8e63f5d9437b</guid><dc:creator>Simonr</dc:creator><description>&lt;p&gt;Hi Tofik&lt;/p&gt;
&lt;p&gt;At a first glance, I see that you call the done(); call before emulation_stop(); This should be the other way around, as you should stop the emulation before you release the reference to the application callback. Please make sure that both these return NRF_SUCCESS as well.&lt;/p&gt;
&lt;p&gt;Next, it was discovered in &lt;a href="https://devzone.nordicsemi.com/support-private/support/253221"&gt;this ticket&lt;/a&gt;, that the NFCT driver isn&amp;#39;t uninitialized inside nfc_t4t_done(); in SDK 17.0.0, so you&amp;#39;re correct that it is a bug. You will have to do this yourself in the application by calling nrfx_nfct_uninit() after nfc_t4t_done().&lt;/p&gt;
&lt;p&gt;Best regards,&lt;/p&gt;
&lt;p&gt;Simon&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item></channel></rss>