1 Star 0 Fork 1

idoio_conn / Linux_Greenhouse-app

加入 Gitee
与超过 1200万 开发者一起发现、参与优秀开源项目,私有仓库也完全免费 :)
免费加入
克隆/下载
serial.h 564 Bytes
一键复制 编辑 原始数据 按行查看 历史
HoweiXue 提交于 2016-05-24 20:47 . Linux_Greenhouse-app
#ifndef _SERIAL_H_
#define _SERIAL_H_
#include <stdio.h>
#include <stdlib.h>
#include <unistd.h>
#include <fcntl.h>
#define SERIAL_MAX_LINECOUNT 700
typedef struct msg_t {
struct msg_t *next;
int len;
char body[SERIAL_MAX_LINECOUNT];
} SERIALMSG, *PSERIALMSG;
extern int open_serial(const char *devname, const char *fmt);
extern int close_serial();
extern char *read_serial(char *buf);
char *timed_read_serial(char *buf, int to_sec, int to_msec);
extern int clear_serial(void);
extern int write_serial(const char *buf, int len);
#endif//_SERIAL_H_
马建仓 AI 助手
尝试更多
代码解读
代码找茬
代码优化
1
https://gitee.com/idoio_conn/Linux_Greenhouse-app.git
git@gitee.com:idoio_conn/Linux_Greenhouse-app.git
idoio_conn
Linux_Greenhouse-app
Linux_Greenhouse-app
master

搜索帮助

344bd9b3 5694891 D2dac590 5694891