xubuntu openocd nRF51822 download --- 2

原创 2015年07月10日 23:34:14

昨天很晚的时候才终于发现其实Unkown USB Device并不是错误,只是个警告而已,所以我们不关心就可以,让Makefile继续往下走就可以,于是我尝试mbs,s110,cload和firmware的下载,执行如下命令:

make flash
make flash_s110
make flash_mbs
make flash_cload

具体执行过程如下:

bitcraze@bitcraze-vm:~/projects/crazyflie2-nrf-firmware$ make flash_mbs
openocd -d2 -f interface/stlink-v2.cfg -f target/nrf51_stlink.tcl -c init -c targets -c "reset halt" \
                 -c "flash write_image erase bootloaders/nrf_mbs_v1.0.hex" -c "verify_image bootloaders/nrf_mbs_v1.0.hex" -c "reset halt" \
               -c "mww 0x4001e504 0x01" -c "mww 0x10001014 0x3F000" \
               -c "reset run" -c shutdown
Open On-Chip Debugger 0.8.0 (2014-05-10-23:21)
Licensed under GNU GPL v2
For bug reports, read
	http://openocd.sourceforge.net/doc/doxygen/bugs.html
debug_level: 2
Info : This adapter doesn't support configurable speed
Info : STLINK v2 JTAG v16 API v2 SWIM v0 VID 0x0483 PID 0x3748
Info : using stlink api v2
Info : Target voltage: 2.556986
Info : nrf51.cpu: hardware has 4 breakpoints, 2 watchpoints
    TargetName         Type       Endian TapName            State       
--  ------------------ ---------- ------ ------------------ ------------
 0* nrf51.cpu          hla_target little nrf51.cpu          halted
target state: halted
target halted due to debug-request, current mode: Thread 
xPSR: 0xc1000000 pc: 0x000006d0 msp: 0x000007c0
auto erase enabled
Warn : Unknown device (HWID 0x00000058)
^CMakefile:122: recipe for target 'flash_mbs' failed
make: *** [flash_mbs] Interrupt

bitcraze@bitcraze-vm:~/projects/crazyflie2-nrf-firmware$ make flash_mbs
openocd -d2 -f interface/stlink-v2.cfg -f target/nrf51_stlink.tcl -c init -c targets -c "reset halt" \
                 -c "flash write_image erase bootloaders/nrf_mbs_v1.0.hex" -c "verify_image bootloaders/nrf_mbs_v1.0.hex" -c "reset halt" \
               -c "mww 0x4001e504 0x01" -c "mww 0x10001014 0x3F000" \
               -c "reset run" -c shutdown
Open On-Chip Debugger 0.8.0 (2014-05-10-23:21)
Licensed under GNU GPL v2
For bug reports, read
	http://openocd.sourceforge.net/doc/doxygen/bugs.html
debug_level: 2
Info : This adapter doesn't support configurable speed
Info : STLINK v2 JTAG v16 API v2 SWIM v0 VID 0x0483 PID 0x3748
Info : using stlink api v2
Info : Target voltage: 2.556986
Info : nrf51.cpu: hardware has 4 breakpoints, 2 watchpoints
    TargetName         Type       Endian TapName            State       
--  ------------------ ---------- ------ ------------------ ------------
 0* nrf51.cpu          hla_target little nrf51.cpu          halted
target state: halted
target halted due to debug-request, current mode: Thread 
xPSR: 0xc1000000 pc: 0x000006d0 msp: 0x000007c0
auto erase enabled
Warn : Unknown device (HWID 0x00000058)
wrote 3072 bytes from file bootloaders/nrf_mbs_v1.0.hex in 19.481831s (0.154 KiB/s)
target state: halted
target halted due to breakpoint, current mode: Thread 
xPSR: 0x61000000 pc: 0x2000002e msp: 0x000007c0
verified 2112 bytes in 0.288700s (7.144 KiB/s)
target state: halted
target halted due to debug-request, current mode: Thread 
xPSR: 0xc1000000 pc: 0x000006d0 msp: 0x000007c0
shutdown command invoked
bitcraze@bitcraze-vm:~/projects/crazyflie2-nrf-firmware$ make flash_cload
openocd -d2 -f interface/stlink-v2.cfg -f target/nrf51_stlink.tcl -c init -c targets -c "reset halt" \
                 -c "flash write_image erase bootloaders/cload_nrf_v1.0.hex" -c "verify_image bootloaders/cload_nrf_v1.0.hex" -c "reset halt" \
               -c "mww 0x4001e504 0x01" -c "mww 0x10001014 0x3F000" \
               -c "mww 0x4001e504 0x01" -c "mww 0x10001080 0x3A000" -c "reset run" -c shutdown
Open On-Chip Debugger 0.8.0 (2014-05-10-23:21)
Licensed under GNU GPL v2
For bug reports, read
	http://openocd.sourceforge.net/doc/doxygen/bugs.html
debug_level: 2
Info : This adapter doesn't support configurable speed
Info : STLINK v2 JTAG v16 API v2 SWIM v0 VID 0x0483 PID 0x3748
Info : using stlink api v2
Info : Target voltage: 2.556986
Info : nrf51.cpu: hardware has 4 breakpoints, 2 watchpoints
    TargetName         Type       Endian TapName            State       
--  ------------------ ---------- ------ ------------------ ------------
 0* nrf51.cpu          hla_target little nrf51.cpu          running
target state: halted
target halted due to debug-request, current mode: Thread 
xPSR: 0xc1000000 pc: 0x000006d0 msp: 0x000007c0
auto erase enabled
Warn : Unknown device (HWID 0x00000058)
wrote 13312 bytes from file bootloaders/cload_nrf_v1.0.hex in 82.957291s (0.157 KiB/s)
target state: halted
target halted due to breakpoint, current mode: Thread 
xPSR: 0x61000000 pc: 0x2000002e msp: 0x000007c0
verified 12368 bytes in 0.351360s (34.375 KiB/s)
target state: halted
target halted due to debug-request, current mode: Thread 
xPSR: 0xc1000000 pc: 0x000006d0 msp: 0x000007c0
shutdown command invoked
bitcraze@bitcraze-vm:~/projects/crazyflie2-nrf-firmware$ 
bitcraze@bitcraze-vm:~/projects/crazyflie2-nrf-firmware$ make flash_s110
openocd -d2 -f interface/stlink-v2.cfg -f target/nrf51_stlink.tcl -c init -c targets -c "reset halt" \
                 -c "nrf51 mass_erase" \
                 -c "flash write_image erase s110/s110_nrf51822_7.0.0_softdevice.hex" \
                 -c "reset run" -c shutdown
Open On-Chip Debugger 0.8.0 (2014-05-10-23:21)
Licensed under GNU GPL v2
For bug reports, read
	http://openocd.sourceforge.net/doc/doxygen/bugs.html
debug_level: 2
Info : This adapter doesn't support configurable speed
Info : STLINK v2 JTAG v16 API v2 SWIM v0 VID 0x0483 PID 0x3748
Info : using stlink api v2
Info : Target voltage: 2.558242
Info : nrf51.cpu: hardware has 4 breakpoints, 2 watchpoints
    TargetName         Type       Endian TapName            State       
--  ------------------ ---------- ------ ------------------ ------------
 0* nrf51.cpu          hla_target little nrf51.cpu          running
target state: halted
target halted due to debug-request, current mode: Thread 
xPSR: 0xc1000000 pc: 0x000006d0 msp: 0x000007c0
Warn : Unknown device (HWID 0x00000058)
auto erase enabled
Info : Padding image section 0 with 2112 bytes
wrote 87040 bytes from file s110/s110_nrf51822_7.0.0_softdevice.hex in 543.104126s (0.157 KiB/s)
shutdown command invoked
bitcraze@bitcraze-vm:~/projects/crazyflie2-nrf-firmware$ make flash
openocd -d2 -f interface/stlink-v2.cfg -f target/nrf51_stlink.tcl -c init -c targets -c "reset halt" \
                 -c "flash write_image erase cf2_nrf.hex" -c "verify_image cf2_nrf.hex" \
                 -c "reset run" -c shutdown
Open On-Chip Debugger 0.8.0 (2014-05-10-23:21)
Licensed under GNU GPL v2
For bug reports, read
	http://openocd.sourceforge.net/doc/doxygen/bugs.html
debug_level: 2
Info : This adapter doesn't support configurable speed
Info : STLINK v2 JTAG v16 API v2 SWIM v0 VID 0x0483 PID 0x3748
Info : using stlink api v2
Info : Target voltage: 2.558242
Info : nrf51.cpu: hardware has 4 breakpoints, 2 watchpoints
    TargetName         Type       Endian TapName            State       
--  ------------------ ---------- ------ ------------------ ------------
 0* nrf51.cpu          hla_target little nrf51.cpu          running
target state: halted
target halted due to debug-request, current mode: Thread 
xPSR: 0xc1000000 pc: 0x000006d0 msp: 0x000007c0
auto erase enabled
Warn : Unknown device (HWID 0x00000058)
wrote 45056 bytes from file cf2_nrf.hex in 282.951080s (0.156 KiB/s)
target state: halted
target halted due to breakpoint, current mode: Thread 
xPSR: 0x61000000 pc: 0x2000002e msp: 0x000007c0
verified 44944 bytes in 0.579762s (75.705 KiB/s)
shutdown command invoked
那其实,在Makefile的最后,我们可以看到:

factory_reset:
	make mass_erase
ifeq ($(strip $(S110)),1)
	make flash_s110
	make flash_mbs
	make flash_cload
endif
	make flash
所以看上去如果S110=1,那么只要执行make factory_reset就可以将s110,mbs,cload和firmware全部下载进去,不用分步进行,一键搞定,真爽! 昨天的研究也没白费,终于搞懂了。

xubuntu openocd nRF51822 download

最近发愁怎么在xubuntu系统里下载nRF51822和STM32F405RGT6的事情,今天终于下载成功,记录下解决的过程。 进入到bitcraze共享的Virtual Box虚拟机之后,进入到如下...
  • xingqingly
  • xingqingly
  • 2015年07月09日 23:32
  • 1250

openOCD+jlink调试uboot

转载: 点击打开链接
  • LH806732
  • LH806732
  • 2014年04月10日 21:32
  • 905

BLE-nRF51822学习(2)-芯片手册阅读

ARM芯片已经hen
  • iamlvshijie
  • iamlvshijie
  • 2014年11月21日 13:50
  • 2045

NRF51822 download 程序出错

问题一:Download softdevice 出错使用nRFgo download softDevice 时出现programming failed 问题二: 使用KEIL download 程序...
  • zBen_Daydream
  • zBen_Daydream
  • 2015年07月12日 15:11
  • 299

Error:Flash Download Failed-"Cortex-M0"

今天打算用KEIL把例程download到新买的nRF51822开发板上, 却download不进去,弹出Error:Flash Download Failed-"Cortex-M0" 检查了...
  • ganxiniuhe
  • ganxiniuhe
  • 2015年04月25日 11:17
  • 2508

Ubuntu下使用OpenOCD通过Jlink烧写HEX到STM32

本文地址:http://blog.csdn.net/smarxx/article/details/8486052,转载请保留 本文前提:     1、OpenOCD(v0.6)已经装好,并且打开J...
  • SMarxX
  • SMarxX
  • 2013年01月09日 17:21
  • 5354

使用 OpenOCD 进行单步调试

虽然不喜欢进行单步调试,但是不可否认它的重要性,所以也尝试了一下,以帮助后来有需要的小伙伴。关于 ESP32 的更多博客,请查看 【ESP32 系列博客 - 目录】【安装 OpenOCD】 本人使...
  • tidyjiang
  • tidyjiang
  • 2017年05月22日 15:25
  • 1797

openocd0.6.0的安装与配置

1. openocd0.6.0安装 1.1. 源码下载     下载代码主要有两种方式:     1.从openocd的官网(http://openocd.berlios.de/web/...
  • hcx25909
  • hcx25909
  • 2012年02月19日 18:40
  • 2482

stm32的调试之路-OpenOCD+JLINK

这两天吧cortex m3的开发调试环境给弄好了,只可惜还没有写过程序,没有用OpenOCD真正的调试过程序, 今天大体了解了一下GPIO的资料,看了看libopencm3中gpio.h。 仿照例...
  • xiaocaoguangming
  • xiaocaoguangming
  • 2011年11月15日 00:08
  • 4257

STM32环境准备:JLink + OpenOCD

http://blog.arduino.cn/2009/06/06/stm32%E7%8E%AF%E5%A2%83%E5%87%86%E5%A4%87%EF%BC%9Ajlink-openocd/ 终...
  • jordon_ah
  • jordon_ah
  • 2009年07月31日 11:48
  • 5602
内容举报
返回顶部
收藏助手
不良信息举报
您举报文章:xubuntu openocd nRF51822 download --- 2
举报原因:
原因补充:

(最多只允许输入30个字)