<?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 ChangeTimingRequest</title><link>https://devzone.nordicsemi.com/f/nordic-q-a/10191/nrf8001-changetimingrequest</link><description>The ble-sdk-arduino UART examples (and others?) have a rather convoluted scheme to delay the ChangeTimingRequest until after an ACI_EVT_PIPE_STATUS event indicates that the Pipe is open. 
 The &amp;quot;System command/System event operating mode dependency&amp;quot; table</description><dc:language>en-US</dc:language><generator>Telligent Community 13</generator><lastBuildDate>Tue, 15 Dec 2015 12:05:42 GMT</lastBuildDate><atom:link rel="self" type="application/rss+xml" href="https://devzone.nordicsemi.com/f/nordic-q-a/10191/nrf8001-changetimingrequest" /><item><title>RE: nRF8001 ChangeTimingRequest</title><link>https://devzone.nordicsemi.com/thread/37794?ContentTypeID=1</link><pubDate>Tue, 15 Dec 2015 12:05:42 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:35164b9a-d893-4236-a00b-3586ee532003</guid><dc:creator>awneil</dc:creator><description>&lt;p&gt;There seems to be another flaw in this approach (or, rather, the SDK implementation of it):&lt;/p&gt;
&lt;p&gt;Occasionally, I see an &amp;quot;unsolicited&amp;quot; Timing Event before (all of) the PipeStatus events have been received to indicate that all the Pipes are available for use; ie, before the ChangeTimingRequest has been issued.&lt;/p&gt;
&lt;p&gt;The SDK code sees this event, and assumes that it is the result of the ChangeTimingRequest - but it isn&amp;#39;t!&lt;/p&gt;
&lt;p&gt;So the SDK code starts transmitting before the Pipe is ready - causing Pipe Error 96 (Pipe State Invalid).&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: nRF8001 ChangeTimingRequest</title><link>https://devzone.nordicsemi.com/thread/37792?ContentTypeID=1</link><pubDate>Fri, 13 Nov 2015 13:19:15 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:5e9c442f-5c07-498a-8b67-61ed75bc64c2</guid><dc:creator>awneil</dc:creator><description>&lt;p&gt;Ah - I see.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: nRF8001 ChangeTimingRequest</title><link>https://devzone.nordicsemi.com/thread/37791?ContentTypeID=1</link><pubDate>Fri, 13 Nov 2015 12:33:20 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:2a0729e0-ebca-4d3c-950e-2216879516c9</guid><dc:creator>run_ar</dc:creator><description>&lt;p&gt;The initiator is the central device. So during service discovery we normally use the connection parameters set by the master/central device, not the parameters used by nRFgo studio.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: nRF8001 ChangeTimingRequest</title><link>https://devzone.nordicsemi.com/thread/37790?ContentTypeID=1</link><pubDate>Fri, 13 Nov 2015 12:29:28 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:1528f585-e44d-44d0-af5b-6f4de30624f3</guid><dc:creator>awneil</dc:creator><description>&lt;p&gt;Isn&amp;#39;t that what I said?&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: nRF8001 ChangeTimingRequest</title><link>https://devzone.nordicsemi.com/thread/37789?ContentTypeID=1</link><pubDate>Fri, 13 Nov 2015 12:25:24 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:3292f1e8-10ab-4843-8bbf-3dcb5b750dcf</guid><dc:creator>run_ar</dc:creator><description>&lt;p&gt;No, when the connection is initialized the connection parameters are sent from the initiator in the connection request. Normally the peripheral would then check these parameters to see if they are suitable. If they are not, you can send a connection parameter update request using one of the two functions in lib_aci. One where you define the parameters when calling the function and one where us use the Peripheral Preferred Connection Parameters (this is the values you set in nRFgo studio).&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: nRF8001 ChangeTimingRequest</title><link>https://devzone.nordicsemi.com/thread/37788?ContentTypeID=1</link><pubDate>Fri, 13 Nov 2015 09:07:54 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:3a723424-a8ee-40cb-84e6-d835b0e93405</guid><dc:creator>awneil</dc:creator><description>&lt;p&gt;Taking this a little further:&lt;/p&gt;
&lt;p&gt;When the device first connects, I guess it uses the timing as configured in nRFgo studio?
So the settings in nRFgo studio should be &amp;quot;optimised&amp;quot; for the Service Discovery?&lt;/p&gt;
&lt;p&gt;And the ChangeTimingRequest is then used to set timings appropriate to the actual operational requirements of the  &lt;em&gt;application&lt;/em&gt;?&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: nRF8001 ChangeTimingRequest</title><link>https://devzone.nordicsemi.com/thread/37793?ContentTypeID=1</link><pubDate>Thu, 12 Nov 2015 21:37:53 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:24cec3dd-e00e-400a-bb1d-184015c850d7</guid><dc:creator>awneil</dc:creator><description>&lt;p&gt;Great - thanks.&lt;/p&gt;
&lt;p&gt;It would be useful if these things were noted in the code.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: nRF8001 ChangeTimingRequest</title><link>https://devzone.nordicsemi.com/thread/37787?ContentTypeID=1</link><pubDate>Thu, 12 Nov 2015 19:58:15 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:a46ea181-ae0b-4b3b-bd62-8a18a09c8558</guid><dc:creator>run_ar</dc:creator><description>&lt;p&gt;There are two reasons for this implementation.
First we didn&amp;#39;t want to change the timing parameters until after the service discovery procedure completed, and waiting until notifications are enabled (will result in the pipe status event) ensures this. The reason we wanted to wait is that we usually use slower parameters after the update procedure, and we have the same scheme for most/all examples.&lt;/p&gt;
&lt;p&gt;The second reason (if I remember correctly) was that iOS wasn&amp;#39;t to found of connection parameter update requests being sent to soon after the connection was established. This could in some cases lead to the connection being terminated (I don&amp;#39;t remember the exact details).&lt;/p&gt;
&lt;p&gt;Unfortunately there is one problem with this scheme. In case you reconnect to a already bonded device, the bonded device will assume the peer keeps the state of it&amp;#39;s CCCD&amp;#39;s (as per spec), so we don&amp;#39;t necessarily get the pipe status event. So there is a risk the connection parameters might not get updated. A better implementation could be to simply check the timing given when the connection was established and use a timer to trigger the Connection parameter update request.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item></channel></rss>