<?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>serial interface</title><link>https://devzone.nordicsemi.com/f/nordic-q-a/57891/serial-interface</link><description>Hi, 
 I just started working with Nordic nRF52840 serial interfaces,can you please tell me which one is best for serial communication among SPI and I2c and why?And can you please tell me the regarding hardware connections. 
 
 
 Thanks&amp;amp;Regards, 
 Lakshmi</description><dc:language>en-US</dc:language><generator>Telligent Community 13</generator><lastBuildDate>Wed, 19 Feb 2020 04:25:54 GMT</lastBuildDate><atom:link rel="self" type="application/rss+xml" href="https://devzone.nordicsemi.com/f/nordic-q-a/57891/serial-interface" /><item><title>RE: serial interface</title><link>https://devzone.nordicsemi.com/thread/235043?ContentTypeID=1</link><pubDate>Wed, 19 Feb 2020 04:25:54 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:1fa1337b-ee55-472d-ab36-0805567a5c24</guid><dc:creator>lakshmi123</dc:creator><description>&lt;p&gt;Thank you soo much for your reply.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: serial interface</title><link>https://devzone.nordicsemi.com/thread/234944?ContentTypeID=1</link><pubDate>Tue, 18 Feb 2020 13:46:39 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:28752ed9-422d-4862-9f28-4fe65f59f865</guid><dc:creator>Einar Thorsrud</dc:creator><description>&lt;p&gt;Hi,&lt;/p&gt;
[quote user="lakshmi123"]According to my knowledge SPI can not verify the bits whether it is properly sending or not(like ack),speed wise is SPI ok,[/quote]
&lt;p&gt;You are right that SPI does not implement acknowledgment.&lt;/p&gt;
[quote user="lakshmi123"]And in nordic nRF52840 have 4xmasters and 3xslaves =12 we can connect.[/quote]
&lt;p&gt;I don&amp;#39;t follow your logic. SPI has a concept of chip select, where only the selected slave is active, others are high impedance. So you can use more than one slaves on one bus if needed.&lt;/p&gt;
[quote user="lakshmi123"]in i2c i read total 127 slaves we can connect.then i2c is best may be...please correct me if i assumes wrong.[/quote]
&lt;p&gt;You are right that you theoretically can have 127 slaves on a TWI bus, but that does not seem like a very realistic number for most products.&amp;nbsp;&lt;/p&gt;
&lt;p&gt;If you need to connect a very high number of slave devices with no additional HW, then I2C may be more sensible. But that would be an unusual use case. In any case, you should choose whatever works for your product, just be aware of the differences.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: serial interface</title><link>https://devzone.nordicsemi.com/thread/234632?ContentTypeID=1</link><pubDate>Mon, 17 Feb 2020 12:25:23 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:3c923420-71b0-41b5-960f-f61af02c9fc1</guid><dc:creator>lakshmi123</dc:creator><description>&lt;p&gt;Can you please suggest me.&amp;nbsp;&amp;nbsp;&lt;span&gt;According to my knowledge SPI can not verify the bits whether it is properly sending or not(like ack),speed wise is SPI ok,And in nordic nRF52840 have 4xmasters and 3xslaves =12 we can connect.in i2c i read total 127 slaves we can connect.then i2c is best may be...please correct me if i assumes wrong.&lt;/span&gt;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: serial interface</title><link>https://devzone.nordicsemi.com/thread/234612?ContentTypeID=1</link><pubDate>Mon, 17 Feb 2020 11:27:50 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:0099bd3e-8c6d-49ac-8775-63e02847d004</guid><dc:creator>Einar Thorsrud</dc:creator><description>&lt;p&gt;Hi&amp;nbsp;Lakshmi,&lt;/p&gt;
[quote user=""]which one is best for serial communication among SPI and I2c[/quote]
&lt;p&gt;Often the interface is dictated by what the other components support. However, if you can choose, SPI is usually preferable. This is mainly because SPI has a much higher speed, meaning that the transactions take a shorter time, allowing the nRF to go back to sleep more quickly, thereby saving power.&lt;/p&gt;
[quote user=""]And can you please tell me the regarding hardware connections.[/quote]
&lt;p&gt;Any GPIO on the nRF can have any digital functionality (though you should avoid pins close to the radio, as described under &lt;a href="https://infocenter.nordicsemi.com/topic/ps_nrf52840/pin.html?cp=4_0_0_6_0"&gt;Pin assignments&lt;/a&gt;). There is no difference between which pins can be used for SPI and TWI (I2C).&lt;/p&gt;
&lt;p&gt;Einar&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item></channel></rss>