配置設備 tcsetatttr, tcgetattr
Write, read 寫/讀數據
關閉close
一.虛擬機串行端口設置:
1.關閉Ubuntu
2.接好6818開發板串口
3.打開:編輯虛擬機設置
4.點擊下方:添加
5.點擊: 串行端口
6.點擊:完成
7.OK
8.開啟Ubuntu
二.Linux下minicom配置
1.安裝 :sudo apt-get install minicom
sudo minicom
ctrl A —-> O —-> Serial port setup
Change which setting?
———————————————————————–
回車
保存 —–> Save setup as dfl
-----[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 |
--------------------------
回車 ————>>>> Exit from Minicom
sudo minicom —–>>> 回車 (若光標下移,則成功,否則改Serial Device : /dev/ttyS2,還不行就一直往上加)
Minicom發送文件
進入minicom終端 : sudo minicom
Welcome to minicom 2.5
OPTIONS: I18n
Compiled on May 2 2011, 00:39:27.
Port /dev/ttyS2
Press CTRL-A Z for help on special keys
[root@GEC6818 /]#AT S7=45 S0=0 L1 V1 X4 &c1 E1 Q0
-/bin/sh: c1: not found
-/bin/sh: AT: not found[root@GEC6818 /]#
[1] Done(127) AT S7=45 S0=0 L1 V1 X4
[root@GEC6818 /]#
[root@GEC6818 /]#
root@GEC6818 /]#rx write_serial 回車
輸入完后按ctrl a s
更多關于云服務器,域名注冊,虛擬主機的問題,請訪問三五互聯官網:m.shinetop.cn