<?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>RANG timing spec?</title><link>https://devzone.nordicsemi.com/f/nordic-q-a/25175/rang-timing-spec</link><description>It looks like the random number generator is relative slow as implied by the documents. I wonder if it has been spec&amp;#39;ed some where? Exactly how much time does it take to generate a byte? Or at least some idea of worst case timing? It seems important to</description><dc:language>en-US</dc:language><generator>Telligent Community 13</generator><lastBuildDate>Fri, 15 Sep 2017 08:55:56 GMT</lastBuildDate><atom:link rel="self" type="application/rss+xml" href="https://devzone.nordicsemi.com/f/nordic-q-a/25175/rang-timing-spec" /><item><title>RE: RANG timing spec?</title><link>https://devzone.nordicsemi.com/thread/99182?ContentTypeID=1</link><pubDate>Fri, 15 Sep 2017 08:55:56 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:65754463-7723-4b7f-b8d0-f6c769ca276c</guid><dc:creator>MartinBL</dc:creator><description>&lt;p&gt;As mentioned in the specs &amp;quot;The time [t_RNG,UNI] to generate a byte cannot be guaranteed&amp;quot;. The RNG uses Von Neumann’s debiasing algorithm which compares pairs of bits generated by the RNG and if both values in the pair are the same (&amp;#39;0&amp;#39; or &amp;#39;1&amp;#39;) they are discarded. Hence, there is a probability that you will get long sequences of 0&amp;#39;s or 1&amp;#39;s and that the process will take a (relatively) long time.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: RANG timing spec?</title><link>https://devzone.nordicsemi.com/thread/99183?ContentTypeID=1</link><pubDate>Thu, 14 Sep 2017 16:36:18 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:5dec1870-3ae5-4119-945b-27c0c3a68f06</guid><dc:creator>bluebeam</dc:creator><description>&lt;p&gt;Oh thanks. I didn&amp;#39;t look the electrical spec. I&amp;#39;m using 52832.&lt;/p&gt;
&lt;p&gt;The question is still about the worse case scenario. Can I say if the typical time to generate one byte is 120us, then it&amp;#39;ll take 1.2ms to generate 10 bytes? If occasionally it takes, say 3ms to generate 1 byte then the total time will be so much different. It seems very undeterministic. How should I think about this from deisgn perspective. Particularly I need to do this in between connection interval. A few ms variation will be pretty big impact on design.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: RANG timing spec?</title><link>https://devzone.nordicsemi.com/thread/99181?ContentTypeID=1</link><pubDate>Thu, 14 Sep 2017 11:38:41 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:b0b1d0f9-8da3-4bc9-861c-3194753f6c0e</guid><dc:creator>MartinBL</dc:creator><description>&lt;p&gt;Hi,&lt;/p&gt;
&lt;p&gt;What chip are you looking at? We have numbers for the nRF51 in the Product spec v3.3:&lt;/p&gt;
&lt;p&gt;&lt;img src="https://devzone.nordicsemi.com/cfs-file/__key/communityserver-discussions-components-files/4/dandg.PNG" alt="imgage" /&gt;&lt;/p&gt;
&lt;p&gt;Values for the nRF52 can be found &lt;a href="http://infocenter.nordicsemi.com/topic/com.nordic.infocenter.nrf52832.ps.v1.1/rng.html?cp=2_1_0_25_3_0#unique_55767493"&gt;here&lt;/a&gt;.&lt;/p&gt;
&lt;p&gt;Both chips also have an event register called VALRDY that you can use to get notified for every new random number written to the VALUE register.&lt;/p&gt;
&lt;p&gt;A simple way to use it is like this:&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;while(NRF_RNG-&amp;gt;EVENTS_VALRDY != 1)
{
    // Do nothing, but wait
}
&lt;/code&gt;&lt;/pre&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item></channel></rss>