[問題] serial 導向問題

看板LinuxDev作者 (yshihyu)時間7年前 (2017/03/15 20:23), 編輯推噓0(001)
留言1則, 1人參與, 最新討論串1/1
https://gist.github.com/anonymous/dcb1765e005110cab52cfa571ac2ddf7 上面程式是碼 hello world 字串導向 /dev/ttyS0 sudo ./test_uart ttyS0 我開cutecom 跟 minicom 想收hello world 字串但都收不到 baud rate 兩邊都是115200 可是我導向某個終端機 sudo ./test_uart pts/22 可以收到 hello world 字串 不明白為什麼 ttyS0 收不到字串 謝謝 -- ※ 發信站: 批踢踢實業坊(ptt.cc), 來自: 175.181.157.189 ※ 文章網址: https://www.ptt.cc/bbs/LinuxDev/M.1489580623.A.A29.html

04/03 13:33, , 1F
fd = open(dev_name, O_RDWR | O_NOCTTY | O_NDELAY);?
04/03 13:33, 1F
文章代碼(AID): #1OoJ9Fef (LinuxDev)