www.pudn.com > wmmp-sms-linux.rar > ttyfun.h, change:2006-12-26,size:799b
#ifndef _TTY_FUN_H_ #define _TTY_FUN_H_ #include "typedef.h" #ifndef _LINUX_ #include "windows.h" #endif /* SERIAL DEFINE */ #define FLOWCTR_NONE 0 #define FLOWCTR_HARDWARE 1 #define FLOWCTR_XONXOFF 2 #define NO_PARITY 0 #define ODD_PARITY 1 #define EVEN_PARITY 2 //extern int gttyfd; //tty file descriptor #ifdef _WINDOWS_ extern HANDLE ghCom; #endif extern int wait_for_OK(int fd, const char *szMatch, uint uiTime); extern int opentty(const char *dev); extern int initialtty(int fd, int inspeed,int databits,int stopbits,int parity,int crtscts); extern int readtty(int fd, int len, int timeout, void *pRecv, int *pRetLen); extern int writetty(int fd, int len, int timeout, const void *pSend); extern int cleartty(int fd); extern int closetty(int fd); #endif