Template Files
A number of small application templates are found throughout the apps directory. Each of these files contains a small, well-defined set of functionality that enables a software developer to easily understand its implementation via the TSCF client-side SDK.
SDK: +---apps/tsc_sip/tsc_sip_client | +---tsc_sip_client.c Provides a basic SIP client utilizing TCP/TLS/UDP/DTLS for tunnel transport of inner UDP sockets. Supports Linux, Windows, and Android operating systems. +---apps/tsc_sip/tsc_sip_server | +---tsc_sip_server.c Provides a basic SIP server utilizing TCP/TLS/UDP/DTLS for tunnel transport of inner UDP sockets. Supports Linux, Windows, and Android operating systems. +---apps/tsc_sip/tsc_sip_inner_tcp | +---tsc_sip_inner_tcp.c Provides a basic SIP client utilizing TCP for tunnel transport and demonstrating usage of TCP sockets for applications such as HTTP -- supports Linux operating systems.
All of the above files contain extensive comments making it an easy task to navigate through the code. Using tsc_sip_client.c as an example, you can readily proceed through the file.
- Search for tsc_ctrl_init () and examine the code immediately following this function for the details of tunnel initialization.
- Search for Create a Tunnel and examine the code immediately following for the details of tunnel creation and the configuration exchange between the TSCF server and client.
- Search for SIP SOCKET CREATION and examine the code that creates and binds TSCF sockets.
- Search for REGISTER TRANSACTION and examine the code that builds a SIP REGISTRAR request and processes the REGISTRAR response.
- Search for INVITE TRANSACTION and examine the code that builds a SIP INVITE request and processes the REGISTRAR response.
- Search for Build and send ACK to examine ACK creation and processing code.
- Search for RTP Exchange to examine RTP code.
- Search for BYE TRANSACTION to find code that terminates a SIP connection.
- Search for TEST DONE to find code that terminates a tunnel.