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

Programming MDBT40 with Jlink: Failed to download RAMCode!

Hi,

I am trying to program MDBT40 with Jlink and having some problems. Here is the scenario: I have two versions of the MDBT40. One that I took off a BLE NANO (RedBear Labs, 256kb Flash, 16Kb RAM), and one I ordered from SeeedStudio (256kb Flash, 32kb RAM). I connected the MDBT40 with 32kHz crystal and two capacitors (15pf), VDD, GND, SCLK snd SDIO. I compiled the ble_app_hrs using SDK 8.00 and successfully upload it to the 16kb RAM version. It ran and I was able to see it with Nordic Master Toolbox App. However, when I try to repeat the same procedure with the 32kb version, I get the following error ("Failed to download RAMCode!", see below).

Is there any specific operation I need to do before the first flash of the device? Another related question, in the "ble_app_hrs_gcc_nrf51.ld" file, what should be the values? Right now, I am using the following:

FLASH (rx) : ORIGIN = 0x18000, LENGTH = 0x28000 RAM (rwx) : ORIGIN = 0x20002000, LENGTH = 0x2000

I don't fully understand why these values work with the 16kb version... I found somewhere on the internet that I need to change the RAM length from 8000 to 2000 (0x8000 is the default for the nRF DK). But 0x2000 doesn't correspond to 16Kb....

Please help!

Thanks,

Shay


Device "NRF51822_XXAA" selected.

Found SWD-DP with ID 0x0BB11477 Found Cortex-M0 r0p0, Little endian. FPUnit: 4 code (BP) slots and 0 literal slots CoreSight components: ROMTbl 0 @ F0000000 ROMTbl 0 [0]: F00FF000, CID: B105100D, PID: 000BB471 ROM Table ROMTbl 1 @ E00FF000 ROMTbl 1 [0]: FFF0F000, CID: B105E00D, PID: 000BB008 SCS ROMTbl 1 [1]: FFF02000, CID: B105E00D, PID: 000BB00A DWT ROMTbl 1 [2]: FFF03000, CID: B105E00D, PID: 000BB00B FPB ROMTbl 0 [1]: 00002000, CID: 00000000, PID: 00000000 ??? Cortex-M0 identified. J-Link>loadbin s110.hex 0 Halting CPU for downloading file. Downloading file [s110.hex]... ****** Error: Failed to download RAMCode! Unspecified error -1

Parents Reply Children
No Data
Related