<?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>nrf8001 reset</title><link>https://devzone.nordicsemi.com/f/nordic-q-a/11829/nrf8001-reset</link><description>BobLouwe.logicdata Hi devs, 
 I&amp;#39;m setting up my own .NET mircro framework stack for the Adafruit nRF8001 Break Out board. When write the Reset port I do get an interrupt on the Ready port, but when I start reading from the SPI I getting all 0xFF. When</description><dc:language>en-US</dc:language><generator>Telligent Community 13</generator><lastBuildDate>Sat, 20 Feb 2016 21:11:45 GMT</lastBuildDate><atom:link rel="self" type="application/rss+xml" href="https://devzone.nordicsemi.com/f/nordic-q-a/11829/nrf8001-reset" /><item><title>RE: nrf8001 reset</title><link>https://devzone.nordicsemi.com/thread/44773?ContentTypeID=1</link><pubDate>Sat, 20 Feb 2016 21:11:45 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:6c926598-6690-40c0-83f0-6a08b22e190a</guid><dc:creator>Bob Louwe</dc:creator><description>&lt;p&gt;I did some research on the SPI  clock signal on .NET micro framework. There is a parameter on the SPI configuation that specifies to hold the line low or high between byte exchange. This parameter is not used for the initial state of the clock line. The default will let the initial state to high. What I did was sending a byte (f.e. 0x00) before the reset. I added to capture file. And now I get the DeviceStartedEvent with no prior strange data. Thanks. Problem solved!&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: nrf8001 reset</title><link>https://devzone.nordicsemi.com/thread/44774?ContentTypeID=1</link><pubDate>Fri, 19 Feb 2016 08:42:11 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:9c763ae7-d0c9-4c36-88e7-afad7c991a58</guid><dc:creator>run_ar</dc:creator><description>&lt;p&gt;As far as I can see from your logic trace you get the device started event after re-asserting the reqn line. The data you get before that doesn&amp;#39;t make much sense to me, but you should make sure the clk line is low prior to lowering REQN. Please try this and let me know how that goes.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: nrf8001 reset</title><link>https://devzone.nordicsemi.com/thread/44772?ContentTypeID=1</link><pubDate>Thu, 18 Feb 2016 10:36:30 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:2b057de2-c446-4b33-b421-0521d001e9ba</guid><dc:creator>Bob Louwe</dc:creator><description>&lt;p&gt;I have uploaded the capture file and resolved the problem. I just ignore the (first) events when it is not valid (length byte should be &amp;lt; 32). Furthermore I changed my interrupt handling routine. I disabled the interrupt when in the routine. Now I leave it unchanged. So, I do now get a valid DeviceStartedEvent.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: nrf8001 reset</title><link>https://devzone.nordicsemi.com/thread/44771?ContentTypeID=1</link><pubDate>Wed, 17 Feb 2016 13:48:33 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:242de5fe-d9df-4e2f-8efd-46bfda491030</guid><dc:creator>Bob Louwe</dc:creator><description>&lt;p&gt;Sorry, I mislabeled the MOSI. It should be MISO. So, what you see is that I get 0x00 and then a 0x82 (assuming LSB). I will connect both data lines to the Logic Anlyzer, which is btw a really amazing device. I will get back to you asap with the capture file (I am not in the office right now).&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: nrf8001 reset</title><link>https://devzone.nordicsemi.com/thread/44770?ContentTypeID=1</link><pubDate>Wed, 17 Feb 2016 13:26:18 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:d60c7637-c2cc-4230-876c-7e404122e62b</guid><dc:creator>run_ar</dc:creator><description>&lt;p&gt;I cannot see the MISO line in. Could you upload the actual file? I see data being transmitted on MOSI. Could you wait with this until after you have received the device started event.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: nrf8001 reset</title><link>https://devzone.nordicsemi.com/thread/44769?ContentTypeID=1</link><pubDate>Wed, 17 Feb 2016 10:46:19 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:c50d9c86-e6bf-4076-b842-01bb1228bc7b</guid><dc:creator>Bob Louwe</dc:creator><description>&lt;p&gt;I have added the capture file. This is the scenario where I pull the reset high and I get the 0x00 and 0x82. I still have to test when I pull it low.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: nrf8001 reset</title><link>https://devzone.nordicsemi.com/thread/44768?ContentTypeID=1</link><pubDate>Wed, 17 Feb 2016 07:00:46 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:4b5b4404-9394-4ae4-8421-4048ceca71fb</guid><dc:creator>run_ar</dc:creator><description>&lt;p&gt;So, how are you doing? I would recommend that you continue using your logic analyzer to debug this. Check that you see the same data here as on your application mcu. If you upload the capture file I could take a look at it as well. Unfortunately you cannot upload pictures in the comment, but you can upload pictures in the question itself.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: nrf8001 reset</title><link>https://devzone.nordicsemi.com/thread/44767?ContentTypeID=1</link><pubDate>Mon, 15 Feb 2016 21:26:44 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:7a93f1ed-8abd-42a5-af62-4fa0804df57e</guid><dc:creator>Bob Louwe</dc:creator><description>&lt;p&gt;I discovered that I pull the reset high, while I should pull it low for at least 200ns, according to the sheet. I will try that.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: nrf8001 reset</title><link>https://devzone.nordicsemi.com/thread/44766?ContentTypeID=1</link><pubDate>Mon, 15 Feb 2016 14:31:43 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:982c4a54-fe00-455b-bc04-9ead4b1b9169</guid><dc:creator>Bob Louwe</dc:creator><description>&lt;p&gt;I connected a logic analyzer and step-by-step solved my (stupid) mistakes. The biggest issue was that there was no clock signal. This was caused by addressing the wrong SPI module. So the timing issues and the SPI issues are solved, but...
After the reset I read the first two bytes 0x00 and 0x82. According the spec the first byte should be ignored and the second byte is the length and hould be smaller than 31. I expect the DeviiceStartedEvent. Any suggestions?
Is it possible to add a picture to comments?&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: nrf8001 reset</title><link>https://devzone.nordicsemi.com/thread/44765?ContentTypeID=1</link><pubDate>Sun, 14 Feb 2016 15:19:47 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:34030540-b77d-44e4-bd2a-ad3b8421f2ed</guid><dc:creator>Bob Louwe</dc:creator><description>&lt;p&gt;I think the bit order is MSB, so I will reverse the bits.
I do not poll, when I reset I get an interrupt on the RDY line. Should I ignore the interrupt for 50ms and do the sequence you described?&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: nrf8001 reset</title><link>https://devzone.nordicsemi.com/thread/44761?ContentTypeID=1</link><pubDate>Fri, 12 Feb 2016 12:44:53 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:a4e5f652-c440-4097-8ca3-bee97170669b</guid><dc:creator>run_ar</dc:creator><description>&lt;p&gt;ok, as far as I can see Clock phase is ok (rising edge.)&lt;br /&gt;
Frequency is supported (2MHz).&lt;br /&gt;
I assume SpiClockIdleState = false means the clock polarity is zero -&amp;gt; ok.&lt;br /&gt;
What data order do you have? this should be Least significant bit first.&lt;/p&gt;
&lt;p&gt;After resetting the nRF8001 you should wait for it to lower the RDYN line (this is valid after about 50ms (62ms according to ps)). Then pull REQN low and start clocking out the device started event.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: nrf8001 reset</title><link>https://devzone.nordicsemi.com/thread/44764?ContentTypeID=1</link><pubDate>Thu, 11 Feb 2016 13:36:54 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:39cdeffb-e4fd-455d-b9d5-094259c18e6b</guid><dc:creator>Bob Louwe</dc:creator><description>&lt;p&gt;Here is my setup code (.NET MF/C#):&lt;/p&gt;
&lt;p&gt;`
private const bool SpiChipSelectActiveState = true; // set signal to low when accessing chip
private const int SpiChipSelectSetupTime = 0;
private const int SpiChipSelectHoldTime = 0;
private const bool SpiClockIdleState = false; // set signal to low when not accessing chip
private const bool SpiClockEdge = true; // sample data on rising edge
private const int SpiClockRateKHz = 2000;&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;    private InterruptPort _dataReadyPort;
    private const bool DataReadyGlitchFilter = false;

    private OutputPort _resetPort;
    private const bool ResetInitialState = false;

    private OutputPort _reqPort;
    private const bool ReqInitialState = false;

    _spiConfiguration = new SPI.Configuration(Cpu.Pin.GPIO_NONE, SpiChipSelectActiveState, SpiChipSelectSetupTime,
            SpiChipSelectHoldTime, SpiClockIdleState, SpiClockEdge, SpiClockRateKHz, spiModule);

        _resetPort = new OutputPort(resetPin, ResetInitialState);
        _reqPort = new OutputPort(reqPin, ReqInitialState);

        _dataReadyPort = new InterruptPort(dataReadyPin, DataReadyGlitchFilter, Port.ResistorMode.PullUp,
            Port.InterruptMode.InterruptEdgeHigh);
        _dataReadyPort.OnInterrupt += HandleDataReady;
&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;`&lt;/p&gt;
&lt;p&gt;After this code I set the _resetPort high and the HandleDataReady is called. In the HandleDataReady I create the SPI and start reading.
Note that the chip select port is set to GPIO_NONE since the chip select is handled by the _reqPort. All other SpiChipSelect...-parameters should be read as don&amp;#39;t care, I assume.&lt;/p&gt;
&lt;p&gt;I cannot use the &amp;#39;transport layer verification project example&amp;#39; since it is for the Arduino, but I looked at it before.&lt;/p&gt;
&lt;p&gt;Thanks for the support.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: nrf8001 reset</title><link>https://devzone.nordicsemi.com/thread/44763?ContentTypeID=1</link><pubDate>Thu, 11 Feb 2016 12:38:11 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:7d6cd3b5-9ecb-41ad-8e3e-9f236f83a521</guid><dc:creator>run_ar</dc:creator><description>&lt;p&gt;Can you share your spi config? And please check for endianess. Note that there is an &lt;a href="https://github.com/NordicSemiconductor/ble-sdk-arduino/tree/master/libraries/BLE/examples/ble_aci_transport_layer_verification"&gt;transport layer verification project example&lt;/a&gt; that I would recommend you use to test your implementation.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: nrf8001 reset</title><link>https://devzone.nordicsemi.com/thread/44762?ContentTypeID=1</link><pubDate>Thu, 11 Feb 2016 12:37:39 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:fa026524-3511-4fdc-9237-84376451d161</guid><dc:creator>awneil</dc:creator><description>&lt;p&gt;On what are you basing your stack?&lt;/p&gt;
&lt;p&gt;Have you looked at &lt;a href="https://github.com/NordicSemiconductor/ble-sdk-arduino/"&gt;github.com/.../&lt;/a&gt; ?&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item></channel></rss>