xubuntu openocd nRF51822 download --- 2

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

make flash

make flash_s110

make flash_mbs

make flash_cload

具体执行过程如下:

[email protected]:~/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

[email protected]:~/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
[email protected]:~/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
[email protected]:~/projects/crazyflie2-nrf-firmware$
[email protected]:~/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
[email protected]:~/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全部下载进去,不用分步进行,一键搞定,真爽! 昨天的研究也没白费,终于搞懂了。

版权声明:本文为博主原创文章,未经博主允许不得转载。

时间: 2024-12-19 16:02:48

xubuntu openocd nRF51822 download --- 2的相关文章

xubuntu openocd nRF51822 download

最近发愁怎么在xubuntu系统里下载nRF51822和STM32F405RGT6的事情,今天终于下载成功,记录下解决的过程. 进入到bitcraze共享的Virtual Box虚拟机之后,进入到如下目录: cd /home/bitcraze/projects/crazyflie2-nrf-firmware/ 我们会发现Makefile文件, #Put your personal build config in config.mk and DO NOT COMMIT IT! -include c

[nRF51822] 14、浅谈蓝牙低功耗(BLE)的几种常见的应用场景及架构(科普类干货)

蓝牙在短距离无线通信领域占据举足轻重的地位—— 从手机.平板.PC到车载设备, 到耳机.游戏手柄.音响.电视, 再到手环.电子秤.智能医疗器械(血糖仪.数字血压计.血气计.数字脉搏/心率监视器.数字体温计.耳温枪.皮肤水分计等), 再到智能家居等领域均占有一席之地. 而蓝牙低功耗(BLE)是在蓝牙4.0协议上修改以适用低功耗应用场景的一种蓝牙协议. 随着上一股智能消费类电子大潮的到来,BLE的各种应用也像雨后春笋般在市场上铺开. 如果想 紧跟蓝牙协议的最新动态 ,可以在https://www.b

基于OpenOCD的vsllink调试器使用

@20150308 首先利用Mingw编译一个在Win7下可用的openocd.exe. 准备: 下载集成包:http://www.versaloon.com/download/MinGW_configured.7z 在C盘解压MinGW_configured.7z,然后打开C:msys1.0msys.bat,进入.homeopenocd目录.执行下面的命令 ./bootstrap ./configure –enable-jlink –enable-vsllink make 在src目录下的op

nrf51822 --- 外部中断(按键2)

1.目的 nrf51822外部中断 2.分析 在实际应用中经常要用到外部中断,比如按键唤醒. 3.平台: 协议栈版本:SDK10.0.0 编译软件:keil 5.12 硬件平台:微雪开发板nrf51822 例子:SDK 10.0.0\ 1.目的 nrf51822外部中断 2.分析 在实际应用中经常要用到外部中断,比如按键唤醒.在这里设置5个外部按键中断 3.平台: 协议栈版本:SDK10.0.0 编译软件:keil 5.12 硬件平台:微雪开发板nrf51822 例子:SDK 10.0.0\ex

[编译] 4、在Linux下搭建nRF51822的开发烧写环境(makefile版)

星期日, 09. 九月 2018 07:51下午 - beautifulzzzz 1.安装步骤 1) 从GNU Arm Embedded Toolchain官网下载最新的gcc-arm工具链,写文章时下载的是: gcc-arm-none-eabi-5_4-2016q3-20160926-linux.tar.bz2 2) 从NORDIC官网下载相应版本的SDK,我这里选择的是12.3.0版本: Code Name Version nRF5-SDK-v12-zip nRF5 SDK Zip File

[编译] 6、开源两个简单且有用的安卓APP命令行开发工具和nRF51822命令行开发工具

星期四, 27. 九月 2018 12:00上午 - BEAUTIFULZZZZ 一.前言 前几天给大家介绍了如何手动搭建安卓APP命令行开发环境和nRF51822命令行开发环境,中秋这几天我把上面篇文章的操作流程全部做成了shell脚本,使得可以让其他人简单运行下脚本.就能够直接建立绿色开发环境,岂不美哉? <[编译] 5.在Linux下搭建安卓APP的开发烧写环境(makefile版)-- 在Linux上用命令行+VIM开发安卓APP> <[编译] 4.在Linux下搭建nRF518

Download the Hibernate Tools

首先去官网上下载最新版本的Hibernate Tools JBoss Tools 4.5.0.Final Requirements: Java 8 and Eclipse Oxygen 4.7 有 4 中方法 下载Hibernate  Tools 1) Eclipse Market Place Drag and drop this icon into your active Eclipse Oxygen 4.7 workspace, or alternatively, search for "J

downLoad

String root= ServletActionContext.getServletContext().getRealPath(File.separator).replace("\\", File.separator); String fileName = "download.text"; File file = new File(root + fileName); in = new FileInputStream(file); // 设置响应正文的MIME类型

Android系统定制——Download Android System 及加载system镜像文件

定制android系统(配置及相关系统的镜像文件),具体可参考:Driver_All_in_One_V1.0--MT6735_6753.pdf文档,特别需要理解的是Download部分. 与之对应的软件是:Smart Phone Flash Tool,一般是在菜单栏的Download部分进行选择操作. Download-agent(下载代理):选择 \升级固件与升级固件的工具\SP_Flash_Tool_exe_Windows_v5.1536.00.000 文件(通常不用特别选择,使用默认的即可