<?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 GPIO incontrollable!</title><link>https://devzone.nordicsemi.com/f/nordic-q-a/36784/nrf52832-gpio-incontrollable</link><description>Hi,everybody! 
 I use nRF52832,supply volt 3.0V normal, program can be downloaded , run and debug,i ensure the program is accurately.To control a gpio P0.09,on the hardware, P0.09 series a resistor to the led and the led is grounded,i n the program I</description><dc:language>en-US</dc:language><generator>Telligent Community 13</generator><lastBuildDate>Thu, 26 Jul 2018 07:52:09 GMT</lastBuildDate><atom:link rel="self" type="application/rss+xml" href="https://devzone.nordicsemi.com/f/nordic-q-a/36784/nrf52832-gpio-incontrollable" /><item><title>RE: nRF52832 GPIO incontrollable!</title><link>https://devzone.nordicsemi.com/thread/141469?ContentTypeID=1</link><pubDate>Thu, 26 Jul 2018 07:52:09 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:e0c99ceb-d8c2-409e-9e1a-7d970ea7c1c7</guid><dc:creator>bjorn-spockeli</dc:creator><description>&lt;p&gt;The snippet below is pulled from the&amp;nbsp;SystemInit() function in the system_nrf52.c file , which is run at startup. So if you want to use the NFC pins as GPIOs you simply have to add&amp;nbsp;CONFIG_NFCT_PINS_AS_GPIOS to your preprocessor defines.&lt;/p&gt;
&lt;p&gt;&lt;pre class="ui-code" data-mode="c_cpp"&gt;  /* Configure NFCT pins as GPIOs if NFCT is not to be used in your code. If CONFIG_NFCT_PINS_AS_GPIOS is not defined,
       two GPIOs (see Product Specification to see which ones) will be reserved for NFC and will not be available as
       normal GPIOs. */
    #if defined (CONFIG_NFCT_PINS_AS_GPIOS)
        if ((NRF_UICR-&amp;gt;NFCPINS &amp;amp; UICR_NFCPINS_PROTECT_Msk) == (UICR_NFCPINS_PROTECT_NFC &amp;lt;&amp;lt; UICR_NFCPINS_PROTECT_Pos)){
            NRF_NVMC-&amp;gt;CONFIG = NVMC_CONFIG_WEN_Wen &amp;lt;&amp;lt; NVMC_CONFIG_WEN_Pos;
            while (NRF_NVMC-&amp;gt;READY == NVMC_READY_READY_Busy){}
            NRF_UICR-&amp;gt;NFCPINS &amp;amp;= ~UICR_NFCPINS_PROTECT_Msk;
            while (NRF_NVMC-&amp;gt;READY == NVMC_READY_READY_Busy){}
            NRF_NVMC-&amp;gt;CONFIG = NVMC_CONFIG_WEN_Ren &amp;lt;&amp;lt; NVMC_CONFIG_WEN_Pos;
            while (NRF_NVMC-&amp;gt;READY == NVMC_READY_READY_Busy){}
            NVIC_SystemReset();
        }
    #endif&lt;/pre&gt;&lt;/p&gt;
&lt;p&gt;&amp;nbsp;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: nRF52832 GPIO incontrollable!</title><link>https://devzone.nordicsemi.com/thread/141450?ContentTypeID=1</link><pubDate>Thu, 26 Jul 2018 06:22:51 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:5f44fe82-6f35-40d6-9fe7-630238f1b938</guid><dc:creator>vsion</dc:creator><description>&lt;p&gt;&lt;span&gt;Although you don&amp;#39;t reply, but I also want to say with you, the things settled, is not what we discussed yesterday, is a question of NFC, P0.09 and P0.10 was just what I used as a gpio, it is the default NFC function, so I need to set the register to normal gpio, then everything is normal work, also do not need to add the MOS tube, just change the NFC function to gpio function, can work normally, but still want to thank you.&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span&gt;const uint32_t UICR_ADDR_0x20C &amp;nbsp; &amp;nbsp;__attribute__((at(0x1000120C))) __attribute__((used)) = 0xFFFFFFFE;&lt;/span&gt;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: nRF52832 GPIO incontrollable!</title><link>https://devzone.nordicsemi.com/thread/141254?ContentTypeID=1</link><pubDate>Wed, 25 Jul 2018 06:30:40 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:7f468d3e-cb99-40b1-aa77-2c7f57b46f21</guid><dc:creator>vsion</dc:creator><description>&lt;p&gt;&lt;span&gt;And I set the usable gpio to toggle the high and low level once every 1 second. Then I used the multimeter to see that the gpio is 3.0v for a while and 0v for a while.See the led lights up every once in a while and off every once in a while.&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span&gt;The above is my description of the phenomenon after the experiment.&lt;/span&gt;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: nRF52832 GPIO incontrollable!</title><link>https://devzone.nordicsemi.com/thread/141251?ContentTypeID=1</link><pubDate>Wed, 25 Jul 2018 06:04:21 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:c60f43c0-5271-4d9a-96ad-28cb8e0e5052</guid><dc:creator>vsion</dc:creator><description>&lt;p&gt;Hi,RK&lt;/p&gt;
&lt;p&gt;&amp;nbsp; &amp;nbsp;&amp;nbsp;&lt;span&gt;Just now, I suspended the other IO port, wrote the program to enable the IO port to work normally, which can be raised and pulled down.&lt;/span&gt;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: nRF52832 GPIO incontrollable!</title><link>https://devzone.nordicsemi.com/thread/141247?ContentTypeID=1</link><pubDate>Wed, 25 Jul 2018 05:27:53 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:b8de8332-b993-41bf-9f8a-dd83212aa37d</guid><dc:creator>vsion</dc:creator><description>&lt;p&gt;Hi RK,&lt;/p&gt;
&lt;p&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp;&lt;span&gt;Before testing again, I removed the LED and the resistance,As you say,I set all P0.09 and P0.10 as output high level, and no external devices were connected at this time. These two pins were suspended. At this time, the output voltage of these two pins should be 3.0v (at this time, the operating voltage of MCU is 3.0v), but after my measurement, it was found that the output voltage of these two pins was around 0.2v or below 0.2v.There is no high level voltage of about 3.0v output at all&lt;/span&gt;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: nRF52832 GPIO incontrollable!</title><link>https://devzone.nordicsemi.com/thread/141237?ContentTypeID=1</link><pubDate>Wed, 25 Jul 2018 03:40:13 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:61ef1a45-da54-47ac-a4b6-ceee6259bfa1</guid><dc:creator>vsion</dc:creator><description>&lt;p&gt;ok,tks,I&amp;#39;&lt;span&gt;ll add a MOS to increase its drive capacity.&lt;/span&gt;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: nRF52832 GPIO incontrollable!</title><link>https://devzone.nordicsemi.com/thread/141236?ContentTypeID=1</link><pubDate>Wed, 25 Jul 2018 03:15:39 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:05ba074b-27bc-4f71-8b36-bd67d89ab6d2</guid><dc:creator>RK</dc:creator><description>&lt;p&gt;I&amp;#39;ve now explained this to you three times. I will do it a fourth. You cannot light an LED of that type that with 0.5mA. 50 ohms would be appropriate for a GPIO at 3v which could source 20mA, but this can&amp;#39;t source 20mA, it can source 0.5mA.&amp;nbsp;&lt;/p&gt;
&lt;p&gt;You have two problems&lt;/p&gt;
&lt;p&gt;1) you are trying to drive something with 20mA from a 0.5mA source&lt;/p&gt;
&lt;p&gt;2) even if you weren&amp;#39;t whatever calculation you did for your original resistance was entirely wrong.&amp;nbsp;&lt;/p&gt;
&lt;p&gt;However in this case 2) doesn&amp;#39;t matter because of 1)&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: nRF52832 GPIO incontrollable!</title><link>https://devzone.nordicsemi.com/thread/141235?ContentTypeID=1</link><pubDate>Wed, 25 Jul 2018 03:00:19 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:a2629186-dc88-4e33-a2d2-91e0eefbf4e3</guid><dc:creator>vsion</dc:creator><description>&lt;p&gt;and&amp;nbsp;a&lt;span&gt;t this time, the working voltage of MCU was adjusted to 3.0v&lt;/span&gt;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: nRF52832 GPIO incontrollable!</title><link>https://devzone.nordicsemi.com/thread/141234?ContentTypeID=1</link><pubDate>Wed, 25 Jul 2018 02:59:02 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:5e6d5677-a3ec-463a-9fbc-55df381705b5</guid><dc:creator>vsion</dc:creator><description>&lt;p&gt;&lt;span&gt;I also changed to 50omhs, and the test lights were not on.&lt;/span&gt;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: nRF52832 GPIO incontrollable!</title><link>https://devzone.nordicsemi.com/thread/141233?ContentTypeID=1</link><pubDate>Wed, 25 Jul 2018 02:46:40 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:e7c911c7-0cd4-4438-9bad-30476b3534ad</guid><dc:creator>RK</dc:creator><description>&lt;p&gt;This is basic electronics. If the drive is limited to 0.5mA then that is all the current you can get out of the pin which means it will drop the voltage however low it needs to be to get 0.5mA. So without the resistor you get the max current available which is 0.5mA and that&amp;#39;s probably a voltage across the LED of about 0.2v, hard to say really as that is so far away from the operating region the charts don&amp;#39;t really cover it.&amp;nbsp;&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;
&lt;p&gt;You can&amp;#39;t drive an LED from a GPIO like that.&amp;nbsp;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: nRF52832 GPIO incontrollable!</title><link>https://devzone.nordicsemi.com/thread/141232?ContentTypeID=1</link><pubDate>Wed, 25 Jul 2018 02:43:43 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:43be6c1f-68ff-464f-a8fd-edc6255aa5ca</guid><dc:creator>vsion</dc:creator><description>&lt;p&gt;Yes,I read all your messages.&lt;span&gt;This means that the drive capacity is not enough, but I have short-circuited the series resistance between LED&amp;nbsp;and GPIO,Is it not enough to connect the led directly to the gpio port?&lt;/span&gt;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: nRF52832 GPIO incontrollable!</title><link>https://devzone.nordicsemi.com/thread/141230?ContentTypeID=1</link><pubDate>Wed, 25 Jul 2018 01:44:45 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:ca854f32-8c07-4eb3-b0dc-bf37b38b236d</guid><dc:creator>RK</dc:creator><description>&lt;p&gt;Did you bother to read my reply AT ALL? The FIRST thing I pointed out to you that the standard drive for a GPIO is 0.5mA. That&amp;#39;s nowhere near enough current to light your LED. So yes the voltage is going to be very small because the pin is limiting the current to 0.5mA which probably means yes about 0.2v is all you get across the LED.&amp;nbsp;&lt;/p&gt;
&lt;p&gt;I&amp;#39;ll repeat the last sentence&lt;/p&gt;
&lt;p&gt;You can&amp;#39;t drive a 20mA nominal current LED from a GPIO. You certainly can&amp;#39;t do it in Standard drive mode, you might, just about, get it to glow in High drive mode which will give you 5mA.&amp;nbsp;&lt;/p&gt;
&lt;p&gt;If you want to drive a 20mA LED you need to drive it through a transistor switch circuit.&amp;nbsp;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: nRF52832 GPIO incontrollable!</title><link>https://devzone.nordicsemi.com/thread/141228?ContentTypeID=1</link><pubDate>Wed, 25 Jul 2018 01:39:18 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:e176e845-f5b5-47d2-8ec1-81fe0fbfc467</guid><dc:creator>vsion</dc:creator><description>&lt;p&gt;&lt;em&gt;&lt;span class="skip"&gt;Thank you for your reply.&lt;/span&gt;&lt;/em&gt;&lt;/p&gt;
&lt;p&gt;&lt;span&gt;I tested it today,&lt;/span&gt;even short-circuited the resistance,th&lt;span&gt;ere&amp;#39;s still no reaction.I measured the gpio high level output voltage only about 0.18v,low level output voltage about 0.00...V. &lt;/span&gt;I guess the gpio has no output at all.D&lt;em&gt;&lt;span class="skip"&gt;on&amp;#39;t know why?&lt;/span&gt;&lt;/em&gt;Is it possible that the chip is broken?&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: nRF52832 GPIO incontrollable!</title><link>https://devzone.nordicsemi.com/thread/141125?ContentTypeID=1</link><pubDate>Tue, 24 Jul 2018 10:58:59 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:2cdf9cd2-c238-494d-9a50-e2f273ee1dc1</guid><dc:creator>RK</dc:creator><description>&lt;p&gt;Standard output, 0.5mA, taking a look at the spec for that LED it wants more like 20mA, at 0.5mA you&amp;#39;re barely turning it on. Even if you could source 20mA from the pin you have a 1K resistor (where did you get THATvalue from). Assuming a Vf on the LED of 2.0v and a supply of 3.0V, your drop over the resistor is 1.0v so your current would be limited to about 1mA even if the pin could supply more. 1mA is so low on the graph of luminous intensity vs current&amp;nbsp; as to be basically .. off.&amp;nbsp;&lt;/p&gt;
&lt;p&gt;You can&amp;#39;t drive a 20mA nominal current LED from a GPIO, even in High mode&amp;nbsp; (~5mA) and certainly not&amp;nbsp; in standard mode (0.5mA) and even if it&amp;nbsp; could supply 20mA, your current limiting resistor is way too large. I calculate 50 ohms to be closer to the mark.&amp;nbsp;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: nRF52832 GPIO incontrollable!</title><link>https://devzone.nordicsemi.com/thread/141113?ContentTypeID=1</link><pubDate>Tue, 24 Jul 2018 09:13:14 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:7e85fdcd-1e8f-42f1-b30c-52e1bc421f06</guid><dc:creator>vsion</dc:creator><description>&lt;p&gt;&lt;img alt=" " src="https://devzone.nordicsemi.com/resized-image/__size/320x240/__key/communityserver-discussions-components-files/4/7041.code.png" /&gt;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item></channel></rss>