<?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>nrf52840 C and C++ Combined</title><link>https://devzone.nordicsemi.com/f/nordic-q-a/61708/nrf52840-c-and-c-combined</link><description>Hi 
 Im struggling to use the ble_app_template_cpp within SDKv16. I am using the nrf52840 DK (PCA10056) and want to us the S140 SoftDevice. The example isn&amp;#39;t built for either. 
 I&amp;#39;ve converted over the Makefile and can compile the code successfully but</description><dc:language>en-US</dc:language><generator>Telligent Community 13</generator><lastBuildDate>Thu, 06 Aug 2020 13:49:50 GMT</lastBuildDate><atom:link rel="self" type="application/rss+xml" href="https://devzone.nordicsemi.com/f/nordic-q-a/61708/nrf52840-c-and-c-combined" /><item><title>RE: nrf52840 C and C++ Combined</title><link>https://devzone.nordicsemi.com/thread/263468?ContentTypeID=1</link><pubDate>Thu, 06 Aug 2020 13:49:50 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:bc3b4c4e-a744-4098-8742-31a11a23470b</guid><dc:creator>aplatts</dc:creator><description>&lt;p&gt;Thanks, been on another project. I&amp;#39;ll look back into this issue next week.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: nrf52840 C and C++ Combined</title><link>https://devzone.nordicsemi.com/thread/255485?ContentTypeID=1</link><pubDate>Wed, 17 Jun 2020 10:52:12 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:91d7c9f1-dc7e-4d09-9fd1-923c4df009fa</guid><dc:creator>aplatts</dc:creator><description>&lt;p&gt;Hi Simonr&lt;/p&gt;
&lt;p&gt;How do I add the &amp;#39;reset-handler&amp;#39; entry point within my linker script?&lt;/p&gt;
&lt;p&gt;Thanks&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: nrf52840 C and C++ Combined</title><link>https://devzone.nordicsemi.com/thread/255459?ContentTypeID=1</link><pubDate>Wed, 17 Jun 2020 09:58:06 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:0c35a5c0-76a8-4fcb-8d03-1eacc18c0d46</guid><dc:creator>Torsten Robitzki</dc:creator><description>&lt;p&gt;I would set the environment variable VERBOSE, to force make to print the command line tool invocations.&amp;nbsp;Reset_Handler() should usually be implemented in the startup files and should have C binding. So, you should make sure, that the startup file is compiled, is compiled by a C compiler (not a C++ compiler) and that the resulting object file is linked into your binary. Looking into the map file might give hints to whether the&amp;nbsp;Reset_Handler() is linked in a C function or as C++ function.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: nrf52840 C and C++ Combined</title><link>https://devzone.nordicsemi.com/thread/255425?ContentTypeID=1</link><pubDate>Wed, 17 Jun 2020 08:23:15 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:a32d585d-4c48-4870-88e2-c3010a8c58ff</guid><dc:creator>Simonr</dc:creator><description>&lt;p&gt;Hi Andrew&lt;/p&gt;
&lt;p&gt;Can you make sure your Linker entry point is set to reset_handler, and that the debugger setting &amp;quot;Start From Entry Point Symbol&amp;quot; is set to&amp;nbsp;&lt;strong&gt;No&amp;nbsp;&lt;/strong&gt;in your application? Depending on which development environment you&amp;#39;re using, where you set these settings vary. This is in order to make sure we enter&amp;nbsp;the SoftDevice&amp;#39;s reset_handler() and not the application&amp;#39;s.&lt;/p&gt;
&lt;p&gt;Best regards,&lt;/p&gt;
&lt;p&gt;Simon&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: nrf52840 C and C++ Combined</title><link>https://devzone.nordicsemi.com/thread/255286?ContentTypeID=1</link><pubDate>Tue, 16 Jun 2020 13:39:39 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:c1173b5e-8619-4d8c-a2ff-44302b454b22</guid><dc:creator>aplatts</dc:creator><description>&lt;p&gt;Hi&lt;/p&gt;
&lt;p&gt;Same result, with or without the space:&lt;/p&gt;
&lt;p&gt;Linking target: nrf52840_xxaa.out&lt;br /&gt;/Users/andrewplatts/opt/gcc-arm-none-eabi-9-2019-q4-major/bin/../lib/gcc/arm-none-eabi/9.2.1/../../../../arm-none-eabi/bin/ld: warning: cannot find entry symbol Reset_Handler; defaulting to 0000000000027000&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: nrf52840 C and C++ Combined</title><link>https://devzone.nordicsemi.com/thread/254803?ContentTypeID=1</link><pubDate>Fri, 12 Jun 2020 20:28:49 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:c21639ea-492f-48a8-bf69-eb6cccd5c6e3</guid><dc:creator>Dmitry</dc:creator><description>&lt;p&gt;Hmm.. is there a line &amp;#39;&amp;#39;Assembling file: ..../modules/nrfx/mdk/gcc_startup_nrf52840.S&amp;quot; in build log?&lt;/p&gt;
&lt;p&gt;I don&amp;#39;t have VSC IDE, but the same line without space after &amp;quot;abspath&amp;quot; produces an empty output under my linux build environment.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: nrf52840 C and C++ Combined</title><link>https://devzone.nordicsemi.com/thread/254789?ContentTypeID=1</link><pubDate>Fri, 12 Jun 2020 16:22:00 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:606f490e-35fa-493c-b856-fa7403e2b996</guid><dc:creator>aplatts</dc:creator><description>&lt;p&gt;Hi Dmitry&lt;/p&gt;
&lt;p&gt;The file is found so the MakFile structure is correct.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: nrf52840 C and C++ Combined</title><link>https://devzone.nordicsemi.com/thread/254557?ContentTypeID=1</link><pubDate>Thu, 11 Jun 2020 16:09:41 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:81245bf7-40b5-43d6-a346-02db810646f0</guid><dc:creator>Dmitry</dc:creator><description>&lt;p&gt;Hi,&lt;/p&gt;
&lt;p&gt;seems there&amp;#39;s a space missing at line 135:&lt;/p&gt;
&lt;p&gt;ASM_SOURCE_FILES&amp;nbsp; = $(abspath $(SDK_ROOT)/modules/nrfx/mdk/gcc_startup_nrf52840.S)&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: nrf52840 C and C++ Combined</title><link>https://devzone.nordicsemi.com/thread/254521?ContentTypeID=1</link><pubDate>Thu, 11 Jun 2020 13:57:59 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:55751d75-07e6-4a05-ace3-a3a84bb594a8</guid><dc:creator>aplatts</dc:creator><description>&lt;p&gt;Hi Simon&lt;/p&gt;
&lt;p&gt;Yes, it is the original from the SDK (attached).&lt;/p&gt;
&lt;p&gt;&lt;a href="https://devzone.nordicsemi.com/cfs-file/__key/communityserver-discussions-components-files/4/gcc_5F00_startup_5F00_nrf52840.S"&gt;devzone.nordicsemi.com/.../gcc_5F00_startup_5F00_nrf52840.S&lt;/a&gt;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: nrf52840 C and C++ Combined</title><link>https://devzone.nordicsemi.com/thread/254476?ContentTypeID=1</link><pubDate>Thu, 11 Jun 2020 12:09:14 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:847217b1-f168-4cbd-85a7-378be3fecc97</guid><dc:creator>Nguyen Hoan Hoang</dc:creator><description>&lt;p&gt;27000 is exactly where you firmware starts when using it with Softdevice S140. &amp;nbsp;It is defined in the linker script.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: nrf52840 C and C++ Combined</title><link>https://devzone.nordicsemi.com/thread/254475?ContentTypeID=1</link><pubDate>Thu, 11 Jun 2020 12:08:44 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:c0aea36d-e538-4114-af46-b5f98da79b78</guid><dc:creator>Nguyen Hoan Hoang</dc:creator><description>&lt;p&gt;It&amp;#39;s C++ over the SDK. &amp;nbsp;The SDK is required as it is stated in the README.md&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: nrf52840 C and C++ Combined</title><link>https://devzone.nordicsemi.com/thread/254469?ContentTypeID=1</link><pubDate>Thu, 11 Jun 2020 12:00:00 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:f65a58da-229d-41f4-bf7a-95f9c6fa6ee7</guid><dc:creator>Simonr</dc:creator><description>&lt;p&gt;Hi Andrew&lt;/p&gt;
&lt;p&gt;Can you check that the&amp;nbsp;startup file that is used in your project is identical to the one provided in our SDK?&amp;nbsp;&lt;/p&gt;
&lt;p&gt;Best regards,&lt;/p&gt;
&lt;p&gt;Simon&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: nrf52840 C and C++ Combined</title><link>https://devzone.nordicsemi.com/thread/254228?ContentTypeID=1</link><pubDate>Wed, 10 Jun 2020 11:11:57 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:f309cf35-335e-4736-8efa-fb688606e1c7</guid><dc:creator>aplatts</dc:creator><description>&lt;p&gt;Hi Simor.&lt;/p&gt;
&lt;p&gt;Apologies I have been diverted by another project. Back on this issue now.&lt;br /&gt;&lt;br /&gt;The only reference within the MakeFile to _startup_nrf52840.S is within the ASM_SOURCE_FILES:&lt;/p&gt;
&lt;div&gt;
&lt;div&gt;&lt;span&gt;&lt;/span&gt;&lt;/div&gt;
&lt;pre class="ui-code" data-mode="text"&gt;#assembly files common to all targets
ASM_SOURCE_FILES = $(abspath$(SDK_ROOT)/modules/nrfx/mdk/gcc_startup_nrf52840.S)&lt;/pre&gt;
&lt;div&gt;&lt;span&gt;&lt;/span&gt;&lt;/div&gt;
&lt;div&gt;&lt;span&gt;&lt;/span&gt;&lt;/div&gt;
&lt;div&gt;&lt;span&gt;The folder &amp;#39;modules/nrfx/mdk/ is part of the SDK and contains many variants of _startup_nrf*****.S files. Not sure why this is an issue.&lt;/span&gt;&lt;/div&gt;
&lt;div&gt;&lt;span&gt;&lt;/span&gt;&lt;/div&gt;
&lt;div&gt;&lt;span&gt;I still get the following compile error:&lt;/span&gt;&lt;/div&gt;
&lt;div&gt;&lt;span&gt;&lt;/span&gt;&lt;/div&gt;
&lt;div&gt;&lt;span&gt;&lt;/span&gt;&lt;/div&gt;
&lt;div&gt;&lt;span&gt;-/opt/gcc-arm-none-eabi-9-2019-q4-major/bin/../lib/gcc/arm-none-eabi/9.2.1/../../../../arm-none-eabi/bin/ld: warning: cannot find entry symbol Reset_Handler; defaulting to 0000000000027000&lt;/span&gt;&lt;/div&gt;
&lt;div&gt;&lt;span&gt;&lt;/span&gt;&lt;/div&gt;
&lt;div&gt;&lt;span&gt;&lt;/span&gt;&lt;/div&gt;
&lt;div&gt;&lt;span&gt;Please advise.&lt;/span&gt;&lt;/div&gt;
&lt;div&gt;&lt;span&gt;&lt;/span&gt;&lt;/div&gt;
&lt;div&gt;&lt;span&gt;Thanks&lt;/span&gt;&lt;/div&gt;
&lt;/div&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: nrf52840 C and C++ Combined</title><link>https://devzone.nordicsemi.com/thread/251641?ContentTypeID=1</link><pubDate>Tue, 26 May 2020 08:59:02 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:b99c7717-2eb1-4a37-b71f-d3c11946e533</guid><dc:creator>Simonr</dc:creator><description>&lt;p&gt;Hi&lt;/p&gt;
&lt;p&gt;Please make sure that you don&amp;#39;t have any additional _startup_nrf52840.s files in your project, as we&amp;#39;ve seen this error before due to conflicting startup files.&lt;/p&gt;
&lt;p&gt;Best regards,&lt;/p&gt;
&lt;p&gt;Simon&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: nrf52840 C and C++ Combined</title><link>https://devzone.nordicsemi.com/thread/251543?ContentTypeID=1</link><pubDate>Mon, 25 May 2020 15:05:56 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:da138ecf-2262-4b03-aa33-fa619c0f75b4</guid><dc:creator>aplatts</dc:creator><description>&lt;p&gt;Hi Nguyen&lt;/p&gt;
&lt;p&gt;Thanks, but it isn&amp;#39;t the advice i was looking for: &amp;#39;use another SDK&amp;#39;. I prefer to use the manufactures SDK.&lt;/p&gt;
&lt;p&gt;I understand what the error is, but I don&amp;#39;t know how to resolve it with SDK16.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: nrf52840 C and C++ Combined</title><link>https://devzone.nordicsemi.com/thread/251347?ContentTypeID=1</link><pubDate>Sat, 23 May 2020 15:29:38 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:6e0a6d90-105f-4991-9d54-633e86fd7c0b</guid><dc:creator>Nguyen Hoan Hoang</dc:creator><description>&lt;p&gt;Sorry I didn&amp;#39;t see the error. &amp;nbsp;It is cause by the missing startup code. Somehow the linker did not find it.&lt;/p&gt;
&lt;p&gt;if you wish to use C++ with the SDK, checkout this library&amp;nbsp;&lt;a href="https://github.com/IOsonata/IOsonata"&gt;https://github.com/IOsonata/IOsonata&lt;/a&gt;. It supports different ARM vendors including the nRF series&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: nrf52840 C and C++ Combined</title><link>https://devzone.nordicsemi.com/thread/251344?ContentTypeID=1</link><pubDate>Sat, 23 May 2020 14:45:17 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:775e3e66-1581-4e5f-b354-006261685cc4</guid><dc:creator>aplatts</dc:creator><description>&lt;p&gt;Hi Nguyen&lt;/p&gt;
&lt;p&gt;I&amp;#39;ll try that, but not sure how that will fix this issue:&lt;/p&gt;
&lt;p&gt;&lt;pre class="ui-code" data-mode="text"&gt;Compiling file: main.cpp
Linking target: nrf52840_xxaa.out
/Users/home/opt/gcc-arm-none-eabi-9-2019-q4-major/bin/../lib/gcc/arm-none-eabi/9.2.1/../../../../arm-none-eabi/bin/ld: warning: cannot find entry symbol Reset_Handler; defaulting to 0000000000027000
Preparing: nrf52840_xxaa.bin
Preparing: nrf52840_xxaa.hex&lt;/pre&gt;&lt;/p&gt;
&lt;p&gt;This is a compile error of the main code nothing to do with the SD.&lt;/p&gt;
&lt;p&gt;Thanks&lt;/p&gt;
&lt;p&gt;Andrew&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: nrf52840 C and C++ Combined</title><link>https://devzone.nordicsemi.com/thread/251312?ContentTypeID=1</link><pubDate>Fri, 22 May 2020 18:17:19 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:451a2301-cda1-4c19-8cd3-f26d69544f26</guid><dc:creator>Nguyen Hoan Hoang</dc:creator><description>&lt;p&gt;Flashing softdevice and firmware separately might not work. &amp;nbsp;Try use mergehex to merge them together.&amp;nbsp;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: nrf52840 C and C++ Combined</title><link>https://devzone.nordicsemi.com/thread/251302?ContentTypeID=1</link><pubDate>Fri, 22 May 2020 16:34:44 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:ddb479bb-c3ee-4f66-9aa6-7d45dee39e1a</guid><dc:creator>aplatts</dc:creator><description>&lt;p&gt;Hi Patrick&lt;br /&gt;&lt;br /&gt;It is included (see line 134 of MakeFile):&lt;/p&gt;
&lt;p&gt;#assembly files common to all targets&lt;br /&gt;ASM_SOURCE_FILES = $(abspath$(SDK_ROOT)/modules/nrfx/mdk/gcc_startup_nrf52840.S)&lt;/p&gt;
&lt;p&gt;Thanks&lt;/p&gt;
&lt;p&gt;Andrew&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: nrf52840 C and C++ Combined</title><link>https://devzone.nordicsemi.com/thread/251298?ContentTypeID=1</link><pubDate>Fri, 22 May 2020 16:23:16 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:531c275f-4073-4e66-8fe8-9476d54a2fb9</guid><dc:creator>Patrick</dc:creator><description>&lt;p&gt;Make sure you have included gcc_startup_nrf52840.S, located in modules/nrfx/mdk, in your project.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item></channel></rss>