version 1.65c OS Requirement: WIN Vista WIN 2003 + DirectX 8+ WINXP WIn2000 + DirectX 8+ Win98 and Me + DirectX 8+ Mem 64M + CPU: P2 400 + Please copy dlls in bin folder to windows/system32 to make sure they can be accessable by your application. If you are using activex control in bin folder, you don't need to copy dlls into windows\system32, but the ocx is required to be registered before you use it. command to register: regsvr32 gtsipctrl.ocx. Version History: ---V1.65c 1. Fixed compatibility problems with CallCentric and Vonage. 2. Fixed a registration timeout issue. ---V1.65 1. Added support for RFC 2883. (DTMF in RTP) 2. Resolved problem with SIP CANCEL and ACK after call is ringing. This problem is introduced from 6.4 (Maybe. I think.) ---V1.64 1. Fixed a bug for Audio Recording feature of SIP client phone. When set "gtphone.audio.record.enabled" to 1 to enable automatical audio recording, the WAV file couldn't be played by Windows Media Player. Now this bug is fixed. The wav files can be played by WMP. 2. SDK can play 8K Mono 16Bit PCM, 8Bit Mulaw, 8Bit Alaw wav files now. SDK was only able to play 8K 8Bit Mulaw wav files. 3. Added "Music On Hold" feature to all interfaces, also in sample code "SIPServerApp". 4. a Delph6 sample is added into SDK. It is in folder sdk/samples/ocx/delphi6. 5. On_SentRTPPacket, On_RenderDXAudio, On_CaptureDXAudio now accept the buffer from application. Those functions were used to send audio buffer to application, but they now also accept the change of buffer. If you changed the buffer of On_SentRTPPacket and On_CaptureDXAudio, the audio will be taken effect to remote side. If you changed the buffer of On_RenderDXAudio, the audio will has effect on local sound card. ---V1.63 1. Added a sample for Borland C++ Build 6. 2. Removed Allow SIP Header from SIP Request. 3. Fixed a bug with 183 - Session Progress. Old code doesn't release RTP port and DX audio in some cases when 183 message occures. 4. Added four virtual functions for .NET class GTAPIASM.GTAPIEnv to access low level layer audio data.(See V1.53 comments for how to use these functions.) virtual void On_RecvRTPPacket(int ch, int fmt, IntPtr buf, int buflen, unsigned short seq, unsigned int timestamp, IntPtr pSysTime) virtual void On_SentRTPPacket(int ch, int fmt, IntPtr buf, int buflen, unsigned short seq, unsigned int timestamp, IntPtr pSysTime) virtual void On_CaptureDXAudio(int ch, int fmt, IntPtr buf, int buflen, unsigned short seq, unsigned int timestamp, IntPtr pSysTime) virtual void On_RenderDXAudio(int ch, int fmt, IntPtr buf, int buflen, unsigned short seq, unsigned int timestamp, IntPtr pSysTime) ****Import Notice**** for using above four functions in .NET program. If you enable those functions, you will get these functions triggered every 20 milliseconds. Because the thread to trigger those functions is low level thread of Span, you can NOT access any Windows GUI functions to update your Windows status. (for example, update text value of edit or static.) You have to do a very fast job to copy buffer to your local, then start your process. How to copy buffer from native code to .NET managed code? Please see the link http://www.wit-igraph.com/doc/prog/apps/engine/vbc/mem.htm or sample source code in GTAPIASM project. 5. Added two methods and one event for chan's timer. (C++, OCX, .NET) void StartTimer(int ch, unsigned long milli_secs); void StopTimer(int ch); virtual void OnTimer(int ch); How to use it? Start a timer by using StartTimer function, then handle it on OnTimer function. 6. Added two methods for retrieving code and text of lastest SIP message. C++ CGTAPIEnv class: int GetChanLastMsgCode(int ch); const char* GetChanLastMsgText(int ch); .NET GTAPIASM::GTAPIENV int GetChanLastMsgCode(int ch); string GetChanLastMsgText(int ch); OCX ActiveX Control: int GetChanLastMsgCode(int ch); BSTR GetChanLastMsgText(int ch); These methods are good for getting the reason of unsuccessful outbound calls. Sample: On_RecvIdle(int ch) //OnCallIdle(int ch) in OCX { if(outbound call) { //if the call didn't even get connected and it isn't cancelled by user int msgCode = GetChanLastMsgCode(ch); if(msgCode == 486) //busy } else(inbound call) { //if the call didn't even get connected and it isn't cancelled by user //then it is a missed call } } The value list of GetChanLastMsgCode is defined in RFC 3261. for example: Informational = "100" ; Trying / "180" ; Ringing / "181" ; Call Is Being Forwarded / "182" ; Queued / "183" ; Session Progress Success = "200" ; OK Redirection = "300" ; Multiple Choices / "301" ; Moved Permanently / "302" ; Moved Temporarily / "305" ; Use Proxy / "380" ; Alternative Service Client-Error = "400" ; Bad Request / "401" ; Unauthorized / "402" ; Payment Required / "403" ; Forbidden / "404" ; Not Found / "405" ; Method Not Allowed / "406" ; Not Acceptable / "407" ; Proxy Authentication Required / "408" ; Request Timeout / "410" ; Gone / "413" ; Request Entity Too Large / "414" ; Request-URI Too Large / "415" ; Unsupported Media Type / "416" ; Unsupported URI Scheme / "420" ; Bad Extension / "421" ; Extension Required / "423" ; Interval Too Brief / "480" ; Temporarily not available / "481" ; Call Leg/Transaction Does Not Exist / "482" ; Loop Detected / "483" ; Too Many Hops / "484" ; Address Incomplete / "485" ; Ambiguous / "486" ; Busy Here / "487" ; Request Terminated / "488" ; Not Acceptable Here / "491" ; Request Pending / "493" ; Undecipherable Server-Error = "500" ; Internal Server Error / "501" ; Not Implemented / "502" ; Bad Gateway / "503" ; Service Unavailable / "504" ; Server Time-out / "505" ; SIP Version not supported / "513" ; Message Too Large Global-Failure = "600" ; Busy Everywhere / "603" ; Decline / "604" ; Does not exist anywhere / "606" ; Not Acceptable ---V1.62 1. Added support for abbreviation of SIP Header. (Both in dlls and ocx) 2. Two new buttons added into VB.NET SIP phone sample to show how to dynamically changed sound device in a live call, and how to dynamically do audio recording. ---V1.61 Changed the sample code of "SIPServerApp". It can accept DTMF digits when playing or recording audio file. ---V1.60 An activeX is added into SDK family. VB6, Dephi and Borland C++ Builder programers can use this OCX to develop SIP applications. OCX name: GTSIPCtrl.ocx How to register this activeX in Windows: c:\sdkfolder\bin\>regsvr32 gtsipctrl.ocx How to insert this activeX into your projects: See picture http://www.pcbest.net/images/insert-ocx.jpg Guide to this ActiveX: http://www.pcbest.net/sipsdkref-ocx.htm sdkfolder\samples\OCX\VB6 is the sample code of this ActiveX. ---V1.59 1. Dynamically change "gtphone.audio.record.enabled" without restarting sip server. (For phone client) This makes dynamically recording audio channel available. 2. Play a list of audio. (For Server Application) It is possible to play a list of audio file. For example, if we want to play 3 files: 1.wav, 2.wav and 3.wav. Steps: Send_AddAudio(0, "1.wav"); Send_AddAudio(0, "2.wav"); Send_AddAudio(0, "3.wav"); Send_PlayAudio(0, "", 0, "", 0); 3. DTMF detection is available for PlayAudio and RecordAudio (For sever application only) void Send_PlayAudio(int ch, const char* audioFileName, int iMaxDigit, const char* termStr, int iMaxTimer); int iMaxDigit : Maxium number of digits arrived. (0 = unlimited) const char* termStr: If any of character in the termStr pressed, the audio will stop. ("" = no term string) int iMaxTimer: timeout value. (0 = no limitation) void Send_RecordAudio(int ch, const char* audioFileName, int iMaxDigit, const char* termStr, int iMaxTimer); same as above. sample: a. If we want to play a audio, but when "#" is pressed or max 4 digits arrived, audio will be stopped. Send_PlayAudio(0, "audio.wav", 4, "#", 0); b. If we want to record a audio which is max of 60 seconds length, but when "#" is pressed, recording audio will stop. Send_RecordAudio(0, "audio.wav", 0, "#", 60000); 4. Ability to use one sound card to play, another one to record. (For client phone application using DirectX for audio.) Add two tags for specifying direcx playback and recording devices separately: "gtsrv.sip.dxsound.device.playback" "gtsrv.sip.dxsound.device.capture" Please use keyword of devices. For example, we have two sound cards. One is Intel 2345M, antoher is SoundBlaster SB879B. We want Intel to play voice, and SB to recording. Then: CFG_SetValue("gtsrv.sip.dxsound.device.playback", "2345M"); CFG_SetValue("gtsrv.sip.dxsound.device.capture", "SB879B"); 5. Ability to change sound card dynamically in a live call. Add one function to CGTAPIEnv class to reset dx device. Call sample: CFG_SetValue("gtsrv.sip.dxsound.device.playback", "2345M"); //set key word of playback device CFG_SetValue("gtsrv.sip.dxsound.device.capture", "SB879B"); //set key word of recording device Send_ResetDxAudio(ch); 6. Add one tag to control the way of DTMF "gtsrv.sip.dtmf.method" 0 = default, Using DTMF in audio 1 = SIP Info 2 = RTP Package (Not support yet, soon will be done). 7. Add a callback function to CGTAPIEnv class for message indication of vocie mail box virtual void On_RecvNotifySimpleMsgSummary(const char* sMsgWaiting, const char* sMsgAccount, const char* sVoiceMsg){} const char* sMsgWaiting : Yes or No const char* sMsgAccount : The sip account to retrieve voice message const char* sVoiceMsg : Voice message count 8. On_RecvDTMFDone of CGTAPIEnv has new format. Old : void On_RecvDTMFDone(int ch) New : void On_RecvDTMFDone(int ch, int reason, const char* dtmfBuf) ---V1.58 1. Add a tag for identify if application is a SIP server or SIP client phone. CFG_SettValue("gtsrv.sip.server.model", "1") //Server model, default. or CFG_SettValue("gtsrv.sip.server.model", "0") //SIP Client Phone model, using DX audio 2. Four more functions added to env class play tones. //num = 0-9, '*' or '#' bool PlayNumTone(char num); bool PlayLocalRingSound(); bool PlayRemoteRingSound(); bool PlayBusySound(); ---V1.57 Enhanced error handling. Env class member function On_RecvError(int ch) is changed to On_RecvError(int ch, int errCode). Please use gterr.h as error code list reference. ---V1.56 Resolved the following several issues: 1. unable to access what kind of audio codec is being used. Fixed. Use the following functions to access audio codec that being used. C++ : int CGTAPIEnv ::GetChanAudioCodec(int ch); .NET : int GTAPIASM.GTAPIEnv.GetChanAudioCodec(int ch); 102 = Speex 101 = iLBC 30ms 100 = iLBC 20ms 3 = GSM 98 = G726-32 0 = G711-Mulaw 8 = G711-Alaw 2. When using second sound card as DXSound audio, the following functions only operator the first primary sound card. void SetMicVolume(float v); float GetMicVolume(); void SetSpeakerVolume(float v); float GetSpeakerVolume(); Fixed: Above functions will handle second audio card's volume if it is using sencond as DXSound audio. 3. When multipul channels are connected, audio quality is bad. Fixed. ---V1.55 In order to assist programmers who are using SDK to develop IVR applications, "SIP Server App" is added into sample code. The soure code of this application has two version: C++ and VB.NET. The application will help programmers with Playing audio, recording audio, echo test, call bridge, and DTMF Detection. Play Sound: Answer the call, and play the specified sound file. Record Sound: Answer the call, and record sound into a WAV file. Echo Test: A sample to return voice back to sender. Call Bridge: Full Duplex Connect two channels, so two clients can talk with each other. DTMF Detector: Answer calls, and wait for DTMF digits. Digits will be displayed on the channels' status line. Please copy GTSIPServerApp.ini in INI folder to c:\, and edit it with your condiguration. ---V1.54 Reslove the crash when using "gtsrv.sip.dxsound.device" to specify dxsound device ---V1.53 Add four virtual functions to class GTNetCmdClientI for raw audio access. Note: only C++ programers can use these interface now, because those functions are very realtime, and must return ASAP. Set "gtsrv.sip.on.rtp.packet" to 1, or 2, or 3 to access rtp data. 1 = MULAW 2 = ALAW 3 = PCM Overwrite the following two functions to get raw audio data. virtual void On_RecvRTPPacket(int ch, int fmt, char* buf, int buflen, unsigned short seq, unsigned int timestamp, SYSTEMTIME* pSysTime) virtual void On_SentRTPPacket(int ch, int fmt, char* buf, int buflen, unsigned short seq, unsigned int timestamp, SYSTEMTIME* pSysTime) Set "gtsrv.sip.on.dx.audio" to 1, or 2, or 3 to access directx audio data 1 = MULAW 2 = ALAW 3 = PCM Overwrite the following two functions to get raw directx audio data. virtual void On_CaptureDXAudio(int ch, int fmt, char* buf, int buflen, unsigned short seq, unsigned int timestamp, SYSTEMTIME* pSysTime) virtual void On_RenderDXAudio(int ch, int fmt, char* buf, int buflen, unsigned short seq, unsigned int timestamp, SYSTEMTIME* pSysTime)