<?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>Advertising Battery levels on a beacon</title><link>https://devzone.nordicsemi.com/f/nordic-q-a/2023/advertising-battery-levels-on-a-beacon</link><description>Hey folks, 
 I am currently trying to use my nrf51822 evaluation board as a beacon. This is working pretty well but I need to have it broadcast its current battery level as well. From what I have seen this means I need to make some kind of interrupt</description><dc:language>en-US</dc:language><generator>Telligent Community 13</generator><lastBuildDate>Fri, 17 Feb 2017 23:40:48 GMT</lastBuildDate><atom:link rel="self" type="application/rss+xml" href="https://devzone.nordicsemi.com/f/nordic-q-a/2023/advertising-battery-levels-on-a-beacon" /><item><title>RE: Advertising Battery levels on a beacon</title><link>https://devzone.nordicsemi.com/thread/8691?ContentTypeID=1</link><pubDate>Fri, 17 Feb 2017 23:40:48 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:d219ebae-b26b-4da7-87d3-000b5ebc2bbd</guid><dc:creator>Carlos Villavicencio</dc:creator><description>&lt;p&gt;Thanks Ole. Have you ported this to SDK 11 and softdevice 130?&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Advertising Battery levels on a beacon</title><link>https://devzone.nordicsemi.com/thread/8690?ContentTypeID=1</link><pubDate>Fri, 24 Apr 2015 10:27:57 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:8989c65b-ce7c-48de-989f-cbc030b595f6</guid><dc:creator>GunMin</dc:creator><description>&lt;p&gt;Ole Morten, your example(nrf51-ble-app-temp) is How does the search?&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Advertising Battery levels on a beacon</title><link>https://devzone.nordicsemi.com/thread/8689?ContentTypeID=1</link><pubDate>Mon, 31 Mar 2014 19:24:09 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:e36cc8c6-e048-4e5e-9b3f-d4247b0c4a8d</guid><dc:creator>Chris Butler</dc:creator><description>&lt;p&gt;Those links help a good bit. I am still struggling with how exactly the calculation works and how I can verify it. Testing my actual battery voltage gives me 3.0v outside of the circuit, testing it in the working circuit gives 2.85v, the ACD however gives 0x55( or 85%) out of 3.0v which would correspond to 2.55v. When using the devlopement board with USB power it reads 0x65 when the max voltage is set to 3.0v in the code. What would be causing this discrepancy?&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Advertising Battery levels on a beacon</title><link>https://devzone.nordicsemi.com/thread/8688?ContentTypeID=1</link><pubDate>Mon, 31 Mar 2014 14:10:05 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:beae7390-1e87-40e2-8031-547ed535c0b7</guid><dc:creator>Ole Morten</dc:creator><description>&lt;p&gt;I&amp;#39;m not sure I understand your question, but is it covered by either of these?
&lt;a target="_blank" href="https://devzone.nordicsemi.com/index.php/using-adc-to-measure-battery-voltage" rel="nofollow"&gt;https://devzone.nordicsemi.com/index.php/using-adc-to-measure-battery-voltage&lt;/a&gt;
&lt;a target="_blank" href="https://devzone.nordicsemi.com/index.php/what-voltage-range-can-be-measured-with-the-adc" rel="nofollow"&gt;https://devzone.nordicsemi.com/index.php/what-voltage-range-can-be-measured-with-the-adc&lt;/a&gt;
In that example, the value that comes out of the ADC is converted to a value between 0 and 100 (0x64) and then sent over the air. Please note that I&amp;#39;d rather recommend using manufacturer specific data for this, instead of the service data used by the example. The reason the example uses service data is for backwards compatibility with earlier apps.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Advertising Battery levels on a beacon</title><link>https://devzone.nordicsemi.com/thread/8692?ContentTypeID=1</link><pubDate>Mon, 31 Mar 2014 14:06:24 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:698def32-73dd-491b-b05d-f9616bea85f3</guid><dc:creator>Chris Butler</dc:creator><description>&lt;p&gt;Thanks a lot, this is exactly what I needed. I do have one question though, what does the battery reading the ADC sends back correspond to?&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Advertising Battery levels on a beacon</title><link>https://devzone.nordicsemi.com/thread/8687?ContentTypeID=1</link><pubDate>Mon, 31 Mar 2014 09:59:28 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:135b101b-85c1-4477-b171-ca6e54a7377e</guid><dc:creator>Ole Morten</dc:creator><description>&lt;p&gt;This is actually implemented in the &lt;a href="https://github.com/NordicSemiconductor/nrf51-ble-app-temp"&gt;nrf51-ble-app-temp&lt;/a&gt;, available here, so I&amp;#39;d recommend you to take a look on it. In summary, it uses app_timer to trigger a periodic timeout, in which it uses the ADC to measure the battery level, and updates the advertisement data.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item></channel></rss>