Understanding the CTI32 Service

  1. Home
  2. CTI32 Legacy Articles
  3. Understanding the CTI32 Service

Understanding the CTI32 Service

Author’s note:  This article supports our legacy products.  At Inventive Labs, after two decades of providing telephony tools, we never stop supporting those who rely on our products to run their businesses.  We no longer recommend Dialogic. This article is for our customers who are using legacy equipment. For more information about these legacy products and where we are today, read  Ditch Dialogic & Convert to Voice Elements.

The CTI32 Sevice (CTI32Svc.exe) hosts the CTI32Engine on each telephony machine.

By running as a service, the CTI32Engine is able to manage the telephony resources on the machine without needing a user to logon to the console.

System Initialization

The CTI32Service, when started, in turn starts the CTI32Engine. The engine reads the configuration files such CTI32.INI and CTI32Engine.config. The CTI32Engine then opens and initializes the telephony resources based on the configuration specified. You can modify the configuration by using the CTI32Config.exe utility.

The system can then place or accept calls.

When an inbound call arrives, the loaded configuration determines what code to use to process the call. For simple applications, the system simply looks at the DefaultDLL, DefaultMethod, and DefaultType parameters of your configuration.

The system passes to the DLL a reference to the ConfigData structure and the ChannelData structure for the call. You can then use these for manipulating the call. You can also request an outbound channel, call another party, and route the current call to the outbound call leg.

For regular outbound work, the Engine uses a concept of a Dispatch DLL. This is a DLL that is called by the Engine at startup. When the DispatchDLL code executes you can “Dispatch” calls according to your needs.

The standard approach for a Dispatch DLL is to read a database, launch outbound calls as necessary, then repeat the process.

Other approaches include:

  • Using a socket connection to communication with an application that permits a user to control the call flow
  • Using the CTI32StatusClient to send commands through the built-in UserQueue
  • Using a datastore for controlling the system
  • Any other approach that you can devise. We have seen quite a few.

It is up to you to decide what approach best suits your needs.

How this approach affects development

A lot of developers are used to creating a Desktop Application. Since the CTI32Engine uses DLL’s, there is no “Application” for you to start with as a shell.

Fortunately, creating your DLL’s for CTI32 is relatively easy and we provide numerous samples for you to see just how to create and implement your telephony application.

You may have concerns about debugging. Since the system handles multiple calls, the code is called by multiple threads. Trying to debug interactively when hundreds of calls are in process, just wont work. Accordingly, CTI32 relies heavily on logging. This is the most effective way to debug multi-threaded applications.

If you are in a controlled environment, and you have only one or two calls being placed at a time, you can debug interactively. For more information on this approach, see: How to use an interactive debugger with CTI32

Was this article helpful to you? No Yes 13

How can we help?