更新时间:2023-02-21 22:23:45
serial = new phpSerial;
// 首先我们必须指定设备。这适用于linux和windows(如果
// 你的linux串行设备是/ dev COM1的/ ttyS0等)
serial = new phpSerial; // First we must specify the device. This works on both linux and windows (if // your linux serial device is /dev/ttyS0 for COM1, etc)
serial-> deviceSet( COM13跨度>);
// 我们可以更改波特率,奇偶校验,长度,停止位,流量控制
serial->deviceSet("COM13"); // We can change the baud rate, parity, length, stop bits, flow control
serial-> confBaudRate(9600);
serial->confBaudRate(9600);