<?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>TWIM I2C soft reset function?</title><link>https://devzone.nordicsemi.com/f/nordic-q-a/128159/twim-i2c-soft-reset-function</link><description>Hi 
 The TWI driver has a twi_clear_bus() function but the TWIM does not. 
 I&amp;#39;m getting an I2C error, and need to do I2C soft reset. I&amp;#39;m doing this manually at moment but just wondering why a there is no reset in the TWIM. 
 
 We are using SDK3.2 for</description><dc:language>en-US</dc:language><generator>Telligent Community 13</generator><lastBuildDate>Mon, 25 May 2026 16:36:52 GMT</lastBuildDate><atom:link rel="self" type="application/rss+xml" href="https://devzone.nordicsemi.com/f/nordic-q-a/128159/twim-i2c-soft-reset-function" /><item><title>RE: TWIM I2C soft reset function?</title><link>https://devzone.nordicsemi.com/thread/566823?ContentTypeID=1</link><pubDate>Mon, 25 May 2026 16:36:52 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:4bf9570b-0ed2-4788-b8dc-68c033b1a8f2</guid><dc:creator>Susheel Nuguru</dc:creator><description>&lt;p&gt;Sorry for very late reply, this thread somehow fell in the gaps of not being visible to me.&lt;/p&gt;
&lt;p&gt;Try this&lt;/p&gt;
&lt;p&gt;&lt;pre class="ui-code" data-mode="text"&gt;const struct device *i2c_dev = DEVICE_DT_GET(DT_NODELABEL(i2cXXX)); 

if (i2c_transfer(i2c_dev, msgs, num, addr) &amp;lt; 0) {
    i2c_recover_bus(i2c_dev);
}&lt;/pre&gt;&lt;/p&gt;
&lt;div&gt;&lt;/div&gt;
&lt;p&gt;That should be it. No nrfx calls, no manual disable/enable. The Zephyr wrapper handles peripheral disable, pin recovery, pinctrl restore, and re-enable for you.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item></channel></rss>