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

📄 shpa3api.h

📁 三汇CTI示例程序源码
💻 H
📖 第 1 页 / 共 5 页
字号:
//*****************Software License Agreement*******************

//1.	Hangzhou Synway Information Engineering Co., Ltd (hereinafter referred to as 'The Company') owns the complete copyrights to "this software and all its accessories, files and relative documents" (hereinafter referred to as 'The Product'). Groups and individuals are required to obtain permission from The Company prior to usage of the Product.

//2.	The Company grants permission to use The Product at no cost to groups and individuals who fully meet the following criteria:
//    A.	Using The Product in-conjunction with The Company's hardware products acquired through authorized sales channels;
//    B.	Unselfish promotion of The Product and any part of The Product to a third-party.

//3.	All groups and individuals not corresponding to Section 2 who wish to use The Product are required to obtain written permission from The Company.

//4.	Permission granted to Groups and individuals is non-transferable.

//5.	With the use of The Product, the user fully understands and agrees to all terms listed in this agreement.


#ifndef WIN32
	#ifndef OS_LINUX
		#ifndef TYPEDEF_H
			#define TYPEDEF_H

			typedef char         	CHAR;
			typedef float           FLOAT;
			typedef int				BOOL;
			typedef int             INT;
			typedef long			LONG;
			typedef void            VOID;

			typedef unsigned char	BYTE;
			typedef unsigned char   UCHAR;
			typedef unsigned int    UINT;
			typedef unsigned long   DWORD;
			typedef unsigned long   ULONG;
			typedef unsigned short  USHORT;
			typedef unsigned short	WORD;

			typedef BOOL            *LPBOOL;
			typedef BYTE            *LPBYTE;
			typedef BYTE            *PBYTE;
			typedef CHAR            *LPSTR;
			typedef CHAR            *LPTSTR;
			typedef CHAR            *PCHAR;
			typedef DWORD           *LPDWORD;
			typedef DWORD           *PDWORD;
			typedef WORD            *LPWORD;
			typedef WORD            *PWORD;
			typedef UCHAR           *PUCHAR;
			typedef void            *PVOID;
			typedef long			*LPLONG;
			typedef long			*PLONG;
			typedef void            *LPVOID;

			typedef const CHAR      *LPCSTR;
			typedef const CHAR      *LPCTSTR;
			typedef const void      *LPCVOID;

		#endif // end of #ifndef TYPEDEF_H
	#endif // end of #ifndef OS_LINUX

	#ifndef WINAPI
		#define WINAPI
	#endif

#endif // end of #ifndef WIN32

#ifndef SHCTI_CONST
	#define SHCTI_CONST

//-----------------------------------------------------------------------
// definition of channel type, which can be retrieved by invoking
// function "SsmGetFlag()" and set by invoking "SsmSetFlag()"
//-----------------------------------------------------------------------
enum{
	F_RCVDTMFSENS=1,				
	F_TXDTMFAMP=2,						
	F_RCVPHONUMHOLDUP=3,				
	F_RELATIVEENGYHOOKDETECT=4,			
	F_RXR2FILTERTIME=5,				
	F_RECTOFILEA_CALLBACKTIME = 6,
	F_CALLERIDSTYLE=7,
	F_InVoiceToBus=8,
	F_ClearInVoiceOnRcvDtmf=9,
	F_MixerResToBus=10,
	F_HighAndLowFreqEnScale=11,
	F_DualAndAllFreqEnScale=12,
	F_EchoCancelInFsk=13,				
	F_ChToRingingOnRingCnt=14,
	F_ISDNNet_WaitRemotePickup=15,
	F_ClearInVoiceOnRcv450Hz=16

};

//-----------------------------------------------------------------------
// definition of blocking reason, which can be retrieved by invoking
// function "SsmGetBlockReason()"
//-----------------------------------------------------------------------
enum{
	BLOCKBY_NULL,
	BLOCKBY_TupRcvMGB,
	BLOCKBY_TupRcvHGB,
	BLOCKBY_TupRcvSGB,
	BLOCKBY_TupWaitRLGTimeout,
	BLOCKBY_TupBlockByApp,
};

//-----------------------------------------------------------------------
// Definition of status on blocking remote circuit or circuit groups,
// which might be used by following functions
//		1. "SsmChkBlockRemoteXXX()"
//		2. "SsmChkBlockRemoteXXX()"
//-----------------------------------------------------------------------
#define BLOCKREMOTE_Unblocked			0	// no block-signal is issued
#define BLOCKREMOTE_Blocked				1	// is in blocked state now
#define BLOCKREMOTE_WaitBlockAck		2	// waiting for acknowledgement signal after sending block-signal
#define BLOCKREMOTE_WaitUnblockAck		3	// waiting for acknowledgement signal after sending unblock-signal

//-----------------------------------------------------------------------
// Definition of local blocking status on circuit or circuit groups,
// which might be used by following functions
//		 "SsmQueryLocalXXXBlockState()"
//-----------------------------------------------------------------------
#define BLOCK_AppBlockCic	0x00000001	// channel is blocked by invoking SsmBlockLocalCh()
#define BLOCK_TupRcvBLO		0x00000002	// channel is blocked by received BLO
#define BLOCK_TupRcvSGB		0x00000004	// channel is blocked by received SGB
#define BLOCK_TupRcvHGB		0x00000008	// channel is blocked by received HGB
#define BLOCK_TupRcvMGB		0x00000010	// channel is blocked by received MGB
#define BLOCK_AppBlockPCM	0x00000020	// channel is blocked by invoking SsmBlockLocalPCM()


//-----------------------------------------------------------------------
// Definition of channel unavailable reason
//-----------------------------------------------------------------------
#define UNAVAILABLE_PcmSyncLos		0x00000001	
#define UNAVAILABLE_Mtp3Unusuable	0x00000002	

//-----------------------------------------------------------------------
// Definition of DST D-Channel Event
//-----------------------------------------------------------------------
#define DST_OFFHOOK							0x8
#define DST_ONHOOK							0xe
#define DST_LT_ON							0x1001
#define DST_LT_OFF							0x1002
#define DST_LT_FLASHING						0x1003
#define DST_DGT_PRS							0x1006
#define DST_DGT_RLS							0x1007
#define DST_MSG_CHG							0x1008
#define DST_LT_FASTFLASHING					0x100b
#define DST_FUNC_BTN_PRS					0x100e
#define DST_FUNC_BTN_RLS					0x100f
#define DST_HOLD_BTN_PRS					0x1010
#define DST_HOLD_BTN_RLS					0x1011
#define DST_RELEASE_BTN_PRS					0x1012
#define DST_RELEASE_BTN_RLS					0x1013
#define DST_TRANSFER_BTN_PRS				0x1014
#define DST_ANSWER_BTN_PRS					0x1015
#define DST_SPEAKER_BTN_PRS					0x1016
#define DST_REDIAL_BTN_PRS					0x1017
#define DST_CONF_BTN_PRS					0x1018
#define DST_RECALL_BTN_PRS					0x1019
#define DST_FEATURE_BTN_PRS					0x101a
#define DST_EXIT_BTN_PRS					0x101c
#define	DST_HELP_BTN_PRS					0x101d
#define DST_SOFT_BTN_PRS					0x101e
#define DST_RING_ON							0x101f
#define DST_RING_OFF						0x1020
#define DST_MENU_BTN_PRS					0x1022
#define DST_PREVIOUS_BTN_PRS				0x1023
#define DST_NEXT_BTN_PRS					0x1024
#define DST_LT_QUICKFLASH					0x1025
#define DST_DISPLAY_CLOCK					0x1028
#define DST_DISPLAY_TIMER					0x1029
#define DST_DISPLAY_CLEAR					0x102a
#define DST_CFWD							0x102b
#define DST_CFWD_CANCELED					0x102c
#define DST_AUTO_ANSWER						0x102d
#define DST_AUTO_ANSWER_CANCELED			0x102e
#define DST_SET_BUSY						0x102f
#define DST_SET_BUSY_CANCELED				0x1030
#define DST_LT_VERY_FASTFLASHING			0x1033
#define DST_SPEAKER_BTN_RLS					0x1034
#define DST_REDIAL_BTN_RLS					0x1035
#define DST_TRANSFER_BTN_RLS				0x1036
#define DST_CONF_BTN_RLS					0x1037
#define DST_ABANDONED						0x103a
#define DST_MSG_BTN_PRS						0x1040
#define DST_AUDIO_CHG						0x104a
#define DST_DISPLAY_MSG						0x104b
#define DST_PROGRAM_BTN_PRS					0x104e
#define DST_MUTE_BTN_PRS					0x104f
#define DST_SHIFT_BTN_PRS					0x1055
#define DST_PAGE_BTN_PRS					0x1057
#define DST_SOFT_BTN_RLS					0x1059
#define DST_FEATURE_LT_OFF					0x1068
#define DST_FEATURE_LT_ON					0x1069
#define DST_FEATURE_LT_FLASHING				0x106A
#define DST_FEATURE_LT_FASTFLASHING			0x106B
#define DST_FEATURE_LT_VERY_FASTFLASHING	0x106C
#define DST_SPEAKER_LT_OFF					0x1070
#define DST_SPEAKER_LT_ON					0x1071
#define DST_SPEAKER_LT_FLASHING				0x1072
#define DST_SPEAKER_LT_FASTFLASHING			0x1073
#define DST_SPEAKER_LT_VERY_FASTFLASHING	0x1074
#define DST_SPEAKER_LT_WINK					0x1076
#define DST_MIC_LT_OFF						0x1078
#define DST_MIC_LT_ON						0x1079
#define DST_MIC_LT_FLASHING					0x107A
#define DST_MIC_LT_FASTFLASHING				0x107B
#define DST_MIC_LT_VERY_FASTFLASHING		0x107C
#define DST_HOLD_LT_OFF						0x1080
#define DST_HOLD_LT_ON						0x1081
#define DST_HOLD_LT_FLASHING				0x1082
#define DST_HOLD_LT_FASTFLASHING			0x1083
#define DST_HOLD_LT_VERY_FASTFLASHING		0x1084
#define DST_RING_LT_OFF                     0x10B8
#define DST_RING_LT_ON                      0x10B9
#define DST_RING_LT_FLASHING                0x10BA
#define DST_RING_LT_FASTFLASHING            0x10BB
#define DST_RING_LT_VERY_FASTFLASHING       0x10BC
#define DST_ANSWER_LT_OFF                   0x10C0
#define DST_ANSWER_LT_ON                    0x10C1
#define DST_ANSWER_LT_FLASHING              0x10C2
#define DST_ANSWER_LT_FASTFLASHING          0x10C3
#define DST_ANSWER_LT_VERY_FASTFLASHING     0x10C4
#define DST_PROGRAM_LT_OFF					0x10C8
#define DST_PROGRAM_LT_ON					0x10C9
#define DST_PROGRAM_LT_FLASHING				0x10CA
#define DST_PROGRAM_LT_FASTFLASHING			0x10CB
#define DST_PROGRAM_LT_VERY_FASTFLASHING	0x10CC
#define DST_PROGRAM_LT_QUICKFLASH			0x10CD
#define DST_PROGRAM_LT_WINK					0x10CE
#define DST_PROGRAM_LT_MEDIUM_WINK			0x10CF
#define DST_MSG_LT_OFF						0x10D0
#define DST_MSG_LT_ON						0x10D1
#define DST_MSG_LT_FLASHING					0x10D2
#define DST_MSG_LT_FASTFLASHING				0x10D3
#define DST_MSG_LT_VERY_FASTFLASHING		0x10D4
#define DST_TRANSFER_LT_OFF					0x10D8
#define DST_TRANSFER_LT_ON					0x10D9
#define DST_TRANSFER_LT_FLASHING			0x10DA
#define DST_TRANSFER_LT_FASTFLASHING		0x10DB
#define DST_TRANSFER_LT_VERY_FASTFLASHING	0x10DC
#define DST_TRANSFER_LT_WINK				0x10DE
#define DST_CONFERENCE_LT_OFF               0x10E0
#define DST_CONFERENCE_LT_ON                0x10E1
#define DST_CONFERENCE_LT_FLASHING          0x10E2
#define DST_CONFERENCE_LT_FASTFLASHING      0x10E3
#define DST_CONFERENCE_LT_VERY_FASTFLASHING 0x10E4
#define DST_CONFERENCE_LT_WINK				0x10E6
#define DST_REDIAL_LT_OFF					0x1100
#define DST_REDIAL_LT_ON					0x1101
#define DST_REDIAL_LT_FLASHING				0x1102
#define DST_REDIAL_LT_FASTFLASHING			0x1103
#define DST_REDIAL_LT_VERY_FASTFLASHING		0x1104
#define DST_PAGE_LT_OFF						0x1108
#define DST_PAGE_LT_ON						0x1109
#define DST_PAGE_LT_FLASHING				0x110A
#define DST_PAGE_LT_FASTFLASHING			0x110B
#define DST_PAGE_LT_VERY_FASTFLASHING		0x110C
#define DST_CTRL_BTN_PRS					0x110e
#define DST_CANCEL_BTN_PRS					0x1110
#define DST_MIC_BTN_PRS						0x1112
#define DST_FLASH_BTN_PRS					0x1114
#define DST_FLASH_BTN_RLS					0x1115
#define DST_DIRECTORY_BTN_PRS				0x1116
#define DST_MUTE_LT_OFF						0x111E
#define DST_MUTE_LT_ON						0x111F
#define DST_MUTE_LT_FLASHING				0x1120
#define DST_MUTE_LT_FASTFLASHING			0x1121
#define DST_MUTE_LT_VERY_FASTFLASHING		0x1122
#define DST_MUTE_LT_QUICKFLASH				0x1123
#define DST_MUTE_LT_WINK					0x1124
#define DST_FUNC_LT_WINK					0x114B
#define DST_SPEEDDIAL_BTN_PRS				0x1163
#define DST_SPEEDDIAL_BTN_RLS				0x1164
#define DST_DND_BTN_PRS						0x1165
#define DST_DND_BTN_RLS						0x1166
#define DST_DND_LT_OFF						0x116D
#define DST_DND_LT_ON						0x116E
#define DST_DND_LT_FLASHING					0x116F
#define DST_DND_LT_FASTFLASHING				0x1170
#define DST_DND_LT_WINK						0x1173
#define DST_CALLBACK_BTN_PRS		        0x1191
#define DST_CALLBACK_BTN_RLS				0x1192
#define DST_MUTE_BTN_RLS					0x11F4
#define DST_CALLBACK_LT_OFF					0x1266
#define DST_CALLBACK_LT_ON					0x1267
#define DST_CALLBACK_LT_FLASHING			0x1268
#define DST_CALLBACK_LT_WINK				0x1269
#define DST_CALLBACK_LT_FASTFLASHING		0x126a
#define DST_ICM_LT_OFF						0x126b
#define DST_ICM_LT_ON						0x126c
#define DST_ICM_LT_FLASHING					0x126d
#define DST_ICM_LT_WINK						0x126e
#define DST_ICM_LT_FASTFLASHING				0x126f
#define DST_ICM_BTN_PRS						0x1270
#define DST_ICM_BTN_RLS						0x1271
#define DST_FUNC_LT_FASTFLASHING			DST_LT_FASTFLASHING
#define DST_FUNC_LT_FLASHING				DST_LT_FLASHING
#define DST_FUNC_LT_OFF						DST_LT_OFF
#define DST_FUNC_LT_ON						DST_LT_ON
#define DST_FUNC_LT_QUICKFLASH				DST_LT_QUICKFLASH
#define DST_FUNC_LT_VERY_FASTFLASHING		DST_LT_VERY_FASTFLASHING

//-----------------------------------------------------------------------
//
//-----------------------------------------------------------------------
enum{
	C_ERROR_INIT_FAILURE      =0,
	C_ERROR_SSMAPI_UNOPENED   =1,
	C_ERROR_INVALID_APPCH     =2,
	C_ERROR_UNSUPPORTED_OP    =3,
	C_ERROR_INDEX_UNOPENED    =4,
	C_ERROR_INVALID_BUSCH     =5,
	C_ERROR_OP_UNOPENED       =6,
	C_ERROR_INVALID_FORMAT    =7,
	C_ERROR_INVALID_PARAMETER =8,
	C_ERROR_FILEOP_FAILURE    =9,
	C_ERROR_MEMORY_FAILURE    =10,
	C_ERROR_RESOURCE_USEUP    =11,

⌨️ 快捷键说明

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