<?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>Reading ADC value from analog input</title><link>https://devzone.nordicsemi.com/f/nordic-q-a/6524/reading-adc-value-from-analog-input</link><description>Hello, I&amp;#39;m using nRF51822-mKIT for a research. 
 
 To verify ADC readings from analog input, I&amp;#39;ve connected P0_5 to GND and ran the following code: 
 uint16_t adc_result; 

NRF_ADC-&amp;gt;INTENSET = (ADC_INTENSET_END_Disabled &amp;lt;&amp;lt; ADC_INTENSET_END_Pos);</description><dc:language>en-US</dc:language><generator>Telligent Community 13</generator><lastBuildDate>Tue, 21 Apr 2015 11:43:30 GMT</lastBuildDate><atom:link rel="self" type="application/rss+xml" href="https://devzone.nordicsemi.com/f/nordic-q-a/6524/reading-adc-value-from-analog-input" /><item><title>RE: Reading ADC value from analog input</title><link>https://devzone.nordicsemi.com/thread/22782?ContentTypeID=1</link><pubDate>Tue, 21 Apr 2015 11:43:30 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:6afce51c-1261-43c8-8cd3-20753047b5dc</guid><dc:creator>Stefan Birnir Sverrisson</dc:creator><description>&lt;p&gt;Hi&lt;/p&gt;
&lt;p&gt;Have you perhaps followed &lt;a href="https://github.com/NordicSemiconductor/nrf51-ADC-examples/blob/master/rtc0_triggering_ADC_sample_from_GPIO_pin/main.c"&gt;this example&lt;/a&gt;?  Your configuration seems correct. What if you try to run the linked example directly, does that work?&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Reading ADC value from analog input</title><link>https://devzone.nordicsemi.com/thread/22781?ContentTypeID=1</link><pubDate>Thu, 16 Apr 2015 19:34:17 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:e5276dd0-5dab-41a8-832d-9b2071eafaa1</guid><dc:creator>Justin</dc:creator><description>&lt;p&gt;Thank you for an advice! I tried adding the following line of code before enabling ADC&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;nrf_gpio_cfg_input(NRF_GPIO_PORT_SELECT_PORT0, GPIO_PIN_CNF_PULL_Disabled);
&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;Since the input pin P0_5 is part of GPIO PORT 0. However, the adc result was unchanged. Did I use the function correctly to configure GPIO?&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Reading ADC value from analog input</title><link>https://devzone.nordicsemi.com/thread/22780?ContentTypeID=1</link><pubDate>Wed, 15 Apr 2015 22:01:19 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:161bdd42-5e23-4de9-a5f6-b251e3a3c458</guid><dc:creator>H&amp;#229;kon Alseth</dc:creator><description>&lt;p&gt;It might be that the input buffer (in NRF_GPIO-&amp;gt;PIN_CNF[mypin]) is not connected at your specific GPIO. Try calling nrf_gpio_cfg_input to connect this inside the GPIO peripheral, then do the AD conversion.&lt;/p&gt;
&lt;p&gt;Cheers,
Håkon&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item></channel></rss>