Overview | Package | Class | Tree | Deprecated | Index | Help
PREV PACKAGE NEXT PACKAGE | FRAMES NO FRAMES

## Package cnrg.itx.gtwy

The gateway is the interface where the computer and telephone networks can transfer voice data to one another. In the cnrg.itx.gtwy package, the software is configured to program Dialogic Corporation's D41/EPCI card. The Windows NT platform is necessary to use this software. It is important to note that the D41/EPCI channels are limited to servicing half-duplex connections only. In order to service a full-duplex connection, two channels are needed per session. A "line" is an abstraction of these two channels.

See:
Description

Class Summary
Gateway | This class contains the main Gateway control.
Line | A class that provides information regarding each Gateway line.
ListenChannel | Takes care of servicing incoming calls from the phone.
PlayChannel | This class controls the second channel in a data connection.
PlayDestination | The user-defined destination of voice data packets from the computer network to the gateway.
RecordChannel | Takes care of sending voice data from the primary channel from the phone to the computer network.
RecordSource | This is abstracted as the source for the voice data packets sent from the Gateway to the computer network.
SignalInterface | Used as an interface between the Gateway and the signaling component.

Exception Summary
GatewayException | A `GatewayException` is a exception thrown by the various Gateway components.

## Package cnrg.itx.gtwy Description

The gateway is the interface where the computer and telephone networks can transfer voice data to one another. In the cnrg.itx.gtwy package, the software is configured to program Dialogic Corporation's D41/EPCI card. The Windows NT platform is necessary to use this software.

It is important to note that the D41/EPCI channels are limited to servicing half-duplex connections only. In order to service a full-duplex connection, two channels are needed per session. A "line" is an abstraction of these two channels. To all outside components, the Gateway uses one "line" to provide a full-duplex transfer. Also, the minimum packet size that could be transferred from the phone to a channel is 512 bytes. A constant called BUFFERSIZE in Gateway.java is therefore set to 512. The minimum packet size that could be played out on a phone is 1024 bytes. In Gateway.java, a constant called PXFERFACTOR is set to 2. To determine the transfer size to the phone, BUFFERSIZE is multiplied by PXFERFACTOR.

Before running the Gateway, it may be necessary to reconfigure the software. In Gateway.java, the constants that can be changed are BUFFERSIZE, PXFERFACTOR, LINECOUNT, CHANNELCOUNT, and PHONENUMBER. Change BUFFERSIZE and PXFERFACTOR to set the channel transfer rate. LINECOUNT and CHANNELCOUNT are the total number of line abstractions and channels on the Gateway. Set PHONENUMBER equal to the telephone numbers used to call the lines. In the software scheme, the first number calls the first line, the second calls the second line, and so on.

In dialogic.cpp, all the global constants could be changed. The most important are initialfd and pread_timeout. initialfd is the basis for some dummy file descriptors. Change this constant to a higher value if there are too many file descriptors for the Gateway card to handle. If the Gateway does not receive packets from a computer in a certain amount of time, it will time out and play silence on the phone. Increase pread_timeout to increase the waiting time. However, unpredictable results will occur when pread_timeout is too high.

To run the Gateway, set the classpath to the following directories: ITX\src\cnrg\itx\ds and ITX\gtwy. The necessary files are DSComm.dll, resolv.conf, dialogic.dll, and various .wav files found in ITX\gtwy. Once this is done, run Gateway.exe.

If a different Gateway card is being used, create a new directory and write a new .dll or .so. The native methods are defined in ChannelControl.java. In ChannelControl.java, change the name of the file referred to by System.loadLibrary according to the name of the .dll or .so. Use the .wav files in ITX\gtwy or create new ones. If dialogic.dll is to be recompiled use the given project in ITX\src\cnrg\itx\gtwy\dialogic. Go to Project->Settings->Link(tab)->Output File Name and set the output to be dialogic.dll on the ITX\gtwy directory.

Overview | Package | Class | Tree | Deprecated | Index | Help
PREV PACKAGE NEXT PACKAGE | FRAMES NO FRAMES