一款体积非常小、绿色的仿真终端软件
<P>不一定每个人都用得着的</P><P>顶</P> <P>感兴趣的,可以提供源程序</P><P>C 主程序部分:</P><P>/************************************************************************
Comm.c
-- Show dialog for user to set commnication parameter.</P><P>*************************************************************************/</P><P>#include <windows.h>
#include "PComm.h"
#include "resource.h"
#include "comm.h"</P><P>extern HINSTANCE GhInst;
extern COMMDATA GCommData;
extern BOOLGbOpen;</P><P>static void InitOpenDlg(HWND hDlg);</P><P>#define BAUDCOUNT 20
#define DATABITCOUNT 4
#define PARITYCOUNT 5
#define STOPBITCOUNT 2</P><P>int GBaudTable = {
B50,B75,B110,B134,B150,B300,B600,B1200,B1800,B2400,
B4800,B7200,B9600,B19200,B38400,B57600,
B115200,B230400,B460800,B921600
};</P><P>int GDataBitsTable = {
BIT_5,BIT_6,BIT_7,BIT_8
};</P><P>int GParityTable = {
P_NONE, P_EVEN, P_ODD, P_MRK, P_SPC
};</P><P>int GStopBitsTable ={
STOP_1,STOP_2
};</P><P>
BOOL CALLBACK PortDlgProc(HWND hDlg,UINT iMsg,WPARAM wParam,LPARAM lParam)
{
static BOOL fhw;</P><P> switch(iMsg){
case WM_INITDIALOG:
InitOpenDlg(hDlg);
if(SendDlgItemMessage(hDlg,IDC_HW,BM_GETSTATE,0,0L)==BST_CHECKED)
fhw = TRUE;
else
fhw = FALSE;
return TRUE;</P><P> case WM_COMMAND:
if(HIWORD(wParam)==BN_CLICKED){
if(LOWORD(wParam) == IDC_HW){
EnableWindow(GetDlgItem(hDlg,IDC_RTS),fhw);
fhw = !fhw;
return TRUE;
}
}
switch (LOWORD(wParam)){
case IDOK:
GCommData.Port = (int)SendDlgItemMessage(hDlg,IDC_PORT,CB_GETCURSEL,0,0L)+1;</P><P> GCommData.ibaudrate = (int)SendDlgItemMessage(hDlg,IDC_BAUD,CB_GETCURSEL,0,0L);
GCommData.iparity = (int)SendDlgItemMessage(hDlg,IDC_PARITY,CB_GETCURSEL,0,0L);
GCommData.ibytesize = (int)SendDlgItemMessage(hDlg,IDC_DATABITS,CB_GETCURSEL,0,0L);
GCommData.istopbits = (int)SendDlgItemMessage(hDlg,IDC_STOPBITS,CB_GETCURSEL,0,0L);
GCommData.BaudRate = GBaudTable;
GCommData.Parity = GParityTable;
GCommData.ByteSize = GDataBitsTable;
GCommData.StopBits = GStopBitsTable;</P><P> GCommData.Hw =
(SendDlgItemMessage(hDlg,IDC_HW,BM_GETSTATE,0,0L)==BST_CHECKED);</P><P> GCommData.Sw =
(SendDlgItemMessage(hDlg,IDC_SW,BM_GETSTATE,0,0L)==BST_CHECKED);</P><P> GCommData.Dtr =
(SendDlgItemMessage(hDlg,IDC_DTR,BM_GETSTATE,0,0L)==BST_CHECKED);</P><P> GCommData.Rts =
(SendDlgItemMessage(hDlg,IDC_RTS,BM_GETSTATE,0,0L)==BST_CHECKED);
/* Fall through */
case IDCANCEL:
EndDialog(hDlg,LOWORD(wParam));
return TRUE;
}
break;
}
return FALSE;
}</P><P>
static void FillComboBox(HINSTANCE hInstance,HWND hCtrlWnd,
int idstr,int tablelen,int pos)
{
char buf[ 20 ] ;
int idx;</P><P> for (idx=0; idx<tablelen; idx++){
/* load the string from the string resources and
add it to the combo box */
LoadString(hInstance,idstr+idx,buf,sizeof(buf)) ;
SendMessage(hCtrlWnd,CB_ADDSTRING,0,(LPARAM)buf);
}
SendMessage(hCtrlWnd,CB_SETCURSEL,(WPARAM)pos,0L) ;
}</P><P>static void InitOpenDlg(HWND hDlg)
{
char buf;
int com;
int set;</P><P> /* fill port combo box and make initial selection */
for (com=1; com<=MAXCOM; com++){
wsprintf(buf,"%s%d","COM",com) ;
SendDlgItemMessage(hDlg,IDC_PORT,CB_ADDSTRING,0,(LPARAM)buf);
}
SendDlgItemMessage(hDlg,IDC_PORT,CB_SETCURSEL,
(WPARAM)(GCommData.Port-1),0L);
if(GbOpen)
EnableWindow(GetDlgItem(hDlg,IDC_PORT),FALSE);</P><P> /* fill baudrate combo box and make initial selection */
FillComboBox(GhInst,GetDlgItem(hDlg,IDC_BAUD),
IDS_BAUD50,BAUDCOUNT,GCommData.ibaudrate);</P><P> /* fill data bits combo box and make initial selection */
FillComboBox(GhInst,GetDlgItem(hDlg,IDC_DATABITS),
IDS_DATABIT5,DATABITCOUNT,GCommData.ibytesize);</P><P> /* fill parity combo box and make initial selection */
FillComboBox(GhInst,GetDlgItem(hDlg,IDC_PARITY),
IDS_PARITYNONE,PARITYCOUNT,GCommData.iparity);</P><P> /* fill stop bits combo box and make initial selection */
FillComboBox(GhInst,GetDlgItem(hDlg,IDC_STOPBITS),
IDS_ONESTOPBIT,STOPBITCOUNT,GCommData.istopbits);</P><P> set = GCommData.Hw ? BST_CHECKED : BST_UNCHECKED;
SendDlgItemMessage(hDlg,IDC_HW,BM_SETCHECK,(WPARAM)set,0L);</P><P> set = GCommData.Sw ? BST_CHECKED : BST_UNCHECKED;
SendDlgItemMessage(hDlg,IDC_SW,BM_SETCHECK,(WPARAM)set,0L);</P><P> set = GCommData.Dtr ? BST_CHECKED : BST_UNCHECKED;
SendDlgItemMessage(hDlg,IDC_DTR,BM_SETCHECK,(WPARAM)set,0L);</P><P> set = GCommData.Rts ? BST_CHECKED : BST_UNCHECKED;
SendDlgItemMessage(hDlg,IDC_RTS,BM_SETCHECK,(WPARAM)set,0L);</P><P> /* disable RTS setting when RTS/CTS flow control */
EnableWindow(GetDlgItem(hDlg,IDC_RTS),!(GCommData.Hw));
}
</P> <P>喜欢 Delphi 也可以</P><P>(*********************************************************************
PComm.pas
-- PComm Lib unit for Delphi (32 bit version).</P><P>
History: Date Author Comment
5/29/98 Casper Wrote it.
12/11/98 CasperUpdate
04/27/99 Casper Update
(add sio_ActXon, sio_ActXoff,
sio_break_ex)
**********************************************************************)</P><P>unit PComm;</P><P>interface</P><P>const
{ baud rate setting }
B50 = $0;
B75 = $1;
B110 = $2;
B134 = $3;
B150 = $4;
B300 = $5;
B600 = $6;
B1200 = $7;
B1800 = $8;
B2400 = $9;
B4800 = $A;
B7200 = $B;
B9600 = $C;
B19200 = $D;
B38400 = $E;
B57600 = $F;
B115200 = $10;
B230400 = $11;
B460800 = $12;
B921600 = $13;</P><P>{ data bit }
BIT_5 = $0;
BIT_6 = $1;
BIT_7 = $2;
BIT_8 = $3;</P><P>{ stop bit }
STOP_1 = $0;
STOP_2 = $4;</P><P>{ parity }
P_EVEN = $18;
P_ODD= $8;
P_SPC= $38;
P_MRK= $28;
P_NONE = $0;</P><P>{ modem control setting }
C_DTR = $1;
C_RTS = $2;</P><P>{ modem line status }
S_CTS = $1;
S_DSR = $2;
S_RI= $4;
S_CD= $8;</P><P>{ error code }
SIO_OK = 0;
SIO_BADPORT = -1;{ No such port or port not opened }
SIO_OUTCONTROL = -2;{ Can't control board }
SIO_NODATA = -4;{ No data to read or no buffer to write }
SIO_OPENFAIL = -5; { No such port or port has opened }
SIO_RTS_BY_HW = -6;{ Can't set because H/W flowctrl }
SIO_BADPARM = -7;{ Bad parameter }
SIO_WIN32FAIL = -8;(* Call win32 function fail, please call }
GetLastError to get the error code *)
SIO_BOARDNOTSUPPORT= -9;{ Board does not support this function}
SIO_FAIL = -10; { PComm function run result fail }
SIO_ABORT_WRITE= -11; { Write has blocked, and user abort write }
SIO_WRITETIMEOUT = -12; { Write timeout has happened }</P><P>{ file transfer error code }
SIOFT_OK = 0;
SIOFT_BADPORT = -1; { No such port or port not open }
SIOFT_TIMEOUT = -2; { Protocol timeout }
SIOFT_ABORT = -3; { User key abort }
SIOFT_FUNC = -4; { Func return abort }
SIOFT_FOPEN = -5; { Can not open files }
SIOFT_CANABORT = -6; { Ymodem CAN signal abort }
SIOFT_PROTOCOL = -7; { Protocol checking error abort }
SIOFT_SKIP = -8; { Zmodem remote skip this send file }
SIOFT_LACKRBUF = -9; { Zmodem Recv-Buff size must >= 2K bytes }
SIOFT_WIN32FAIL = -10; (* OS fail }
GetLastError to get the error code *)
SIOFT_BOARDNOTSUPPORT = -11; { Board does not support this function}</P><P>type</P><P>IrqProc = procedure(port: Longint);stdcall;
CallBackProc = function(len: Longint; rlen: Longint; buf: PChar; flen: Longint): Longint;stdcall;</P><P>{Import routine from PComm.dll}
function sio_open(port: Longint): Longint; stdcall;
function sio_close(port: Longint): Longint; stdcall;
function sio_ioctl(port, baud, mode: Longint): Longint; stdcall;
function sio_flowctrl(port, mode: Longint): Longint; stdcall;
function sio_flush(port, func: Longint): Longint; stdcall;
function sio_DTR(port, mode: Longint): Longint; stdcall;
function sio_RTS(port, mode: Longint): Longint; stdcall;
function sio_lctrl(port, mode: Longint): Longint; stdcall;
function sio_baud(port, speed: Longint): Longint; stdcall;
function sio_getch(port: Longint): Longint; stdcall;
function sio_read(port: Longint; buf: PChar; len: Longint): Longint; stdcall;
function sio_linput(port: Longint; buf:PChar; len: Longint; term:Longint): Longint; stdcall;
function sio_putch(port, term: Longint): Longint; stdcall;
function sio_putb(port: Longint; buf:PChar; len: Longint): Longint; stdcall;
function sio_write(port: Longint; buf:PChar; len: Longint): Longint; stdcall;
function sio_putb_x(port: Longint; buf:PChar; len: Longint; tick:Longint): Longint; stdcall;
function sio_putb_x_ex(port: Longint; buf:PChar; len: Longint; tms:Longint): Longint; stdcall;
function sio_lstatus(port: Longint): Longint; stdcall;
function sio_iqueue(port: Longint): Longint; stdcall;
function sio_oqueue(port: Longint): Longint; stdcall;
function sio_Tx_hold(port: Longint): Longint; stdcall;
function sio_getbaud(port: Longint): Longint; stdcall;
function sio_getmode(port: Longint): Longint; stdcall;
function sio_getflow(port: Longint): Longint; stdcall;
function sio_data_status(port: Longint): Longint; stdcall;
function sio_term_irq(port: Longint; func: IrqProc; code: Byte): Longint; stdcall;
function sio_cnt_irq(port: Longint; func: IrqProc; count: Longint): Longint; stdcall;
function sio_modem_irq(port: Longint; func: IrqProc): Longint; stdcall;
function sio_break_irq(port: Longint; func: IrqProc): Longint; stdcall;
function sio_Tx_empty_irq(port: Longint; func: IrqProc): Longint; stdcall;
function sio_break(port, time: Longint): Longint; stdcall;
function sio_break_ex(port, time: Longint): Longint; stdcall;
function sio_view(port: Longint; buf: PChar; len: Longint): Longint; stdcall;
function sio_TxLowWater(port, size: Longint): Longint; stdcall;
function sio_AbortWrite(port: Longint): Longint; stdcall;
function sio_AbortRead(port: Longint): Longint; stdcall;
function sio_SetWriteTimeouts(port, timeouts: Longint): Longint; stdcall;
function sio_GetWriteTimeouts(port: Longint; var TotalTimeouts:Longint): Longint; stdcall;
function sio_SetReadTimeouts(port, TotalTimeouts, IntervalTimeouts: Longint): Longint; stdcall;
function sio_GetReadTimeouts(port: Longint; var TotalTimeouts, IntervalTimeouts: Longint): Longint; stdcall;
function sio_ActXon(port: Longint): Longint; stdcall;
function sio_ActXoff(port: Longint): Longint; stdcall;
function sio_FtASCIITx(port:Longint; fname:PChar; func:CallBackProc; key:Longint): Longint; stdcall;
function sio_FtASCIIRx(port:Longint; fname:PChar; func:CallBackProc; key:Longint; sec:Longint): Longint; stdcall;
function sio_FtXmodemCheckSumTx(port:Longint; fname:PChar; func:CallBackProc; key:Longint): Longint; stdcall;
function sio_FtXmodemCheckSumRx(port:Longint; fname:PChar; func:CallBackProc; key:Longint): Longint; stdcall;
function sio_FtXmodemCRCTx(port:Longint; fname:PChar; func:CallBackProc; key:Longint): Longint; stdcall;
function sio_FtXmodemCRCRx(port:Longint; fname:PChar; func:CallBackProc; key:Longint): Longint; stdcall;
function sio_FtXmodem1KCRCTx(port:Longint; fname:PChar; func:CallBackProc; key:Longint): Longint; stdcall;
function sio_FtXmodem1KCRCRx(port:Longint; fname:PChar; func:CallBackProc; key:Longint): Longint; stdcall;
function sio_FtYmodemTx(port:Longint; fname:PChar; func:CallBackProc; key:Longint): Longint; stdcall;
function sio_FtYmodemRx(port:Longint; var fname:PChar;fnLongInt;func:CallBackProc; key:Longint): Longint; stdcall;
function sio_FtZmodemTx(port:Longint; fname:PChar; func:CallBackProc; key:Longint): Longint; stdcall;
function sio_FtZmodemRx(port:Longint; var fname:PChar;fnLongInt;func:CallBackProc; key:Longint): Longint; stdcall;
function sio_FtKermitTx(port:Longint; fname:PChar; func:CallBackProc; key:Longint): Longint; stdcall;
function sio_FtKermitRx(port:Longint; var fname:PChar;fnLongInt;func:CallBackProc; key:Longint): Longint; stdcall;</P><P>
implementation
function sio_open; external 'PComm.dll';
function sio_close; external 'PComm.dll';
function sio_ioctl; external 'PComm.dll';
function sio_flowctrl; external 'PComm.dll';
function sio_flush; external 'PComm.dll';
function sio_DTR; external 'PComm.dll';
function sio_RTS; external 'PComm.dll';
function sio_lctrl; external 'PComm.dll';
function sio_baud; external 'PComm.dll';
function sio_getch; external 'PComm.dll';
function sio_read; external 'PComm.dll';
function sio_linput; external 'PComm.dll';
function sio_putch; external 'PComm.dll';
function sio_putb; external 'PComm.dll';
function sio_write; external 'PComm.dll';
function sio_putb_x; external 'PComm.dll';
function sio_putb_x_ex; external 'PComm.dll';
function sio_lstatus; external 'PComm.dll';
function sio_iqueue; external 'PComm.dll';
function sio_oqueue; external 'PComm.dll';
function sio_Tx_hold; external 'PComm.dll';
function sio_getbaud; external 'PComm.dll';
function sio_getmode; external 'PComm.dll';
function sio_getflow; external 'PComm.dll';
function sio_data_status; external 'PComm.dll';
function sio_term_irq; external 'PComm.dll';
function sio_cnt_irq; external 'PComm.dll';
function sio_modem_irq; external 'PComm.dll';
function sio_break_irq; external 'PComm.dll';
function sio_Tx_empty_irq; external 'PComm.dll';
function sio_break; external 'PComm.dll';
function sio_break_ex; external 'PComm.dll';
function sio_view; external 'PComm.dll';
function sio_TxLowWater; external 'PComm.dll';
function sio_AbortWrite; external 'PComm.dll';
function sio_AbortRead; external 'PComm.dll';
function sio_SetWriteTimeouts; external 'PComm.dll';
function sio_GetWriteTimeouts; external 'PComm.dll';
function sio_SetReadTimeouts; external 'PComm.dll';
function sio_GetReadTimeouts; external 'PComm.dll';
function sio_ActXon; external 'PComm.dll';
function sio_ActXoff; external 'PComm.dll';
function sio_FtASCIITx; external 'PComm.dll';
function sio_FtASCIIRx; external 'PComm.dll';
function sio_FtXmodemCheckSumTx; external 'PComm.dll';
function sio_FtXmodemCheckSumRx; external 'PComm.dll';
function sio_FtXmodemCRCTx; external 'PComm.dll';
function sio_FtXmodemCRCRx; external 'PComm.dll';
function sio_FtXmodem1KCRCTx; external 'PComm.dll';
function sio_FtXmodem1KCRCRx; external 'PComm.dll';
function sio_FtYmodemTx; external 'PComm.dll';
function sio_FtYmodemRx; external 'PComm.dll';
function sio_FtZmodemTx; external 'PComm.dll';
function sio_FtZmodemRx; external 'PComm.dll';
function sio_FtKermitTx; external 'PComm.dll';
function sio_FtKermitRx; external 'PComm.dll';</P><P>end.
</P> <P>擅长 VB 的也有:</P><P>Attribute VB_Name = "PComm"
'********************************************************
' PComm.bas
' -- PComm module for Visual Basic(5.0 above)
'
' Description:
' When you want to develop one VB application with PComm,
' you should add this module to your project.
'
' History:
' Date Author Comment
' 01/10/1997Victor wrote it.
' 06/01/1998Casper supprot VB5.0 'AddressOf' operator
' (sio_xxx_irq & sio_Ftxxx function)
'
' 04/27/1999Casper Update. (add sio_ActXon, sio_ActXoff,
' sio_break_ex)
'********************************************************</P><P>'Baud Rate Setting
Global Const B50 = &H0
Global Const B75 = &H1
Global Const B110 = &H2
Global Const B134 = &H3
Global Const B150 = &H4
Global Const B300 = &H5
Global Const B600 = &H6
Global Const B1200 = &H7
Global Const B1800 = &H8
Global Const B2400 = &H9
Global Const B4800 = &HA
Global Const B7200 = &HB
Global Const B9600 = &HC
Global Const B19200 = &HD
Global Const B38400 = &HE
Global Const B57600 = &HF
Global Const B115200 = &H10
Global Const B230400 = &H11
Global Const B460800 = &H12
Global Const B921600 = &H13</P><P>' Mode setting
Global Const BIT_5 = &H0 ' Data bits define
Global Const BIT_6 = &H1
Global Const BIT_7 = &H2
Global Const BIT_8 = &H3</P><P>Global Const STOP_1 = &H0 ' Stop bits define
Global Const STOP_2 = &H4</P><P>Global Const P_EVEN = &H18 ' Parity define
Global Const P_ODD = &H8
Global Const P_SPC = &H38
Global Const P_MRK = &H28
Global Const P_NONE = &H0</P><P>' Modem Control setting
Global Const C_DTR = &H1
Global Const C_RTS = &H2</P><P>' Modem Line Status
Global Const S_CTS = &H1
Global Const S_DSR = &H2
Global Const S_RI = &H4
Global Const S_CD = &H8</P><P>' Error code
Global Const SIO_OK = 0
Global Const SIO_BADPORT = -1 ' No such port or port not opened
Global Const SIO_OUTCONTROL = -2 ' Can't control board
Global Const SIO_NODATA = -4 ' No data to read or no buffer to write
Global Const SIO_OPENFAIL = -5 ' No such port or port has opened
Global Const SIO_RTS_BY_HW = -6 ' RTS can't set by H/W flowctrl
Global Const SIO_BADPARM = -7 ' Bad parameter
Global Const SIO_WIN32FAIL = -8 ' Call win32 function fail, please call
' GetLastError to get the error code
Global Const SIO_BOARDNOTSUPPORT = -9 'Board does not support this function
Global Const SIO_FAIL = -10 ' PComm function run result fail
Global Const SIO_ABORT_WRITE = -11' Write has blocked, and user abort write
Global Const SIO_WRITETIMEOUT = -12 ' Write timeoue has happened</P><P>'File transfer error code
Global Const SIOFT_OK = 0
Global Const SIOFT_BADPORT = -1 ' No such port or port not open
Global Const SIOFT_TIMEOUT = -2 ' Protocol timeout
Global Const SIOFT_ABORT = -3 ' User key abort
Global Const SIOFT_FUNC = -4 ' Func return abort
Global Const SIOFT_FOPEN = -5 ' Can not open files
Global Const SIOFT_CANABORT = -6 ' Ymodem CAN signal abort
Global Const SIOFT_PROTOCOL = -7 ' Protocol checking error abort
Global Const SIOFT_SKIP = -8 ' Zmodem remote skip this send file
Global Const SIOFT_LACKRBUF = -9 ' Zmodem Recv-Buff size must >= 2K bytes
Global Const SIOFT_WIN32FAIL = -10 ' OS fail
' GetLastError to get the error code
Global Const SIOFT_BOARDNOTSUPPORT = -11'Board does not support this function</P><P>
Declare Function sio_open Lib "PComm.dll" (ByVal Port As Long) As Long
Declare Function sio_close Lib "PComm.dll" (ByVal Port As Long) As Long
Declare Function sio_ioctl Lib "PComm.dll" (ByVal Port As Long, ByVal baud As Long, ByVal mode As Long) As Long
Declare Function sio_flowctrl Lib "PComm.dll" (ByVal Port As Long, ByVal mode As Long) As Long
Declare Function sio_flush Lib "PComm.dll" (ByVal Port As Long, ByVal func As Long) As Long
Declare Function sio_DTR Lib "PComm.dll" (ByVal Port As Long, ByVal mode As Long) As Long
Declare Function sio_RTS Lib "PComm.dll" (ByVal Port As Long, ByVal mode As Long) As Long
Declare Function sio_lctrl Lib "PComm.dll" (ByVal Port As Long, ByVal mode As Long) As Long
Declare Function sio_baud Lib "PComm.dll" (ByVal Port As Long, ByVal speed As Long) As Long
Declare Function sio_getch Lib "PComm.dll" (ByVal Port As Long) As Long
Declare Function sio_read Lib "PComm.dll" (ByVal Port As Long, ByRef buf As Byte, ByVal length As Long) As Long
Declare Function sio_linput Lib "PComm.dll" (ByVal Port As Long, ByRef buf As Byte, ByVal length As Long, ByVal Term As Long) As Long
Declare Function sio_putch Lib "PComm.dll" (ByVal Port As Long, ByVal Term As Long) As Long
Declare Function sio_putb Lib "PComm.dll" Alias "sio_write" (ByVal Port As Long, ByRef buf As Byte, ByVal length As Long) As Long
Declare Function sio_write Lib "PComm.dll" (ByVal Port As Long, ByRef buf As Byte, ByVal length As Long) As Long
Declare Function sio_putb_x Lib "PComm.dll" (ByVal Port As Long, ByRef buf As Byte, ByVal length As Long, ByVal tick As Long) As Long
Declare Function sio_putb_x_ex Lib "PComm.dll" (ByVal Port As Long, ByRef buf As Byte, ByVal length As Long, ByVal tms As Long) As Long
Declare Function sio_lstatus Lib "PComm.dll" (ByVal Port As Long) As Long
Declare Function sio_iqueue Lib "PComm.dll" (ByVal Port As Long) As Long
Declare Function sio_oqueue Lib "PComm.dll" (ByVal Port As Long) As Long
Declare Function sio_Tx_hold Lib "PComm.dll" (ByVal Port As Long) As Long
Declare Function sio_getbaud Lib "PComm.dll" (ByVal Port As Long) As Long
Declare Function sio_getmode Lib "PComm.dll" (ByVal Port As Long) As Long
Declare Function sio_getflow Lib "PComm.dll" (ByVal Port As Long) As Long
Declare Function sio_data_status Lib "PComm.dll" (ByVal Port As Long) As Long
Declare Function sio_term_irq Lib "PComm.dll" (ByVal Port As Long, ByVal func As Long, ByVal code As Byte) As Long
Declare Function sio_cnt_irq Lib "PComm.dll" (ByVal Port As Long, ByVal func As Long, ByVal count As Long) As Long
Declare Function sio_modem_irq Lib "PComm.dll" (ByVal Port As Long, ByVal func As Long) As Long
Declare Function sio_break_irq Lib "PComm.dll" (ByVal Port As Long, ByVal func As Long) As Long
Declare Function sio_Tx_empty_irq Lib "PComm.dll" (ByVal Port As Long, ByVal func As Long) As Long
Declare Function sio_break Lib "PComm.dll" (ByVal Port As Long, ByVal time As Long) As Long
Declare Function sio_break_ex Lib "PComm.dll" (ByVal Port As Long, ByVal time As Long) As Long
Declare Function sio_view Lib "PComm.dll" (ByVal Port As Long, ByRef buf As Byte, ByVal length As Long) As Long
Declare Function sio_TxLowWater Lib "PComm.dll" (ByVal Port As Long, ByVal size As Long) As Long
Declare Function sio_AbortWrite Lib "PComm.dll" (ByVal Port As Long) As Long
Declare Function sio_AbortRead Lib "PComm.dll" (ByVal Port As Long) As Long
Declare Function sio_SetWriteTimeouts Lib "PComm.dll" (ByVal Port As Long, ByVal timeouts As Long) As Long
Declare Function sio_GetWriteTimeouts Lib "PComm.dll" (ByVal Port As Long, ByRef TotalTimeouts As Long) As Long
Declare Function sio_SetReadTimeouts Lib "PComm.dll" (ByVal Port As Long, ByVal TotalTimeouts As Long, ByVal IntervalTimeouts As Long) As Long
Declare Function sio_GetReadTimeouts Lib "PComm.dll" (ByVal Port As Long, ByRef TotalTimeouts As Long, ByRef InterfalTimeouts As Long) As Long
Declare Function sio_ActXon Lib "PComm.dll" (ByVal Port As Long) As Long
Declare Function sio_ActXoff Lib "PComm.dll" (ByVal Port As Long) As Long</P><P>Declare Function sio_FtASCIITx Lib "PComm.dll" ( _
ByVal Port As Long, ByVal fname As String, ByVal func As Long, ByVal key As Long _
) As Long</P><P>Declare Function sio_FtASCIIRx Lib "PComm.dll" ( _
ByVal Port As Long, ByVal fname As String, ByVal func As Long, ByVal key As Long, ByVal sec As Long _
) As Long</P><P>Declare Function sio_FtXmodemCheckSumTx Lib "PComm.dll" ( _
ByVal Port As Long, ByVal fname As String, ByVal func As Long, ByVal key As Long _
) As Long</P><P>Declare Function sio_FtXmodemCheckSumRx Lib "PComm.dll" ( _
ByVal Port As Long, ByVal fname As String, ByVal func As Long, ByVal key As Long _
) As Long</P><P>Declare Function sio_FtXmodemCRCTx Lib "PComm.dll" ( _
ByVal Port As Long, ByVal fname As String, ByVal func As Long, ByVal key As Long _
) As Long</P><P>Declare Function sio_FtXmodemCRCRx Lib "PComm.dll" ( _
ByVal Port As Long, ByVal fname As String, ByVal func As Long, ByVal key As Long _
) As Long</P><P>Declare Function sio_FtXmodem1KCRCTx Lib "PComm.dll" ( _
ByVal Port As Long, ByVal fname As String, ByVal func As Long, ByVal key As Long _
) As Long</P><P>Declare Function sio_FtXmodem1KCRCRx Lib "PComm.dll" ( _
ByVal Port As Long, ByVal fname As String, ByVal func As Long, ByVal key As Long _
) As Long</P><P>Declare Function sio_FtYmodemTx Lib "PComm.dll" ( _
ByVal Port As Long, ByVal fname As String, ByVal func As Long, ByVal key As Long _
) As Long</P><P>Declare Function sio_FtYmodemRx Lib "PComm.dll" ( _
ByVal Port As Long, ByRef fname As Long, ByVal fno As Long, ByVal func As Long, ByVal key As Long _
) As Long</P><P>Declare Function sio_FtZmodemTx Lib "PComm.dll" ( _
ByVal Port As Long, ByVal fname As String, ByVal func As Long, ByVal key As Long _
) As Long</P><P>Declare Function sio_FtZmodemRx Lib "PComm.dll" ( _
ByVal Port As Long, ByRef fname As Long, ByVal fno As Long, ByVal func As Long, ByVal key As Long _
) As Long</P><P>Declare Function sio_FtKermitTx Lib "PComm.dll" ( _
ByVal Port As Long, ByVal fname As String, ByVal func As Long, ByVal key As Long _
) As Long</P><P>Declare Function sio_FtKermitRx Lib "PComm.dll" ( _
ByVal Port As Long, ByRef fname As Long, ByVal fno As Long, ByVal func As Long, ByVal key As Long _
) As Long</P> <P>密码</P> 晕死,版主这么强 打不开,密码多少? <p>太好啦!!</p>
<p>谢谢</p> 有密码的!多少? <p>太好啦!!<img title="dvubb" border="0" alt="图片点击可在新窗口打开查看" align="middle" src="http://www.1000bbs.com/images/emot/em50.gif" onload="imgresize(this);"/></p>
<p>谢谢</p> 受教了 密码....要密码. <p>试用下!</p> <p>很好很强大,楼主还有玛雅语言的?</p> 顶 <font face="Verdana">学习中,不错的东西hao</font> <div class="quote"><b>以下是引用<i>sunlzs</i>在2011-5-18 22:17:00的发言:</b><br/><font face="Verdana">学习中,不错的东西hao</font> </div>
<p>谢谢提供</p>
页:
[1]