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

Unable to find the module using nRF UART

Hello everyone,

My job is to migrate a functionnal code made with IAR to GCC Eclipse.

When I compile with IAR and flash the hex file (softdevice and application) using nRFgo Studio, it works fine ! I can connect to my module and works well.

But when I migrated the code to Eclipse, I had to change some things for the compilation, the code compiles, the .hex file is generated but doesn't work I can't see my module when trying to connect using bluetooth.

It is may be the compilations options, what do you guys think?

Here are my CFLAGS:

CFLAGS = -DSOFTDEVICE_PRESENT -DNRF51 -DS110 -DBLE_STACK_SUPPORT_REQD -DBSP_DEFINES_ONLY -mcpu=cortex-m0 -mthumb -mabi=aapcs --std=gnu11 -Wall -mfloat-abi=soft -ffunction-sections -fdata-sections -fno-strict-aliasing --short-enums

The LDFLAGS:

LDFLAGS = -Xlinker -Map=$(LISTING_DIRECTORY)/$(OUTPUT_FILENAME).map -mthumb -mabi=aapcs -L $(TEMPLATE_PATH) -T$(LINKER_SCRIPT) -mcpu=cortex-m0 -Wl,--gc-sections --specs=nano.specs -lc -lnosys

The ASMFLAGS:

ASMFLAGS = -x assembler-with-cpp -DBOARD_PCA10028 -DSOFTDEVICE_PRESENT -DNRF51 -DS110 -DBLE_STACK_SUPPORT_REQD -DBSP_DEFINES_ONLY

Here is my linker script:

SEARCH_DIR(.)
GROUP(-lgcc -lc -lnosys)

MEMORY
{
  FLASH (rx) : ORIGIN = 0x18000, LENGTH = 0x27fff
  RAM (rwx) :  ORIGIN = 0x20002000, LENGTH = 0x5fff
}

INCLUDE "gcc_nrf51_common.ld"

Versions: GCC: 5.4 SDK: 8.1

Best regards,

--

Hamza

Parents Reply Children
No Data
Related