Skip to content

Instantly share code, notes, and snippets.

@fanoush
Last active March 11, 2021 17:39
Show Gist options
  • Save fanoush/06eee6344a2e59f7b12707b25d87edda to your computer and use it in GitHub Desktop.
Save fanoush/06eee6344a2e59f7b12707b25d87edda to your computer and use it in GitHub Desktop.
first console:
pi@raspberrypi:~ $ sudo openocd -d2 -f interface/stlink.cfg -f target/nrf52.cfg
Open On-Chip Debugger 0.10.0+dev-00637-gb3ed97a4 (2019-01-03-22:45)
Licensed under GNU GPL v2
For bug reports, read
http://openocd.org/doc/doxygen/bugs.html
debug_level: 2
Info : auto-selecting first available session transport "hla_swd". To override use 'transport select <transport>'.
Info : The selected transport took over low-level target control. The results might differ compared to plain JTAG/SWD
adapter speed: 1000 kHz
Info : Listening on port 6666 for tcl connections
Info : Listening on port 4444 for telnet connections
Info : clock speed 1000 kHz
Info : STLINK V2J17S4 (API v2) VID:PID 0483:3748
Info : Target voltage: 3.264253
Info : nrf52.cpu: hardware has 6 breakpoints, 4 watchpoints
Info : Listening on port 3333 for gdb connections
Info : accepting 'telnet' connection on tcp/4444
#0 : nrf52.flash (nrf5) at 0x00000000, size 0x00000000, buswidth 1, chipwidth 1
#1 : nrf52.uicr (nrf5) at 0x10001000, size 0x00000000, buswidth 1, chipwidth 1
Info : nRF52832-QFAA(build code: B0) 512kB Flash
wrote 524288 bytes to file flash-bank0.bin from flash bank 0 at offset 0x00000000 in 11.674448s (43.856 KiB/s)
shutdown command invoked
Info : dropped 'telnet' connection
second console:
pi@raspberrypi:~ $ telnet localhost 4444
Trying ::1...
Trying 127.0.0.1...
Connected to localhost.
Escape character is '^]'.
Open On-Chip Debugger
> flash banks
#0 : nrf52.flash (nrf5) at 0x00000000, size 0x00000000, buswidth 1, chipwidth 1
#1 : nrf52.uicr (nrf5) at 0x10001000, size 0x00000000, buswidth 1, chipwidth 1
> flash read_bank 0 flash-bank0.bin
nRF52832-QFAA(build code: B0) 512kB Flash
wrote 524288 bytes to file flash-bank0.bin from flash bank 0 at offset 0x00000000 in 11.674448s (43.856 KiB/s)
> shutdown
shutdown command invoked
Connection closed by foreign host.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment