FreeRDP
|
#include <winpr/assert.h>
#include <errno.h>
#include <fcntl.h>
#include <sys/ioctl.h>
#include <termios.h>
#include <unistd.h>
#include "comm_serial_sys.h"
#include "comm.h"
#include <winpr/crt.h>
#include <winpr/wlog.h>
Macros | |
#define | CMSPAR 010000000000 |
#define | TTY_THRESHOLD_THROTTLE 128 /* now based on remaining room */ |
#define | TTY_THRESHOLD_UNTHROTTLE 128 |
#define | N_TTY_BUF_SIZE 4096 |
#define | BAUD_TABLE_END 0010020 /* __MAX_BAUD + 1 */ |
Functions | |
static BOOL | commstatus_error (WINPR_COMM *pComm, const char *ctrl) |
static BOOL | get_properties (WINPR_COMM *pComm, COMMPROP *pProperties) |
static BOOL | set_baud_rate (WINPR_COMM *pComm, const SERIAL_BAUD_RATE *pBaudRate) |
static BOOL | get_baud_rate (WINPR_COMM *pComm, SERIAL_BAUD_RATE *pBaudRate) |
static BOOL | set_serial_chars (WINPR_COMM *pComm, const SERIAL_CHARS *pSerialChars) |
static BOOL | get_serial_chars (WINPR_COMM *pComm, SERIAL_CHARS *pSerialChars) |
static BOOL | set_line_control (WINPR_COMM *pComm, const SERIAL_LINE_CONTROL *pLineControl) |
static BOOL | get_line_control (WINPR_COMM *pComm, SERIAL_LINE_CONTROL *pLineControl) |
static BOOL | set_handflow (WINPR_COMM *pComm, const SERIAL_HANDFLOW *pHandflow) |
static BOOL | get_handflow (WINPR_COMM *pComm, SERIAL_HANDFLOW *pHandflow) |
static BOOL | set_timeouts (WINPR_COMM *pComm, const SERIAL_TIMEOUTS *pTimeouts) |
static BOOL | get_timeouts (WINPR_COMM *pComm, SERIAL_TIMEOUTS *pTimeouts) |
static BOOL | set_lines (WINPR_COMM *pComm, UINT32 lines) |
static BOOL | clear_lines (WINPR_COMM *pComm, UINT32 lines) |
static BOOL | set_dtr (WINPR_COMM *pComm) |
static BOOL | clear_dtr (WINPR_COMM *pComm) |
static BOOL | set_rts (WINPR_COMM *pComm) |
static BOOL | clear_rts (WINPR_COMM *pComm) |
static BOOL | get_modemstatus (WINPR_COMM *pComm, ULONG *pRegister) |
static BOOL | is_wait_set (WINPR_COMM *pComm) |
static BOOL | set_wait_mask (WINPR_COMM *pComm, const ULONG *pWaitMask) |
static BOOL | get_wait_mask (WINPR_COMM *pComm, ULONG *pWaitMask) |
static BOOL | set_queue_size (WINPR_COMM *pComm, const SERIAL_QUEUE_SIZE *pQueueSize) |
static BOOL | purge (WINPR_COMM *pComm, const ULONG *pPurgeMask) |
static BOOL | get_commstatus (WINPR_COMM *pComm, SERIAL_STATUS *pCommstatus) |
static BOOL | refresh_PendingEvents (WINPR_COMM *pComm) |
static void | consume_event (WINPR_COMM *pComm, ULONG *pOutputMask, ULONG event) |
static BOOL | unlock_return (WINPR_COMM *pComm, BOOL res) |
static BOOL | wait_on_mask (WINPR_COMM *pComm, ULONG *pOutputMask) |
static BOOL | set_break_on (WINPR_COMM *pComm) |
static BOOL | set_break_off (WINPR_COMM *pComm) |
static BOOL | set_xoff (WINPR_COMM *pComm) |
static BOOL | set_xon (WINPR_COMM *pComm) |
static BOOL | get_dtrrts (WINPR_COMM *pComm, ULONG *pMask) |
static BOOL | config_size (WINPR_COMM *pComm, ULONG *pSize) |
static BOOL | immediate_char (WINPR_COMM *pComm, const UCHAR *pChar) |
static BOOL | reset_device (WINPR_COMM *pComm) |
const SERIAL_DRIVER * | SerialSys_s (void) |
Variables | |
static const speed_t | BAUD_TABLE [][3] |
static const ULONG | SERIAL_SYS_SUPPORTED_EV_MASK |
static const SERIAL_DRIVER | SerialSys |
#define BAUD_TABLE_END 0010020 /* __MAX_BAUD + 1 */ |
#define CMSPAR 010000000000 |
WinPR: Windows Portable Runtime Serial Communication API
Copyright 2011 O.S. Systems Software Ltda. Copyright 2011 Eduardo Fiss Beloni belon Copyright 2014 Marc-Andre Moreau i@os syste ms.c om.brmarca Copyright 2014 Hewlett-Packard Development Company, L.P. ndre .more au@g mail. com
Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.
#define N_TTY_BUF_SIZE 4096 |
#define TTY_THRESHOLD_THROTTLE 128 /* now based on remaining room */ |
#define TTY_THRESHOLD_UNTHROTTLE 128 |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
const SERIAL_DRIVER* SerialSys_s | ( | void | ) |
WinPR: Windows Portable Runtime Serial Communication API
Copyright 2014 Hewlett-Packard Development Company, L.P.
Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
NOTE: Only XonChar and XoffChar are plenty supported with the Linux N_TTY line discipline.
ERRORS: ERROR_IO_DEVICE ERROR_INVALID_PARAMETER when Xon and Xoff chars are the same; ERROR_NOT_SUPPORTED
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |