jlink

Keil 5使用JLink直接调试正在运行的CPU

℡╲_俬逩灬. 提交于 2019-11-28 23:15:18
环境: 目标CPU:STM32F429 连接工具:JLink V9 连接方式:SWO 调试工具:Keil MDK 5.20 使用场景: 目标板正在运行,但是出BUG了,需要调试,而当前又没有在线debug, 于是就需要用调试器在不复位CPU的前提下附着到正在运行的板子上. 使用步骤: 1.首先确认你有与当前CPU运行的程序一样的源码,编译时生成了调试信息(Debug Information). 2.修改debug设置,去掉"Load Appcalition at Startup"的勾选. 3.检查JLink的设置,"Connect:Normal"表示正常连接,不复位,"Reset:Normal" 表示连接后不复位,不勾选"Reset after Conn",不勾选"Download to Flash" 4.将JLink连接至目标板的调试接口. 5.点击Keil中的调试按钮,启动调试.前面的设置正确的话CPU会停止运行,但不会复位,此时只能看汇编指令,没有C源码. 6.在Command窗口输入命令:LOAD %L INCREMENTAL(这条命令是加载当前项目的输出文件,读取调试信息,这样就可以看到C源码了). 7.现在就和正常调试一样了. 备注: 第6步还有另一种方式自动加载,在"Debug"设置对话框里填入一个"Initialization File:", 在该文件里面写上

Upload images to Imgur from Mathematica

与世无争的帅哥 提交于 2019-11-28 17:10:23
Here's a challenge to all mathematica tag followers. Let's make it a lot more convenient to insert images into SO post from Mathematica by creating an imgur uploader. How can we create a function imgur[g_] that will rasterize its argument (making sure that the final size is not wider than the width of StackOverflow posts), convert it to PNG, upload it to imgur, and return a ready to be pasted MarkDown line such as ![Mathematica graphic](http://i.imgur.com/ZENa4.jpg) ? Useful references: Imgur API Example of using POST request from Mathematica on WRI blog (posting to Twitter) by ragfield

解放串口调试(使用JLink SEGGER RTT来打印和输入调试信息)

十年热恋 提交于 2019-11-27 22:41:57
解放串口调试(使用JLink SEGGER RTT来打印和输入调试信息) 之前调试一直使用的串口作为调试口,但是由于串口数量的限制所以必须找到另一种方法作为调试使用。于是在网上寻找到了这个方法,在此记录方便以后的查询。 1、使用 JLINK SEGGER RTT 打印调试信息 很简单,首先从Jlink官网上下载RTT代码,然后将这四个文件添加到自己工程中去,并且在主程序工程中添加 SEGGER_RTT.h 文件。相关代码下载链接( 点击打开链接 )。 之后可以使用 SEGGER_RTT_printf(0,"Test%d %s %x\n",count,"123",0x10); 打印调试信息,在JLINK安装目录中打开J-Link RTT Viewer,就可以看到调试信息。初步测试好像不能打印浮点型的数据。 打印信息如下: 2、RTT输入检测 首先在程序中添加SEGGER_RTT_Read(0,rtt_buf,sizeof(rtt_buf)); 其次在 J-Link RTT Viewer控制台的Input里面选择Sending/Send on Enter,然后End of Line选择None 这样就可以通过下方输入框输入信息,按Enter发送 这样,程序里面接收数组rtt_buf就是输入框所输入的信息。 这个工具还是很好用的。有需要的可以参考下。 来源: CSDN 作者:

PlatformIO+Jlink进行调试

风格不统一 提交于 2019-11-27 21:24:57
PlatformIO自带调试功能具体配置如下 https://docs.platformio.org/en/latest/plus/debug-tools/jlink.html 我是用的是直接用jlink连接STM32进行所有的开发和调试功能 只需要几步简单的操作: 1、Add Configuration文件 在Platformio.ini中添加如下配置 1 [env:genericSTM32F103ZE] 2 platform = ststm32 3 board = genericSTM32F103ZE 4 framework = cmsis 5 upload_protocol = jlink 6 build_flags = -g 7 debug_tool = jlink 2、点击甲壳虫,选择configuration文件里添加的那个name的调试器来进行调试。 如图为调试界面,各种寄存器信息、变量信息、和调试操作按键。 上面的是用PlatformIO自带的调试功能。 还用另外一种调试是通过Cortex-Debug插件来进行调试的 1、VS code 插件管理器中搜索 Cortex Debug 2、platformio.ini中添加 1 build_flags=-g 3、添加调试配置 VS Code 菜单栏——调试——添加配置 选择{}Cortex Debug:JLink

Upload images to Imgur from Mathematica

独自空忆成欢 提交于 2019-11-27 10:14:44
问题 Here's a challenge to all mathematica tag followers. Let's make it a lot more convenient to insert images into SO post from Mathematica by creating an imgur uploader. How can we create a function imgur[g_] that will rasterize its argument (making sure that the final size is not wider than the width of StackOverflow posts), convert it to PNG, upload it to imgur, and return a ready to be pasted MarkDown line such as ![Mathematica graphic](http://i.imgur.com/ZENa4.jpg) ? Useful references: Imgur

Is there a way to add maven dependencies while using the maven-jlink-plugin?

谁说我不能喝 提交于 2019-11-27 02:06:32
I'm using this Github project to get exposed to the new modular features in Java 9. I would like to add dependencies to the project and be able to build a native image. However, when I try to add a new dependency to the pom.xml, and add the requires statement to the module-info.java, I get a the following error from the maven-jlink-plugin: Error: module-info.class not found for joda.time module I'm trying to use this as a proof of concept that I can deploy images using the new linking phase, but naturally I need to be able to have external dependencies and I need to use maven (work constraint)

Create Java runtime image on one platform for another using Jlink

随声附和 提交于 2019-11-26 16:08:12
问题 I created runtime image using jlink on my Linux machine. And I see linux folder under the include folder. Does it mean that I can use this runtime image only for Linux platform? If yes, are there any ways to create runtime images on one platform for another (e.g. on Linux for Windows and vice versa) 回答1: The include directory is for header files, such as jni.h , that are needed when compiling C/C++ code that uses JNI and other native interfaces. It's nothing to do with jlink . The jlink tool