Global Call API for HMP on Windows Programming Guide — August 2006 83
Application Development Guidelines

5.3.2.6 Device Initialization Hint (Flexible Routing)

In some applications, when xx_open() fun ctions (Global Call, Voice, Fax) are issued
asynchronously, it may cause slow device-initialization performance. Fortunately, you can avoid
this particular problem quite simply by reorganizing the way the application opens and then
configures devices. The recommendation is to do all xx_open( ) functions for all channels before
proceeding with the next function. For example, you would have one loop through the system
devices to do all the xx_open() functions first, and then start a second loop through the devices to
configure them, instead of doing one single loop where an xx_open( ) is immediately followed by
other API functions on the same device. With this method, by the time all xx_open() commands
are completed, the first channel will be initialized, so you won’t experience problems.
This change is not necessary for all applications, but if you experience poor initialization
performance, you can gain back speed by using this hint.

5.3.2.7 Using Protocols (Flexible Routing)

For ISDN protocols, the protocol to use is determined at board initialization time and not when
opening a Global Call device. Protocol parameters are configured in the CONFIG file before the
firmware is downloaded to the board. If a protocol is specified in the devicename parameter of the
gc_OpenEx( ) function when opening a device, it is ignored.
For T1/E1 CAS/R2MF protocols, the protocol to use for a trunk is selected using the “Trunk
Configurator” feature of the configuration manager (DCM). Protocol files are provided with the
system software in the \data directory under the Dialogic home directory. A protocol can be
configured by changing the parameter values in the corresponding Country Dependent Parameter
(CDP) file located in the \data directory. See the Global Call Country Dependent Parameters
(CDP) for PDK Protocols Configuration Guide for details on the parameters that can be changed
for each protocol. If a protocol is specified in the devicename parameter of the gc_OpenEx( )
function when opening a device, it is ignored.
5.3.3 Handling Multiple Call Objects Per Channel in a Glare Condition
When using Digital Network Interface boards, Global Call supports the handling of multiple call
objects per channel in a glare condition. An application running on bi-directional circuits is capable
of handling two CRNs on a single line device, where one call can be in an Idle state, while the other
call is in Active state. For example, a glare condition occurs when a call has been dropped but not
released and an inbound call is detected as indicated in Table10. In order to avoid a long delay in
processing the inbound call, the Global Call library does not wait for the outbound call to be
released before notifying the application of the inbound call.
Table10. Handling Glare
Application Global Call Library
gc_MakeCall(CRN1) -->
<-- GCEV_DISCONNECTED(CRN1)
gc_DropCall(CRN1) -->