當前位置:編程學習大全網 - 網站源碼 - 串口程序源代碼

串口程序源代碼

選項顯式

String形式的私有strData

私有子命令1_Click()'發送

MSComm1。Output = "123456 "

末端接頭

私有子窗體_Load()

MSComm1。Settings = "9600,N,8,1 "

Mscomm1。“rthreshold = 1”觸發ONCOMM事件。

MSComm1。PortOpen = True

MSComm1。“輸入模式= CominputModeText”ASCII接收

Text1 = " "

末端接頭

私有Sub MSComm 1 _ on com()

選擇案例摘要。MSComm1。CommEvent

案件受理

strData = Mscomm1。投入

0 = text 1 & amp;strData

結束選擇

末端接頭

  • 上一篇:ktv手機點歌微信怎麽退出
  • 下一篇:瘋狂坦克2的操作指南
  • copyright 2024編程學習大全網