diff options
Diffstat (limited to 'PACE/pace/posix/termios.h')
-rw-r--r-- | PACE/pace/posix/termios.h | 48 |
1 files changed, 29 insertions, 19 deletions
diff --git a/PACE/pace/posix/termios.h b/PACE/pace/posix/termios.h index e2fdb0d8af8..36f6d5e44d5 100644 --- a/PACE/pace/posix/termios.h +++ b/PACE/pace/posix/termios.h @@ -13,8 +13,8 @@ * * ============================================================================ */ -#ifndef PACE_SYS_TERMIOS_H_POSIX -#define PACE_SYS_TERMIOS_H_POSIX +#ifndef PACE_SYS_TERMIOS_H +#define PACE_SYS_TERMIOS_H #include "pace/sys/types.h" #include <termios.h> @@ -23,28 +23,38 @@ extern "C" { #endif /* PACE_HAS_CPLUSPLUS) */ -#ifndef PACE_CC_T -#define PACE_CC_T -typedef cc_t pace_cc_t; -#endif /* PACE_CC_T */ + PACE_INLINE speed_t pace_cfgetospeed (const struct termios * termiosp); -#ifndef PACE_SPEED_T -#define PACE_SPEED_T -typedef speed_t pace_speed_t; -#endif /* PACE_SPEED_T */ + PACE_INLINE int pace_cfsetospeed (struct termios * termios_p, speed_t speed); -#ifndef PACE_TCFLAG_T -#define PACE_TCFLAG_T -typedef tcflag_t pace_tcflag_t; -#endif /* PACE_TCFLAG_T */ + PACE_INLINE speed_t pace_cfgetispeed (const struct termios * termios_p); -#ifndef PACE_TERMIOS -#define PACE_TERMIOS -typedef struct termios pace_termios; -#endif /* PACE_TERMIOS */ + PACE_INLINE int pace_cfsetispeed (struct termios * termios_p, speed_t speed); + + PACE_INLINE int pace_tcdrain (int fildes); + + PACE_INLINE int pace_tcflow (int fildes, int action); + + PACE_INLINE int pace_tcflush (int fildes, int queue_selector); + + PACE_INLINE int pace_tcgetattr (int fildes, struct termios * termios_p); + + PACE_INLINE pid_t pace_tcgetpgrp (int fildes); + + PACE_INLINE int pace_tcsendbreak (int fildes, int duration); + + PACE_INLINE int pace_tcsetattr (int fildes, + int optional_actions, + const struct termios * termios_p); + + PACE_INLINE int pace_tcsetpgrp (int fildes, pid_t pgrp_id); #if defined (PACE_HAS_CPLUSPLUS) } #endif /* PACE_HAS_CPLUSPLUS */ -#endif /* PACE_SYS_TERMIOS_H_POSIX */ +#if defined (PACE_HAS_INLINE) +# include "pace/posix/termios.inl" +#endif /* PACE_HAS_INLINE */ + +#endif /* PACE_SYS_TERMIOS_H */ |