serial.h
来自「一个linux下的用QT2编写的关于gprs的发短信,拨打电话的源码」· C头文件 代码 · 共 25 行
H
25 行
#ifndef _SERIAL_H_#define _SERIAL_H_#include <stdio.h>#include <string.h>#include <sys/types.h>#include <sys/stat.h>#include <fcntl.h>#include <unistd.h>#include <termios.h>#include <stdlib.h>#include <errno.h>class MySerial{public: MySerial(); ~MySerial();public: static int set_opt(int fd,int nSpeed, int nBits, char nEvent, int nStop); static int open_port(int fd,int comport); static int nwrite(int serialfd,const char *data,int datalength);};#endif
⌨️ 快捷键说明
复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?