| 
    Xenomai API
    2.6.5
    
   | 
 
 
 | 
Files | |
| file | rtserial.h | 
| Real-Time Driver Model for Xenomai, serial device profile header.  | |
Data Structures | |
| struct | rtser_config | 
| Serial device configuration.  More... | |
| struct | rtser_status | 
| Serial device status.  More... | |
| struct | rtser_event | 
| Additional information about serial device events.  More... | |
Macros | |
| #define | RTSER_RTIOC_BREAK_CTL _IOR(RTIOC_TYPE_SERIAL, 0x06, int) | 
| Set or clear break on UART output line.  More... | |
RTSER_DEF_BAUD | |
| #define | RTSER_DEF_BAUD 9600 | 
RTSER_xxx_PARITY | |
| #define | RTSER_NO_PARITY 0x00 | 
| #define | RTSER_ODD_PARITY 0x01 | 
| #define | RTSER_EVEN_PARITY 0x03 | 
| #define | RTSER_DEF_PARITY RTSER_NO_PARITY | 
RTSER_xxx_BITS | |
| #define | RTSER_5_BITS 0x00 | 
| #define | RTSER_6_BITS 0x01 | 
| #define | RTSER_7_BITS 0x02 | 
| #define | RTSER_8_BITS 0x03 | 
| #define | RTSER_DEF_BITS RTSER_8_BITS | 
RTSER_xxx_STOPB | |
| #define | RTSER_1_STOPB 0x00 | 
| valid only in combination with 5 data bits  | |
| #define | RTSER_1_5_STOPB 0x01 | 
| valid only in combination with 5 data bits  | |
| #define | RTSER_2_STOPB 0x01 | 
| valid only in combination with 5 data bits  | |
| #define | RTSER_DEF_STOPB RTSER_1_STOPB | 
| valid only in combination with 5 data bits  | |
RTSER_xxx_HAND | |
| #define | RTSER_NO_HAND 0x00 | 
| #define | RTSER_RTSCTS_HAND 0x01 | 
| #define | RTSER_DEF_HAND RTSER_NO_HAND | 
RTSER_RS485_xxx | |
| #define | RTSER_RS485_DISABLE 0x00 | 
| #define | RTSER_RS485_ENABLE 0x01 | 
| #define | RTSER_DEF_RS485 RTSER_RS485_DISABLE | 
RTSER_FIFO_xxx | |
| #define | RTSER_FIFO_DEPTH_1 0x00 | 
| #define | RTSER_FIFO_DEPTH_4 0x40 | 
| #define | RTSER_FIFO_DEPTH_8 0x80 | 
| #define | RTSER_FIFO_DEPTH_14 0xC0 | 
| #define | RTSER_DEF_FIFO_DEPTH RTSER_FIFO_DEPTH_1 | 
RTSER_TIMEOUT_xxx | |
Special timeout values, see also RTDM_TIMEOUT_xxx  | |
| #define | RTSER_TIMEOUT_INFINITE RTDM_TIMEOUT_INFINITE | 
| #define | RTSER_TIMEOUT_NONE RTDM_TIMEOUT_NONE | 
| #define | RTSER_DEF_TIMEOUT RTDM_TIMEOUT_INFINITE | 
RTSER_xxx_TIMESTAMP_HISTORY | |
| #define | RTSER_RX_TIMESTAMP_HISTORY 0x01 | 
| #define | RTSER_DEF_TIMESTAMP_HISTORY 0x00 | 
RTSER_MCR_xxx | |
| #define | RTSER_MCR_DTR 0x01 | 
| #define | RTSER_MCR_RTS 0x02 | 
| #define | RTSER_MCR_OUT1 0x04 | 
| #define | RTSER_MCR_OUT2 0x08 | 
| #define | RTSER_MCR_LOOP 0x10 | 
RTSER_BREAK_xxx | |
| typedef struct rtser_config | rtser_config_t | 
| Serial device configuration.  | |
| typedef struct rtser_status | rtser_status_t | 
| Serial device status.  | |
| typedef struct rtser_event | rtser_event_t | 
| Additional information about serial device events.  | |
| #define | RTSER_BREAK_CLR 0x00 | 
| Serial device configuration.  | |
| #define | RTSER_BREAK_SET 0x01 | 
| Serial device configuration.  | |
| #define | RTIOC_TYPE_SERIAL RTDM_CLASS_SERIAL | 
| Serial device configuration.  | |
Sub-Classes of RTDM_CLASS_SERIAL | |
| #define | RTDM_SUBCLASS_16550A 0 | 
IOCTLs | |
| #define | RTSER_RTIOC_GET_CONFIG _IOR(RTIOC_TYPE_SERIAL, 0x00, struct rtser_config) | 
| Get serial device configuration.  More... | |
| #define | RTSER_RTIOC_SET_CONFIG _IOW(RTIOC_TYPE_SERIAL, 0x01, struct rtser_config) | 
| Set serial device configuration.  More... | |
| #define | RTSER_RTIOC_GET_STATUS _IOR(RTIOC_TYPE_SERIAL, 0x02, struct rtser_status) | 
| Get serial device status.  More... | |
| #define | RTSER_RTIOC_GET_CONTROL _IOR(RTIOC_TYPE_SERIAL, 0x03, int) | 
| Get serial device's modem contol register.  More... | |
| #define | RTSER_RTIOC_SET_CONTROL _IOW(RTIOC_TYPE_SERIAL, 0x04, int) | 
| Set serial device's modem contol register.  More... | |
| #define | RTSER_RTIOC_WAIT_EVENT _IOR(RTIOC_TYPE_SERIAL, 0x05, struct rtser_event) | 
| Wait on serial device events according to previously set mask.  More... | |
This is the common interface a RTDM-compliant serial device has to provide. Feel free to comment on this profile via the Xenomai mailing list (Xenomai@xenomai.org) or directly to the author (jan.kiszka@web.de).
Profile Revision: 3 
RTDM_NAMED_DEVICE, RTDM_EXCLUSIVE "rtser<N>", N >= 0 RTDM_CLASS_SERIAL | #define RTSER_RTIOC_BREAK_CTL _IOR(RTIOC_TYPE_SERIAL, 0x06, int) | 
Set or clear break on UART output line.
| [in] | arg | RTSER_BREAK_SET or RTSER_BREAK_CLR (int) | 
Environments:
This service can be called from:
Rescheduling: never.
| #define RTSER_RTIOC_GET_CONFIG _IOR(RTIOC_TYPE_SERIAL, 0x00, struct rtser_config) | 
Get serial device configuration.
| [out] | arg | Pointer to configuration buffer (struct rtser_config) | 
Environments:
This service can be called from:
Rescheduling: never.
| #define RTSER_RTIOC_GET_CONTROL _IOR(RTIOC_TYPE_SERIAL, 0x03, int) | 
Get serial device's modem contol register.
| [out] | arg | Pointer to variable receiving the content (int, see RTSER_MCR_xxx) | 
Environments:
This service can be called from:
Rescheduling: never.
| #define RTSER_RTIOC_GET_STATUS _IOR(RTIOC_TYPE_SERIAL, 0x02, struct rtser_status) | 
Get serial device status.
| [out] | arg | Pointer to status buffer (struct rtser_status) | 
Environments:
This service can be called from:
RTSER_LSR_OVERRUN_ERR, RTSER_LSR_PARITY_ERR, RTSER_LSR_FRAMING_ERR, and RTSER_SOFT_OVERRUN_ERR that may have occured during previous read accesses to the device will be saved for being reported via this IOCTL. Upon return from RTSER_RTIOC_GET_STATUS, the saved state will be cleared.Rescheduling: never.
| #define RTSER_RTIOC_SET_CONFIG _IOW(RTIOC_TYPE_SERIAL, 0x01, struct rtser_config) | 
Set serial device configuration.
| [in] | arg | Pointer to configuration buffer (struct rtser_config) | 
Environments:
This service can be called from:
Rescheduling: never.
| #define RTSER_RTIOC_SET_CONTROL _IOW(RTIOC_TYPE_SERIAL, 0x04, int) | 
Set serial device's modem contol register.
| [in] | arg | New control register content (int, see RTSER_MCR_xxx) | 
Environments:
This service can be called from:
Rescheduling: never.
| #define RTSER_RTIOC_WAIT_EVENT _IOR(RTIOC_TYPE_SERIAL, 0x05, struct rtser_event) | 
Wait on serial device events according to previously set mask.
| [out] | arg | Pointer to event information buffer (struct rtser_event) | 
Environments:
This service can be called from:
Rescheduling: possible.