This post is older than 2 years and might not be relevant anymore
More Info: Consider searching for newer posts

nrf52840 C and C++ Combined

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't built for either.

I've converted over the Makefile and can compile the code successfully but my code isn't running. When compiling I get the following error and I assume this is the reason my code won't run:

Fullscreen
1
2
3
4
5
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
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX

My IDE is VSC with arm_ggc and the SDK is v16.

Fullscreen
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
PROJECT_NAME := ble_app_template_pca10056_s140
SDK_ROOT := ../../../nRF5SDK160098a08e2
PRJ_ROOT := ../../..
export OUTPUT_FILENAME
#MAKEFILE_NAME := $(CURDIR)/$(word $(words $(MAKEFILE_LIST)),$(MAKEFILE_LIST))
MAKEFILE_NAME := $(MAKEFILE_LIST)
MAKEFILE_DIR := $(dir $(MAKEFILE_NAME) )
TEMPLATE_PATH = $(SDK_ROOT)/components/toolchain/gcc
ifeq ($(OS),Windows_NT)
include $(TEMPLATE_PATH)/Makefile.windows
else
include $(TEMPLATE_PATH)/Makefile.posix
endif
MK := mkdir
RM := rm -rf
#echo suspend
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX

Any ideas as I've been stuck on this for hours.