<?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 control the GPIO P0.18 to output High and low with nrf52832?</title><link>https://devzone.nordicsemi.com/f/nordic-q-a/117342/how-to-control-the-gpio-p0-18-to-output-high-and-low-with-nrf52832</link><description>background: 
 1: my board is the same with the nRF52832-CIAA Reference Layout 1_0 from nordic docs. 
 2: the source code is from sample code: blinky_led 
 3: only change the led0 to led1 
 
 #define LED0_NODE DT_ALIAS(led0) 
 to 
 
 
 #define LED0_NODE</description><dc:language>en-US</dc:language><generator>Telligent Community 13</generator><lastBuildDate>Fri, 27 Dec 2024 09:56:41 GMT</lastBuildDate><atom:link rel="self" type="application/rss+xml" href="https://devzone.nordicsemi.com/f/nordic-q-a/117342/how-to-control-the-gpio-p0-18-to-output-high-and-low-with-nrf52832" /><item><title>RE: How to control the GPIO P0.18 to output High and low with nrf52832?</title><link>https://devzone.nordicsemi.com/thread/516307?ContentTypeID=1</link><pubDate>Fri, 27 Dec 2024 09:56:41 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:fa7871d5-0763-4bed-9e07-6ae65eacc619</guid><dc:creator>403417724@qq.com</dc:creator><description>&lt;p&gt;hi, Thanks for your support.&amp;nbsp; Can not control led should be have two reason:&lt;/p&gt;
&lt;p&gt;1: I confirm that P0.18 be short with VDD, so the output always high; when fixed hardware, it can work when debug mode.&lt;/p&gt;
&lt;p&gt;2: But It doesn&amp;#39;t work when i use flash mode.( program the build output file to flash), i use the vscode + nrf connect develop environment.&amp;nbsp; I don&amp;#39;t know this reason.&amp;nbsp;&amp;nbsp;&lt;/p&gt;
&lt;p&gt;I guess that i have not program the bootloader or softdevice?&amp;nbsp; But when i click the flash button. just print：&lt;/p&gt;
&lt;p&gt;The program &amp;#39;f:/projects/nrf/projects/blinky/build_og/zephyr/zephyr.elf&amp;#39; has exited with code 0 (0x00000000).&lt;/p&gt;
&lt;p&gt;No any tips for me to select other files to program.such as bootloader or softdiveice...etc.&lt;/p&gt;
&lt;p&gt;Could you help me for the second pointer. Thanks at first!&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: How to control the GPIO P0.18 to output High and low with nrf52832?</title><link>https://devzone.nordicsemi.com/thread/515798?ContentTypeID=1</link><pubDate>Thu, 19 Dec 2024 15:29:14 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:a7268b07-cc99-4b8b-a2da-0c1c7d1551ce</guid><dc:creator>Einar Thorsrud</dc:creator><description>&lt;p&gt;Hi,&lt;/p&gt;
&lt;p&gt;Yes, there si no problem with the putput being floating. (A floating input is a problem, but then you can enable internal pull resistors).&lt;/p&gt;
&lt;p&gt;S0S1 means standard drive. For driving a LED direclty, you probably want high drive (or even consider using a buffer). But I sggest considering one thing a ta&amp;nbsp; time, and if you do not measure any changing voltage on the pin when it is set high or low that is not related to this (you could consider disconnecting it if you have it connected to a LED or anything else now to reduce the unknowns).&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: How to control the GPIO P0.18 to output High and low with nrf52832?</title><link>https://devzone.nordicsemi.com/thread/515797?ContentTypeID=1</link><pubDate>Thu, 19 Dec 2024 15:22:26 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:f8ea87ed-baea-47bb-b51c-002bfa9aca33</guid><dc:creator>403417724@qq.com</dc:creator><description>&lt;p&gt;OK , i will do check the HW connect next.&lt;/p&gt;
&lt;p&gt;And do you see my sch ? is it ok? can the P0.18&amp;nbsp; floating ? and GPIO CNF[18]=3 (S0S1)?&lt;/p&gt;
&lt;p&gt;I guess that if GPIO CNF=3, do not need to PULL UP to 3.3V or PULL DOWN to GND with a RES.&lt;/p&gt;
&lt;p&gt;is correct that use the S0S1 for floating pin?&amp;nbsp;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: How to control the GPIO P0.18 to output High and low with nrf52832?</title><link>https://devzone.nordicsemi.com/thread/515777?ContentTypeID=1</link><pubDate>Thu, 19 Dec 2024 14:39:38 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:4c63882b-755d-4953-aa38-dc58486efb8b</guid><dc:creator>Einar Thorsrud</dc:creator><description>&lt;p&gt;Hi,&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;
&lt;p&gt;If you can write the information here in text that would be good, but looking at the video, it looks like it would be difficult to measure at the wrong point. I notice that you have an overlay file though. While I did not spot any issue when glancing at the video, the example works on the DK with toggling the P0.18 without any changes except the single line that you described in the initial post. So I reocmend you pelase revert all changes and test exactly that one, which I verified works on my end. If that does not work, perhaps you need to look at the soldering on your board. Could it be that you have been unlucky and that the pin is not soldered to the PCB so that there is no actual connection?&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: How to control the GPIO P0.18 to output High and low with nrf52832?</title><link>https://devzone.nordicsemi.com/thread/515772?ContentTypeID=1</link><pubDate>Thu, 19 Dec 2024 14:30:12 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:7008f887-0da4-4110-a5bd-0aebf05efc21</guid><dc:creator>403417724@qq.com</dc:creator><description>&lt;p&gt;I have upload the video to youtube. Please try this one, thanks a lot!&lt;/p&gt;
&lt;p&gt;&lt;a href="http://www.youtube.com/watch?v=Qw8N2xWOhSE"&gt;www.youtube.com/watch?v=Qw8N2xWOhSE&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;Yes , i can running the code. and find nothing excepion.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: How to control the GPIO P0.18 to output High and low with nrf52832?</title><link>https://devzone.nordicsemi.com/thread/515750?ContentTypeID=1</link><pubDate>Thu, 19 Dec 2024 13:37:03 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:7942847b-7fea-4bbf-b43e-d7a10014d7a7</guid><dc:creator>Einar Thorsrud</dc:creator><description>&lt;p&gt;Hi,&lt;/p&gt;
[quote user="403417724@qq.com"]&lt;p&gt;1: Could you tell me whether can attach files directly here?&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;[/quote]
&lt;p&gt;You can either drag-and-drop the file right into the box where you are writing the reply, or you can use Insert -&amp;gt; Image/video/file.&lt;/p&gt;
[quote user="403417724@qq.com"]2: I upload some files in my qq zone, could you access these?&amp;nbsp;[/quote]
&lt;p&gt;No, I am not ble to access it.&lt;/p&gt;
[quote user="403417724@qq.com"]PCB is my self-define board( Just from the official&amp;nbsp; pcb file of chip package for Altium Designer tool) not&amp;nbsp; official nRF52 DK board.[/quote]
&lt;p&gt;Then we need to look at your board and verity that you are actually measuring on something that is physically connected to P0.18.&lt;/p&gt;
&lt;p&gt;How are you building the project? Are you building for nrf52dk_nrf52832 or another target?&lt;/p&gt;
&lt;p&gt;From what I see in the initial post you have been able to debug so that you know that the application is running, is that correct?&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: How to control the GPIO P0.18 to output High and low with nrf52832?</title><link>https://devzone.nordicsemi.com/thread/515730?ContentTypeID=1</link><pubDate>Thu, 19 Dec 2024 12:51:33 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:5c0cedce-37bb-47a2-9136-fc77c9b69371</guid><dc:creator>403417724@qq.com</dc:creator><description>&lt;p&gt;1: Could you tell me whether can attach files directly here?&lt;/p&gt;
&lt;p&gt;2: I upload some files in my qq zone, could you access these?&amp;nbsp;&lt;/p&gt;
&lt;p&gt;URL: &lt;a id="" href="https://user.qzone.qq.com/403417724/infocenter"&gt;https://user.qzone.qq.com/403417724/infocenter&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;PCB is my self-define board( Just from the official&amp;nbsp; pcb file of chip package for Altium Designer tool) not&amp;nbsp; official nRF52 DK board.&lt;/p&gt;
&lt;p&gt;-&amp;gt; sch: my sch picutre&lt;/p&gt;
&lt;p&gt;-&amp;gt; pcb: my board pcb layout picture&lt;/p&gt;
&lt;p&gt;-&amp;gt; reg_P0.18_high is the debug screen-shot when set P0.18 to high in vscode&lt;/p&gt;
&lt;p&gt;&lt;span&gt;-&amp;gt; reg_P0.18_low is the debug screen-shot when set P0.18 to low in vscode&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;3: all GPIO are floatting&lt;/p&gt;
&lt;p&gt;4: no overlay files.&lt;/p&gt;
&lt;p&gt;5: prj.conf are below:&lt;/p&gt;
&lt;div&gt;
&lt;div&gt;&lt;span&gt;CONFIG_GPIO&lt;/span&gt;&lt;span&gt;=y&lt;/span&gt;&lt;/div&gt;
&lt;div&gt;&lt;span&gt;CONFIG_SERIAL&lt;/span&gt;&lt;span&gt;=y&lt;/span&gt;&lt;/div&gt;
&lt;div&gt;&lt;span&gt;CONFIG_CONSOLE&lt;/span&gt;&lt;span&gt;=y&lt;/span&gt;&lt;/div&gt;
&lt;div&gt;&lt;span&gt;CONFIG_UART_CONSOLE&lt;/span&gt;&lt;span&gt;=y&lt;/span&gt;&lt;/div&gt;
&lt;div&gt;&lt;span&gt;CONFIG_PRINTK&lt;/span&gt;&lt;span&gt;=y&lt;/span&gt;&lt;/div&gt;
&lt;/div&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: How to control the GPIO P0.18 to output High and low with nrf52832?</title><link>https://devzone.nordicsemi.com/thread/515670?ContentTypeID=1</link><pubDate>Thu, 19 Dec 2024 09:37:34 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:ed3d787d-e4f5-48d9-9a6a-0390cbb54f5c</guid><dc:creator>Einar Thorsrud</dc:creator><description>&lt;p&gt;Hi,&lt;/p&gt;
&lt;p&gt;I see. Using the blinky sample, just changing from&amp;nbsp;#define LED0_NODE DT_ALIAS(led0) to&amp;nbsp;#define LED0_NODE DT_ALIAS(led1) is enough to ue P0.18 instead if you are building for the nRF52 DK as target board.&lt;/p&gt;
&lt;p&gt;Can you show how you build, sot hat I see which board you build for and verifyt hat you have nod modified the board fiels or added an overlay file (so that we know that led1 actually poitns to P0.18)? If that is OK, the next is to look at your hardware. Is there an issu ethere so that the poitn you are measuring on is not actually connected to P0.18?&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: How to control the GPIO P0.18 to output High and low with nrf52832?</title><link>https://devzone.nordicsemi.com/thread/515624?ContentTypeID=1</link><pubDate>Thu, 19 Dec 2024 02:10:58 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:95c8a986-df2b-4fc7-a2b8-1e5f0d60b5e1</guid><dc:creator>403417724@qq.com</dc:creator><description>&lt;p&gt;Thanks for your reply.&lt;/p&gt;
&lt;p&gt;1：Sorry， the sample code name should be blinky,the path is ..\ncs\v2.7.0\zephyr\samples\basic\blinky&lt;/p&gt;
&lt;p&gt;2: The HW board is just from&amp;nbsp;&lt;span&gt;nRF52832-CIAA Reference Layout 1_0 from nordic docs.&amp;nbsp;&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span&gt;3:&amp;nbsp; I just simple measure with VICTOR VC890D to mesure the voltage between P0.18 and GND.&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span&gt;I dont know how to attach files here.&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span&gt;So you mean all reg(CNF, OUT, IN, DIR, LATCH, DETECTMODE) related are list here. and no error obviously？&lt;/span&gt;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: How to control the GPIO P0.18 to output High and low with nrf52832?</title><link>https://devzone.nordicsemi.com/thread/515274?ContentTypeID=1</link><pubDate>Tue, 17 Dec 2024 13:30:12 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:fc51f224-f473-461e-8391-6f1e840fd813</guid><dc:creator>Einar Thorsrud</dc:creator><description>&lt;p&gt;Hi,&lt;/p&gt;
[quote user=""]&lt;p&gt;2: the source code is from sample code: blinky_led&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;[/quote]
&lt;p&gt;I am unable to find this sample. Can you specify which SDK version you are using and the path to the sample?&lt;/p&gt;
[quote user=""]&lt;p&gt;1: seems that the output reg is right (at least the reg value can be change with my control), but&amp;nbsp; the measured voltage is always 3.3V with&amp;nbsp;multimeter.&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;[/quote]
&lt;p&gt;If the pin is configured as an output and the output register indicate it is high, that should be reflected on the pin. How are you measuring it?&amp;nbsp;Could there be an issue on the HW? Can you share details on your HW and how you measure?&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item></channel></rss>