<?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>nrf52832 Taking power on UART Lines</title><link>https://devzone.nordicsemi.com/f/nordic-q-a/49974/nrf52832-taking-power-on-uart-lines</link><description>nrf52832 is connected to the main controller of the circuit on uart lines (RX and TX). 
 We have observed that even when we completely cut-off the power of nrf52832 then also it does not switch off. And it continues to be and running. And it draws power</description><dc:language>en-US</dc:language><generator>Telligent Community 13</generator><lastBuildDate>Tue, 23 Jul 2019 14:55:10 GMT</lastBuildDate><atom:link rel="self" type="application/rss+xml" href="https://devzone.nordicsemi.com/f/nordic-q-a/49974/nrf52832-taking-power-on-uart-lines" /><item><title>RE: nrf52832 Taking power on UART Lines</title><link>https://devzone.nordicsemi.com/thread/200124?ContentTypeID=1</link><pubDate>Tue, 23 Jul 2019 14:55:10 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:eb82e59f-131d-4838-9e3b-fe89b83ba667</guid><dc:creator>hmolesworth</dc:creator><description>&lt;p&gt;Have a look at this post where we discuss&amp;nbsp;&lt;a href="https://devzone.nordicsemi.com/f/nordic-q-a/32798/nrf52832-io-problem/130207#130207"&gt;phantom power and back-drive&lt;/a&gt;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: nrf52832 Taking power on UART Lines</title><link>https://devzone.nordicsemi.com/thread/200077?ContentTypeID=1</link><pubDate>Tue, 23 Jul 2019 13:17:11 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:d9631776-3e83-4992-ab12-3555a4d125f3</guid><dc:creator>kamran_iosite</dc:creator><description>[quote userid="18353" url="~/f/nordic-q-a/49974/nrf52832-taking-power-on-uart-lines/200064"] turn off external UART interface[/quote]
&lt;p&gt;Do you mean NRF&amp;#39;s UART? How to do this for NRF?&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: nrf52832 Taking power on UART Lines</title><link>https://devzone.nordicsemi.com/thread/200064?ContentTypeID=1</link><pubDate>Tue, 23 Jul 2019 13:04:12 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:43b00ad4-a0d0-4e94-81fa-1180449caf95</guid><dc:creator>johnny</dc:creator><description>&lt;p&gt;maybe just turn off external UART interface and set pin to low&amp;nbsp;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: nrf52832 Taking power on UART Lines</title><link>https://devzone.nordicsemi.com/thread/199997?ContentTypeID=1</link><pubDate>Tue, 23 Jul 2019 10:33:31 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:b980467f-0871-4b06-a7bd-2bfc483b0936</guid><dc:creator>kamran_iosite</dc:creator><description>&lt;p&gt;Yes sure.&amp;nbsp;&lt;/p&gt;
&lt;p&gt;Setup: one nrf52832 Development board.&lt;/p&gt;
&lt;p&gt;Content of main()&lt;/p&gt;
&lt;p&gt;int main(void)&lt;br /&gt;{&lt;br /&gt;&lt;br /&gt; log_init();&amp;nbsp; &amp;nbsp;timer_init();&amp;nbsp; &amp;nbsp;uart_init();&lt;br /&gt; db_discovery_init();&amp;nbsp; power_management_init();&lt;br /&gt; ble_stack_init();&amp;nbsp; &amp;nbsp;gatt_init();&amp;nbsp; nus_c_init();&amp;nbsp; scan_init();&lt;br /&gt; gpio_init();&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;
&lt;p&gt;nrf_gpio_input_disconnect(8); // disconnect RX&lt;br /&gt; nrf_gpio_input_disconnect(6); // &lt;span&gt;disconnect TX&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;
&lt;p&gt;app_timer_init();&lt;br /&gt; app_timer_create(&amp;amp;testtimer,APP_TIMER_MODE_SINGLE_SHOT,timerfunction);&lt;br /&gt;&lt;br /&gt; for (;;)&lt;br /&gt; {&lt;br /&gt; idle_state_handle();&lt;br /&gt; }&lt;br /&gt;}&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;
&lt;p&gt;I have configured an interrupt on PIN 11 and a one-shot timer (of 5 sec ) is started once interrupt is received.&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;
&lt;p&gt;Interrupt callback function:&lt;/p&gt;
&lt;p&gt;void in_pin_handler1(nrf_drv_gpiote_pin_t pin, nrf_gpiote_polarity_t action)&lt;br /&gt;{&lt;br /&gt; nrf_gpio_cfg_watcher(8);&amp;nbsp; &amp;nbsp;// Enable RX&lt;br /&gt; nrf_gpio_cfg_watcher(6);&amp;nbsp; // Enable TX&lt;/p&gt;
&lt;p&gt;printf(&amp;quot;BLE&amp;quot;);&lt;br /&gt; scan_start();&lt;br /&gt; app_timer_start(testtimer, 5*32768, NULL);&lt;br /&gt; &lt;br /&gt;}&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;
&lt;p&gt;Timer callback function:&lt;/p&gt;
&lt;p&gt;static void timerfunction(void * p_context)&lt;br /&gt;{&lt;br /&gt; UNUSED_PARAMETER(p_context);&lt;/p&gt;
&lt;p&gt;&lt;br /&gt; nrf_gpio_input_disconnect(8);&amp;nbsp; &amp;nbsp;&lt;span&gt;//&amp;nbsp;Disconnect RX&lt;/span&gt;&lt;br /&gt; nrf_gpio_input_disconnect(6);&amp;nbsp; &amp;nbsp;&lt;span&gt;//&amp;nbsp;Disconnect&amp;nbsp;TX&lt;/span&gt;&lt;br /&gt;&lt;br /&gt; nrf_ble_scan_stop();&lt;br /&gt; printf(&amp;quot;\r\n&amp;quot;);&lt;br /&gt;}&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;
&lt;p&gt;In the above setup: the UART lines should only active when the timer is running for 5 seconds after receiving interrupts. But the UART lines are always active.&amp;nbsp;&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;
&lt;p&gt;To know the state of UART lines:&lt;/p&gt;
&lt;p&gt;In the function :&lt;/p&gt;
&lt;p&gt;uart_event_handle(app_uart_evt_t * p_event)&lt;/p&gt;
&lt;p&gt;I have included a printf statement.&amp;nbsp; (printf(&amp;quot;uart_event_handle&amp;quot;))&lt;/p&gt;
&lt;p&gt;The above print statement should only get executed while the timer is running but no matter if the timer is running or not, I always get the print statement if i send some data to nrf.&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;
&lt;p&gt;Hope it clarifies the issue&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: nrf52832 Taking power on UART Lines</title><link>https://devzone.nordicsemi.com/thread/199992?ContentTypeID=1</link><pubDate>Tue, 23 Jul 2019 10:20:54 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:40b061b0-b661-4c1e-a844-602e41700337</guid><dc:creator>RK</dc:creator><description>&lt;p&gt;[quote userid="81774" url="~/f/nordic-q-a/49974/nrf52832-taking-power-on-uart-lines/199989"][/quote]&lt;/p&gt;
&lt;p&gt;But it does not work.&lt;/p&gt;
&lt;p&gt;Any suggestions?&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;
&lt;p&gt;Yes I suggest you explain properly what &amp;quot;But it does not work&amp;quot; means.&amp;nbsp;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: nrf52832 Taking power on UART Lines</title><link>https://devzone.nordicsemi.com/thread/199989?ContentTypeID=1</link><pubDate>Tue, 23 Jul 2019 10:16:44 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:e47d9cf7-1849-4ed8-93b5-cc58636805f7</guid><dc:creator>kamran_iosite</dc:creator><description>&lt;p&gt;Hi,&lt;/p&gt;
&lt;p&gt;I want to configure RX and&amp;nbsp;TX as GPIO and then to disconnect the input buffer, I am using the following functions:&lt;/p&gt;
&lt;p&gt;nrf_gpio_cfg_input(rx_pin, NRF_GPIO_PIN_NOPULL);&amp;nbsp; &amp;nbsp;--&amp;gt;&amp;gt; this is to configure as input&lt;/p&gt;
&lt;p&gt;nrf_gpio_input_disconnect(rx_pin);&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;--&amp;gt;&amp;gt; this is used to disconnect the buffer&lt;/p&gt;
&lt;p&gt;nrf_gpio_cfg_watcher(rx_pin);&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; --&amp;gt;&amp;gt; this is used to enable input again on rx and tx lines. it is used when i want to enable the UART lines.&lt;/p&gt;
&lt;p&gt;But it does not work.&lt;/p&gt;
&lt;p&gt;Any suggestions?&lt;/p&gt;
&lt;p&gt;NOTE: earlier I mentioned that I am switching off nrf52832. But now I have dropped that method and the aim here is to disable UART lines after the communication is complete. And&amp;nbsp;enable UART again when needed via an interrupt pin (this interrupt pin I working fine.)&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;
&lt;p&gt;Thanks&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: nrf52832 Taking power on UART Lines</title><link>https://devzone.nordicsemi.com/thread/199323?ContentTypeID=1</link><pubDate>Thu, 18 Jul 2019 13:54:22 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:7e598737-e4cb-4917-99d2-3b14073d69fc</guid><dc:creator>kamran_iosite</dc:creator><description>&lt;p&gt;Thanks,&amp;nbsp;&lt;a href="https://devzone.nordicsemi.com/members/jared"&gt;Jared&lt;/a&gt; and &lt;a href="https://devzone.nordicsemi.com/members/awneil"&gt;awneil&lt;/a&gt;.&lt;/p&gt;
&lt;p&gt;Will implement as suggested and share the feedback here.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: nrf52832 Taking power on UART Lines</title><link>https://devzone.nordicsemi.com/thread/199308?ContentTypeID=1</link><pubDate>Thu, 18 Jul 2019 13:26:57 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:f8ddc737-fb3b-4ef7-a0fd-8a93384b490e</guid><dc:creator>Jared</dc:creator><description>&lt;p&gt;It seems I was too quick on this one, I thought i read sleep instead of turning it OFF. Good that we have a community that reviews our answers ;)&lt;/p&gt;
&lt;p&gt;Well, awneil is&amp;nbsp;correct in pointing out that my previous suggestion won&amp;#39;t work and that the focus should be on the other device.&lt;a href="https://infocenter.nordicsemi.com/topic/com.nordic.infocenter.nrf52832.ps.v1.1/abs_max_ratings.html?cp=3_1_0_4#abs_max_ratings"&gt; I would also like to add that a GPIO pin should never be connected to a voltage that is VDD + 0.3 V.&amp;nbsp;&lt;/a&gt;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: nrf52832 Taking power on UART Lines</title><link>https://devzone.nordicsemi.com/thread/199270?ContentTypeID=1</link><pubDate>Thu, 18 Jul 2019 12:20:27 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:ff588b95-0e02-44fd-9c37-da258b3d406f</guid><dc:creator>awneil</dc:creator><description>&lt;p&gt;No - that won&amp;#39;t work!&lt;/p&gt;
&lt;p&gt;&lt;a href="https://devzone.nordicsemi.com/members/kamran_5f00_iosite"&gt;kamran_iosite&lt;/a&gt; is turning the nRF off - so it is the &lt;em&gt;&lt;strong&gt;other&lt;/strong&gt;&lt;/em&gt; device which needs to have its lines set to an appropriate state!&lt;/p&gt;
&lt;p&gt;Setting them as inputs &lt;em&gt;might&lt;/em&gt; work;&lt;/p&gt;
&lt;p&gt;Setting them low &lt;em&gt;might&lt;/em&gt; work;&lt;/p&gt;
&lt;p&gt;Insufficient information - and not a Nordic issue.&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: nrf52832 Taking power on UART Lines</title><link>https://devzone.nordicsemi.com/thread/199259?ContentTypeID=1</link><pubDate>Thu, 18 Jul 2019 12:01:36 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:9e51fcee-0a37-4572-aeb3-869ba36786e5</guid><dc:creator>Jared</dc:creator><description>&lt;p&gt;Hi,&lt;/p&gt;
&lt;p&gt;The suitable state would be to set the pins that are connected to&amp;nbsp;rx and&amp;nbsp;tx as GPIO Input and disconnect the input buffer.&amp;nbsp; You can do this by writing to the appropriate &lt;a href="https://infocenter.nordicsemi.com/topic/com.nordic.infocenter.nrf52832.ps.v1.1/gpio.html?cp=3_1_0_19_2_9#register.PIN_CNF-0"&gt;PIN_CNF[N] register&lt;/a&gt;.&lt;/p&gt;
&lt;p&gt;regards&lt;/p&gt;
&lt;p&gt;Jared&amp;nbsp;&amp;nbsp;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: nrf52832 Taking power on UART Lines</title><link>https://devzone.nordicsemi.com/thread/199217?ContentTypeID=1</link><pubDate>Thu, 18 Jul 2019 10:20:02 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:6354e623-d15a-46c5-add2-afad93dd90f7</guid><dc:creator>kamran_iosite</dc:creator><description>&lt;p&gt;Hi,&lt;/p&gt;
&lt;p&gt;Thanks for your response.&lt;/p&gt;
[quote userid="6462" url="~/f/nordic-q-a/49974/nrf52832-taking-power-on-uart-lines/199211"]You need to ensure that signal lines are either disconnected[/quote]
&lt;p&gt;I am thinking to use a tri-state buffer IC to isolate the UART lines. The buffer IC is&amp;nbsp;&lt;span&gt;74LVC126APW,118 (&lt;a href="https://assets.nexperia.com/documents/data-sheet/74LVC126A.pdf"&gt;https://assets.nexperia.com/documents/data-sheet/74LVC126A.pdf&lt;/a&gt;). Will you suggest this?&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;
[quote userid="6462" url="~/f/nordic-q-a/49974/nrf52832-taking-power-on-uart-lines/199211"]put into a suitable state.[/quote]
&lt;p&gt;Can this be done in nrf52832 code? If yes, please share some references on this.&lt;/p&gt;
&lt;p&gt;&lt;span&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span&gt;&lt;span&gt;Thanks for the help.&lt;/span&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span&gt;&lt;span&gt;&lt;span&gt;&lt;span&gt;&lt;span&gt;Regards&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span&gt;&lt;span&gt;&lt;span&gt;&lt;span&gt;&lt;span&gt;&lt;span&gt;Kamran&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: nrf52832 Taking power on UART Lines</title><link>https://devzone.nordicsemi.com/thread/199211?ContentTypeID=1</link><pubDate>Thu, 18 Jul 2019 10:09:41 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:a685b5a6-67d7-4a0d-ad0a-0cfde9a526e6</guid><dc:creator>awneil</dc:creator><description>[quote userid="81774" url="~/f/nordic-q-a/49974/nrf52832-taking-power-on-uart-lines"]Is this normal behavior? [/quote]
&lt;p&gt;&lt;strong&gt;Yes.&lt;/strong&gt; For &lt;em&gt;&lt;strong&gt;any&lt;/strong&gt;&lt;/em&gt; chip - not just nRF.&lt;/p&gt;
[quote userid="81774" url="~/f/nordic-q-a/49974/nrf52832-taking-power-on-uart-lines"]What can be done to avoid this[/quote]
&lt;p&gt;You need to ensure that signal lines are either disconnected, or put into a suitable state.&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item></channel></rss>