<?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>measuring battery level problem</title><link>https://devzone.nordicsemi.com/f/nordic-q-a/35777/measuring-battery-level-problem</link><description>Hi to all, 
 i am working on a project based on nrf51822 soc, i want measure level of battery with nrf51822 ADC channel. 
 i have an example code that measure the level of battery but it return different value each time that i measure the battery level</description><dc:language>en-US</dc:language><generator>Telligent Community 13</generator><lastBuildDate>Tue, 26 Jun 2018 14:04:10 GMT</lastBuildDate><atom:link rel="self" type="application/rss+xml" href="https://devzone.nordicsemi.com/f/nordic-q-a/35777/measuring-battery-level-problem" /><item><title>RE: measuring battery level problem</title><link>https://devzone.nordicsemi.com/thread/137710?ContentTypeID=1</link><pubDate>Tue, 26 Jun 2018 14:04:10 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:ad8afb42-8c73-4218-b2b3-b8cead26a99b</guid><dc:creator>AmbystomaLabs</dc:creator><description>&lt;p&gt;And a trick on this that works well is set the radio notification distance to the maximum (5500usec in SDK 11) so you have time to do a proper A/D conversion with some averaging if you wish.&lt;/p&gt;
&lt;p&gt;Then measure the battery voltage before the radio goes active not after.&amp;nbsp; This way you are assured of some radio inactivity to allow your battery to recover and show its true nominal voltage.&lt;/p&gt;
&lt;p&gt;To do this just add &amp;quot;if (radio_evt)&amp;quot; in the handler.&amp;nbsp; If true then the radio is getting ready to go active after the notification distance period.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: measuring battery level problem</title><link>https://devzone.nordicsemi.com/thread/137705?ContentTypeID=1</link><pubDate>Tue, 26 Jun 2018 13:51:39 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:80ea90b4-a749-423f-aaf1-618d41672127</guid><dc:creator>H&amp;#229;kon Alseth</dc:creator><description>&lt;p&gt;Hi,&lt;/p&gt;
&lt;p&gt;&amp;nbsp;&lt;/p&gt;
&lt;p&gt;You can use the radio_notification library which&amp;nbsp;provides&amp;nbsp;you with this functionality:&lt;/p&gt;
&lt;p&gt;&lt;a href="https://devzone.nordicsemi.com/tutorials/b/software-development-kit/posts/radio-notification"&gt;https://devzone.nordicsemi.com/tutorials/b/software-development-kit/posts/radio-notification&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;&amp;nbsp;&lt;/p&gt;
&lt;p&gt;Kind regards,&lt;/p&gt;
&lt;p&gt;Håkon&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item></channel></rss>