| 123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879880881882883884885886887888889890891892893894895896897898899900901902903904905906907908909910911912913914915916917918919920921922923924925926927928929930931932933934935936937938939940941942943944945946947948949950951952953954955956957958959960961962963964965966967968969970971972973974975976977978979980981982983984985986987988989990991992993994995996997998999100010011002100310041005100610071008100910101011101210131014101510161017101810191020102110221023102410251026102710281029103010311032103310341035103610371038103910401041104210431044104510461047104810491050105110521053105410551056105710581059106010611062106310641065106610671068106910701071107210731074107510761077107810791080108110821083108410851086108710881089109010911092109310941095109610971098109911001101110211031104110511061107110811091110111111121113111411151116111711181119112011211122112311241125112611271128112911301131113211331134113511361137113811391140114111421143114411451146114711481149115011511152115311541155115611571158115911601161116211631164116511661167116811691170117111721173117411751176117711781179118011811182118311841185118611871188118911901191119211931194119511961197119811991200120112021203120412051206120712081209121012111212121312141215121612171218121912201221122212231224122512261227122812291230123112321233123412351236123712381239124012411242124312441245124612471248124912501251125212531254125512561257125812591260126112621263126412651266126712681269127012711272127312741275127612771278127912801281128212831284128512861287128812891290129112921293129412951296129712981299130013011302130313041305130613071308130913101311131213131314131513161317131813191320132113221323132413251326132713281329133013311332133313341335133613371338133913401341134213431344134513461347134813491350135113521353135413551356135713581359136013611362136313641365136613671368136913701371137213731374137513761377137813791380138113821383138413851386138713881389139013911392139313941395139613971398139914001401140214031404140514061407140814091410141114121413141414151416141714181419142014211422142314241425142614271428142914301431143214331434143514361437143814391440144114421443144414451446144714481449145014511452145314541455145614571458145914601461146214631464146514661467146814691470147114721473147414751476147714781479148014811482148314841485148614871488148914901491149214931494149514961497149814991500150115021503150415051506150715081509151015111512151315141515151615171518151915201521152215231524152515261527152815291530153115321533153415351536153715381539154015411542154315441545154615471548154915501551155215531554155515561557155815591560156115621563156415651566156715681569157015711572157315741575157615771578157915801581158215831584158515861587158815891590159115921593159415951596159715981599160016011602160316041605160616071608160916101611161216131614161516161617161816191620162116221623162416251626162716281629163016311632163316341635163616371638163916401641164216431644164516461647164816491650165116521653165416551656165716581659166016611662166316641665166616671668166916701671167216731674167516761677167816791680168116821683168416851686168716881689169016911692169316941695169616971698169917001701170217031704170517061707170817091710171117121713171417151716171717181719172017211722172317241725172617271728172917301731173217331734173517361737173817391740174117421743174417451746174717481749175017511752175317541755175617571758175917601761176217631764176517661767176817691770177117721773177417751776177717781779178017811782178317841785178617871788178917901791179217931794179517961797179817991800180118021803 |
- /***********************************************************************/
- /* EhangCom: API Head file
- *
- * FILE: srllib.h
- * DESCRIPTION: Header File for EhangCom Standard Runtime library
- *
- * Copyright (c) EhangCom Corp. All Rights Reserved
- *
- * THIS IS UNPUBLISHED PROPRIETARY SOURCE CODE OF EhangCom Corp.
- * The copyright notice above does not evidence any actual or
- * intended publication of such source code.
- */
- /**********************************************************************/
- #ifndef __SRLLIB_H__
- #define __SRLLIB_H__
- #define ISX_API_VER "2.0.21.18"
- #define ISX_API_SPX ""
- #include "IsxApi.h"
- #ifdef WIN32
- #include <windows.h>
- #endif
- /*
- * mode for all ISX_xxx function
- */
- #ifndef EV_ASYNC
- #define EV_SYNC 0x0000 //Used
- #define EV_BIT_01 0x0001
- #define EV_BIT_02 0x0002
- #define EV_BIT_03 0x0004 //Used
- #define EV_BIT_04 0x0008 //Used
- #define EV_BIT_05 0x0010 //Used
- #define EV_BIT_06 0x0020 //Used
- #define EV_BIT_07 0x0040 //Used
- #define EV_BIT_08 0x0080 //Used
- #define EV_BIT_09 0x0100 //Used
- #define EV_BIT_10 0x0200 //Used
- #define EV_BIT_11 0x0400 //Used
- #define EV_BIT_12 0x0800 //Used
- #define EV_BIT_13 0x1000
- #define EV_BIT_14 0x2000
- #define EV_BIT_15 0x4000
- #define EV_ASYNC 0x8000 //Used
- #endif
- #ifndef ENUM_OPERMODE
- #define ENUM_OPERMODE 1
- typedef enum{
- OPER_UNKNOWN = -1,
- OPER_PLAY = 1,
- OPER_RECORD,
- OPER_GETDIG,
- OPER_ACCEPTCALL,
- OPER_ANSWERCALL,
- OPER_MAKECALL,
- OPER_DROPCALL,
- OPER_SETBILLING,
- OPER_SENDMOREINFO,
- OPER_DLCACHE,
- OPER_DLMEM,
- OPER_STOPCH,
- OPER_PUTEVT,
- OPER_SYSNOTIFY,
- OPER_CST,
- OPER_GETTRCOUNT,
- OPER_XOIP_SETRESATTR,
- OPER_XOIP_GETRESATTR,
- OPER_XOIP_GETSSINFO,
- OPER_XOIP_STARTMEDIA,
- OPER_XOIP_STOP,
- OPER_XOIP_SENDDIGITS,
- OPER_XOIP_ENABLEEVENT,
- OPER_XOIP_DISABLEEVENT,
- OPER_XOIP_RECEIVEDIGITS,
- OPER_XOIP_SENDRFC2833,
- OPER_SENDCPG,
- OPER_CALLPROCEEDING,
- OPER_CALLPROGRESS,
- OPER_SETUPACK,
- OPER_SIP_SENDREINVITE,
- OPER_SIP_SENDREINVITEACK,
- OPER_SIP_SENDREGISTER,
- OPER_XOIP_SWITCH_VF,
- OPER_SIP_SENDINFO,
- OPER_SIP_SENDINFOACK,
- OPER_NR_SCROUTE,
- OPER_NR_SCUNROUTE,
- OPER_SIP_SENDREGISTERACK,
- OPER_SIP_SENDTRYING,
- OPER_DT_SETTSSIG,
- OPER_DT_GETTSSIG,
- OPER_SIP_SENDSUBSCRIBE,
- OPER_SIP_SENDNOTIFYACK,
- OPER_GETCONFENERGY,
- OPER_ESTCONF,
- OPER_ADDCONF,
- OPER_REMCONF,
- OPER_DELCONF,
- OPER_SETCDE ,
- OPER_ESTCONF_EX,
- OPER_ADDCONF_EX,
- OPER_REMCONF_EX,
- OPER_SETCDE_EX,
- OPER_SETLMASKEX,
- OPER_SS7_SENDEXT,
- OPER_FXS_SEND,
- OPER_FXS_RECV,
- OPER_MO_SETHOOK,
- OPER_MO_DIAL,
- OPER_MS_GENRING,
- OPER_MS_WTRING,
- OPER_AG_SENDTONE,
- OPER_RECVFSK,
- OPER_SENDFSK,
- OPER_SIP_RECVUPDATE,
- OPER_SIP_SENDUPDATE,
- OPER_SIP_RECVUPDATEACK,
- OPER_SIP_SENDUPDATEACK,
- OPER_SIP_RECVACK,
- OPER_SIP_SENDACK,
- OPER_SIP_RECVPRACK,
- OPER_SIP_SENDPRACK,
- OPER_SIP_SENDPRACKACK,
- OPER_SIP_RECVPRACKACK,
- OPER_CAUSE_172, //[2015-9-7]同抢时GCEV_DISCONNECTED需要传这个操作类型
- }OPERATIONS;
- #endif
- #ifndef _BRD_TYPE_
- #define _BRD_TYPE_
- //board type
- typedef enum{
- BT_NULL = -1,
- BT_MB = 0,
- BT_DSP = 1,
- BT_XOIP = 2,
- BT_PRI = 3,
- BT_SS7 = 4,
- BT_TRUNK = 5,
- BT_SIP = 6,
- BT_FiberTrunk = 7,
- BT_FiberSwitch = 8,
- BT_TRUNK_LAW = 9,
- BT_AG_FXO = 10,
- BT_AG_FXS = 11,
- BT_TRUNK_MIX = 12,
- BT_TRUNK_LAW_MIX = 13,
- BT_M3G = 14,
- BT_TRUNK_HIIMP_MIX = 15,
- BT_AG_AHR = 16,
- BT_SLOT2 = 127
- }BRD_TYPE;
- #endif
- #ifndef MAX_NODE_NUM
- #define MAX_NODE_NUM 8
- #define MAX_PRD_NUM 32
- #define MAX_M3GC_NUM 32
- #define MAX_TRUNK_BRD 30
- #define MAX_SPAN_NUM 8
- #define MAX_DSP_BRD 16
- #define MAX_XOIP_BRD 16
- #define MAX_PRI_BRD 4
- #define MAX_SS7_BRD 4
- #define MAX_SIP_BRD 4
- #define MAX_AG_BRD 30
- #define MAX_M3G_BRD 16
- #ifndef _UNDEFINE_MAX_IP_LEN
- #define MAX_IP_LEN 32
- #endif
- #define EHANG_MAX_IP_LEN 32
- #define EHANG_MAX_FILENAME_LEN 256
- #endif
- #define MAX_SPANCH_NUM 32
- #define MAX_DSPCH_NUM 256
- #define MAX_CONF_NUM 256
- #define MAX_XOIPCH_NUM 512 //[2013-6-19]404 -> 512
- #define MAX_CSCH_NUM 1
- #define MAX_FXSCH_NUM 512
- #define MAX_SIPCH_NUM 30000
- #define MAX_AGCH_NUM 4
- #define MAX_M3GCH_NUM 512 //[2013-6-19]256 -> 512
- #define MAX_CACHE_NUM 1344
- #define MAX_ERRMSG_LEN 64
- #define MAX_FMEM_NUM 32
- #define MAX_AGTELNUM_LEN 32
- #define MAX_FSKDATA_LEN 800
- #define MAX_CALLID_DATA_LEN 240
- #define MAX_USR2USRINFO_LEN 103
- #define MAX_TESTDATA_LEN (1024+40)
- #define MAX_FLASH_DATA_LEN 220
- typedef struct{
- USHORT LOLITC : 1; //Loss of Line Interface Transmit Clock
- USHORT TOCD : 1; //Transmit Open-Circuit Detector
- USHORT TCLE : 1; //Transmit Current Limit Exceeded
- USHORT LRCL : 1; //Line Interface Receive Carrier Loss
- USHORT RLOS : 1; //Rx Loss Of Sync
- USHORT FRCL : 1; //Framer Receive Carrier Loss
- USHORT RUA1 : 1; //Receive Unframed All Ones
- USHORT RYEL : 1; //Receive Yellow Alarm
- USHORT RLOSC : 1; //RLOS clean
- USHORT FRCLC : 1; //FRCL clean
- USHORT RUA1C : 1; //RUA1 clean
- USHORT RYELC : 1; //RYEL clean
- USHORT Rfu : 4; //Reserved for future use.
- }ELE_SPAN_ALARM;
- // Optic trunk alarm
- typedef struct {
- USHORT LoREI : 1; //VC12: Remote Error Indicator
- USHORT LoRDI : 1; //VC12: Remote Incorrect Indicator
- USHORT TuLOP : 1; //VC12: TU Lose of pointer
- USHORT LoTIM : 1; //VC12: TU trace mismatch (alarm not include this bit)
- USHORT LoPSLM : 1; //VC12: Path signal lable mismatch
- USHORT Rfu : 1; //VC12: rev(alarm not include this bit)
- USHORT LoBIP2 : 2; //VC12: current value of BIP2(alarm not include these bits)
- USHORT LoV5 : 8; //current V5(alarm not include these bits)
- } SDH_SPAN_ALARM;
- // Current alarm of VC12
- //alarm or status of V5:
- //bit 7,6 5 4 3 2 1 0
- //Name LO_BIP2 x LO_PSLM LO_TIM TU_LOP LO-RDI LO-REI
- //LO_BIP2: Current value of BIP2
- //LO_PSLM: VC12 Path signal label mismatch
- //LO_TIM: VC12 TU trace mismatch
- //TU_LOP: VC12 Lose of Pointer
- //LO_RDI: Remote Incorrect Indicator
- //LO_REI: Remote Error Indicator
- //{{System Event
- #pragma pack(1)
- #ifndef _SYS_EVT_DATA
- #define _SYS_EVT_DATA
- typedef struct{
- UCHAR m3gcno;
- UCHAR conn_status; //refer to eM3G_BRD_CONN_STATUS
- }M3G_CONN_ST;
- #ifndef __DCH_
- #define __DCH_
- typedef struct{
- UCHAR nodeno;
- UCHAR brdno;
- UCHAR spanno;
- }D_CH;
- #endif
- #ifndef _DCH_ALARM
- #define _DCH_ALARM
- typedef struct {
- D_CH ch;
- UCHAR timeslot;
- UCHAR DChId;
- UCHAR ucAlarm;
- }DCH_ALARM;
- #endif
- typedef struct {
- UCHAR ucStackId;
- UCHAR ucLinksetId;
- UCHAR ucLinkId;
- UCHAR ucAlarm;
- }LINK_ALARM;
- #ifndef __SIPSTACK_STATUS //[2015-4-22] value of event<SYSEV_SIPSTACK_STATUS>
- #define __SIPSTACK_STATUS
- #define SIPSTACK_DEACTIVE 0
- #define SIPSTACK_ACTIVE 1
- #endif
- typedef struct{
- CHAR cIsxNo;
- CHAR cBrdNo;
- CHAR cSpanNum;
- union{
- CHAR cStatus;
- SHORT sCap;
- USHORT usAlarm; /*parse by ELE_SPAN_ALARM(cBrdNo<8) or SDH_SPAN_ALARM(cBrdNo>8)*/
- USHORT sRet;
- M3G_CONN_ST m3gConnSt;
- DCH_ALARM dchAlarm;
- LINK_ALARM linkAlarm;
- USHORT usCap;
- }u;
- }SYS_EVT_DATA;
- #endif
- #pragma pack()
- #ifndef ISXEV_USER_START
- #define ISXEV_USER_START 0x8000
- #endif
- #ifndef SYSEV_MC_STATUS
- #define SYSEV_MC_STATUS 0x4000 /* Master Controller status */
- #define SYSEV_PRD_STATUS 0x4001 /* PRD status */
- #define SYSEV_MB_STATUS 0x4002 /* Mother board status */
- #define SYSEV_DSP_STATUS 0x4003 /* DSP board status */
- #define SYSEV_PRI_STATUS 0x4004 /* PRI board status */
- #define SYSEV_SPAN_STATUS 0x4005 /* Span status */
- #define SYSEV_DSP_BRD_CAP 0x4006 /* DSP board capability */
- #define SYSEV_PRI_BRD_CAP 0x4007 /* PRI board capability */
- #define SYSEV_XOIP_BRD_CAP 0x4008 /* XOIP board capability */
- #define SYSEV_SPAN_ALARM 0x4009 /* Span alarm event */
- #define SYSEV_SPAN_E1 0x400a /* Set span type to E1 */
- #define SYSEV_SPAN_T1 0x400b /* Set span type to T1 */
- #define SYSEV_SPAN_J1 0x400c /* Set span type to J1 */
- #define SYSEV_SS7_STATUS 0x400d /* SS7 board status */
- #define SYSEV_CAP_DATA 0x400e /* Signaling date */
- #define SYSEV_XOIP_STATUS 0x400f /* XOIP board status */
- #define SYSEV_SS7_BRD_CAP 0x4010 /* SS7 board capability */
- #define SYSEV_SIP_STATUS 0x4011 /* SIP board status */
- #define SYSEV_SIP_BRD_CAP 0x4012 /* SIP board capability */
- #define SYSEV_M3G_STATUS 0x4013 /* M3G board status */
- #define SYSEV_M3G_BRD_CAP 0x4014 /* M3G board capability */
- #define SYSEV_M3G_CONN_STATUS 0x4015 /* M3G board to M3GC connect status */
- #define SYSEV_ETHERCAP_DATA 0x4017 /* SIP/XOIP cap date */
- #define SYSEV_PRI_L2DATA 0x4018 /* PRI L2 data */
- #define SYSEV_MRCPS_STATUS 0x4019 /* MRCPServer status */
- #define SYSEV_RTPS_STATUS 0x401a /* RTPProxy status */
- #define SYSEV_RTPS_CAP 0x401b /* RTP proxy CAP change */
- #define SYSEV_FXS_STATUS 0x401d /* FaxServer status */
- #define SYSEV_AG_STATUS 0x401e /* AG status */
-
- #define SYSEV_SIP_REGISTERSENT 0x4100 /* SIP Register sent */
- #define SYSEV_SIP_RECVREGISTERACK 0x4101 /* SIP Register ACK received */
- #define SYSEV_SIP_REGISTERACKSENT 0x4102 /* SIP Register ACK sent */
- #define SYSEV_SIP_RECVREGISTER 0x4103 /* SIP Register received */
- #define SYSEV_SIP_TRANSACTIONSENT 0x4104 /* SIP Transaction sent */
- #define SYSEV_SIP_RECVTRANSACTION 0x4105 /* SIP Transaction received */
- #define SYSEV_SIP_TRANSACTIONACKSENT 0x4106 /* SIP Transaction ACK sent */
- #define SYSEV_SIP_RECVTRANSACTIONACK 0x4107 /* SIP Transaction ACK received */
- #define SYSEV_SIP_REGUSER_NEW 0x4108 /* SIP register user new added */
- #define SYSEV_SIP_REGUSER_DEL 0x4109 /* SIP register user deleted */
- #define SYSEV_SIP_REGUSER_ERR 0x410a /* SIP register user reg fail */
- #define SYSEV_SS7_CGBSENT 0x4200 /* SS7 CGB sent */
- #define SYSEV_SS7_GRSSENT 0x4201 /* SS7 GRS sent */
- #define SYSEV_SS7_CGUSENT 0x4202 /* SS7 CGU sent */
- #define SYSEV_SS7_RECVCGB 0x4203 /* SS7 CGB received */
- #define SYSEV_SS7_RECVGRS 0x4204 /* SS7 GRS received */
- #define SYSEV_SS7_RECVCGU 0x4205 /* SS7 CGU received */
- #define SYSEV_PRIDCH_ALARM 0x4206 /* PRI dch alarm received */
- #define SYSEV_S7LINK_ALARM 0x4207 /* SS7 link alarm received */
- #define SYSEV_SIPSTACK_STATUS 0x4208 /* SIP stack status received [2015-4-22]*/
-
- #define SYSEV_MSGEVT_END SYSEV_SIPSTACK_STATUS /* end */
- #endif
- //}}
- //{{Device information
- typedef enum{
- enDS_NotExist, //Not exist
- enDS_OutOfServices, //Out of services
- enDS_Working, //Working
- }enDEV_STATUS;
- typedef struct{
- enDEV_STATUS Status;
- }DI_PRD;
- typedef enum{
- enST_E1,
- enST_T1,
- enST_J1
- }enSPAN_TYPE;
- typedef struct{
- enDEV_STATUS Status; /*status*/
- enSPAN_TYPE SpanType; /*span type*/
- USHORT usAlarm; /*span alarm*/
- }DI_SPAN;
- typedef struct{
- DI_SPAN Span[MAX_SPAN_NUM];
- }DI_TRUNK;
- typedef struct{
- enDEV_STATUS Status;
- USHORT usCap;
- }DI_DSP;
- typedef struct{
- enDEV_STATUS Status;
- USHORT usCap;
- }DI_XOIP;
- typedef struct{
- enDEV_STATUS Status;
- USHORT usCap;
- }DI_PRI;
- typedef struct{
- enDEV_STATUS Status;
- USHORT usCap;
- }DI_SS7;
- typedef struct{
- enDEV_STATUS Status;
- USHORT usCap;
- }DI_SIP;
- typedef struct{
- INT iBrdType; //refer to AG_BRDTYPE_NULL, AG_BRDTYPE_FXO, AG_BRDTYPE_FXS
- }DI_AG;
- typedef struct{
- enDEV_STATUS Status;
- USHORT usCap;
- }DI_M3G;
- typedef struct{
- enDEV_STATUS MbStatus;
- USHORT usSpanLicNum;
- DI_TRUNK Trunk[MAX_TRUNK_BRD];
- DI_DSP Dsp[MAX_DSP_BRD];
- DI_XOIP Xoip[MAX_XOIP_BRD];
- DI_PRI Pri[MAX_PRI_BRD];
- DI_SS7 Ss7[MAX_SS7_BRD];
- DI_SIP Sip[MAX_SIP_BRD];
- DI_AG Ag[MAX_AG_BRD];
- DI_M3G M3g[MAX_M3G_BRD];
- }DI_ISX;
- typedef struct{
- DI_PRD Prd[MAX_PRD_NUM];
- DI_ISX Isx[MAX_NODE_NUM];
- }DEV_INFO;
- //}}
- #pragma pack(1)
- #ifndef _GEN_RESULT
- #define _GEN_RESULT
- typedef struct{
- SHORT sRetVal;
- union{
- INT confid;
- }u1;
- union{
- INT iConfereeNum;
- }u2;
- }GEN_RESULT;
- #endif
- #pragma pack()
- //////////////////////////////////////////////////////////////////////////
- //{{Last Error Code
- #ifndef LE_SUCCESS
- #define LE_SUCCESS 0x00000000
- #define LE_FAILURE 0x8fffffff
- #define LE_INVALID_DEVTYPE 0x80000000
- #define LE_INVALID_NODENO 0x80000001
- #define LE_INVALID_BRDNUM 0x80000002
- #define LE_INVALID_CHANNEL 0x80000003
- #define LE_INVALID_PARM 0x80000004
- #define LE_INVALID_PRDNO 0x80000005
- #define LE_INVALID_STATE 0x80000006
- #define LE_DEV_OUTOFSERVICE 0x80000010
- #define LE_DEV_OPENED 0x80000011
- #define LE_DEV_OPENING 0x80000012
- #define LE_DEV_CLOSING 0x80000013
- #define LE_DEV_CLOSED 0x80000014
- #define LE_OPER_TIMEOUT 0x80000020
- #define LE_INVALID_DEVHDL 0x80000021
- #define LE_LINK_FAIL 0x80000030
- #define LE_NO_RES1 0x81000008 //no SN
- #define LE_NO_RES2 0x81000009 //mapi com send queue is full
- #define LE_ITEM_NOT_EXIST 0x82000001
- #define LE_ITEM_EXIST 0x82000002
- #define LE_TABLE_FULL 0x82000003
-
- #endif
- //}}
- /*
- * Error codes returned by ATDV_LASTERR()
- */
- #ifndef _ISXDEV_LASTERR
- #define _ISXDEV_LASTERR
- #define ISXEC_NOERROR 0x0000 /* No Errors */
- #define ISXEC_SYSTEM 0x0001 /* System Error */
- #define ISXEC_FWERROR 0x0002 /* Firmware Error */
- #define ISXEC_TIMEOUT 0x0003 /* Function Timed Out */
- #define ISXEC_BADIOTT 0x0004 /* Invalid Entry in the DX_IOTT */
- #define ISXEC_BADTPT 0x0005 /* Invalid Entry in the DX_TPT */
- #define ISXEC_BADPARM 0x0006 /* Invalid Parameter in Function Call */
- #define ISXEC_BADDEV 0x0007 /* Invalid Device Descriptor */
- #define ISXEC_BADPROD 0x0008 /* Func. Not Supported on this Board */
- #define ISXEC_BUSY 0x0009 /* Device is Already Busy */
- #define ISXEC_IDLE 0x000a /* Device is Idle */
- #define ISXEC_BADWAVEFILE 0x000c /* Bad/Unsupported WAV file */
- #define ISXEC_XPBPARM 0x000d /* Bad XPB structure */
- #define ISXEC_NOSUPPORT 0x000e /* Not supported */
- #define ISXEC_NOTIMP 0x000f /* Function not implemented */
- #define ISXEC_NORESOURCE 0x0013 /* No Resources */
- #define ISXEC_OPERTIMEOUT 0x0016 /* Operation timeout */
- #define ISXEC_BADSVMT 0x0017 /* The SVMT is not the default */
- #define ISXEC_UNKNOWNDEV 0x0018 /* Unknown device */
- #define ISXEC_BADPARM_M 0x0028 /* <M> Invalid Parameter in Function Call */
- #define ISXEC_CH_OCCUPIED 0x0029 /* <M> Channel is already occupied */
- #define ISXEC_NO_CH 0x002a /* <M> Channel is not exist */
- #define ISXEC_NO_CAP 0x002b /* <M> The device has no the capability */
- #define ISXEC_OPEN_FILE 0x002c /* <M> Can not open the file */
- #define ISXEC_BAD_FILEFMT 0x002d /* <M> Unknown file format */
- #define ISXEC_BAD_DATA 0x002e /* <M> The DSP not support the data format */
- #define ISXEC_PRD_OFS 0x002f /* <M> The PRD is out of service */
- #define ISXEC_CH_OFS 0x0030 /* <M> The channel is out of service */
- #define ISXEC_NO_REC 0x0031 /* <M> The channel is not recording */
- #define ISXEC_NO_PLAY 0x0032 /* <M> The channel is not playing */
- #define ISXEC_CREATE_FILE 0x0033 /* <M> Can not create the file */
- #define ISXEC_NO_PRD 0x0034 /* <M> The PRD is not exist */
- #define ISXEC_NO_CACHEID 0x0035 /* <M> The system has no cache id */
- #define ISXEC_NO_CACHEVOC 0x0036 /* <M> The cache voice is not exist */
- #define ISXEC_NO_DSP 0x0037 /* <M> The dsp is not exist */
- #define ISXEC_DSP_OFS 0x0038 /* <M> The DSP is out of service */
- #define ISXEC_NO_CONF 0x0039 /* <M> The conference is not exist */
- #define ISXEC_NO_CONFID 0x003a /* <M> The system has no conf-id */
- #define ISXEC_CH_INCONF 0x003b /* <M> The channel is already in the conference */
- #define ISXEC_RECORDING 0x003c /* <M> The channel is already recording */
- #define ISXEC_PLAYING 0x003d /* <M> The channel is already playing */
- #define ISXEC_NO_MEMVOC 0x003e /* <M> The memory voice is not exist */
- #define ISXEC_UNKNOWN_M 0x003f /* <M> Unknown reason */
- #define ISXEC_UNKNOWN_MM 0x0040 /* <M> Unknown error number from MasterController */
- #define ISXEC_CACHEV_BUSY 0x0041 /* <M> Delete fail because of the cache voice is in use */
- #define ISXEC_NOT_FLEX 0x0042 /* <M> The conference is not flexiable */
- #define ISXEC_NO_MEM 0x0043 /* <M> The memory is not enough */
- #define ISXEC_INVALID_STATE 0x0044 /* <M> The state is invalid */
- #define ISXEC_BAD_HANDLE 0x0045 /* <M> Bad handle */
- /*
- * GTD Error Codes
- */
- //#define ISXEC_TONEID 0x41 /* Bad Tone Template ID */
- //#define ISXEC_MAXTMPLT 0x42 /* Max number of Templates Exists */
- //#define ISXEC_INVSUBCMD 0x43 /* Invalid Sub Command Number */
- //#define ISXEC_CHANNUM 0x44 /* Invalid Channel Number Specified */
- //#define ISXEC_FREQDET 0x45 /* Invalid Freq Component Values */
- // /* in Tone Template Description */
- #define ISXEC_CADENCE 0x0046 /* Invalid Cadence Component Values */
- /* in Tone Template Description */
- #define ISXEC_ASCII 0x0047 /* Invalid ASCII Value */
- /* in Tone Template Description */
- #define ISXEC_DIGTYPE 0x0048 /* Invalid Dig_Type Value */
- /* in Tone Template Description */
- #define ISXEC_MSGSTATUS 0x0049 /* Invalid Message Status Setting */
- /*
- * Speed and Volume Control Error Codes
- */
- #define ISXEC_SVADJBLKS 0x004a /* Invalid Number of Speed/Volume */
- /* Adjustment Blocks */
- #define ISXEC_SPDVOL 0x004b /* Must Specify either SV_SPEEDTBL or SV_VOLUMETBL */
- #define ISXEC_SVMTRANGE 0x004d /* An out of Range entry in DX_SVMT */
- #define ISXEC_PRD_DSP_FILEORDIR_NOT_EXIST 0x004f /* <PRD-DSP> File or dir not exist */
- #define ISXEC_PRD_DSP_READ_FILE_FAIL 0x0050 /* <PRD-DSP> Read file fail. */
- #define ISXEC_PRD_DSP_FILE_NOT_ENOUGH_DATA 0x0051 /* <PRD-DSP> Not enough data in the file. */
- #define ISXEC_PRD_DSP_NOT_RESAMPLE_RES 0x0052 /* <PRD-DSP> Not enough resample resource. */
- #define ISXEC_PRD_DSP_INIT_RESAMPLE_RES_FAIL 0x0053 /* <PRD-DSP> resample init fail. */
- #define ISXEC_PRD_DSP_FIFO_FULL 0x0054 /* <PRD-DSP> FIFO full. */
- #define ISXEC_PRD_DSP_UNKNOWN_VOICE_FMT 0x0055 /* <PRD-DSP> Unknown voice format. */
- #define ISXEC_PRD_DSP_PROMPT_STATUS_ERROR 0x0056 /* <PRD-DSP> Wrong state for cache voice. */
- #define ISXEC_PRD_DSP_CREATE_POOL_FAIL 0x0057 /* <PRD-DSP> Create APR pool fail. */
- #define ISXEC_PRD_DSP_GET_FILE_INFO_FAIL 0x0058 /* <PRD-DSP> Get file info fail. */
- #define ISXEC_PRD_DSP_SEEK_FILE_FAIL 0x0059 /* <PRD-DSP> File seek operation fail. */
- #define ISXEC_PRD_DSP_CHAN_NOT_OCCPED 0x005a /* <PRD-DSP> The channel is not occupied. */
- #define ISXEC_PRD_DSP_INVALID_WAVE_FILE 0x005b /* <PRD-DSP> Invalid WAVE file format. */
- #define ISXEC_PRD_DSP_WRITE_WAVE_FILE_FAIL 0x005c /* <PRD-DSP> Write WAVE file fail. */
- #define ISXEC_PRD_DSP_SEND_MESSAGE_FAIL 0x005d /* <PRD-DSP> Send network message fail. */
- #define ISXEC_PRD_DSP_FILE_NOT_EXIST_OR_CLOSED 0x005e /* <PRD-DSP> File not exist or closed. */
- #define ISXEC_PRD_DSP_WRITE_FILE_FAIL 0x005f /* <PRD-DSP> Write file fail. */
- #define ISXEC_PRD_DSP_NETWORK_DISCONED 0x0060 /* <PRD_DSP> The network(MAPI) disconnected. */
- #define ISXEC_DSP_MC_CONF_RET_LSTNERID_INVAL 0x0061 /* <DSP-MC> Invalid listener index. */
- #define ISXEC_DSP_MC_CONF_RET_NOT_FLEXABLE 0x0062 /* <DSP-MC> The conference is not flexiable. */
- #define ISXEC_DSP_MC_PROMPT_RET_INDEX_INVAL 0x0063 /* <DSP-MC> Invalid cache voice index. */
- #define ISXEC_DSP_MC_OCT_ERROR 0x0064 /* <DSP-MC> Octasic access error. */
- #define ISXEC_DSP_MC_CN8478_ERROR 0x0065 /* <DSP-MC> CN8478 error. */
- #define ISXEC_DSP_MC_PRD_NET_ERROR 0x0066 /* <DSP-MC> The communication to PRD error. */
- #define ISXEC_DSP_MC_QUEUE_BUSY 0x0067 /* <DSP-MC> The inner queue busy. */
- #define ISXEC_DSP_MC_PRD_NET_BUSY 0x0068 /* <DSP-MC> The communication to PRD busy. */
- #define ISXEC_MC_MAPI_BYTE_ORDER_CONVERT_FAIL 0x0069 /* <MC-MAPI> Endian convert fail. */
- #define ISXEC_MC_MAPI_SEND_MESSAGE_FAIL 0x006a /* <MC-MAPI> Send network message fail. */
- #define ISXEC_MC_MAPI_PROMPT_NOT_OCCPED_BY_THIS_MOD 0x006b /* <MC-MAPI> The cache prompt is not belong to the APP. */
- #define ISXEC_MC_MAPI_PROMPT_STATUS_ERROR 0x006c /* <MC-MAPI> Wrong cache prompt state. */
- #define ISXEC_MC_MAPI_CHAN_NOT_OCCPED_BY_THIS_MOD 0x006d /* <MC-MAPI> The channel is not belong to the APP. */
- #define ISXEC_MC_MAPI_CONF_STATUS_ERROR 0x006e /* <MC-MAPI> Wrong conference state. */
- #define ISXEC_MC_MAPI_DSP_CHAN_NOT_IN_CONF_STATUS 0x006f /* <MC-MAPI> The channel is not in conference state. */
- #define ISXEC_PRD_MAPI_INVALID_PARAM 0x0070 /* <PRD_MAPI> Invalid param. */
- #define ISXEC_PRD_MAPI_CHAN_NOT_EXIST 0x0071 /* <PRD_MAPI> Channel not exist. */
- #define ISXEC_PRD_MAPI_CHAN_STATUS_ERROR 0x0072 /* <PRD_MAPI> Bad channel state. */
- #define ISXEC_PRD_MAPI_FD_NOT_OCCPED_BY_THIS_MOD 0x0073 /* <PRD_MAPI> The file handle is not belong to the APP. */
- #define ISXEC_PRD_MAPI_OPEN_FILE_LIMIT 0x0074 /* <PRD_MAPI> Too more files opened. */
- #define ISXEC_PRD_MAPI_FILE_OP_ERR 0x0075 /* <PRD_MAPI> File operation fail. */
- /*
- * VOIP Error Codes
- */
- #define ISXEC_MC_IPMEDIA_RET_BAD_PARAM 0x0076 /* <IPM-MC> Invalid param. */
- #define ISXEC_MC_IPMEDIA_RET_SET_TOS_FAIL 0x0077 /* <IPM-MC> Setup TOS fail. */
- #define ISXEC_MC_IPMEDIA_RET_SET_FAX_FAIL 0x0078 /* <IPM-MC> Setup FAX attribute fail. */
- #define ISXEC_MC_IPMEDIA_RET_SET_VOC_FAIL 0x0079 /* <IPM-MC> Setup VOC attribute fail. */
- #define ISXEC_MC_IPMEDIA_RET_NO_LICENSE 0x007a /* <IPM-MC> No usable license. */
- #define ISXEC_MC_IPMEDIA_RET_FAIL_STATE 0x007b /* <IPM-MC> Bad channel state. */
- #define ISXEC_MC_IPMEDIA_RET_FAIL_SESSION_GET 0x007c /* <IPM-MC> Get SESSION info fail. */
- #define ISXEC_MC_IPMEDIA_RET_FAIL_DEV 0x007d /* <IPM-MC> return error from device. */
- #define ISXEC_MC_IPMEDIA_RET_FAIL_DEV_NOT_INIT 0x007e /* <IPM-MC> Device not initialized. */
- #define ISXEC_MC_IPMEDIA_RET_FAIL_NO_GW 0x007f /* <IPM-MC> No setup gateway. */
- #define ISXEC_MC_IPMEDIA_RET_FAIL_TRANSAC 0x0080 /* <IPM-MC> Error with transaction */
- /*
- * SIP Error Codes
- */
- #define ISXEC_MC_SIPUA_RET_BAD_PARAM 0x0081 /* <SIP-MC> Invalid param. */
- #define ISXEC_MC_SIPUA_RET_BAD_STATE 0x0082 /* <SIP-MC> Bad channel state. */
- #define ISXEC_MC_SIPUA_RET_NO_RESOURCE 0x0083 /* <SIP-MC> No usable resource. */
- #define ISXEC_MC_SIPUA_RET_DEV_BUSY 0x0084 /* <SIP-MC> Device busy. */
- #define ISXEC_MC_SIPUA_RET_START_FAIL 0x0085 /* <SIP-MC> Start SIP stack fail. */
- #define ISXEC_MC_SIPUA_RET_FAIL_NO_LIC 0x0086 /* <SIP-MC> No usable license. */
- #define ISXEC_SIP_BODY_SDP_OVERFLOW 0x0087 /* SIP's number of SDP overflow */
- /*
- * Error Codes Specific to EC TAP
- */
- #define ISXEC_BADMODE 0x0090
- #define ISXEC_UNSUPPORTED 0x0091
- /*
- * M3G Error Codes
- */
- #define ISXEC_CHAN_TYPE_ERROR 0x00a0 /* Channel type error. */
- #define ISXEC_CONNECT 0x00fe /* Connect fail */
- #define ISXEC_UNKNOWN 0x00FF /* Unknown reason */
- /*conference Error codes*/
- #define ISXEC_CONF_BAD_INNERCONFID 0x0100 /* Bad inner conference id*/
- #define ISXEC_CONF_CONFTYPE_ERROR 0x0101 /* Conference type error */
- #define ISXEC_CONF_MEM_NOTEXIST 0x0102 /* Conference member not exist. */
- #define ISXEC_CONF_EMS_CDT_INDEX_EXIST 0x0103 /* Extend Conference EMS_CDT.index is exist*/
- #endif
- //////////////////////////////////////////////////////////////////////////
- //////////////////////////////////////////////////////////////////////////
- //SDK communication error code
- //{{MAPI <--> MC
- #define MER_BAD_MSGLEN 0xFFFA //error message length
- #define MER_BAD_PARAM 0xFFF9 //Invalid Parameter in Function Call
- #define MER_OCCUPIED 0xFFF7 //Channel is already occupied
- #define MER_NO_CH 0xFFF6 //Channel is not exist
- #define MER_NO_ABILITY 0xFFF5 //The device has no the capability
- #define MER_NO_MEMVOC 0xFFF4 //The memory voice is not exist
- #define MER_OPEN_FILE 0xFFF3 //Can not open the file
- #define MER_BAD_FILEFMT 0xFFF2 //Unknown file format
- #define MER_BAD_DATA 0xFFF1 //The DSP not support the data format
- #define MER_PRD_OFS 0xFFF0 //The PRD is out of Service
- #define MER_CH_OFS 0xFFEF //The channel is out of service
- #define MER_PRD_STRM_LK 0xFFEE //Connection between /Play&Record Device and StreamServer fails
- #define MER_NO_REC 0xFFED //The channel is not recording
- #define MER_NO_PLAY 0xFFEC //The channel is not playing
- #define MER_CREATE_FILE 0xFFEB //Can not create the file.
- #define MER_NO_PRD 0xFFEA //The PRD is not exist
- #define MER_NO_MEMIDX 0xFFE9 //No empty memory voice number
- #define MER_NO_MEM 0xFFE8 //The memory is not enough
- #define MER_NO_CACHEIDX 0xFFE7 //Cache sound number is not available
- #define MER_NO_CACHE 0xFFE6 //Cache sound number does not exist
- #define MER_NO_DSPDEV 0xFFE5 //The DSP is not exist
- #define MER_DSP_OFS 0xFFE4 //The DSP is out of service
- #define MER_NO_CONF 0xFFE3 //Specified conference number does not exist
- #define MER_BAD_LSTNRID 0xFFE2 //Parameter LstnrIdx is invalid (DEBUG Only)
- #define MER_BAD_LSTNRMK 0xFFE1 //Parameter LstnrMsk is invalid (DEBUG Only)
- #define MER_BUSY_PLAY 0xFFE0 //Channel is playing
- #define MER_BUSY_REC 0xFFDF //Channel is recording
- #define MER_BUSY_CONF 0xFFDE //Channel is in conference
- #define MER_BAD_BRDNO 0xFDD1 //The system has no conf-id
- #define MER_UNKNOWN 0x8000 //Unknown error
- //}}
- //{{PRD <--> DSP
- #define PER_BADPARAM 0xFFA0 // Invalid Parameter in Function Call
- #define PER_OPENFILE 0xFFA1 // Can not open the file
- #define PER_BAD_FILEFMT 0xFFA2 // Unknown file format
- #define PER_CREATE_FILE 0xFFA3 // Can not create the file
- #define PER_BAD_HANDLE 0xFFA4 // Invalid file handle
- //}}
- //{{DSP <--> MC
- #define DER_BADPARAM 0xFF70 // Invalid parameter
- #define DER_NO_CONF 0xFF71 // The conference is not exist
- #define DER_NO_CH 0xFF72 // Channel is not exist
- #define DER_CACHEV_BUSY 0xFF73 // Delete fail because of the cache voice is in use
- #define DER_NOT_FLEX 0xFF77 // The conference is not flexiable
- #define DER_OPEN_FILE 0xFF78 // Can not open the file
- #define DER_BAD_DATA 0xFF79 // The DSP not support the data format
- #define DER_PRD_OFS 0xFF7A // The PRD is out of service
- #define DER_NO_PRD 0xFF7B // The PRD is not exist
- #define DER_NO_MEM 0xFF7C // The memory is not enough
- #define DER_NO_CACHE 0xFF7D //The cache is not exist
- #define DER_BAD_FILEFMT 0xFF7E // Unknown file format
- #define DER_BUSY_PLAY 0xFF7F // Channel is playing
- #define DER_BUSY_REC 0xFF80 // Channel is recording
- #define DER_CREATE_FILE 0xFF81 // Can not create the file
- #define DER_INVALID_STATE 0xFF82 //Invalid state
- //}}
- //{{MB <--> MC
- #define OER_BADPARAM 0xFED0 //Invalid parameter
- #define OER_DEVBUSY 0xFEDC // Device is busy
- //}}
- //{{prd <--> dsp
- #define PRD_DSP_ERR_FILE_NOT_ENOUGH_DATA 0xFFA5 // Not enough data in the file
- #define PRD_DSP_ERR_NOT_RATE_RES 0xFFA6 // Not enough resample resource
- #define PRD_DSP_ERR_INIT_RATE_RES_FAIL 0xFFA7 // Resample init fail
- #define PRD_DSP_ERR_FIFO_BUFFER_HAS_FULL 0xFFA8 // FIFO BUFFER is full
- #define PRD_DSP_ERR_UNKNOWN_FMT 0xFFA9 // Unknown Format
- #define PRD_DSP_ERR_PROMPT_STATUS_ERROR 0xFFAA // Wrong state for cache voice
- #define PRD_DSP_ERR_CREATE_POOL_FAIL 0xFFAB // Create APR pool fail
- #define PRD_DSP_ERR_GET_FILE_INFO_FAIL 0xFFAC // Get file info fail
- #define PRD_DSP_ERR_SEEK_FILE_FAIL 0xFFAD // File seek operation fail
- #define PRD_DSP_ERR_CHAN_NOT_OCCPED 0xFFAE // The channel is not occupied
- #define PRD_DSP_ERR_INVALID_WAVE_FILE 0xFFAF //Invalid WAVE file format
- #define PRD_DSP_ERR_WRITE_WAVE_FILE_FAIL 0xFFB0 // Write WAVE file fail
- #define PRD_DSP_ERR_SEND_MESSAGE_FAIL 0xFFB1 //Send network message fail
- #define PRD_DSP_ERR_FILE_NOT_EXIST_OR_CLOSED 0xFFB2 //File not exist or closed
- #define PRD_DSP_ERR_WRITE_FILE_FAIL 0xFFB3 //Write file fail
- #define PRD_DSP_ERR_NETWORK_DISCONED 0xFFB4 // The network disconnected
- #define PRD_DSP_ERR_READ_FILE_FAIL 0xFFB5 // Read file fail
- #define PRD_DSP_ERR_FILEORDIR_NOT_EXIST 0xFFB6 //File or dir not exist
- //}}
- //{{prd <--> MAPI
- #define PRD_MAPI_ERR_INVALID_PARAM 0xFE70 //Invalid parameter
- #define PRD_MAPI_ERR_CHAN_NOT_EXIST 0xFE71 //The channel not exist
- #define PRD_MAPI_ERR_CHAN_STATUS_ERROR 0xFE72 // Bad channel state
- #define PRD_MAPI_ERR_FD_NOT_OCCPED_BY_THIS_MOD 0xFE73 // The file handle is not belong to the APP
- #define PRD_MAPI_ERR_OPEN_FILE_LIMIT 0xFE9F // Too more files opened
- #define PRD_MAPI_ERR_FILE_OP_ERR 0xFE9E // File operation fail
- //{{MC errcode
- #define MAPI_ERR_BYTE_ORDER_CONVERT_FAIL 0xFFDC // Endian convert fail
- #define MAPI_ERR_SEND_MESSAGE_FAIL 0xFFDB // Send network message fail
- #define MAPI_ERR_PROMPT_NOT_OCCPED_BY_THIS_MOD 0xFFDA // The cache prompt is not belong to the APP
- #define MAPI_ERR_PROMPT_STATUS_ERROR 0xFFD9 // Wrong cache prompt state
- #define MAPI_ERR_CHAN_NOT_OCCPED_BY_THIS_MOD 0xFFD8 // The channel is not belong to the APP
- #define MAPI_ERR_CONF_STATUS_ERROR 0xFFD7 // Wrong conference state
- #define MAPI_ERR_DSP_CHAN_NOT_IN_CONF_STATUS 0xFFD6 // The channel is not in conference state
- //}}
-
- //{{DSP errcode
- #define ISXOCTDSP_CONF_RET_LSTNERID_INVAL 0xFF74 // Invalid listener index
- #define ISXOCTDSP_CONF_RET_NOT_FLEXABLE 0xFF75 // The conference is not flexiable
- #define ISXOCTDSP_PROMPT_RET_INDEX_INVAL 0xFF76 // Invalid cache voice index
- #define ISXOCTDSP_OCT_ERROR 0xFF83 // Octasic access error
- #define ISXOCTDSP_CN8478_ERROR 0xFF84 // CN8478 Error
- #define ISXOCTDSP_PRD_NET_ERROR 0xFF85 // The communication to PRD error
- #define ISXOCTDSP_QUEUE_BUSY 0xFF86 // The inner queue busy
- #define ISXOCTDSP_PRD_NET_BUSY 0xFF87 // The communication to PRD busy
- //}}
- //{{FaxServer errcode
- #define FER_BADPARAM 0xFC00 //Invalid parameter
- #define FER_BUSY 0xFC01 //channel is busy
- #define FER_INVALID_CH 0xFC02 //Invalid channel
- #define FER_OPENFILE 0xFC03 //Open file fail
- #define FER_INITSTAT 0xFC04 //Init status error
- #define FER_SENDFAX 0xFC05 //start sent fax fail
- #define FER_DLGIMPOP 0xFC06 //D card IPM channel error
- #define FER_AUTH 0xFC07 //auth fail
- #define FER_RECVFAX 0xFC08 //start recv fax fail
- //}}
- //{{IPM errcode
- #define IPMEDIA_RET_BAD_PARAM 0xFB00 /* Invalid parameter */
- #define IPMEDIA_RET_SET_TOS_FAIL 0xFB01 /* set TOS fail */
- #define IPMEDIA_RET_SET_FAX_FAIL 0xFB02 /* set FAX fail */
- #define IPMEDIA_RET_SET_VOC_FAIL 0xFB03 /* set VOC fail */
- #define IPMEDIA_RET_NO_LICENSE 0xFB04 /* no license */
- #define IPMEDIA_RET_FAIL_STATE 0xFB05 /* status error */
- #define IPMEDIA_RET_FAIL_SESSION_GET 0xFB06 /* get session information error */
- #define IPMEDIA_RET_FAIL_DEV 0xFB07 /* device error */
- #define IPMEDIA_RET_FAIL_DEV_NOT_INIT 0xFB08 /* device not init */
- #define IPMEDIA_RET_FAIL_NO_GW 0xFB09 /* no gateway */
- #define IPMEDIA_RET_FAIL_TRANSAC 0xFB0A /* transaction error */
- //}}
- //{{SIP errcode
- #define SIPUA_RET_BAD_PARAM 0xFF10 /* Invalid parameter */
- #define SIPUA_RET_BAD_STATE 0xFF11 /* status error */
- #define SIPUA_RET_NO_RESOURCE 0xFF13 /* no resource */
- #define SIPUA_RET_DEV_BUSY 0xFF14 /* device is busy */
- #define SIPUA_RET_START_FAIL 0xFF16 /* start sip stack fail */
- #define SIPUA_RET_FAIL_NO_LIC 0x8201 /* no license */
- //}}
- //////////////////////////////////////////////////////////////////////////
- /*
- * Type definition for SCBus Timeslots information structure.
- */
- #ifndef __SC_TSINFO__
- #define __SC_TSINFO__
- #ifdef __64BIT
- typedef struct sc_tsinfo {
- UINT sc_numts;
- INT *sc_tsarrayp;
- } SC_TSINFO;
- #else
- typedef struct sc_tsinfo {
- ULONG sc_numts;
- LONG *sc_tsarrayp;
- } SC_TSINFO;
- #endif
- #endif
- /*
- * Termination Parameter Types
- */
- #define IO_CONT 0x0001 /* Next TPT is contiguous in memory */
- #define IO_LINK 0x0002 /* Next TPT found thru tp_nextp ptr */
- #define IO_EOT 0x0004 /* End of the Termination Parameters */
- /*
- * DV_TPT - Termination Parameter Table Structure.
- */
- typedef struct dv_tpt DV_TPT;
- struct dv_tpt {
- USHORT tp_type; /* Flags Describing this Entry */
- USHORT tp_termno; /* Termination Parameter Number */
- USHORT tp_length; /* Length of Terminator */
- USHORT tp_flags; /* Termination Parameter Attributes Flag */
- USHORT tp_data; /* Optional Additional Data */
- USHORT rfu; /* Reserved */
- DV_TPT *tp_nextp; /* Ptr to next DV_TPT if IO_LINK set */
- };
- /* Define NULL if it hasn't been defined already */
- #ifndef NULL
- #define NULL 0L
- #endif
- #ifndef TLV_TYPE_UNKNOWN
- #define TLV_TYPE_MAXVALUE 0x9999
- #define TLV_TYPE_UNKNOWN 0xffff
- #endif
- /**
- ** Defines used for standard attributes
- **/
- /*
- * Undefined attribute or Failed to get attribute
- */
- #ifndef AT_FAILURE
- #define AT_FAILURE -1
- #define AT_FAILUREP NULL
- /*
- * EVENT MANAGEMENT
- */
- #define SR_POLLMODE 0 /* Run SRL in polling mode */
- #define SR_SIGMODE 1 /* Run SRL in signalling/interrupt mode */
- #define SRL_DEVICE 0 /* The SRL device */
- #define SR_TMOUTEVT 0 /* Timeout event - occurs on the SRL DEVICE */
- #define SR_SYSHDL 1 /* The system device */
- #define SR_CUREVENT -1 /* Current event */
- #define SR_TMOUT -1 /* Returned by event scanning functions
- (e.g. sr_waitevt()) when they time out */
- #endif
- #ifndef MAX_DBGID_NUM
- #pragma pack(1)
- #define MAX_DBGID_NUM 20
- #define MAX_DBGID_LEN 32
- typedef struct{
- UCHAR ucMode; //Filter mode, refer to eFILTER_MODE
- CHAR szDbgIdStr[MAX_DBGID_LEN];
- }DBGID_FILTER;
- //ucMode may be as follows:
- typedef enum{
- FILTER_MODE_FULL_MATCHING = 0x00, /*DbgIdStr full matching*/
- FILTER_MODE_INCLUDE_MATCHING = 0x7f, /*DbgIdStr include matching*/
- FILTER_MODE_IGNORE_UPPERCASE = 0x80 /*DbgIdStr ignore uppercase*/
- } eFILTER_MODE;
- /*
- -Log filtering conditions. Log conditions are defined by the LOG_FILTER structure.
- */
- typedef struct{
- UCHAR ucLog2File; /*Whether to save to files.*/
- UCHAR ucOutputErrLogOnly; /*Outputs error logs only. If the field is TRUE,
- ucOutputErrLog, ucOutputSYSLog, ucOutputGCLog, ucOutputDSPLog,
- ucOutputXOIPLog, ucOutputDTILog, ucOutputCSLog and Other...
- are not analyzed.*/
- UCHAR ucOutputErrLog; /*Whether to output error logs. If the field is TRUE,
- error logs are output, otherwise only normal logs are output.*/
- UCHAR ucOutputSYSLog; /*Whether to output system logs. If the field is TRUE, system logs
- are output, otherwise no system logs are output.*/
- UCHAR ucOutputGCLog; /*Whether to output GC logs. If the field is TRUE, GC logs are output,
- otherwise no GC logs are output. GC logs are mainly signaling logs
- including PRI/SS7/SIP signaling function-related logs.*/
- UCHAR ucOutputDSPLog; /*Whether to output DSP logs. If the field is TRUE, DSP logs are
- output, otherwise no DSP logs are output. DSP logs are mainly logs
- related to functions such as playback, recording, conferencing and
- DTMF functions.*/
- UCHAR ucOutputXOIPLog; /*Whether to output XOIP logs. If the field is TRUE, XOIP logs
- are output, otherwise no XOIP logs are output. XOIP logs are mainly
- logs related to VOIP/FOIP media functions.*/
- UCHAR ucOutputDTILog; /*Whether to output DTI logs. If the field is TRUE, DTI logs are
- output, otherwise no DTI logs are output. DTI logs are mainly logs
- related to DTI (Digital Trunk Interface) functions.*/
- UCHAR ucOutputCSLog; /*Whether to output CS logs. If the field is TRUE, CS logs are
- output, otherwise no CS logs are output. CS logs are mainly logs
- related to CS Interface functions.*/
- UCHAR ucOutputPRDLog; /*Whether to output PRD logs. If the field is TRUE, PRD logs are
- output, otherwise no PRD logs are output. PRD logs are mainly logs
- related to PRD Interface functions.*/
- UCHAR ucOutputFXSLog; /*Whether to output FXS logs. If the field is TRUE, FXS logs are
- output, otherwise no FXS logs are output. FXS logs are mainly logs
- related to FXS Interface functions.*/
- UCHAR ucOutputAGLog; /*Whether to output AG logs. If the field is TRUE, AG logs are
- output, otherwise no AG logs are output. AG logs are mainly logs
- related to AG Interface functions.*/
- UCHAR ucOutputM3GLog; /*Whether to output M3G logs. If the field is TRUE, M3G logs are
- output, otherwise no M3G logs are output. M3G logs are mainly logs
- related to M3G Interface functions.*/
- UCHAR ucOutputTimerLog; /*Whether to output timer logs. If the field is TRUE, timer logs are
- output, otherwise no timer logs are output. timer logs are mainly logs
- related to timer debug informations.*/
- UCHAR ucHideDtmfFlag; /*Whether to set hide/show dtmf flag. If the field is TRUE, dtmf are hide,
- otherwise dtmf logs are show. dtmf logs are mainly logs
- related to dtmf debug informations.*/
- UCHAR ucOutputMsgLog; /*Whether to set message flag. If the field is TRUE, message are hide,
- otherwise message logs are show. message logs are mainly logs
- related to message debug informations.*/
- UCHAR ucExternDebugLog; /*Inner use*/
- UCHAR ucReserve[100-7]; /*Reserve*/
- UCHAR ucDbgIdFilterValid; /*Whether to enable the DbgId condition filtering. If the field is TRUE,
- channel DbgId conforms to the condition settings in DbgIdFilter besides
- the above-mentioned conditions. Channel DbgId is set by
- ISX_sr_SetDbgIdStr().*/
- USHORT usDbgIdNum; /*Number of DbgId filtering conditions.*/
- DBGID_FILTER DbgIdFilter[MAX_DBGID_NUM]; /*DbgId filtering condition array. Only the logs that satisfy
- one of the DbgId filtering condition array. The maximum number
- of conditions in the DbgId filtering condition array is
- MAX_DBGID_NUM. Each filtering condition has two fields.
- One field is ucMode that specifies a DbgId string comparison mode.
- 0 indicates perfect matching and 1 indicates containing matching.
- If the top digit of ucMode is 1, it indicates ignoring case.*/
- }LOG_FILTER;
- //{{[2014-11-27]
- #define MAX_MONITOR_MSGID_NUM 32
- typedef struct {
- USHORT nMonitorMsgIDs[MAX_MONITOR_MSGID_NUM];
- } ISX_MONITOR_MSG_TAB;
- //}}
- #pragma pack()
- #endif
- //////////////////////////////////////////////////////////////////////////
- //{{add by 2009-5-20
- #pragma pack(1)
- #ifndef _MIX_TYPE_
- #define _MIX_TYPE_
- typedef enum{
- MIXTYPE_NULL, //not mix
- MIXTYPE_RECORD, //record mix
- MIXTYPE_PLAY, //play mix
- MIXTYPE_RPBOTH, //both record and play mix
- MIXTYPE_HIIMPREC, //high impedance mix
- }MIX_TYPE;
- #define MAX_SPEC_CAP_NUM 32
- typedef struct{
- UCHAR ucMixType; //Mix type, refer to MIX_TYPE
- UCHAR ucUnmixTimeSlot[MAX_SPAN_NUM];/*not mixing timeslot number, E1(0~31), T1/J1(1~24).
- 0xFF indicates all timeslot mixing, buf Xoip board invalid*/
- }MIX_PARAM;
- typedef enum{
- MIXCAP_NON =0, //No specific capability
- MIXCAP_NORMAL =1, //Normal mix capability
- MIXCAP_HIIMP =2, //High impedance mix capability(Only trunk board)
- }MIX_CAP;
- typedef struct{
- UCHAR ucMixCap; //Mix capability, refer to MIX_CAP
- UCHAR ucRvrCap[MAX_SPEC_CAP_NUM-1]; //Reserve
- }UNK_CAP_SET;
- typedef struct{
- UCHAR ucMixCap; //Mix capability, refer to MIX_CAP
- UCHAR ucRvrCap[MAX_SPEC_CAP_NUM-1]; //Reserve
- }M3G_CAP_SET;
- typedef struct{
- UCHAR ucMixCap; //Mix capability, refer to MIX_CAP
- UCHAR ucRvrCap[MAX_SPEC_CAP_NUM-1]; //Reserve
- }SPAN_CAP_SET;
- typedef struct{
- UCHAR ucMixCap; //Mix capability, refer to MIX_CAP
- UCHAR ucRvrCap[MAX_SPEC_CAP_NUM-1]; //Reserve
- }XOIP_CAP_SET;
- typedef struct{
- union{
- SPAN_CAP_SET Span;
- XOIP_CAP_SET Xoip;
- M3G_CAP_SET M3g;
- UNK_CAP_SET Unk;
- };
- }SPEC_CAP;
- #endif
- #pragma pack()
- /*
- * System param ID for ISX_sr_SetSysParam
- */
- #define SYS_PARMID_SYNCFUNC_TIMEOUT 0x00
- #define SYS_PARMID_DAYNUM_FOR_AUTO_DELETE_LOG 0x01
- #define SYS_PARMID_VOX_BUSYDETECT_NUM 0x02
- #define SYS_PARMID_PRINT_KEEPALIVE_LOG 0x03
- #define SYS_PARMID_ENABLE_RAR_LOG 0x04
- #define SYS_PARMID_IMMEDIA_PRINT_LOG 0x05
- #define SYS_PARMID_ENABLE_STOP_RECPLAY_STATMANAGER 0x06
- #define SYS_PARMID_SIPREGISTERACK_AUTHENT_REALM 0x07 //set inner call ISX_gc_SIPSendRegisterAck Ack.Authent.Realm
- /*
- * ISX_sr_default (iParmId)
- */
- #ifndef PARMID_SS7_IAM
- #define PARMID_SS7_IAM 1
- #define PARMID_SS7_ACM 3
- #define PARMID_SS7_ANM 4
- #define PARMID_SS7_REL 5
- #define PARMID_SS7_CPG 6
- #define PARMID_SS7_INF 7
- #define PARMID_SS7_INR 8
- #define PARMID_SS7_USR2UER_INFO 9
- #define PARMID_SS7_CON 10
- #define PARMID_SS7_IDR 11
- #define PARMID_SS7_IDS 12
- #define PARMID_SIP_INVITE 13
- #define PARMID_SIP_RING 14
- #define PARMID_SIP_CONNECT 15
- #define PARMID_PRI_SETUP 16
- #define PARMID_PRI_ALERTING 17
- #define PARMID_PRI_CONNECT 18
- #define PARMID_PRI_DROP 19
- #define PARMID_PRI_SETUPACK 20
- #define PARMID_PRI_PROGRESS 21
- #define PARMID_PRI_PROCEEDING 22
- #define PARMID_SIP_INVITE_EX_REQ 23
- #define PARMID_SIP_OPTIONS 24
- #define PARMID_SIP_INVITE_URI 25
- #define PARMID_SIP_INVITE_LONG_URL 26
- #define PARMID_SIP_INVITE_LONG_USER 27
- #define PARMID_SIP_INVITE_LONGLONG_USER 28
- #define PARMID_ISXSIP_ADDR_URL 29
- #define PARMID_ISXSIP_ADDR_URL_EX 30
- #define PARMID_ISXSIP_ADDR_LONG_URL 31
- #define PARMID_ISXSIP_ADDR_LONG_USR 32
- #define PARMID_SIP_SUBSCRIBE 33
- #define PARMID_SIP_MESSAGE 34
- #define PARMID_DSPCH_VQECFG 200
- #endif
- /*
- * ISX_sr_insertparm (parmID)
- */
- #ifndef SIPPARMID_DESTADD
- #define SIPPARMID_DESTADD 200 //normal destination address
- #define SIPPARMID_SRCADD 201 //normal source address
- #define SIPPARMID_DESTDISPLAY 202 //destination display name
- #define SIPPARMID_SRCDISPLAY 203 //source display name
- #define SIPPARMID_DESTADD_LONG_URL 204 //LONG_URL destination address
- #define SIPPARMID_SRCADD_LONG_URL 205 //LONG_URL source address
- #define SIPPARMID_DESTADD_LONG_USR 206 //LONG_USER destination address
- #define SIPPARMID_SRCADD_LONG_USR 207 //LONG_USER source address
- #define SIPPARMID_DESTADD_URI 208 //URI destination address
- #define SIPPARMID_SRCADD_URI 209 //URI source address
- #define SIPPARMID_DESTADD_LONGLONG_USR 210 //LONGLONG_USER destination address
- #define SIPPARMID_SRCADD_LONGLONG_USR 211 //LONGLONG_USER source address
- //set ie_body
- #define SIPPARMID_CHCAP 301 //channel capability
- #define SIPPARMID_MEDIADESC 302 //media description
- #define SIPPARMID_ORIGIN 303 //origin
-
- #endif
- /*
- * ISX_sr_convert (convertID)
- */
- #ifndef CONID_CODECID2PLAYLOAD
- #define CONID_CODECID2PLAYLOAD 401 //(SIP) convert codec-id to payload-id
- #endif
- //////////////////////////////////////////////////////////////////////////
- #if defined(__cplusplus)
- extern "C" {
- #endif
- /* SRL standard attribute functions */
- /************************************************************************/
- /* Function: ISX_ATDV_ERRMSGP()
- Description:
- The ISX_ATDV_ERRMSGP() function returns an ASCIIZ string that describes the error that occurs
- during the last function call. The pointer remains valid throughout the execution of the application.
- If no error occurs, the function returns a "No Error" string.
- Return value:
- Pointer to string
- Parameter:
- -dev
- Valid device handle returned by the xx_open() function
- */
- /************************************************************************/
- ISXAPI_FUNC_STDCL(CHAR*) ISX_ATDV_ERRMSGP(INT dev);
- /************************************************************************/
- /* Function: ISX_ATDV_LASTERR()
- Description:
- The ISX_ATDV_LASTERR() function returns codes (INT integers) that indicates errors that occur
- during the last function call. The error codes are located in all relevant header files such as
- voclib.h and dtilib.h.
- Return value:
- AT_FAILURE: failure. The specified handle is invalid
- Others: error code
- Parameter:
- -dev
- Valid device handle returned by the ISX_xx_open() function
- */
- /************************************************************************/
- ISXAPI_FUNC_STDCL(INT) ISX_ATDV_LASTERR(INT dev);
- /************************************************************************/
- /* Function: ISX_sr_getlasterr()
- Description:
- The ISX_sr_getlasterr() function obtains the error code during the last call function.
- The function is similar to the GetLastError() function in Windows API. Their difference
- is that ISX_ATDV_LASTERR() applies to devices and ISX_sr_getlasterr() applies to threads.
- ISX_sr_getlasterr() is generally used to obtain failure causes of the ISX_xx_open() function.
- Return value:
- -1: failure
- Others: error code during the last function call
- */
- /************************************************************************/
- ISXAPI_FUNC_STDCL(INT) ISX_sr_getlasterr();
- /************************************************************************/
- /* Function: ISX_sr_GetErrMsg()
- Description:
- The ISX_sr_getlasterr() function returns codes that indicates errors that occur
- during the last function call.
- Return value:
- Pointer to string
- Parameter:
- -sRetVal
- error code returned by the ISX_sr_getlasterr() function
- */
- /************************************************************************/
- ISXAPI_FUNC_STDCL(CHAR*) ISX_sr_GetErrMsg(INT sRetVal);
- /* Wait for next event */
- /************************************************************************/
- /* Function: ISX_sr_waitevt()
- Description:
- The ISX_sr_waitevt() function waits for an event within the specified time. If an event occurs,
- 0 is returned immediately. If no event occurs within the specified time, -1 (SR_TMOUT) is returned.
- Return value:
- 0 success.An event occurs
- -1 failure. No event occurs
- Parameter:
- -timeout
- Timeout time in ms. If the parameter value is -1, it indicates infinite waiting.
- */
- /************************************************************************/
- ISXAPI_FUNC_STDCL(INT) ISX_sr_waitevt(LONG tmout);
- /************************************************************************/
- /* Function: ISX_sr_waitevtEx()
- Description:
- The ISX_sr_waitevtEx() function waits for device events. The function can be regard as an extension
- of the ISX_sr_waitevt() function. If events are detected on the specified devices, the function
- returns 0 immediately. If no event occurs on the specified devices within the specified time,
- the function times out and returns -1 (SR_TMOUT).
- Parameter:
- -handlep
- Device handle array
- -count
- Number of handles in the handle array
- -tmout
- Timeout time in ms. If the value is -1, it indicates infinite waiting until an event occurs.
- -rfup
- Reserved for future use
- */
- /************************************************************************/
- ISXAPI_FUNC_STDCL(INT) ISX_sr_waitevtEx(INT *handlep, INT count, LONG tmout, LONG* rfup);
- /************************************************************************/
- /* Function: ISX_sr_getevtdev()
- Description:
- The ISX_sr_getevtdev() function returns the device handle of the current event. If no current
- event exists, -1 is returned. If timeout occurs when waiting for an event, the function returns
- SRL_DEVICE. If SR_SYSHDL is returned, it indicates that the event is a system event.
- Return value:
- -1: failure
- Others: event device handle
- */
- /************************************************************************/
- ISXAPI_FUNC_STDCL(INT) ISX_sr_getevtdev();
- /************************************************************************/
- /* Function: ISX_sr_getevttype()
- Description:
- The ISX_sr_getevttype() function returns the type of the current event. If no current event exists,
- -1 is returned. If timeout occurs while waiting for an event, the function returns SR_TMOUTEVT.
- Return value:
- -1 failure
- Others: event type
- */
- /************************************************************************/
- ISXAPI_FUNC_STDCL(INT) ISX_sr_getevttype();
- /************************************************************************/
- /* Function: ISX_sr_getevtlen()
- Description:
- The ISX_sr_getevtlen() function returns the length of the additonal data of the current event.
- If no current event exists, 0 is returned.
- Return value:
- -1 failure
- Others: event length
- */
- /************************************************************************/
- ISXAPI_FUNC_STDCL(INT) ISX_sr_getevtlen();
- /************************************************************************/
- /* Function: ISX_sr_getevtdatap()
- Description:
- The ISX_sr_getevtdatap() function returns the address of the additional data of the current event.
- Please use ISX_sr_getevtlen() to determine the valid length of the variable-length data. If there
- is no variable-length data for the current event, NULL is returned. The returned pointer is valid
- before ISX_sr_waitevt() or ISX_sr_waitevtEx() is called again.
- Return value:
- NULL: no variable-length data for the event
- Others: address of variable-length data of the event
- */
- /************************************************************************/
- ISXAPI_FUNC_STDCL(VOID*) ISX_sr_getevtdatap();
- /************************************************************************/
- /* Function: ISX_sr_getevtopertype()
- Description:
- The ISX_sr_getopertype() function returns the event-related operation type.
- Return value:
- Returns the event-related operation type, refer to OPERATIONS
- */
- /************************************************************************/
- ISXAPI_FUNC_STDCL(INT) ISX_sr_getevtopertype();
- /************************************************************************/
- /* Function: ISX_sr_getevtoperindex()
- Description:
- The ISX_sr_getevtoperindex() function returns the event-related operation number. You can specify
- an operation index for some operations such as recording, playback and obtaining the number of
- played or recorded bytes. When an event is generated, the number can be obtained through
- ISX_sr_getevtoperindex() so that a programmer can know which operation results in the event.
- Return value:
- Returns the number of the operation corresponding to the event
- */
- /************************************************************************/
- ISXAPI_FUNC_STDCL(UINT) ISX_sr_getevtoperindex();
- /************************************************************************/
- /* Function: ISX_sr_getevtname()
- Description:
- The ISX_sr_getevtname() function obtains the event name of a certain event or the
- current event (iEvtType is SR_CUREVENT).
- Return value:
- Pointer to string
- Parameter:
- -iEvtType
- Event type
- */
- /************************************************************************/
- #ifndef EHANG_ISXAPI_STD_C
- ISXAPI_FUNC_STDCL(CHAR*) ISX_sr_getevtname(INT iEvtType = SR_CUREVENT);
- #else
- ISXAPI_FUNC_STDCL(CHAR*) ISX_sr_getevtname(INT iEvtType);
- #endif
- /************************************************************************/
- /* Function: ISX_sr_getopername()
- Description:
- The ISX_sr_getopername() function obtains the operation name of a certain operation
- or the current event (iOperType is SR_CUREVENT).
- Return value:
- Pointer to string
- Parameter:
- -iOperType
- Operation type
- */
- /************************************************************************/
- #ifndef EHANG_ISXAPI_STD_C
- ISXAPI_FUNC_STDCL(CHAR*) ISX_sr_getopername(INT iOperType = SR_CUREVENT);
- #else
- ISXAPI_FUNC_STDCL(CHAR*) ISX_sr_getopername(INT iOperType);
- #endif
- /************************************************************************/
- /* Function: ISX_sr_SetSysParam()
- Description:
- The ISX_sr_SetSysParam() function Sets system parameter.
- Return value:
- 0 success
- -1 failure
- Parameter:
- -parmID
- parameter ID, may be as follows:
- SYS_PARMID_SYNCFUNC_TIMEOUT ( value is SHORT type )
- SYS_PARMID_DAYNUM_FOR_AUTO_DELETE_LOG ( value is INT type )
- -valuep
- Pointer to parameter value.
- */
- /************************************************************************/
- ISXAPI_FUNC_STDCL(INT) ISX_sr_SetSysParam(USHORT parmID, const VOID * valuep);
- /************************************************************************/
- /* Function: ISX_Api_SetIsxPrdNum()
- Description:
- The ISX_Api_SetIsxPrdNum() function sets the maximum number of ISX/PRD nodes supported
- by ISX-SDK. The ISX-SDK only supports two ISX nodes and two PRD nodes by default.
- The function shall be called prior to ISX_Api_Init(), otherwise it will not take effect.
- Return value:
- 0 success
- -1 failure
- Parameter:
- -iMaxIsxNum
- Number of ISX nodes supported by SDK. The maximum number is MAX_NODE_NUM. If the parameter
- value is -1, no modification is made and the default is used.
- -iMaxPrdNum
- Number of PRD nodes supported by SDK. The maximum number is MAX_PRD_NUM. If the parameter
- value is -1, no modification is made and the default is used.
- */
- /************************************************************************/
- ISXAPI_FUNC_STDCL(INT) ISX_Api_SetIsxPrdNum(INT iMaxIsxNum, INT iMaxPrdNum);
- ISXAPI_FUNC_STDCL(INT) ISX_Api_SetPrdAddrMapping(CHAR cPrdNo, CHAR* szIp);
- /************************************************************************/
- /* Function: ISX_Api_Init()
- Description:
- The ISX_Api_Init() function initializes ISX API function library that contains functions
- such as Voice, DTI, SRL and GC functions. Before these functions are used, the application
- must call ISX_Api_Init( ) to initialize the function library first. The function is generally
- called during the initialization of the whole application. ISX_Api_Uninit( ) is called at
- the end of the whole application. ISX_Api_Init( ) and ISX_Api_Uninit( ) cannot be repeatedly
- called in an application.
- Return value:
- 0 success
- -1 failure
- Parameter:
- -szMCIp
- Master controller IP address
- -usMCPort
- Master controller port
- -ucKeepAlive
- Checks the cycle of keep-alive messages (i.e. heartbeat cycle). ISX API communicates with
- MC through TCP/IP. ISX API regularly sends keep-alive messages to MC to check whether the
- peer or network is normal. After receiving a keep-alive message, MC sends a response message
- to ISX API. If MC does not receive any keep-alive message sent by ISX API, MC automatically
- disconnects from ISX API. The mechanism is inconvenient for the program single-step follow-up
- and commissioning. Therefore, we design the parameter so that the user can set an inspection cycle.
- The default cycle is 20s. Values specified by the parameter are the multiple of the default cycle.
- For example, if usKeepAlive is equal to 3, the inspection cycle is 60s.
- -pszVersion
- SDK Version, must be ISX_API_VER
- */
- /************************************************************************/
- #ifndef EHANG_ISXAPI_STD_C
- ISXAPI_FUNC_STDCL(INT) ISX_Api_Init(CHAR* szMCIp, USHORT usMCPort, UCHAR ucKeepAlive = 1, CHAR* pszVersion=(CHAR*)ISX_API_VER);
- #else
- ISXAPI_FUNC_STDCL(INT) ISX_Api_Init(CHAR* szMCIp, USHORT usMCPort, UCHAR ucKeepAlive, CHAR* pszVersion/*ISX_API_VER*/);
- #endif
- /************************************************************************/
- /* Function: ISX_Api_Uninit()
- Description:
- The ISX_Api_Uninit() function stops the function library from working, disconnects from MC
- and releases resources occupied by the function library.
- Return value:
- 0 success
- -1 failure
- */
- /************************************************************************/
- ISXAPI_FUNC_STDCL(INT) ISX_Api_Uninit();
- /************************************************************************/
- /* Function: ISX_sr_putevt()
- Description:
- The ISX_sr_putevt() function allows the application to add an event in the ISX API event queue.
- If there is variable-length data, please use evtdatap to specify the source data address and
- specify the length of the variable-length data through the evtlen parameter. The ISX_sr_putevt()
- function will copy the variable-length data to the queue. Therefore, the user may discard evtdatap
- when the function returns.
- Note: The event generated by the ISX_sr_putevt() function can be obtained through the ISX_sr_waitevt()
- or ISX_sr_waitevtEx() function.
- Return value:
- 0 success
- -1 failure
- Parameter:
- -dev
- Device handle
- -evt
- Event type. It may be a user-defined type. The value can be obtained through ISX_sr_getevttype().
- -len
- Variable-length event length. The value can be obtained through ISX_sr_getevtlen(). If there is no
- variable-length data, please set the parameter to 0.
- -datap
- Variable-length data address. Variable-length data can be obtained through ISX_sr_getevtdatap().
- If there is no variable-length data, please set the parameter to NULL.
- -err
- Error code. The value can be obtained through ISX_ATDV_LASTERR(). If the value is 0, no error code is set.
- -ulOperIndex
- Operation number.
- */
- /************************************************************************/
- #ifndef EHANG_ISXAPI_STD_C
- ISXAPI_FUNC_STDCL(INT) ISX_sr_putevt(INT dev, UINT evt, INT len, VOID *datap, INT err, UINT ulOperIndex=0);
- #else
- ISXAPI_FUNC_STDCL(INT) ISX_sr_putevt(INT dev, UINT evt, INT len, VOID *datap, INT err, UINT ulOperIndex);
- #endif
- /************************************************************************/
- /* Function: ISX_sr_Test()
- Description:
- Inner test
- */
- /************************************************************************/
- ISXAPI_FUNC_STDCL(INT) ISX_sr_Test(UCHAR ucIsxNo, UCHAR ucBrdNo, UCHAR ucBrdType, VOID *pInData, UINT ulInDataLen, VOID* pOutData, UINT* pulOutDataLen);
- /************************************************************************/
- /* Function: ISX_sr_Wait4TestData()
- Description:
- Inner test
- */
- /************************************************************************/
- ISXAPI_FUNC_STDCL(INT) ISX_sr_Wait4TestData(UCHAR ucIsxNo, UCHAR ucBrdNo, UCHAR ucBrdType, VOID* pOutData, UINT* pulOutDataLen, INT timeout);
- /************************************************************************/
- /* Function: ISX_sr_SetDebugOutput()
- Description:
- Inner test
- */
- /************************************************************************/
- ISXAPI_FUNC_STDCL(INT) ISX_sr_SetDebugOutput(BOOL bEnable);
- /************************************************************************/
- /* Function: ISX_sr_Log2File()
- Description:
- The ISX_sr_Log2File() function sets default write log file configuration.
- Return value:
- 0 success
- -1 failure
- Parameter:
- -pszLogPath
- Pointer to Log saving path.
- -ulLogFilter
- Log filter, -1 indicates default configuration; 0 indicates not write log.
- */
- /************************************************************************/
- #ifndef EHANG_ISXAPI_STD_C
- ISXAPI_FUNC_STDCL(INT) ISX_sr_Log2File(CHAR* pszLogPath, ULONGLONG ulLogFilter = (ULONGLONG)-1);
- #else
- ISXAPI_FUNC_STDCL(INT) ISX_sr_Log2File(CHAR* pszLogPath, ULONGLONG ulLogFilter);
- #endif
- /************************************************************************/
- /* Function: ISX_sr_SetLogDir()
- Description:
- The ISX_sr_SetLogDir() function sets a path for logs output by SDK. The ISX_sr_SetLogFilter()
- function specifies whether to save logs output by SDK to files. File names that save SDK logs
- are determined by SDK (currently, another file name shall be used every 500,000 lines and the
- file naming rule is "LogPath ISdkLogyyyymmdd_hhnnss.txt", i.e.
- "LogPath ISdkLog(year)(month)(day)_(hour)(minute)(second).txt").
- Return value:
- 0 success
- -1 failure
- Parameter:
- -pszLogPath
- Pointer to Log saving path.
- */
- /************************************************************************/
- ISXAPI_FUNC_STDCL(INT) ISX_sr_SetLogDir(CHAR* pszLogPath);
- /************************************************************************/
- /* Function: ISX_sr_SetLogFilter()
- Description:
- The ISX_sr_SetLogFilter() function sets filtering conditions for SDK output logs.
- Return value:
- 0 success
- -1 failure
- Parameter:
- -pFilter
- Log filtering conditions, please refer to LOG_FILTER.
- */
- /************************************************************************/
- ISXAPI_FUNC_STDCL(INT) ISX_sr_SetLogFilter(LOG_FILTER* pFilter);
- /************************************************************************/
- /* Function: ISX_sr_StartLogServer()
- Description:
- The ISX_sr_StartLogServer() function starts up LogServer. SDK logs can be saved to files.
- They can also be connected to LogServer through TCP/IP by using IsxLog App so that SDK
- output logs are transmitted to IsxLog App for display in real time. Each APP that calls
- SDK must use independent LogServer, which means that when multiple APPs (programs calling
- ISX API) run in the same computer, LogServer must be started up by using various ports,
- otherwise it will result in port conflict.
- Return value:
- 0 success
- -1 failure
- Parameter:
- -iPort
- LogServer port
- */
- /************************************************************************/
- ISXAPI_FUNC_STDCL(INT) ISX_sr_StartLogServer(INT iPort);
- //ISXAPI_FUNC_STDCL(INT) ISX_sr_ChangeLogServerPort(INT iPort);
- /************************************************************************/
- /* Function: ISX_sr_SetDbgIdStr()
- Description:
- The ISX_sr_SetDbgIdStr() function sets channel DbgId that is a string. If DbgId filtering
- conditions are set during the log output, the If the DbgId in the DbgId filtering conditions
- are compared with the DbgId of the channel. If the two strings are equal (or have a inclusion
- relation, the comparison mode is specified in the DbgId filtering conditions), logs are output,
- otherwise no logs are output.
- Return value:
- 0 success
- -1 failure
- Parameter:
- -iDev
- Device handle of DbgId to be set. It may be a channel handle such as DTI,
- DSP, GC and AG channel handles...
- -szIdStr
- DbgId string. The maximum length shall not exceed MAX_DBGID_LEN-1.
- */
- /************************************************************************/
- ISXAPI_FUNC_STDCL(INT) ISX_sr_SetDbgIdStr(INT iDev, CHAR* szIdStr);
- /************************************************************************/
- /* Function: ISX_sr_GetSdkVer()
- Description:
- The ISX_sr_GetSdkVer() function obtains the SDK version number. The version number returned
- by the function is the version number of the SDK DLL. The user can compare this version with
- ISX_API_VER in the srllib.h header file. If they are equal, it indicates that the header file
- used during the SDK DLL compilation is the same as the header file used during the APP compilation.
- Return value:
- Pointer to current SDK Version string.
- */
- /************************************************************************/
- ISXAPI_FUNC_STDCL(CHAR*) ISX_sr_GetSdkVer();
- /************************************************************************/
- /* Function: ISX_sr_getdevtype()
- Description:
- The ISX_sr_getdevtype() function obtains the type of a specified device.
- Return value:
- return Device type, device types may be as follows:
- DT_DSP_BRD
- DT_DSP_CH
- DT_DTI_CH
- DT_SIG_CH
- DT_CS_CH
- DT_XOIP_CH
- ...
- Parameter:
- -Dev
- Device handle
- */
- /************************************************************************/
- ISXAPI_FUNC_STDCL(INT) ISX_sr_getdevtype(INT dev);
- /************************************************************************/
- /* Function: ISX_sr_TrunkChMapping()
- Description:
- If the type of a trunk is E1, the DTI and GC channels of the trunk have two numbering modes,
- i.e. mapping mode and non-mapping mode. For the mapping and non-mapping modes, refer to
- the description of the ISX_dt_open() and ISX_gc_OpenEx(). The mode must be specified by
- calling the ISX_sr_TrunkChMapping() function. The function must be called before the ISX_dt_open()
- and ISX_gc_OpenEx() functions are called. After the ISX_dt_open() or ISX_gc_OpenEx() function
- is called, ISX_sr_TrunkChMapping() shall not be called, otherwise it will cause confusion.
- The default is mapping mode.
- Return value:
- 0 success
- -1 failure
- Parameter:
- -bEnable
- Whether to use the mapping mode. If it is TRUE, the mapping mode is used. If it is FALSE,
- the non-mapping mode is used.
- */
- /************************************************************************/
- ISXAPI_FUNC_STDCL(INT) ISX_sr_TrunkChMapping(BOOL bEnable);
- ISXAPI_FUNC_STDCL(INT) ISX_sr_QueryDevInfo(DEV_INFO* pDevInfo);
- ISXAPI_FUNC_STDCL(INT) ISX_sr_NoDelayRepair(BOOL bRepair);
- ISXAPI_FUNC_STDCL(INT) ISX_sr_default(INT iParmId, VOID* pParam);
- ISXAPI_FUNC_STDCL(INT) ISX_sr_insertparm(VOID* parm_blkp, USHORT parmID, UCHAR data_size, VOID *datap);
- ISXAPI_FUNC_STDCL(INT) ISX_sr_setparm(VOID* parm_blkp, USHORT parmID, UCHAR data_size, VOID *datap);
- ISXAPI_FUNC_STDCL(INT) ISX_sr_convert(USHORT convertID, VOID* pDest, VOID* pSource);
- /************************************************************************/
- /* Function: ISX_sr_getnet2cfg()
- Description:
- Many daughter boards in the ISX4000 switch have two network ports. The IP address of the first
- network port is internally assigned (automatically calculated according to the IP address of
- the motherboard). The IP address of the second network port is set by the user. The user can set
- the IP address of the second network port through OAM. The ISX_sr_getnet2cfg() function obtains
- the IP address information of the second network port.
- Return value:
- 0 success
- -1 failure
- Parameter:
- -ucIsxNo
- Node number
- -ucBrdNo
- Board number
- -ucBrdType
- Board type as follows:
- BT_DSP: DSP daughter board
- BT_XOIP: XOIP daughter board
- BT_SIP: SIP daughter board
- -ipp
- Pointer to IP address
- -netmaskp
- Pointer to mask address
- */
- /************************************************************************/
- ISXAPI_FUNC_STDCL(INT) ISX_sr_getnet2cfg(UCHAR ucIsxNo, UCHAR ucBrdNo, UCHAR ucBrdType, CHAR* ipp, CHAR* netmaskp);
- /************************************************************************/
- /* Function: ISX_sr_GetSpecCap()
- Description:
- The ISX_sr_GetSpecCap() function obtains special capabilities of daughter boards.
- Some daughter boards of ISX series have some special capabilities. Currently,
- the trunk voice mixing daughter board and the XOIP voice mixing daughter board
- have the special capability of voice mixing that helps meet some special service
- demands such as recording both parties' communication voice not in a conference,
- recording karaoke, etc. For details, refer to the voice mixing function part of
- the programming guide.
- Return value:
- 0 success
- -1 failure
- Parameter:
- -ucIsxNo
- Node number
- -ucBrdNo
- Board number
- -ucBrdType
- Board type as follows:
- BT_TRUNK: Trunk daughter board
- BT_XOIP: XOIP daughter board
- -pSpecCap
- Pointer to the structure address where special capabilities are stored.
- Refer to the SPEC_CAP structure.
- */
- /************************************************************************/
- ISXAPI_FUNC_STDCL(INT) ISX_sr_GetSpecCap(UCHAR ucIsxNo, UCHAR ucBrdNo, UCHAR ucBrdType, SPEC_CAP *pSpecCap);
- /************************************************************************/
- /* Function: ISX_sr_SetMixParm()
- Description:
- The ISX_sr_SetMixParm() function sets voice mixing parameters of a specified special daughter
- board. Daughter boards with the voice mixing capability include the trunk voice mixing daughter
- board and the XOIP voice mixing daughter board.
- Return value:
- 0 success
- -1 failure
- Parameter:
- -ucIsxNo
- Node number
- -ucBrdNo
- Board number
- -ucBrdType
- Board type as follows:
- BT_TRUNK: Trunk daughter board
- BT_XOIP: XOIP daughter board
- -pMixParam
- Pointer the address of voice mixing parameters. Refer to the MIX_PARAM structure.
- */
- /************************************************************************/
- #ifndef EHANG_ISXAPI_STD_C
- ISXAPI_FUNC_STDCL(INT) ISX_sr_SetMixParm(UCHAR ucIsxNo, UCHAR ucBrdNo, UCHAR ucBrdType, MIX_PARAM *pMixParam=NULL);
- #else
- ISXAPI_FUNC_STDCL(INT) ISX_sr_SetMixParm(UCHAR ucIsxNo, UCHAR ucBrdNo, UCHAR ucBrdType, MIX_PARAM *pMixParam);
- #endif
- /************************************************************************/
- /* Function: ISX_sr_GetMixParm()
- Description:
- The ISX_sr_GetMixParm() function obtains voice mixing parameters of a specified special
- daughter board. Daughter boards with the voice mixing capability include the trunk
- voice mixing daughter board and the XOIP voice mixing daughter board.
- Return value:
- 0 success
- -1 failure
- Parameter:
- -ucIsxNo
- Node number
- -ucBrdNo
- Board number
- -ucBrdType
- Board type as follows:
- BT_TRUNK: Trunk daughter board
- BT_XOIP: XOIP daughter board
- -pMixParam
- Pointer the address of voice mixing parameters. Refer to the MIX_PARAM structure.
- */
- /************************************************************************/
- ISXAPI_FUNC_STDCL(INT) ISX_sr_GetMixParm(UCHAR ucIsxNo, UCHAR ucBrdNo, UCHAR ucBrdType, MIX_PARAM *pMixParam);
- /************************************************************************/
- /* Function: ISX_sr_writeflash()
- Description:
- Inner test
- */
- /************************************************************************/
- ISXAPI_FUNC_STDCL(INT) ISX_sr_writeflash(UCHAR ucIsxNo, UCHAR ucBrdNo, UCHAR ucBrdType, const CHAR* pBuffer, USHORT usSize, UINT ulOffset, VOID* pRvr);
- /************************************************************************/
- /* Function: ISX_sr_readflash()
- Description:
- Inner test
- */
- /************************************************************************/
- ISXAPI_FUNC_STDCL(INT) ISX_sr_readflash(UCHAR ucIsxNo, UCHAR ucBrdNo, UCHAR ucBrdType, CHAR* pBuffer, USHORT usSize, UINT ulOffset, UCHAR* pEOF, VOID* pRvr);
- /************************************************************************/
- /* Function: ISX_sr_TestGetMisc()
- Description:
- Inner test
- */
- /************************************************************************/
- typedef struct tagMISC_INFO{
- CHAR cLogStopFlag;
- CHAR cRfu[255];
- }MISC_INFO;
- ISXAPI_FUNC_STDCL(INT) ISX_sr_TestGetMisc(VOID *pMiscBuf, INT iBufLen);
- ISXAPI_FUNC_STDCL(INT) ISX_sr_Hdl2Channel(INT iHdl, CHAR* devtype, CHAR* nodenum, CHAR* brdnum, CHAR* spannum, SHORT* channel);
- ISXAPI_FUNC_STDCL(INT) ISX_sr_Channel2Hdl(CHAR devtype, CHAR nodenum, CHAR brdnum, CHAR spannum, SHORT channel, INT* iHdl);
- ISXAPI_FUNC_STDCL(INT) ISX_sr_SetMsgIdMonitorTab(ISX_MONITOR_MSG_TAB *pMsgTab); //[2014-11-27]
- /* terminate the extern "C" for c plus plus */
- #if defined(__cplusplus)
- }
- #endif
- #endif
|