<?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>How to unblock the CPU during connection intervals with S110 v7.1.0?</title><link>https://devzone.nordicsemi.com/f/nordic-q-a/4248/how-to-unblock-the-cpu-during-connection-intervals-with-s110-v7-1-0</link><description>How do I unblock the CPU with the S110 v7.1.0?</description><dc:language>en-US</dc:language><generator>Telligent Community 13</generator><lastBuildDate>Tue, 05 Jul 2016 05:35:59 GMT</lastBuildDate><atom:link rel="self" type="application/rss+xml" href="https://devzone.nordicsemi.com/f/nordic-q-a/4248/how-to-unblock-the-cpu-during-connection-intervals-with-s110-v7-1-0" /><item><title>RE: How to unblock the CPU during connection intervals with S110 v7.1.0?</title><link>https://devzone.nordicsemi.com/thread/15172?ContentTypeID=1</link><pubDate>Tue, 05 Jul 2016 05:35:59 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:cebd6edc-948b-4afd-a94f-26a9be42e273</guid><dc:creator>hawk</dc:creator><description>&lt;p&gt;I use the old SDK 5.2.0  and S110 6.0.0;   I use the app timer to count sec,min,hour(make one time clock), and found that the second of mine  is less  after  i set  an initial sec/min/hour.   how to avoid delay the app timer of old SDK.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: How to unblock the CPU during connection intervals with S110 v7.1.0?</title><link>https://devzone.nordicsemi.com/thread/15170?ContentTypeID=1</link><pubDate>Fri, 30 Oct 2015 14:09:36 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:46819c07-9048-444e-859b-9e9bfc69e07f</guid><dc:creator>Nikolaus Wittenstein</dc:creator><description>&lt;p&gt;Is this still required in SDK 9?&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: How to unblock the CPU during connection intervals with S110 v7.1.0?</title><link>https://devzone.nordicsemi.com/thread/15173?ContentTypeID=1</link><pubDate>Thu, 25 Jun 2015 10:54:59 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:4f179683-7b72-4a67-9d70-a4c69ad4369b</guid><dc:creator>Milan</dc:creator><description>&lt;p&gt;I use SDK v8.0.0 and latest softdevice s110.  Do I need to do this in my code for performance improvements?&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;C:\Program Files (x86)\Nordic Semiconductor\nrf51\bin&amp;gt;nrfjprog --memrd 0x1000005
C --n 4
0x1000005C: FFFF0086                              |....|
&lt;/code&gt;&lt;/pre&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: How to unblock the CPU during connection intervals with S110 v7.1.0?</title><link>https://devzone.nordicsemi.com/thread/15169?ContentTypeID=1</link><pubDate>Fri, 05 Jun 2015 06:27:25 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:c85852bd-7fdd-4f18-9ecd-9b648f5465b6</guid><dc:creator>Hung Bui</dc:creator><description>&lt;p&gt;@Lucas: It&amp;#39;s only safe to unblock the CPU on XLR3. On chip version 2 (QFAAG0) there are some PANs that don&amp;#39;t allow CPU to be concurrent when the softdevice is active. Please have a look at the release note on S110 v8.0 at Changes section.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: How to unblock the CPU during connection intervals with S110 v7.1.0?</title><link>https://devzone.nordicsemi.com/thread/15168?ContentTypeID=1</link><pubDate>Mon, 15 Dec 2014 00:36:57 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:bd71b0c5-416f-4dac-97a1-b294e33da3c7</guid><dc:creator>Lucas</dc:creator><description>&lt;p&gt;I attempted this on two chips:&lt;/p&gt;
&lt;p&gt;nRF51822-QFAAG0&lt;/p&gt;
&lt;p&gt;nRF51822-QFACA1&lt;/p&gt;
&lt;p&gt;In both cases I saw performance increases. Similar to what you showed above it isn&amp;#39;t perfect. The CPU does block occasionally regardless of if CPU blocking is disabled. I was under the impression that this would only improve performance for hardware revision 3. I guess it works for hardware revision 2 as well? Is this expected behavior?&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: How to unblock the CPU during connection intervals with S110 v7.1.0?</title><link>https://devzone.nordicsemi.com/thread/15165?ContentTypeID=1</link><pubDate>Fri, 12 Dec 2014 01:14:47 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:9c71e51e-e61d-4f6c-84c3-c4b557720779</guid><dc:creator>Lucas</dc:creator><description>&lt;p&gt;Is it also required that this be on latest hardware revision?&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: How to unblock the CPU during connection intervals with S110 v7.1.0?</title><link>https://devzone.nordicsemi.com/thread/15171?ContentTypeID=1</link><pubDate>Fri, 07 Nov 2014 12:44:22 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:2cd685d0-e5d3-4246-a12f-1a02754db496</guid><dc:creator>Hung Bui</dc:creator><description>&lt;p&gt;@Jason: It&amp;#39;s an design issue that we don&amp;#39;t have enough memory bandwidth to handle CPU, encryption block, etc at the same time. And we have to block CPU to have enough memory bandwidth.
But it&amp;#39;s fixed now.&lt;/p&gt;
&lt;p&gt;To use the new feature, you would need to use either SDK v7.0 or if you want to use SDK v6.1 you need to update the API header files from S110 v7.1&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: How to unblock the CPU during connection intervals with S110 v7.1.0?</title><link>https://devzone.nordicsemi.com/thread/15167?ContentTypeID=1</link><pubDate>Mon, 03 Nov 2014 15:55:46 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:9c495a91-fc9e-412a-bcf2-1f354a6c1899</guid><dc:creator>Jason</dc:creator><description>&lt;p&gt;I can not found the  &amp;quot;common_opt.radio_cpu_mutex.enable&amp;quot;  in SDK 6.1...&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: How to unblock the CPU during connection intervals with S110 v7.1.0?</title><link>https://devzone.nordicsemi.com/thread/15166?ContentTypeID=1</link><pubDate>Mon, 03 Nov 2014 15:31:21 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:ca4f7b67-d82e-496c-8e07-d7bd2a8fbcdb</guid><dc:creator>Jason</dc:creator><description>&lt;p&gt;Why nRF51 need to block the CPU to wait for Radio ?&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: How to unblock the CPU during connection intervals with S110 v7.1.0?</title><link>https://devzone.nordicsemi.com/thread/15164?ContentTypeID=1</link><pubDate>Thu, 30 Oct 2014 09:18:33 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:c29b5e3e-e59c-4828-96ce-35c8129ff097</guid><dc:creator>H&amp;#229;kon Alseth</dc:creator><description>&lt;p&gt;Hi,&lt;/p&gt;
&lt;p&gt;To disable the CPU blocking with S110 v7.1.0 or newer, you will have to use this API call:&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;/**@brief Set a BLE option.
 *
 * @details This call allows the application to set the value of an option.
 *
 * @param[in] opt_id Option ID.
 * @param[in] p_opt Pointer to a ble_opt_t structure containing the option value.
 *
 * @retval ::NRF_SUCCESS  Option set successfully.
 * @retval ::NRF_ERROR_INVALID_ADDR Invalid pointer supplied.
 * @retval ::BLE_ERROR_INVALID_CONN_HANDLE Invalid Connection Handle.
 * @retval ::NRF_ERROR_INVALID_PARAM Invalid parameter(s) supplied, check parameter limits and constraints.
 * @retval ::NRF_ERROR_INVALID_STATE Unable to set the parameter at this time.
 * @retval ::NRF_ERROR_BUSY The stack is busy or the previous procedure has not completed.
 */
SVCALL(SD_BLE_OPT_SET, uint32_t, sd_ble_opt_set(uint32_t opt_id, ble_opt_t const *p_opt));
&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;The options available as of now is only one, which is the mutual exclusion of radio activity and CPU usage (read block/unblock CPU in connection interval):&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;/**@brief Common Option IDs.
 * IDs that uniquely identify a common option.
 */
enum BLE_COMMON_OPTS
{
  BLE_COMMON_OPT_RADIO_CPU_MUTEX = BLE_OPT_BASE    /**&amp;lt; Radio CPU mutex option. @ref ble_common_opt_radio_cpu_mutex_t */
};
&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;And here&amp;#39;s a small snippet on how to disable the CPU blocking:&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;uint32_t opt_id = BLE_COMMON_OPT_RADIO_CPU_MUTEX;
ble_opt_t cpu_blocking_enabled;
cpu_blocking_enabled.common_opt.radio_cpu_mutex.enable = 0;
ble_stack_init();
err_code = sd_ble_opt_set(opt_id, &amp;amp;cpu_blocking_enabled);
/* continue init */
&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;Cheers,
Håkon&lt;/p&gt;
&lt;p&gt;===============================&lt;/p&gt;
&lt;p&gt;Additional images showing how the CPU availability is improved when advertising (same applies when in connection):&lt;/p&gt;
&lt;p&gt;Before (CPU blocked during radio active):
&lt;img src="https://devzone.nordicsemi.com/cfs-file/__key/communityserver-discussions-components-files/4/CPUblocked.PNG" alt="image description" /&gt;&lt;/p&gt;
&lt;p&gt;After (Concurrent CPU when radio is active):
&lt;img src="https://devzone.nordicsemi.com/cfs-file/__key/communityserver-discussions-components-files/4/concurrent.PNG" alt="image description" /&gt;&lt;/p&gt;
&lt;p&gt;Black part showing the latency when CPU is blocked.
[ADDED]:
On the second trace, the CPU is still blocked at some periods because it&amp;#39;s the softdevice active and preparing the radio packet, no the radio itself.&lt;/p&gt;
&lt;p&gt;Cheers,&lt;/p&gt;
&lt;p&gt;Hung Bui&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item></channel></rss>