linux java usb 串口_2019-11-02 Linux下USB-串口的使用
在實驗室配置一臺設備要用到串口,但串口線只連到了linux服務器上,又不想跑一趟實驗室,就直接用linux串口連吧,以前都在windows上用putty, securecrt軟件,還真沒直接在linux上使用,查一下命令記錄一下。
1、lsmod | grep usbserial
root@cfl-lab01:~# lsmod | grep usb
usbserial 45056 3 pl2303
看到支持usb-串口設備
2、找到這個USB設備
root@cfl-lab01:~# lsusb
Bus 002 Device 003: ID 0424:2660 Standard Microsystems Corp. Hub
Bus 002 Device 002: ID 8087:0024 Intel Corp. Integrated Rate Matching Hub
Bus 002 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub
Bus 003 Device 001: ID 1d6b:0001 Linux Foundation 1.1 root hub
Bus 001 Device 004: ID 067b:2303 Prolific Technology, Inc. PL2303 Serial Port
Bus 001 Device 002: ID 8087:0024 Intel Corp. Integrated Rate Matching Hub
Bus 001 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub
其中
Bus 001 Device 004: ID 067b:2303 Prolific Technology, Inc. PL2303 Serial Port
就是usb轉串口設備。
3、查看系統是否已識別
root@cfl-lab01:~# dmesg | grep tty
[11500024.905422] pl2303 ttyUSB0: pl2303 converter now disconnected from ttyUSB0
[11500042.302008] usb 1-1.4: pl2303 converter now attached to ttyUSB0
一切ok,可以使用putty或minicom作為串口通信軟件。
創作挑戰賽新人創作獎勵來咯,堅持創作打卡瓜分現金大獎總結
以上是生活随笔為你收集整理的linux java usb 串口_2019-11-02 Linux下USB-串口的使用的全部內容,希望文章能夠幫你解決所遇到的問題。
- 上一篇: Tensorflow-(4)使用Tens
- 下一篇: 小米 redmibook 14 锐龙版