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. java判定数据(对象)类型

    1.说明一 int 是关键字,Integer是包装类,Number是所有数字了的基类(父类).所以,Number是Integer的基础,Integer是int的基础,也称Integer是int的原型类 ...

  2. Servlet快速入门:第一个Servlet程序

    Servlet是整个JavaWeb开发的核心,同时也是一套规范,即公共接口.用于处理客户端发来的请求并作出响应.通常情况下我们会发送不同的请求并交由不同的处理程序来处理,例如处理用户信息和处理订单信息 ...

  3. Nuget & VS Plugin

    VS Plugin vsCode:https://marketplace.visualstudio.com/vscode vs:https://marketplace.visualstudio.com ...

  4. Android面试题 描述一下android的系统架构

    android系统架构从下往上为linux内核层.运行库.应用程序框架层和应用程序层. Linux Kernel:负责硬件的驱动程序.网络.电源.系统安全以及内存管理等功能. Libraries和an ...

  5. python之random、time与sys模块

     一.random模块 import random # float型 print(random.random()) #取0-1之间的随机小数 print(random.uniform(n,m)) #取 ...

  6. 基于Java+Selenium的WebUI自动化测试框架(七)--IE浏览器的设置

    在上一篇我们讲了关于WebDriver的版本,浏览器初始化,以及下载的设定. 在设置IE浏览器进行WebDriver的测试时,通常会遇见以下几种错误: 1.没有关闭IE浏览器的保护模式. 当运行测试用 ...

  7. HDU 4862 Jump 任意起点最大权K链不相交覆盖

    你可以从任意起点开始起跳最多K次 每次跳你可以选择往右或者往下跳 从(x1,y1)跳到(x2,y2) 消耗的能量是曼哈顿距离-1 但是如果每次跳的起点和终点格子里的数字是相同的为X的话你会得到X能量 ...

  8. 中文日历Calendar

    一.层次结构 Object<-----Calendar<-----EastAsianLunisolarCalendar<-----ChineseLunisolarCalendar(农 ...

  9. 沙箱模式以及其使用到的IIFE

    //沙箱 //与外界隔绝的一个环境,外界无法修改该环境内任何信息,沙箱内的东西单独属于一个世界 //360沙箱模式 //将软件和操作系统进行隔离,以达到安全的目的 //苹果手的app使用的就是沙箱模式 ...

  10. Postgresql Useful SQL/Commands

    Update records ' and a.subscriber_id=b.subscriber_id; Connections select count(*) from pg_stat_activ ...