一、安装配置minicom
1、安装minicom
lingd@ubuntu:~$ sudo apt-get install minicom
2、配置minicom
lingd@ubuntu:~$ sudo minicom -s
出现这样的配置界面:
+-----[configuration]------+
| Filenames and paths |
| File transfer protocols |
| Serial port setup |
| Modem and dialing |
| Screen and keyboard |
| Save setup as dfl |
| Save setup as.. |
| Exit |
| Exit from Minicom |
+--------------------------+
选择Serial port setup, 会看到这样的选项:
+-----------------------------------------------------------------------+
| A - Serial Device : /dev/ttyS0 |
| B - Lockfile Location : /var/lock |
| C - Callin Program : |
| D - Callout Program : |
| E - Bps/Par/Bits : 115200 8N1 |
| F - Hardware Flow Control : No |
| G - Software Flow Control : No |
| |
| Change which setting? |
+-----------------------------------------------------------------------+
输入前面对应的字母即可进入相应的选项。将选项A的值设置为/dev/ttyS0 表示是串口1,将选项E的值设置为115200,将选项F设置为NO(请根据实际情况配置).
设置默认上传/下载的目录,选择Filenames and paths , 会看到这样的选项:
+-----------------------------------------------------------------------+
| A - Download directory : /home/lingd/arm/download |
| B - Upload directory : /home/lingd/arm/upload |
| C - Script directory : |
| D - Script program : runscript |
| E - Kermit program : |
| F - Logging options |
| |
| Change which setting? |
+-----------------------------------------------------------------------+
注意:开发板发送给pc的文件将保存在Download directory所设定的目录中,而pc要下载到开发板的文件保存在Upload directory所设定的目录中
设置完成后,选择”Save setup as dfl”,保存为默认设置.
然后选择“Exit”,即可进入Minicom的主界面:
Welcome to minicom 2.4
OPTIONS: I18n
Compiled on Jan 25 2010, 06:49:09.
Port /dev/ttyS0
Press CTRL-A Z for help on special keys
按Ctrl-A,再按z,可以获取到minicom CTRL-A命令的帮助信息
Welco+-------------------------------------------------------------------+
| Minicom Command Summary |
OPTIO| |
Compi| Commands can be called by CTRL-A
Port | |
| Main Functions Other Functions |
Press| |
| 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 | scroll Back........B |
| |
| Select function or press Enter for none. |
| |
| Written by Miquel van Smoorenburg 1991-1995 |
| Some additions by Jukka Lahtinen 1997-2000 |
| i18n by Arnaldo Carvalho de Melo 1998 |
+-------------------------------------------------------------------+
CTRL-A Z for help |115200 8N1 | NOR | Minicom 2.4 | VT102 | Offline
其中,我们用CTRL-A s来发送文件给开发板;而用CTRL-A r来接收开发板上的文件
二、为pc安装lrzsz
lrzsz is a unix communication package providing the XMODEM, YMODEM ZMODEM file transfer protocols.
lingd@ubuntu:~$ sudo apt-get install lrzsz
三、交叉编译lrzsz并下载到开发板上
1、下载lrzsz源码包
到htt
『本文转载自网络,版权归原作者所有,如有侵权请联系删除』