<?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>Dynamically changing of Power level</title><link>https://devzone.nordicsemi.com/f/nordic-q-a/57119/dynamically-changing-of-power-level</link><description>Hello, 
 
 I am using nRF52840, SDK_16.0.0, SoftDevice S140 V7.0.1 and Segger for flashing the image. I am using ‘ble_app_blinky’. 
 
 I want to send packet with different Tx power levels over serial interface. I am using sd_ble_gap_tx_power_set() to</description><dc:language>en-US</dc:language><generator>Telligent Community 13</generator><lastBuildDate>Wed, 29 Jan 2020 09:15:02 GMT</lastBuildDate><atom:link rel="self" type="application/rss+xml" href="https://devzone.nordicsemi.com/f/nordic-q-a/57119/dynamically-changing-of-power-level" /><item><title>RE: Dynamically changing of Power level</title><link>https://devzone.nordicsemi.com/thread/231562?ContentTypeID=1</link><pubDate>Wed, 29 Jan 2020 09:15:02 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:248da168-087a-4a05-96a9-d74d4749058d</guid><dc:creator>beemavishnu</dc:creator><description>&lt;p&gt;Thank you Simon for your inputs.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Dynamically changing of Power level</title><link>https://devzone.nordicsemi.com/thread/231561?ContentTypeID=1</link><pubDate>Wed, 29 Jan 2020 08:02:24 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:0a378644-629b-428f-b2d6-59916f2ac40b</guid><dc:creator>Simonr</dc:creator><description>&lt;p&gt;Hi Vishnu&lt;/p&gt;
&lt;p&gt;1. It should be possible to call sd_ble_gap_tx_power_set() in a connection and update it without disconnecting, but we don&amp;#39;t have any examples doing so I&amp;#39;m afraid, so you&amp;#39;ll have to implement that yourself. You can see a suggestion from my colleague &lt;a href="https://devzone.nordicsemi.com/f/nordic-q-a/48071/dynamic-tx-power-when-connected/190428#190428"&gt;here&lt;/a&gt;.&lt;/p&gt;
&lt;p&gt;2. If you want to change the TX power while in a connection you should just have to use BLE_GAP_TX_POWER_ROLE_CONN as that is the parameter updating the TX power when you&amp;#39;re in a connection.&lt;/p&gt;
&lt;p&gt;Best regards,&lt;/p&gt;
&lt;p&gt;Simon&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Dynamically changing of Power level</title><link>https://devzone.nordicsemi.com/thread/231560?ContentTypeID=1</link><pubDate>Tue, 28 Jan 2020 14:46:58 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:c29e2a0d-dc8c-4e89-ba8e-4e96fb02dd9c</guid><dc:creator>beemavishnu</dc:creator><description>&lt;p&gt;Hi Simon,&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;
&lt;p&gt;1) Your understanding is correct and even I implemented serial interface. My only query is based on current BLE state (Connected or Not-Connected whether can I call &lt;span&gt;sd_ble_gap_tx_power_set() dynamically (Whenever command receives over serial interface).&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span&gt;2) Also based on BLE state do I need to call sd_ble_gap_tx_power_set() using BLE_GAP_TX_POWER_ROLE_ADV and&amp;nbsp;BLE_GAP_TX_POWER_ROLE_CONN.&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span&gt;Thanks &amp;amp; Regards&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span&gt;Vishnu Beema&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span&gt;&lt;/span&gt;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Dynamically changing of Power level</title><link>https://devzone.nordicsemi.com/thread/231559?ContentTypeID=1</link><pubDate>Tue, 28 Jan 2020 14:34:49 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:99c9dc0c-bfe9-4dcd-b01d-721a1e9d526a</guid><dc:creator>Simonr</dc:creator><description>&lt;p&gt;Hi&lt;/p&gt;
&lt;p&gt;I&amp;#39;m sorry, but I&amp;#39;m struggling to see what you want to do here. Do you want the nRF52 to change the TX power whenever a serial command (over UART, SPI, or TWI for example) is received? I don&amp;#39;t think we have an example doing such a thing, but you should be able to make a command trigging the sd_ble_gap_tx_power_set() command. You can check out the &lt;a href="https://infocenter.nordicsemi.com/topic/sdk_nrf5_v16.0.0/uart_example.html"&gt;UART peripheral example&lt;/a&gt; which makes the device print &amp;quot;Exit!&amp;quot; and do nothing if q or Q is received over UART.&lt;/p&gt;
&lt;p&gt;Best regards,&lt;/p&gt;
&lt;p&gt;Simon&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item></channel></rss>