<?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>nrfx_..._uninit not idempotent: can&amp;#39;t be safely called on an already uninitialized driver instance</title><link>https://devzone.nordicsemi.com/f/nordic-q-a/39433/nrfx_-_uninit-not-idempotent-can-t-be-safely-called-on-an-already-uninitialized-driver-instance</link><description>I&amp;#39;m writing some code for doing a soft reset in which I need to reset nrfx driver instances, and I don&amp;#39;t know whether they have already been initialized or not. But unfortunately I can&amp;#39;t safely called the nrf_..._uninit() operation on an uninitialized</description><dc:language>en-US</dc:language><generator>Telligent Community 13</generator><lastBuildDate>Wed, 17 Jan 2024 20:33:55 GMT</lastBuildDate><atom:link rel="self" type="application/rss+xml" href="https://devzone.nordicsemi.com/f/nordic-q-a/39433/nrfx_-_uninit-not-idempotent-can-t-be-safely-called-on-an-already-uninitialized-driver-instance" /><item><title>RE: nrfx_..._uninit not idempotent: can't be safely called on an already uninitialized driver instance</title><link>https://devzone.nordicsemi.com/thread/464687?ContentTypeID=1</link><pubDate>Wed, 17 Jan 2024 20:33:55 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:98dc3948-fc6b-4ba3-b2f5-b7cc3ce7fc9e</guid><dc:creator>Dan Halbert</dc:creator><description>&lt;p&gt;&lt;span&gt;The nrfx 3.2.0 release has added functions like&amp;nbsp;&lt;/span&gt;&lt;code class="notranslate"&gt;nrfx_twim_init_check()&lt;/code&gt;&lt;span&gt;, which return true or false based on whether the driver was initialized or not. This satisfies the alternative solution proposed in&amp;nbsp;&lt;/span&gt;&lt;a class="issue-link js-issue-link" href="https://github.com/NordicSemiconductor/nrfx/issues/43#issuecomment-441665189" data-error-text="Failed to load title" data-id="369843250" data-permission-text="Title is private" data-url="https://github.com/NordicSemiconductor/nrfx/issues/43" data-hovercard-type="issue" data-hovercard-url="/NordicSemiconductor/nrfx/issues/43/hovercard?comment_id=441665189&amp;amp;comment_type=issue_comment"&gt;#43 (comment)&lt;/a&gt;&lt;span&gt;. Thank you.&lt;/span&gt;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: nrfx_..._uninit not idempotent: can't be safely called on an already uninitialized driver instance</title><link>https://devzone.nordicsemi.com/thread/152889?ContentTypeID=1</link><pubDate>Mon, 15 Oct 2018 13:06:13 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:a9ba19bc-3941-4c09-85d1-a3c9ff5d7269</guid><dc:creator>tesc</dc:creator><description>&lt;p&gt;Hi,&lt;/p&gt;
&lt;p&gt;Thanks for linking to the github issue from this thread! What to do is a decision best to be taken by the SDK team, so I think leaving your PR as is is fine.&lt;/p&gt;
&lt;p&gt;Regards,&lt;br /&gt;Terje&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: nrfx_..._uninit not idempotent: can't be safely called on an already uninitialized driver instance</title><link>https://devzone.nordicsemi.com/thread/152880?ContentTypeID=1</link><pubDate>Mon, 15 Oct 2018 12:38:36 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:f8d4ef91-8d93-47e4-a08e-c8e1c40d9388</guid><dc:creator>Dan Halbert</dc:creator><description>&lt;p&gt;Thank you. I also submitted a GitHub ticket at&amp;nbsp;&lt;a href="https://github.com/NordicSemiconductor/nrfx/issues/43"&gt;https://github.com/NordicSemiconductor/nrfx/issues/43 &lt;/a&gt;that essentially says the same thing -- I wasn&amp;#39;t sure whether that was more logical, since I have a prepared Pull Request. I can modify my PR to do what you suggest (right now it just returns nothing, since the &lt;strong&gt;uninit&lt;/strong&gt; functions&amp;nbsp;return void).&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: nrfx_..._uninit not idempotent: can't be safely called on an already uninitialized driver instance</title><link>https://devzone.nordicsemi.com/thread/152847?ContentTypeID=1</link><pubDate>Mon, 15 Oct 2018 11:06:17 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:b5d472be-1055-462a-9a3a-a43c61a8a4e7</guid><dc:creator>tesc</dc:creator><description>&lt;p&gt;Hi,&lt;/p&gt;
&lt;p&gt;Thank you for reporting this. Bug reports and feature requests are always highly appreciated!&lt;/p&gt;
&lt;p&gt;While I do not currently have any suggestions for better workarounds, I have notified the SDK team and they might have some ideas. In any case I have registered a feature request for solving the general use case, for instance by making nrfx_*_uninit() behave similarly to nrfx_*_init() and return NRFX_ERROR_INVALID_STATE if already uninitialized. IMHO that would be the best and most consistent way to solve this within our driver APIs.&lt;/p&gt;
&lt;p&gt;Regards,&lt;br /&gt;Terje&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item></channel></rss>