串口调试 您所在的位置:网站首页 RTL8723DU蓝牙串口波特率 串口调试

串口调试

2024-07-17 14:44| 来源: 网络整理| 查看: 265

安装 minicom¶ sudo apt-get install minicom

连接好串口线的,看一下串口设备文件是什么,下面示例是 /dev/ttyUSB0

$ ls /dev/ttyUSB* /dev/ttyUSB0

运行:

$ sudo minicom Welcome to minicom 2.7 OPTIONS: I18n Compiled on Jan 1 2014, 17:13:19. Port /dev/ttyUSB0, 15:57:00 Press CTRL-A Z for help on special keys

以上提示 CTRL-A Z 是转义键,按 Ctrl-a 然后再按 Z 就可以调出帮助菜单。

+-------------------------------------------------------------------+ Minicom Command Summary | | | | Commands can be called by CTRL-A | | | | Main Functions Other Functions | | | | Dialing directory..D run script (Go)....G | Clear Screen.......C | | Send files.........S Receive files......R | cOnfigure Minicom..O | | comm Parameters....P Add linefeed.......A | Suspend minicom....J | | Capture on/off.....L Hangup.............H | eXit and reset.....X | | send break.........F initialize Modem...M | Quit with no reset.Q | | Terminal settings..T run Kermit.........K | Cursor key mode....I | | lineWrap on/off....W local Echo on/off..E | Help screen........Z | | Paste file.........Y Timestamp toggle...N | scroll Back........B | | Add Carriage Ret...U | | | | Select function or press Enter for none. | +--------------------------------------------------------------------+

根据提示按O进入设置界面,如下:

+-----[configuration]------+ | Filenames and paths | | File transfer protocols | | Serial port setup | | Modem and dialing | | Screen and keyboard | | Save setup as dfl | | Save setup as.. | | Exit | +--------------------------+

把光标移动到“Serial port setup”,按enter进入串口设置界面,再输入前面提示的字母,选择对应的选项,设置成如下:

+-----------------------------------------------------------------------+ | A - Serial Device : /dev/ttyUSB0 | | B - Lockfile Location : /var/lock | | C - Callin Program : | | D - Callout Program : | | E - Bps/Par/Bits : 1500000 8N1 | | F - Hardware Flow Control : No | | G - Software Flow Control : No | | | | Change which setting? | +-----------------------------------------------------------------------+

注意:Hardware Flow Control 和 Software Flow Control 都要设成 No,否则可能导致无法输入。

设置完成后回到上一菜单,选择 Save setup as dfl 即可保存为默认配置,以后将默认使用该配置。



【本文地址】

公司简介

联系我们

今日新闻

    推荐新闻

      专题文章
        CopyRight 2018-2019 实验室设备网 版权所有