<?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>softdevice hex overlap other sectors in RTOS</title><link>https://devzone.nordicsemi.com/f/nordic-q-a/54198/softdevice-hex-overlap-other-sectors-in-rtos</link><description>Hello. 
 I run a project on RTOS base on embOS of Segger. Now I want to add a BLE task base on Nordic BLE peripheral UART. As a standalone project not on RTOS it is run O.K. But when I add it to the RTOS I get a warning it is overlap on other sectors</description><dc:language>en-US</dc:language><generator>Telligent Community 13</generator><lastBuildDate>Fri, 15 Nov 2019 10:30:38 GMT</lastBuildDate><atom:link rel="self" type="application/rss+xml" href="https://devzone.nordicsemi.com/f/nordic-q-a/54198/softdevice-hex-overlap-other-sectors-in-rtos" /><item><title>RE: softdevice hex overlap other sectors in RTOS</title><link>https://devzone.nordicsemi.com/thread/220263?ContentTypeID=1</link><pubDate>Fri, 15 Nov 2019 10:30:38 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:97f39a3b-076c-44c6-beb5-ec0d79c21c96</guid><dc:creator>Sigurd</dc:creator><description>[quote user="BarS"] I get pull to unknown address and my program starck in a loop.[/quote]
&lt;p&gt;&amp;nbsp;If you call e.g.&amp;nbsp;sd_app_evt_wait() it will call&amp;nbsp;__WFE() inside the SoftDevice.&lt;/p&gt;
[quote user="BarS"]But is there any problem could be arize if I use aa RTOS system (specific the Segger embOS)?[/quote]
&lt;p&gt;The SoftDevice uses&amp;nbsp;the&amp;nbsp;&lt;span&gt;peripherals &lt;a href="https://infocenter.nordicsemi.com/topic/sds_s140/SDS/s1xx/sd_resource_reqs/hw_block_interrupt_vector.html?cp=4_5_3_0_6_0"&gt;listed here&lt;/a&gt;.&amp;nbsp;&lt;/span&gt;Make sure that your application and/or embOS does not use them.&amp;nbsp;&lt;/p&gt;
&lt;p&gt;&lt;span&gt;Also note that the systick is sourced by the same clock as the CPU, which is turned off when going to WFE/WFI (sd_app_evt_wait()). It is therefore not recommended to use systick, but RTC or TIMER instead. It could be that embOS uses systick.&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span&gt;&lt;/span&gt;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: softdevice hex overlap other sectors in RTOS</title><link>https://devzone.nordicsemi.com/thread/219999?ContentTypeID=1</link><pubDate>Thu, 14 Nov 2019 08:36:01 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:ffac1ee9-8291-4185-a12e-7d5985f66edc</guid><dc:creator>Bar</dc:creator><description>&lt;p&gt;I follow the example use in the BLE UART and place the syntax on start of FLASH segment and RAM segment with the reserve define all in the flash_placment.xml.&lt;/p&gt;
&lt;p&gt;Also add the MACROS in the Linker option&amp;nbsp;&lt;/p&gt;
&lt;p&gt;FLASH_PH_START=0x0&lt;/p&gt;
&lt;p&gt;FLASH_PH_SIZE=0x100000&lt;/p&gt;
&lt;p&gt;RAM_PH_START=0x20000000&lt;/p&gt;
&lt;p&gt;RAM_PH_SIZE=0x40000&lt;/p&gt;
&lt;p&gt;FLASH_START=0x26000&lt;/p&gt;
&lt;p&gt;FLASH_SIZE=0xda000&lt;/p&gt;
&lt;p&gt;RAM_START=0x20002a98&lt;/p&gt;
&lt;p&gt;RAM_SIZE=0x3d568&lt;/p&gt;
&lt;p&gt;I also check that the hex file place on start with Segger explanationץ&lt;/p&gt;
&lt;p&gt;But when I start running after some commands I get pull to unknown address and my program starck in a loop. I am thinking it it is because the RAM assignment.&lt;/p&gt;
&lt;p&gt;As I see in my BLE_task.c&amp;nbsp;&lt;/p&gt;
&lt;p&gt;I set this one&lt;/p&gt;
&lt;p&gt;// Fetch the start address of the application RAM.&lt;br /&gt; uint32_t ram_start = 0;&lt;br /&gt; err_code = nrf_sdh_ble_default_cfg_set(APP_BLE_CONN_CFG_TAG, &amp;amp;ram_start);&lt;br /&gt; APP_ERROR_CHECK(err_code);&lt;/p&gt;
&lt;p&gt;// Enable BLE stack.&lt;br /&gt; err_code = nrf_sdh_ble_enable(&amp;amp;ram_start);&lt;/p&gt;
&lt;p&gt;So I know it place on start of RAM.&lt;/p&gt;
&lt;p&gt;But what about it size.&lt;/p&gt;
&lt;p&gt;I set the RAM for the project start on&amp;nbsp;&lt;span&gt;0x20002a98 which look enough for RAM.&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span&gt;But is there any problem could be arize if I use aa RTOS system (specific the Segger embOS)?&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span&gt;Maybe there modification need to be&amp;nbsp; done&amp;nbsp;also in thumb_crt0.s also?&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span&gt;Any clue?&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span&gt;Bar.&lt;/span&gt;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: softdevice hex overlap other sectors in RTOS</title><link>https://devzone.nordicsemi.com/thread/219924?ContentTypeID=1</link><pubDate>Wed, 13 Nov 2019 15:57:14 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:6d9404f0-60f6-4705-9382-2826864a62b0</guid><dc:creator>Sigurd</dc:creator><description>&lt;p&gt;In&amp;nbsp;the S140 v6.1.1 release notes we have the following:&lt;/p&gt;
&lt;p&gt;Flash: 152 kB (0x26000 bytes).&lt;br /&gt;RAM: 5.54 kB (0x1628 bytes). This is the minimum required memory. The actual requirements depend on the configuration chosen at sd_ble_enable() time.&lt;/p&gt;
&lt;p&gt;And from&amp;nbsp;the figure &lt;a href="https://infocenter.nordicsemi.com/topic/sds_s140/SDS/s1xx/mem_usage/mem_resource_map_usage.html?cp=3_5_3_0_13_0"&gt;here&lt;/a&gt;, flash starts at 0x0000000, and RAM at 0x20000000&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: softdevice hex overlap other sectors in RTOS</title><link>https://devzone.nordicsemi.com/thread/219755?ContentTypeID=1</link><pubDate>Tue, 12 Nov 2019 18:21:28 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:df99d312-8503-43be-83f0-7f96c5036180</guid><dc:creator>Bar</dc:creator><description>&lt;p&gt;I was copy the flash placement Macro as was show on the BLE project to my project and add the relevant define in the flash_placment.xml. I look on the MAP and I see that I get a reserve area on start of the FLASH size&amp;nbsp; 0x26000 and start of the RAM size 0x2a98 as written in the Macros .But I don&amp;#39;t understand how the SoftDevice know it reserve for him?&lt;/p&gt;
&lt;p&gt;More then that I can make the linking and get run but very quickly&amp;nbsp;it go to no code because the FLASH has some corrupt. It is look the SoftDevice get out of its bondury, or not set on the right place.&amp;nbsp;&amp;nbsp;&lt;/p&gt;
&lt;p&gt;So the question is the SoftDevice as in FLASH use and RAm know where to be place without any command from me?&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: softdevice hex overlap other sectors in RTOS</title><link>https://devzone.nordicsemi.com/thread/219543?ContentTypeID=1</link><pubDate>Mon, 11 Nov 2019 20:14:31 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:21a5cedc-c447-44be-a165-2e9164019b22</guid><dc:creator>Sigurd</dc:creator><description>&lt;p&gt;Hi,&lt;/p&gt;
&lt;p&gt;The embOS RTOS is provided by Segger, and not officially supported by Nordic, so we in Nordic have little experience with it.&amp;nbsp;The nRF5 SDK &lt;a href="https://infocenter.nordicsemi.com/topic/sdk_nrf5_v16.0.0/freertos.html?resultof=%22%46%72%65%65%52%54%4f%53%22%20%22%66%72%65%65%72%74%6f%22%20"&gt;officially support FreeRTOS&lt;/a&gt;, and you can find &lt;a href="https://infocenter.nordicsemi.com/topic/sdk_nrf5_v16.0.0/ble_sdk_app_hrs_freertos.html?cp=5_1_4_2_2_14"&gt;examples&lt;/a&gt; that uses FreeRTOS in the nRF5 SDK. You might also want to take a look at&amp;nbsp;&lt;a href="https://www.zephyrproject.org/"&gt;Zephyr RTOS&lt;/a&gt;.&lt;/p&gt;
&lt;p&gt;That said, it might be easier to start with a SES BLE project in the nRF5 SDK, and try to add embOS to that project. Documentation for the SoftDevice Memory resource map and usage can be found &lt;a href="https://infocenter.nordicsemi.com/topic/sds_s140/SDS/s1xx/mem_usage/mem_resource_map_usage.html?cp=3_5_3_0_13_0"&gt;here&lt;/a&gt;.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item></channel></rss>