Debug (printf) Viewer

http://www.keil.com/support/man/docs/uv4/uv4_db_dbg_serialwin.htm

Serial Window

The Serial window accepts serial input and output data streams. The window displays serial output data received from a simulated CPU, while characters typed into a serial window are input to the simulated CPU. This allows testing a UART interface prior to having the target hardware.

The Debug (printf) Viewer is a special serial window that can exchange data with the microcontoller. For Cortex-M microcontrollers, the window displays printf-data received from the Instrumentation Trace Macrocell (ITM). To redirect output, refer also to Retarget Output via ITM, and Debug Access in the CMSIS documentation.

Open these windows using the toolbar button or the menu View - Serial Windows.

The Context Menu allows:

  • Clearing the window.
  • Copying and saving the content to the clipboard or a file.
  • Setting a Carriage Return to every Line Feed that is received (enabled by default).
  • Switching to various representation modes.
    Terminal Mode Text formatting and cursor control sequences are supported (see table below).
    ASCII Mode Every printable character is displayed. An unprintable character is displayed as white-space (' ').
    HEX Mode Every character is displayed as a HEX-number.
    Mixed Mode Every character is displayed as a HEX-number and ASCII character. An unprintable character is displayed as dot ('.').

ANSI VT100 Terminal Sequences

Sequence Description
  From Target −→ µVision
CR ('\r') Carriage Return
LF ('\n') Line Feed
TAB ('\t') Tabulator
BS (0x08) Back Space
BEL (0x07) Bell
 
<ESC>[C Move cursor (position) 1 to the right
<ESC>[D Move cursor (position) 1 to the left
<ESC>[K Delete line right to cursor
 
<ESC>[J Clear screen
<ESC>[y;xf Set cursor to Row y, Column x; (x,y) are numeric ASCII values
  From µVision ⇒ Target
<ESC>[A Cursor Key UP
<ESC>[B Cursor Key DOWN
<ESC>[C Cursor Key RIGHT
<ESC>[D Cursor Key LEFT

Examples

// Clear screen and set cursor home
void ClearScreen(void)
{
printf("%c[1;1f%c[J", 27, 27);
} // set cursor to position (x, y)
void SetCursorPosition(int x, int y)
{
printf("%c[%i;%if", 27, (signed int)y, (signed int)x);
}

See also

ST Debug (printf) Viewer for Jlink的更多相关文章

  1. Keil ARM-CM3 printf输出调试信息到Debug (printf) Viewer

    参考资料:http://www.keil.com/support/man/docs/jlink/jlink_trace_itm_viewer.htm 1.Target Options -> De ...

  2. Keil Debug (printf) Viewer

    Debug (printf) Viewer Home » µVision Windows » Debug (printf) Viewer The Debug (printf) Viewer windo ...

  3. MDK Debug (printf) Viewer打印数据

    1.Target Options -> Debug -> Settings(JLink) -> Debug里ort选择SW模式 2.在Target Options -> Deb ...

  4. STM32 使用 printf 发送数据配置方法 -- 串口 UART, JTAG SWO, JLINK RTT

    STM32串口通信中使用printf发送数据配置方法(开发环境 Keil RVMDK) http://home.eeworld.com.cn/my/space-uid-338727-blogid-47 ...

  5. 【转】keil+stm32+jlink利用swd方式进行printf输出

    出处:http://www.douban.com/note/248637026/ ----------------------------------------------------------- ...

  6. Jlink使用技巧之虚拟串口功能

    前言 串口调试是单片机开发过程必不可少的一个功能,一般是使用一个UART-TTL的串口模块来实现串口的功能,其实下载调试使用的Jlink仿真器也可以实现串口调试的功能,本篇文章将介绍如何使用Jlink ...

  7. Keil debugging techniques and alternative printf (SWO function)

    One of the basic needs of the embedded software development through the terminal to output debugging ...

  8. 使用SWO代替UART,实现Printf打印功能

    JTAG接口中,有个SWO引脚,一直没有在意,也没有去研究过是干嘛用的.直到发现ST-LINK V2-1上也有个SWO引脚,于是去研究学习它的作用,用起来相比UART方得便多. 本文内容已经整理成PD ...

  9. 【STM32H7教程】第8章 STM32H7的终极调试组件Event Recorder

    完整教程下载地址:http://forum.armfly.com/forum.php?mod=viewthread&tid=86980 第8章   STM32H7的终极调试组件Event Re ...

随机推荐

  1. Windows 网络凭证

    前言 单位内部,员工之间电脑免不了要相互访问(eg:访问共享文件夹).这就引出网络凭证的概念,即你用什么身份访问对端计算机. 实验环境 创建共享文件夹 WinSrv 2008上新建的文件夹shared ...

  2. 静态库 VS 动态库

    如何得到库 ①先写好一堆的.c文件(.c:我们所需要的各种工具函数) ②将这些.c编译为对应的.o ③将所有的这些.o打包为一个仓库文件(静态库或者动态库) 静态库:按照静态库的方式打包 动态库:按照 ...

  3. Django drf:手撸自定义跨域

    项目需求: 1.用域名8000向8001发送请求,用django框架解决跨域问题 2.用上自定义中间件配置,支持get.post.put.detele和非简单请求 3.支持版本控制 4.在settin ...

  4. 用Jmeter做性能测试,之后报表展示

    https://octoperf.com/blog/2017/10/19/how-to-analyze-jmeter-results/ 看到性能测试平台的开发,我在想需要什么功能,报表需要什么样子的 ...

  5. DDD总览

    DDD总览 领域驱动设计(DDD)编码实践   目录 写在前面DDD总览实现业务的3种常见方式基于业务的分包领域模型的门面——应用服务业务的载体——聚合根实体 vs 值对象聚合根的家——资源库创生之柱 ...

  6. YUSS Round 1

    YUSS Round 1 A. 国庆快乐 签到题. #include<bits/stdc++.h> using namespace std; int main() { printf(&qu ...

  7. synchronized关键字所生成的字节码详细分析

    在之前已经将如下这样的源文件对应的字节码文件完整的分析完了,如下: 这次再来写一个内容稍丰富一点的类,准备再来从头至尾的来分析一下,对其字节码的理解进一步巩固,如下: 然后用javap -verbos ...

  8. 0018SpringBoot连接docker中的mysql并使用druid数据源

    由于druid数据源自带监控功能,所以引用druid数据源 1.centos7中安装并启动docker 2.docker安装并启动mysql 3.pom.xml中引入druid依赖 4.applica ...

  9. 分享私藏多年的Markdown编辑器

    相信很多人都使用 Markdown 来编写文章,Markdown 语法简洁,使用起来很是方便,而且各大平台几乎都已支持 Markdown 语法 那么,如何选择一款趁手的 Markdown 编辑器,就是 ...

  10. 是什么是FBC CBV

    - FBV url   -   函数 - CBV url   -   view