<?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>More/almost same current consumption when executing code from RAM instead of flash</title><link>https://devzone.nordicsemi.com/f/nordic-q-a/6458/more-almost-same-current-consumption-when-executing-code-from-ram-instead-of-flash</link><description>Hi , 
 According to nRF51822 Product Specification, running code from flash draws about 4.1mA and running it from RAM draws 2.4mA. But when I tested my code it draws more current/almost same when executing code from RAM compared to flash execution. </description><dc:language>en-US</dc:language><generator>Telligent Community 13</generator><lastBuildDate>Wed, 15 Apr 2015 12:20:16 GMT</lastBuildDate><atom:link rel="self" type="application/rss+xml" href="https://devzone.nordicsemi.com/f/nordic-q-a/6458/more-almost-same-current-consumption-when-executing-code-from-ram-instead-of-flash" /><item><title>RE: More/almost same current consumption when executing code from RAM instead of flash</title><link>https://devzone.nordicsemi.com/thread/22532?ContentTypeID=1</link><pubDate>Wed, 15 Apr 2015 12:20:16 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:b6325a52-bf68-4f56-9215-f8d28a043310</guid><dc:creator>Stefan Birnir Sverrisson</dc:creator><description>&lt;p&gt;For views on optimizing power, look at the current consumption guide on &lt;a href="https://devzone.nordicsemi.com/question/5186/how-to-minimize-current-consumption-for-ble-application-on-nrf51822/#reply-5187"&gt;this thread&lt;/a&gt;.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: More/almost same current consumption when executing code from RAM instead of flash</title><link>https://devzone.nordicsemi.com/thread/22531?ContentTypeID=1</link><pubDate>Fri, 10 Apr 2015 16:42:45 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:6873c04e-8721-4d7a-8b51-26eed4d7ba17</guid><dc:creator>Anand Ramashetty</dc:creator><description>&lt;p&gt;I am optimizing my code to reduce power consumption as much as possible. What do you think on this point ? May I know your views on  optimizing power?&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: More/almost same current consumption when executing code from RAM instead of flash</title><link>https://devzone.nordicsemi.com/thread/22530?ContentTypeID=1</link><pubDate>Fri, 10 Apr 2015 16:38:06 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:59a66c98-1a9b-4bf5-a4e2-300866e7823f</guid><dc:creator>Anand Ramashetty</dc:creator><description>&lt;p&gt;you are exactly right on the first question you are asked. you told me to put -mlong-calls in the CFLAGS to remove the division error.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: More/almost same current consumption when executing code from RAM instead of flash</title><link>https://devzone.nordicsemi.com/thread/22529?ContentTypeID=1</link><pubDate>Fri, 10 Apr 2015 16:34:14 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:db3d4468-b56c-478a-9f31-58602f59939d</guid><dc:creator>Anand Ramashetty</dc:creator><description>&lt;p&gt;Hi rols,&lt;/p&gt;
&lt;p&gt;I need to discuss on this with you. Can you please share your contact number if you don&amp;#39;t mind.&lt;/p&gt;
&lt;p&gt;Regards,
Anand&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: More/almost same current consumption when executing code from RAM instead of flash</title><link>https://devzone.nordicsemi.com/thread/22528?ContentTypeID=1</link><pubDate>Fri, 10 Apr 2015 16:12:43 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:07feed66-b964-448e-af40-fa27005bf5d0</guid><dc:creator>RK</dc:creator><description>&lt;p&gt;Is this the same code you were asking about last week? The bit where you were calling division routines? I pointed out at the time that all those calls into any system routine went right back to flash, and division is slooooowwwwww so it spends a lot of time in flash.&lt;/p&gt;
&lt;p&gt;Are you sure your code is actually spending most of its time executing in RAM or do the calls to system routines and the softdevice, plus all the softdevice code constantly running itself mean that you&amp;#39;re really spending most of your time in flash anyway? I&amp;#39;d have expected that anything running the softdevice is going to spend so much time in flash that it&amp;#39;s pretty pointless moving a little of the user code to ram.&lt;/p&gt;
&lt;p&gt;Is current consumption actually an issue in your app you need to solve or are you just pre-optimizing?&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item></channel></rss>