bluerange-io / bluerange-mesh

BlueRange Mesh (formerly FruityMesh) - The first completely connection-based open source mesh on top of Bluetooth Low Energy (4.1/5.0 or higher)
https://bluerange.io/
Other
287 stars 109 forks source link

Building works, nothing happens after entering debugger #70

Closed xiamaiani closed 7 years ago

xiamaiani commented 7 years ago

Hello,

FruityMesh build now. However when i try to debug it nothing really happens. At first i got some errors that the path to JLinkGDBServerCL.exe was wrong so i changed it. also i needed to edit the usb serial. After I have done this i try to debug it, but for some reason it doesnt start at main. I have softdevice S130 2.0.0 programmed on the board

Edit: Here is my hex build file, maybe it helps

FruityMesh.zip

This is what the debugger says:

debug

`SEGGER J-Link GDB Server V5.12f Command Line Version

JLinkARM.dll V5.12f (DLL compiled May 17 2016 16:03:35)

-----GDB Server start settings----- GDBInit file: none GDB Server Listening port: 2331 SWO raw output listening port: 2332 Terminal I/O port: 2333 Accept remote connection: localhost only Generate logfile: on Verify download: on Init regs on start: on Silent mode: off Single run mode: on Target connection timeout: 0 ms ------J-Link related settings------ J-Link Host interface: USB J-Link script: none J-Link settings file: none ------Target related settings------ Target device: nRF51822_xxAA Target interface: SWD Target interface speed: 1000kHz Target endian: little

Connecting to J-Link... J-Link is connected. Firmware: J-Link Lite-Cortex-M V8 compiled Aug 20 2015 17:57:19 Hardware: V8.00 S/N: 518002839 Feature(s): GDB Checking target voltage... Target voltage: 3.22 V Listening on TCP/IP port 2331 Connecting to target...Connected to target Waiting for GDB connection...Connected to 127.0.0.1 Reading all registers Read 4 bytes @ address 0x00000000 (Data = 0x000007C0) Target interface speed set to 1000 kHz Resetting target Halting target CPU... ...Target halted (PC = 0x000006D0) R0 = FFFFFFFF, R1 = FFFFFFFF, R2 = FFFFFFFF, R3 = FFFFFFFF R4 = FFFFFFFF, R5 = FFFFFFFF, R6 = FFFFFFFF, R7 = FFFFFFFF R8 = FFFFFFFF, R9 = FFFFFFFF, R10= FFFFFFFF, R11= FFFFFFFF R12= FFFFFFFF, R13= 000007C0, MSP= 000007C0, PSP= FFFFFFFC R14(LR) = FFFFFFFF, R15(PC) = 000006D0 XPSR C1000000, APSR C0000000, EPSR 01000000, IPSR 00000000 CFBP 00000000, CONTROL 00, FAULTMASK 00, BASEPRI 00, PRIMASK 00 Reading all registers Read 4 bytes @ address 0x000006D0 (Data = 0x4C174916) Select auto target interface speed (2000 kHz) Flash breakpoints disabled Read 4 bytes @ address 0x000006D0 (Data = 0x4C174916) Downloading 1024 bytes @ address 0x0001B000 - Verified OK Downloading 8 bytes @ address 0x0001B400 - Verified OK Downloading 4096 bytes @ address 0x0001B408 - Verified OK Downloading 4096 bytes @ address 0x0001C408 - Verified OK Downloading 4096 bytes @ address 0x0001D408 - Verified OK Downloading 4096 bytes @ address 0x0001E408 - Verified OK Downloading 4096 bytes @ address 0x0001F408 - Verified OK Downloading 4096 bytes @ address 0x00020408 - Verified OK Downloading 4096 bytes @ address 0x00021408 - Verified OK Downloading 4096 bytes @ address 0x00022408 - Verified OK Downloading 4096 bytes @ address 0x00023408 - Verified OK Downloading 4096 bytes @ address 0x00024408 - Verified OK Downloading 4096 bytes @ address 0x00025408 - Verified OK Downloading 4096 bytes @ address 0x00026408 - Verified OK Downloading 4096 bytes @ address 0x00027408 - Verified OK Downloading 4096 bytes @ address 0x00028408 - Verified OK Downloading 4096 bytes @ address 0x00029408 - Verified OK Downloading 4096 bytes @ address 0x0002A408 - Verified OK Downloading 2103 bytes @ address 0x0002B408 - Verified OK Downloading 8 bytes @ address 0x0002BC40 - Verified OK Downloading 300 bytes @ address 0x0002BC48 - Verified OK Writing register (PC = 0x0001b408) Read 4 bytes @ address 0x0001B408 (Data = 0xAF00B580) Resetting target Halting target CPU... ...Target halted (PC = 0x000006D0) R0 = FFFFFFFF, R1 = FFFFFFFF, R2 = FFFFFFFF, R3 = FFFFFFFF R4 = FFFFFFFF, R5 = FFFFFFFF, R6 = FFFFFFFF, R7 = FFFFFFFF R8 = FFFFFFFF, R9 = FFFFFFFF, R10= FFFFFFFF, R11= FFFFFFFF R12= FFFFFFFF, R13= 000007C0, MSP= 000007C0, PSP= FFFFFFFC R14(LR) = FFFFFFFF, R15(PC) = 000006D0 XPSR C1000000, APSR C0000000, EPSR 01000000, IPSR 00000000 CFBP 00000000, CONTROL 00, FAULTMASK 00, BASEPRI 00, PRIMASK 00 Reading all registers Read 4 bytes @ address 0x000006D0 (Data = 0x4C174916) Starting target CPU... ...Target halted (DBGRQ, PC = 0xFFFFFFFE) Reading all registers Read 4 bytes @ address 0xFFFFFFFE (Data = 0x4C174916) Reading 64 bytes @ address 0x00000000 Reading 64 bytes @ address 0x00000040 Read 4 bytes @ address 0x20007FFC (Data = 0x00000000) Read 4 bytes @ address 0x20007FF8 (Data = 0x00000000) Read 4 bytes @ address 0x00000000 (Data = 0x000007C0) Read 4 bytes @ address 0x20007FF4 (Data = 0x00000000) Read 4 bytes @ address 0x20007FF4 (Data = 0x00000000) Read 4 bytes @ address 0x00000000 (Data = 0x000007C0) Read 4 bytes @ address 0x20007FFC (Data = 0x00000000) Read 4 bytes @ address 0x20007FF4 (Data = 0x00000000) Read 4 bytes @ address 0xFFFFFFFF (Data = 0x000007C0) Reading 64 bytes @ address 0xFFFFFFC0`

EDIT: I tried the same with Informatic's makefiles. I downloaded fruitymesh version 12b87d80. i changed the makefiles and changed the linker files. I rebuild and try to debug These are the results:

debug1

`SEGGER J-Link GDB Server V5.12f Command Line Version

JLinkARM.dll V5.12f (DLL compiled May 17 2016 16:03:35)

-----GDB Server start settings----- GDBInit file: none GDB Server Listening port: 2331 SWO raw output listening port: 2332 Terminal I/O port: 2333 Accept remote connection: localhost only Generate logfile: on Verify download: on Init regs on start: on Silent mode: off Single run mode: on Target connection timeout: 0 ms ------J-Link related settings------ J-Link Host interface: USB J-Link script: none J-Link settings file: none ------Target related settings------ Target device: nRF51822_xxAA Target interface: SWD Target interface speed: 1000kHz Target endian: little

Connecting to J-Link... J-Link is connected. Firmware: J-Link Lite-Cortex-M V8 compiled Aug 20 2015 17:57:19 Hardware: V8.00 S/N: 518002839 Feature(s): GDB Checking target voltage... Target voltage: 3.22 V Listening on TCP/IP port 2331 Connecting to target...Connected to target Waiting for GDB connection...Connected to 127.0.0.1 Reading all registers Read 4 bytes @ address 0x00000000 (Data = 0x000007C0) Target interface speed set to 1000 kHz Resetting target Halting target CPU... ...Target halted (PC = 0x000006D0) R0 = FFFFFFFF, R1 = FFFFFFFF, R2 = FFFFFFFF, R3 = FFFFFFFF R4 = FFFFFFFF, R5 = FFFFFFFF, R6 = FFFFFFFF, R7 = FFFFFFFF R8 = FFFFFFFF, R9 = FFFFFFFF, R10= FFFFFFFF, R11= FFFFFFFF R12= FFFFFFFF, R13= 000007C0, MSP= 000007C0, PSP= FFFFFFFC R14(LR) = FFFFFFFF, R15(PC) = 000006D0 XPSR C1000000, APSR C0000000, EPSR 01000000, IPSR 00000000 CFBP 00000000, CONTROL 00, FAULTMASK 00, BASEPRI 00, PRIMASK 00 Reading all registers Read 4 bytes @ address 0x000006D0 (Data = 0x4C174916) Select auto target interface speed (2000 kHz) Flash breakpoints disabled Read 4 bytes @ address 0x000006D0 (Data = 0x4C174916) Downloading 936 bytes @ address 0x0001B000 - Verified OK Downloading 124 bytes @ address 0x0001B3A8 - Verified OK Writing register (PC = 0x0001b000) Read 4 bytes @ address 0x0001B000 (Data = 0x00007531) Resetting target Halting target CPU... ...Target halted (PC = 0x000006D0) R0 = FFFFFFFF, R1 = FFFFFFFF, R2 = FFFFFFFF, R3 = FFFFFFFF R4 = FFFFFFFF, R5 = FFFFFFFF, R6 = FFFFFFFF, R7 = FFFFFFFF R8 = FFFFFFFF, R9 = FFFFFFFF, R10= FFFFFFFF, R11= FFFFFFFF R12= FFFFFFFF, R13= 000007C0, MSP= 000007C0, PSP= FFFFFFFC R14(LR) = FFFFFFFF, R15(PC) = 000006D0 XPSR C1000000, APSR C0000000, EPSR 01000000, IPSR 00000000 CFBP 00000000, CONTROL 00, FAULTMASK 00, BASEPRI 00, PRIMASK 00 Reading all registers Read 4 bytes @ address 0x000006D0 (Data = 0x4C174916) Starting target CPU... ...Target halted (DBGRQ, PC = 0xFFFFFFFE) Reading all registers Read 4 bytes @ address 0xFFFFFFFE (Data = 0x4C174916) Reading 64 bytes @ address 0x00000000 Reading 64 bytes @ address 0x00000040 Read 4 bytes @ address 0x0000752C (Data = 0xE0008948) Read 4 bytes @ address 0x00007528 (Data = 0xD50107B8) Read 4 bytes @ address 0xD50107B8 (Data = 0x00000000) Read 4 bytes @ address 0x0000752C (Data = 0xE0008948) Read 4 bytes @ address 0xFFFFFFFF (Data = 0xE00007C0) Read 4 bytes @ address 0x00007524 (Data = 0x4950E7E2) Read 4 bytes @ address 0x4950E7E2 (Data = 0x00000000) Read 4 bytes @ address 0x0000752C (Data = 0xE0008948) Read 4 bytes @ address 0x00007524 (Data = 0x4950E7E2) Read 4 bytes @ address 0xFFFFFFFF (Data = 0x490007C0) Read 4 bytes @ address 0x490007B8 (Data = 0x00000000) Read 4 bytes @ address 0x00007524 (Data = 0x4950E7E2) Read 4 bytes @ address 0x00007524 (Data = 0x4950E7E2) Read 4 bytes @ address 0x00007524 (Data = 0x4950E7E2) Read 4 bytes @ address 0x4950E7E2 (Data = 0x00000000) Read 4 bytes @ address 0x0000752C (Data = 0xE0008948) Read 4 bytes @ address 0x00007524 (Data = 0x4950E7E2) Read 4 bytes @ address 0x00007524 (Data = 0x4950E7E2) Read 4 bytes @ address 0xFFFFFFFF (Data = 0x490007C0) Read 4 bytes @ address 0x490007B8 (Data = 0x00000000)`

I hope you can help me with this.

Kind regards