你可以用mscomm控件.
有个函数: mscomm.input
dim strcom as string
strcom=mscomm.input
这个就是从串口读数据.
如果你的机器上装了多串口卡的驱动程序的话也可以使用那里的函数.
dim length_all as string
dim buf_all(len_buf) as string
len_buf=1024
length_all = sio_read(comm, buf_all(0), LEN_BUF)
buf_all() 用来存放读进来的数据.
有个函数: mscomm.input
dim strcom as string
strcom=mscomm.input
这个就是从串口读数据.
如果你的机器上装了多串口卡的驱动程序的话也可以使用那里的函数.
dim length_all as string
dim buf_all(len_buf) as string
len_buf=1024
length_all = sio_read(comm, buf_all(0), LEN_BUF)
buf_all() 用来存放读进来的数据.
解决方案 »
免费领取超大流量手机卡,每月29元包185G流量+100分钟通话, 中国电信官方发货