⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 commprotocol.h

📁 This is a java virtual machine implement in c
💻 H
字号:
/*0001*//*
/*0002./ * Copyright (c) 2000-2001 Sun Microsystems, Inc. All Rights Reserved.
/*0003./ * 
/*0004./ * This software is the confidential and proprietary information of Sun
/*0005./ * Microsystems, Inc. ("Confidential Information").  You shall not
/*0006./ * disclose such Confidential Information and shall use it only in
/*0007./ * accordance with the terms of the license agreement you entered into
/*0008./ * with Sun.
/*0009./ * 
/*0010./ * SUN MAKES NO REPRESENTATIONS OR WARRANTIES ABOUT THE SUITABILITY OF THE
/*0011./ * SOFTWARE, EITHER EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE
/*0012./ * IMPLIED WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR
/*0013./ * PURPOSE, OR NON-INFRINGEMENT. SUN SHALL NOT BE LIABLE FOR ANY DAMAGES
/*0014./ * SUFFERED BY LICENSEE AS A RESULT OF USING, MODIFYING OR DISTRIBUTING
/*0015./ * THIS SOFTWARE OR ITS DERIVATIVES.
/*0016./ * 
/*0017./ */
/*0018*/
/*0019*//*=========================================================================
/*0020./ * SYSTEM:    KVM
/*0021./ * SUBSYSTEM: networking
/*0022./ * FILE:      commProtocol.h
/*0023./ * OVERVIEW:  Prototypes for supporting serial communication ports.
/*0024./ *            If a target platform wants to support serial ports,
/*0025./ *            a platform-specific implementation of the functions
/*0026./ *            must be provided in the Vm<Port>/src directory,
/*0027./ *            where <Port> is the name of your target platform
/*0028./ *            (e.g., Win, Unix, Pilot).
/*0029./ * AUTHOR:    Stephen Flores, Nik Shaylor
/*0030./ *=======================================================================*/
/*0031*/
/*0032*/#ifndef _COMM_PROTOCOL_H_
/*0033*/#define _COMM_PROTOCOL_H_
/*0034*/
/*0035*/#ifndef __P
/*0036*/# ifdef __STDC__
/*0037*/#  define __P(p) p
/*0038*/# else
/*0039*/#  define __P(p) ()
/*0040*/# endif
/*0041*/#endif /* __P */
/*0042*/
/*0043*//* COMM options */
/*0044*/#define STOP_BITS_2     0x01
/*0045*/#define ODD_PARITY      0x02
/*0046*/#define EVEN_PARITY     0x04
/*0047*/#define AUTO_RTS        0x10
/*0048*/#define AUTO_CTS        0x20
/*0049*/#define BITS_PER_CHAR_7 0x80
/*0050*/#define BITS_PER_CHAR_8 0xC0
/*0051*/
/*0052*//*=========================================================================
/*0053./ * Serial protocol prototypes (each platform/port must supply definitions
/*0054./ * of these prototypes)    
/*0055./ *=======================================================================*/
/*0056*/
/*0057*/extern long openPortByNumber __P ((char** ppszError, long port, long baudRate, long options, long blocking));
/*0058*/extern long openPortByName __P ((char** ppszError, char* pszDeviceName, long baudRate, long options, long blocking));
/*0059*/
/*0060*/extern long peekFromPort __P ((long hPort));
/*0061*/extern long readFromPort __P ((char** ppszError, long hPort, char* pBuffer, long nNumberOfBytesToRead));
/*0062*/
/*0063*/extern long writeToPort __P ((char** ppszError, long hPort, char* pBuffer, long nNumberOfBytesToWrite));
/*0064*/
/*0065*/extern void closePort __P ((long hPort));
/*0066*/extern void freePortError __P ((char* pszError));
/*0067*/
/*0068*/#endif /* _COMM_PROTOCOL_H_ */
/*0069*/
/*0070*/

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -