在"c"中的串行通信被称为"c". [英] Serial communication in "c"
问题描述
我正在开发一个与现有系统对话的串行通信程序.系统设置如下:
波特率:19200
停止位:1
奇偶校验:无
数据位:8
11位数据分组包括一个起始位,八个数据位,第九个唤醒位"和一个停止位.可以使用奇偶校验位代替唤醒位.
如果我要发送:
"10100000001"
数据位:"00000001";后8位
唤醒位或奇偶校验位:"1";第9位
停止位:"0"第十位
起始位:"1";第11位
I''m working on a Serial communication program that will talk to an existing system. the system is set up as the following:
baudrate: 19200
stopbits: 1
parity: none
databits: 8
11 bit data packet consist of one start bit, eight data bits, a ninth "wakeup bit", and one stop bit. The parity bit can be used in place of the wakeup bit.
if I were to send:
"10100000001"
databits: "00000001" last 8 bits
wakeup bit or parity bit: "1" 9th bit
stop bit: "0" 10th bit
start bit: "1" 11th bit
Is this correct?
推荐答案
是否正确?这完全取决于串行电缆另一端的设备和程序. :-)
—SA
Correct or not? It totally depends on a device and a program on the other end of your serial cable. :-)
—SA
您可能想看一下这篇文章:
C ++的串行库 [
You may want to take a look at this article:
Serial library for C++[^]
Best regards
Espen Harlinn
这篇关于在"c"中的串行通信被称为"c".的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!