<?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>TWI NRFX problem</title><link>https://devzone.nordicsemi.com/f/nordic-q-a/50797/twi-nrfx-problem</link><description>Hello. I have a problem with enabling nrfx module. I get this error during prohect compilation: &amp;#39;NRFX_TWI0_INST_IDX&amp;#39; undeclared here (not in a function); did you mean &amp;#39;NRFX_TWI_INSTANCE&amp;#39;? I&amp;#39;ve included in project: nrf_drv_twi.c, nrfx_twi.c, nrfx_twim</description><dc:language>en-US</dc:language><generator>Telligent Community 13</generator><lastBuildDate>Mon, 12 Aug 2019 06:30:41 GMT</lastBuildDate><atom:link rel="self" type="application/rss+xml" href="https://devzone.nordicsemi.com/f/nordic-q-a/50797/twi-nrfx-problem" /><item><title>RE: TWI NRFX problem</title><link>https://devzone.nordicsemi.com/thread/203468?ContentTypeID=1</link><pubDate>Mon, 12 Aug 2019 06:30:41 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:32979fa6-d9db-4909-8f21-78bded233c27</guid><dc:creator>Ars Morozov</dc:creator><description>&lt;p&gt;The problem is solved. The problem is that I call&amp;nbsp;&lt;span&gt;NRFX_TWI_INSTANCE instead NRFX_TWIM_INSTANCE. So, if you want use twi with dma, you should use nrfx_twim driver. It&amp;#39;s easy to forget when you look on examples/peripheral and trying to chagne it from nrf_drv to nrfx. In sdk_config.h I&amp;#39;ve disable nrfx_twi, and left enabled only nrfx_twim and twi, use easydma. Also, I&amp;#39;ve removed nrf_twi.c from project. Anyway, can you answer on my previous questions:&lt;/span&gt;&lt;/p&gt;
[quote userid="67850" url="~/f/nordic-q-a/50797/twi-nrfx-problem/203328"]Regarding what you&amp;#39;re are talking about file &amp;quot;apply_old_config.h&amp;quot;. Do I need this file if I want to use only new drivers nrfx? If yes, so for what?[/quote]
&lt;p&gt;&lt;span&gt;&lt;/span&gt;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: TWI NRFX problem</title><link>https://devzone.nordicsemi.com/thread/203328?ContentTypeID=1</link><pubDate>Fri, 09 Aug 2019 13:14:22 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:4a1e0f76-97d6-484c-96c1-fdd9b9e38850</guid><dc:creator>Ars Morozov</dc:creator><description>&lt;p&gt;Hi. Thanks for the answer. It seems that I already read this thread. For me it&amp;#39;s not clear what do you want to see from my &amp;quot;sdk_config.h&amp;quot; file. I attached full file.&lt;a href="https://devzone.nordicsemi.com/cfs-file/__key/communityserver-discussions-components-files/4/6180.sdk_5F00_config.h"&gt;devzone.nordicsemi.com/.../6180.sdk_5F00_config.h&lt;/a&gt;&lt;br /&gt;As I&amp;#39;ve showed in main post of this thread I&amp;#39;ve enabled old driver (TWI_ENABLE...) and enabled new nrfx driver (NRFX_TWI..), but NRFX_TWI_INST_ID0 still undefined.&amp;nbsp;&lt;br /&gt;&lt;br /&gt;Regarding what you&amp;#39;re are talking about file &amp;quot;apply_old_config.h&amp;quot;. Do I need this file if I want to use only new drivers nrfx? If yes, so for what?&lt;br /&gt;&lt;br /&gt;I also want to stress, that I previously have the same problem for timer and for pwm drivers, but when I enable, together with new nrfx defines, old defines of this drivers in sdk_config.h&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: TWI NRFX problem</title><link>https://devzone.nordicsemi.com/thread/203297?ContentTypeID=1</link><pubDate>Fri, 09 Aug 2019 12:10:42 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:9b214234-fbe9-4bff-81f3-bbe578789411</guid><dc:creator>Einar Thorsrud</dc:creator><description>&lt;p&gt;Hi,&lt;/p&gt;
&lt;p&gt;NRFX_TWI0_INST_IDX&amp;nbsp;is made by the&amp;nbsp;NRFX_TWI_INSTANCE macro based on the configuration in sdk_config.h. I cannot say for sure without knowing more about your code and your full sdk_config.h.&lt;/p&gt;
&lt;p&gt;A typical issue&amp;nbsp;if you want to use nrfx directly is that the configuration macros are being replaced by the legacy driver configuration if it is also present in sdk_config.h. (This is done by&amp;nbsp;apply_old_config.h - see &lt;a href="https://devzone.nordicsemi.com/f/nordic-q-a/34317/undefined-reference-to-nrfx_twi_tx/"&gt;this thread&lt;/a&gt; for details). The simplest (and therefore best) solution in most cases is to use the legacy drives and the legacy driver configuration macros in sdk_config.h.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: TWI NRFX problem</title><link>https://devzone.nordicsemi.com/thread/203200?ContentTypeID=1</link><pubDate>Fri, 09 Aug 2019 06:12:23 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:c72ae31e-28b9-4b39-a5b5-5c1e4406afee</guid><dc:creator>Ars Morozov</dc:creator><description>&lt;p&gt;&lt;img src="https://devzone.nordicsemi.com/resized-image/__size/320x240/__key/communityserver-discussions-components-files/4/pastedimage1565331135198v1.png" alt=" " /&gt;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: TWI NRFX problem</title><link>https://devzone.nordicsemi.com/thread/203173?ContentTypeID=1</link><pubDate>Thu, 08 Aug 2019 21:47:22 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:32e27f25-3e5b-407a-aa76-697a6931a1ad</guid><dc:creator>BinderT</dc:creator><description>&lt;p&gt;This looks like a missing .h file.&lt;br /&gt;&lt;br /&gt;Please post hole your compiler output as a code snippit. Easier to find what&amp;#39;s missing.&lt;br /&gt;&lt;br /&gt;&lt;img alt=" " src="https://devzone.nordicsemi.com/resized-image/__size/320x240/__key/communityserver-discussions-components-files/4/insert-code.jpg" /&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item></channel></rss>