<?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>SPI read and write</title><link>https://devzone.nordicsemi.com/f/nordic-q-a/19683/spi-read-and-write</link><description>Dose this capture from the Nordic Specification means that to read bytes from SPI i need to send before. Each byte i send i get a byte!!!
MLy case i have read only sensor that sends periodically. If it is mandatory to send in order to receive so i have</description><dc:language>en-US</dc:language><generator>Telligent Community 13</generator><lastBuildDate>Wed, 15 Feb 2017 13:19:16 GMT</lastBuildDate><atom:link rel="self" type="application/rss+xml" href="https://devzone.nordicsemi.com/f/nordic-q-a/19683/spi-read-and-write" /><item><title>RE: SPI read and write</title><link>https://devzone.nordicsemi.com/thread/76569?ContentTypeID=1</link><pubDate>Wed, 15 Feb 2017 13:19:16 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:48cddcb5-adce-41aa-b7a2-5c38cd4cddb5</guid><dc:creator>ToTo</dc:creator><description>&lt;p&gt;Please reply me after reading well what i mention. you just neglect all the important part.&lt;/p&gt;
&lt;ol&gt;
&lt;li&gt;
&lt;p&gt;nrf_spim_task_trigger(&amp;amp;stSPI_iNRF_SPI_Type,NRF_SPIM_TASK_START); is it ok to lunch spi clk and so receive data&lt;/p&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;p&gt;NRF_SPIM_EVENT_ENDRX  is it ok for when having 4 bytes data to be received. Instead of using 4 times the Ready interrupt when a byte is received&lt;/p&gt;
&lt;p&gt;enter code here&lt;/p&gt;
&lt;/li&gt;
&lt;/ol&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: SPI read and write</title><link>https://devzone.nordicsemi.com/thread/76568?ContentTypeID=1</link><pubDate>Wed, 15 Feb 2017 13:14:29 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:1bf40dc1-72d8-4111-b2b0-0fcc0b81c76a</guid><dc:creator>ToTo</dc:creator><description>&lt;p&gt;I am activating interrupt on :&lt;/p&gt;
&lt;p&gt;NRF_SPIM_EVENT_ENDRX&lt;/p&gt;
&lt;p&gt;Which means i get a notify when the buffer is full (4 bytes received).&lt;/p&gt;
&lt;p&gt;I remind you that the same PIN for notifying DATA is ready is the MISO PIN in the AD7780,; so if I will use  interrupt on that PIN I will need to reconfigure each time (1 time each &amp;lt;100ms) ...form SPI MISO to GIOP for interrupt and vice versa !!!&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: SPI read and write</title><link>https://devzone.nordicsemi.com/thread/76573?ContentTypeID=1</link><pubDate>Wed, 15 Feb 2017 11:51:49 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:55fe4da3-8101-4a26-9ba1-ece3b623ca4d</guid><dc:creator>awneil</dc:creator><description>&lt;blockquote&gt;
&lt;p&gt;when the data is ready the RDY is reset. So I have to do check peiodically each 100ms&lt;/p&gt;
&lt;/blockquote&gt;
&lt;p&gt;No, you don&amp;#39;t &lt;strong&gt;&lt;em&gt;have&lt;/em&gt;&lt;/strong&gt; to: that is &lt;strong&gt;one&lt;/strong&gt; approach - but not the &lt;strong&gt;&lt;em&gt;only&lt;/em&gt;&lt;/strong&gt; approach.&lt;/p&gt;
&lt;p&gt;An alternative would be to use an &lt;strong&gt;interrupt&lt;/strong&gt; ...&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: SPI read and write</title><link>https://devzone.nordicsemi.com/thread/76572?ContentTypeID=1</link><pubDate>Wed, 15 Feb 2017 08:57:54 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:e5da3c64-e8d6-4270-83fa-6ad8e50cfe32</guid><dc:creator>ToTo</dc:creator><description>&lt;p&gt;I have another question : i am using the header provided by Nordic &amp;quot;nrf_spim.h&amp;quot; and it give an API it says :&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;nrf_spim_task_trigger(&amp;amp;stSPI_iNRF_SPI_Type,NRF_SPIM_TASK_START);
&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;So TASK start is launching an SPI transaction as in the documentation&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;/**
 * @brief SPIM tasks.
 */
typedef enum
{
    /*lint -save -e30*/
    NRF_SPIM_TASK_START   = offsetof(NRF_SPIM_Type, TASKS_START),   ///&amp;lt; Start SPI transaction.
    NRF_SPIM_TASK_STOP    = offsetof(NRF_SPIM_Type, TASKS_STOP),    ///&amp;lt; Stop SPI transaction.
    NRF_SPIM_TASK_SUSPEND = offsetof(NRF_SPIM_Type, TASKS_SUSPEND), ///&amp;lt; Suspend SPI transaction.
    NRF_SPIM_TASK_RESUME  = offsetof(NRF_SPIM_Type, TASKS_RESUME)   ///&amp;lt; Resume SPI transaction.
    /*lint -restore*/
} nrf_spim_task_t;
&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;When you launch a transaction dose it launch clk ???&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: SPI read and write</title><link>https://devzone.nordicsemi.com/thread/76571?ContentTypeID=1</link><pubDate>Wed, 15 Feb 2017 08:52:24 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:84fd06f8-f696-425c-87c7-9bf063ddda7c</guid><dc:creator>ToTo</dc:creator><description>&lt;p&gt;Hi , thanks for you reaction. I am using AD7780.  It is an ADC that you fixed in such frequency and do measures periodically. It works with SPI and It has 2 lines : CLK and MISO/RDY. It dose a conversion each 100ms and when the data is ready the RDY is reset. So I have to do check peiodically each 100ms is DRDY which is the same MISO if it is low and then if it is , I start reading (do SPI read) .
I don&amp;#39;t need here MOSI . I need only MISO because the AD7780 is read only peripheral.
Any Idea  ?&lt;br /&gt;
I insist again, I don&amp;#39;t need to send data to the AD7780 to get information back,  it is sending periodically..&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: SPI read and write</title><link>https://devzone.nordicsemi.com/thread/76570?ContentTypeID=1</link><pubDate>Tue, 14 Feb 2017 10:12:28 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:6f6e5c25-ab2d-49ed-a8ce-f9b6639a10bc</guid><dc:creator>awneil</dc:creator><description>&lt;p&gt;Yes, this &lt;strong&gt;&lt;em&gt;is&lt;/em&gt;&lt;/strong&gt; a typical implementation - not just some strange Nordic &amp;quot;funny&amp;quot;.&lt;/p&gt;
&lt;p&gt;This is because the SPI clock is always generated by the Master and, typically, the way to get the Master  to generate its clock is to send something.&lt;/p&gt;
&lt;p&gt;&lt;a href="https://en.wikipedia.org/wiki/Serial_Peripheral_Interface_Bus#Data_transmission"&gt;en.wikipedia.org/.../Serial_Peripheral_Interface_Bus&lt;/a&gt;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: SPI read and write</title><link>https://devzone.nordicsemi.com/thread/76567?ContentTypeID=1</link><pubDate>Tue, 14 Feb 2017 10:05:22 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:238aaa69-0af2-4474-8ad8-54e36bed2a9d</guid><dc:creator>J&amp;#248;rgen Holmefjord</dc:creator><description>&lt;p&gt;Hi,&lt;/p&gt;
&lt;p&gt;SPI is typically implemented using shift registers, meaning that data is clocked out of the master shift register and into the slave register through the MOSI line, and similarly, out of the slave shift register and into the master register through the MISO line.&lt;/p&gt;
&lt;p&gt;In theory, you should be able to clock in the data through the MISO line without having the MOSI line connected. You are still required to &amp;quot;send&amp;quot; dummy data from the master, to make the clock run.&lt;/p&gt;
&lt;p&gt;This operation will depend on your sensor. Could you provide details on the device? Then I might be able to help you with your setup.&lt;/p&gt;
&lt;p&gt;Best regards,&lt;/p&gt;
&lt;p&gt;Jørgen&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item></channel></rss>