Skip to content

Not running well with nRF52832 dev board #1

@daguhl

Description

@daguhl

Debugging happens well with JLink GDB server and command line arm-none-eabi-gdb. Without breakpoints the target runs normally.

With gnu-debugger plugin, even setting no breakpoint, the target starts but at some early init point stops with a SIGTRAP, and keeps stopping there if continuing execution.

Setup:

  • Mac OSX 10.13.6
  • Visual Studio Code v1.30.1
  • Toolchain gcc-arm-none-eabi-6-2017-q2-update-mac, same result as gcc-arm-none-eabi-7-2018-q2-update-mac.
  • J-Link software v640
  • Nordic nRF52832 dev board with J-Link OB

Code at PC: vendor/cmsis/CMSIS/Include/core_cm4.h:1641

/** \brief  Set Pending Interrupt

    The function sets the pending bit of an external interrupt.

    \param [in]      IRQn  Interrupt number. Value cannot be negative.
 */
__STATIC_INLINE void NVIC_SetPendingIRQ(IRQn_Type IRQn)
{
  NVIC->ISPR[(((uint32_t)(int32_t)IRQn) >> 5UL)] = (uint32_t)(1UL << (((uint32_t)(int32_t)IRQn) & 0x1FUL));
}

Debug stack:

?? @ 0x000008CC (Unknown Source:0)
<signal handler called> @ 0xFFFFFFF1 (Unknown Source:0)
?? @ 0x000005DC (Unknown Source:0)
<signal handler called> @ 0xFFFFFFF9 (Unknown Source:0)
NVIC_SetPendingIRQ @ 0x0001DF44 (/Users/daguhl/quark/vendor/cmsis/CMSIS/Include/core_cm4.h:1641)
...snip...

Debug console:

program     = /Users/daguhl/quark/gcc_eclipse/build_quark_app/quark_app.elf
Toolchain   = /usr/local/gcc-arm-none-eabi-7-2018-q2-update/bin
Client      = /usr/local/gcc-arm-none-eabi-7-2018-q2-update/bin/arm-none-eabi-gdb
Server      = JLinkGDBServer
Server host = localhost
Server port = 2331
Server success
Client success
sdacc_nvic_critical_region_exit (critical_region=...) at ../nrf52/sd_access_s112v6.h:732
732	{

Resetting target

Program received signal SIGTRAP, Trace/breakpoint trap.
0x000008cc in ?? ()

Program received signal SIGTRAP, Trace/breakpoint trap.
0x000008cc in ?? ()

Program received signal SIGTRAP, Trace/breakpoint trap.
0x000008cc in ?? ()

...snip...

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions