<?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>What happens on the TWI communication when there is an Interruption</title><link>https://devzone.nordicsemi.com/f/nordic-q-a/77900/what-happens-on-the-twi-communication-when-there-is-an-interruption</link><description>I&amp;#39;m using TWI and BLE functions together. My TWI sensor is operating at 400kHz, low priority. BLE has the highest priority. For example, if nRF52805 is sending commands to the TWI sensor, and it&amp;#39;s been interrupted by BLE. So the TWI sensor doesn&amp;#39;t receive</description><dc:language>en-US</dc:language><generator>Telligent Community 13</generator><lastBuildDate>Tue, 27 Jul 2021 08:43:28 GMT</lastBuildDate><atom:link rel="self" type="application/rss+xml" href="https://devzone.nordicsemi.com/f/nordic-q-a/77900/what-happens-on-the-twi-communication-when-there-is-an-interruption" /><item><title>RE: What happens on the TWI communication when there is an Interruption</title><link>https://devzone.nordicsemi.com/thread/321981?ContentTypeID=1</link><pubDate>Tue, 27 Jul 2021 08:43:28 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:54987356-78f8-4146-91be-6745b8d8b0e4</guid><dc:creator>Kenneth</dc:creator><description>[quote user="StevenW807"]In order to get another sensor measurement, the master needs to re-send the command.[/quote]
&lt;p&gt;Correct.&lt;/p&gt;
[quote user="StevenW807"]I&amp;#39;m new to Nordic nRF52. Do you have any links/tutorials to explaining the&amp;nbsp;&lt;span&gt;EasyDMA?&amp;nbsp;&lt;/span&gt;[/quote]
&lt;p&gt;The twi sensor and twi scanner example in the nRF5 SDK may be good starting points in terms of usage. For documentation you can check out the twi driver and twi documentation:&lt;/p&gt;
&lt;p&gt;&lt;a href="https://infocenter.nordicsemi.com/topic/com.nordic.infocenter.nrf52832.ps.v1.1/twim.html#concept_scx_f5p_xr"&gt;https://infocenter.nordicsemi.com/topic/com.nordic.infocenter.nrf52832.ps.v1.1/twim.html#concept_scx_f5p_xr&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;&lt;a href="https://infocenter.nordicsemi.com/topic/sdk_nrf5_v17.0.2/group__nrfx__twim.html"&gt;https://infocenter.nordicsemi.com/topic/sdk_nrf5_v17.0.2/group__nrfx__twim.html&lt;/a&gt;&amp;nbsp;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: What happens on the TWI communication when there is an Interruption</title><link>https://devzone.nordicsemi.com/thread/321967?ContentTypeID=1</link><pubDate>Tue, 27 Jul 2021 07:49:49 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:f96f65b2-3f8c-4aa5-b31a-bb03faacbc00</guid><dc:creator>StevenW807</dc:creator><description>&lt;p&gt;Excellent explanation, thanks, Kenneth!&amp;nbsp;&lt;/p&gt;
&lt;p&gt;So TWI master (nRF52) sends a command, the TWI slave sensor will return only 1 complete data. In order to get another sensor measurement, the master needs to re-send the command. The salve sensor will NOT return data continuously forever, is that right?&amp;nbsp;&lt;/p&gt;
&lt;p&gt;I&amp;#39;m new to Nordic nRF52. Do you have any links/tutorials to explaining the&amp;nbsp;&lt;span&gt;EasyDMA?&amp;nbsp;&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span&gt;Thank you!&amp;nbsp;&lt;/span&gt;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: What happens on the TWI communication when there is an Interruption</title><link>https://devzone.nordicsemi.com/thread/321939?ContentTypeID=1</link><pubDate>Tue, 27 Jul 2021 06:40:54 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:87d7c5b8-0149-4e7c-a312-5defb6f14931</guid><dc:creator>Kenneth</dc:creator><description>&lt;p&gt;The TWI transfers are typically using EasyDMA (TWIM), which means that only the start may be delayed due to higher interrupt priority may cause the twi call to be delayed in the application. Once started the EasyDMA will tranfer all bytes as configured, even if there are other processing going on, once twi transfer is finished the data reside in RAM ready to be handled in due time.&lt;/p&gt;
&lt;p&gt;In old days before EasyDMA was introduced there could be delays between bytes when interrupted by higher level interrupts, I have not really seen any errors due to this, since there are in any case start and stop conditions on TWI to ensure that the peer know when an entire twi transfer is started and ended.&lt;/p&gt;
&lt;p&gt;Kenneth&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item></channel></rss>