<?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 : Is there a Nordic sample app that uses twi_hw_master.c</title><link>https://devzone.nordicsemi.com/f/nordic-q-a/919/twi-is-there-a-nordic-sample-app-that-uses-twi_hw_master-c</link><description>I have implemented my own I2C driver and I am getting issues with NACKs.
On review my code is doing what twi_hw_master.c is doing. 
 I then went looking for a Nordic sample app that uses twi_hw_master.c 
 Could not find it in obvious places. 
 Does</description><dc:language>en-US</dc:language><generator>Telligent Community 13</generator><lastBuildDate>Sun, 17 Nov 2013 11:47:30 GMT</lastBuildDate><atom:link rel="self" type="application/rss+xml" href="https://devzone.nordicsemi.com/f/nordic-q-a/919/twi-is-there-a-nordic-sample-app-that-uses-twi_hw_master-c" /><item><title>RE: TWI : Is there a Nordic sample app that uses twi_hw_master.c</title><link>https://devzone.nordicsemi.com/thread/4440?ContentTypeID=1</link><pubDate>Sun, 17 Nov 2013 11:47:30 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:4c484b61-2d4a-434e-a2c2-e8b91affb6c0</guid><dc:creator>Mahendra Tailor</dc:creator><description>&lt;p&gt;The attached scope traces show what I mean about the ACK from the slave after the address is sent not going down low enough.&lt;/p&gt;
&lt;p&gt;&lt;img src="https://devzone.nordicsemi.com/cfs-file/__key/communityserver-discussions-components-files/4/I2C_5F00_Read_5F00_Using_5F00_MyOwnDriverUsingTWIperipheral.jpg" alt="I2C_Read_Using_MyOwnDriverUsingTWIperipheral.jpg" /&gt;&lt;/p&gt;
&lt;p&gt;&lt;img src="https://devzone.nordicsemi.com/cfs-file/__key/communityserver-discussions-components-files/4/I2C_5F00_Read_5F00_Using_5F00_sd_5F00_twi_5F00_hw_5F00_master.jpg" alt="I2C_Read_Using_sd_twi_hw_master.jpg" /&gt;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: TWI : Is there a Nordic sample app that uses twi_hw_master.c</title><link>https://devzone.nordicsemi.com/thread/4438?ContentTypeID=1</link><pubDate>Sun, 17 Nov 2013 11:43:53 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:f88df270-87c5-42cf-b885-53853ad1a7e9</guid><dc:creator>Bastiaan</dc:creator><description>&lt;p&gt;I incorporated twi_hw_master.c in my app and it works.
That code polls the EVENT_TXDSENT bit&lt;/p&gt;
&lt;p&gt;My own code, seems to do all the same preperation work but instead of polling EVENT_TXDSENT it enables irq and then waits for a flag that the irq handle sets.&lt;/p&gt;
&lt;p&gt;In my irq scheme the ACK from the slave is not going down low enough implying that the S0D1 is not functioning when the address is written.&lt;/p&gt;
&lt;p&gt;I must be doing something wrong but cannot understand what.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: TWI : Is there a Nordic sample app that uses twi_hw_master.c</title><link>https://devzone.nordicsemi.com/thread/4439?ContentTypeID=1</link><pubDate>Sun, 17 Nov 2013 11:43:53 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:8d113063-b188-4d5f-89db-38c91577b52e</guid><dc:creator>Guest</dc:creator><description>&lt;p&gt;I incorporated twi_hw_master.c in my app and it works.
That code polls the EVENT_TXDSENT bit&lt;/p&gt;
&lt;p&gt;My own code, seems to do all the same preperation work but instead of polling EVENT_TXDSENT it enables irq and then waits for a flag that the irq handle sets.&lt;/p&gt;
&lt;p&gt;In my irq scheme the ACK from the slave is not going down low enough implying that the S0D1 is not functioning when the address is written.&lt;/p&gt;
&lt;p&gt;I must be doing something wrong but cannot understand what.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: TWI : Is there a Nordic sample app that uses twi_hw_master.c</title><link>https://devzone.nordicsemi.com/thread/4437?ContentTypeID=1</link><pubDate>Sat, 16 Nov 2013 12:43:46 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:72932551-4f70-4463-9218-7eb4fa162761</guid><dc:creator>Mahendra Tailor</dc:creator><description>&lt;p&gt;Hi&lt;/p&gt;
&lt;p&gt;When I write data to a slave using the TWI peripheral (my driver based on code from twi_hw_master.c) the ACK from the slave does not go all the way down to the same level as when I read and the nrf is ACKing the data to the slave.&lt;/p&gt;
&lt;p&gt;In desperation, I have changed my code so that it calls the helper functions in twi_sw_master.c and this time I see that the ACK from the same slave goes down as low as an ACK from the nrf.&lt;/p&gt;
&lt;p&gt;My next step is take twi_hw_master.c and use helper functions in there and see if I see any changed behaviour. I still cannot find any Nordic sample apps that use twi_hw_master.c&lt;/p&gt;
&lt;p&gt;Will keep you updated.&lt;/p&gt;
&lt;p&gt;I wonder why Nordic provided twi_sw_master.c which bit-bangs in the first place !!&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: TWI : Is there a Nordic sample app that uses twi_hw_master.c</title><link>https://devzone.nordicsemi.com/thread/4435?ContentTypeID=1</link><pubDate>Sat, 16 Nov 2013 11:16:57 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:24e6e1ce-bb29-44e1-8d9b-2b1a72a213eb</guid><dc:creator>Bastiaan</dc:creator><description>&lt;p&gt;Is there a way of uploading a screen snapshot of a scope?
What I see is that when I read 4 bytes from a slave, the ack from the slave does not go all the way down as far as when the ack&amp;#39;s are sent by the master for the read bytes.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: TWI : Is there a Nordic sample app that uses twi_hw_master.c</title><link>https://devzone.nordicsemi.com/thread/4436?ContentTypeID=1</link><pubDate>Sat, 16 Nov 2013 11:16:57 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:10ec2761-7800-4b4f-95cc-ccfa9765b63c</guid><dc:creator>Guest</dc:creator><description>&lt;p&gt;Is there a way of uploading a screen snapshot of a scope?
What I see is that when I read 4 bytes from a slave, the ack from the slave does not go all the way down as far as when the ack&amp;#39;s are sent by the master for the read bytes.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item></channel></rss>