无需串行端口或视频,可以使用什么简单的方法来调试嵌入式处理器? [英] What simple method can I use to debug an embedded processor without serial port or video?

查看:183
本文介绍了无需串行端口或视频,可以使用什么简单的方法来调试嵌入式处理器?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我们有一个没有任何视频或串行端口的小型嵌入式系统(即我们无法通过printf输出文本)。

我们希望通过初始化顺序跟踪代码的进度。 br>
有一些简单的事情我们可以帮助这个。

它没有运行任何操作系统,硬件平台有些可定制。

We have a small embedded system without any video or serial ports (i.e. we can't output text via printf).
We would like to track the progress of our code through the initialization sequence.
Is there some simple things we can do to help with this.
It is not running any OS, and the hardware platform is somewhat customizable.

推荐答案

最简单的最简单的解决方案是状态LED。基于动作切换LED,无论是二进制形式还是当您可以缩小焦点时出现某些操作。

The simplest most scalable solution are state LEDs. Toggle LEDs based on actions, either in binary form or when certain actions occur if you can narrow your focus.

最强大的将是一个硬件JTAG设备。你甚至不需要设置断点 - 只需能够停止应用程序并检查内存状态就足够了。请注意,某些硬件平台不支持花哨选项,如内存监视或硬件断点。前者通常会不断停止处理器和读取存储器(将您的10MHz系统转换为1kHz系统),而后者有时使用代码替换(替换不同跳转的目标指令)执行,这有时会掩盖其他问题。请注意这些问题及其适用的嵌入式处理器。

The most powerful will be a hardware JTAG device. You don't even need to set breakpoints - simply being able to stop the application and inspect the state of memory may be enough. Note that some hardware platforms do not support "fancy" options such as memory watches or hardware breakpoints. The former is usually worked around with constantly stopping the processor and reading memory (turns your 10MHz system into a 1kHz system), while the latter is sometimes performed using code replacement (replace the targeted instruction with a different jump), which sometimes masks other problems. Be aware of these issues and which embedded processors they apply to.

这篇关于无需串行端口或视频,可以使用什么简单的方法来调试嵌入式处理器?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆