Dialogic
Search
Worldwide
中文 (CHINA)
CANADA English [EN]
CANADA Français [FR]
D/A/CH
NORTHERN EUROPE
日本 (JAPAN)
Contact
DEN
PRODUCTS
SOLUTIONS
TECHNOLOGIES
PURCHASE
PARTNERS
SERVICE CENTER
COMPANY
Dialogic Service Center
Service Contracts
Dialogic
®
Pro™ Contracts
Dialogic
®
Pro™ Summary
Value Per Unit Plan
Standard Per Unit Plan
Premium Per Unit Plan
Standard Service Agreement
Premium Service Agreement
Carrier Pack
Contracts by Product
Contracts by Customer Type
Contracts by Requirement
Technical Helpweb
Helpweb Menu
Helpweb Menu
Dialogic API information
DM3 & JCT products
Host Media Processing (HMP)
Brooktrout
®
Fax
IP Media Server
IMG Gateways
CSP Platforms
MSP Platforms
DMG-series Media Gateways
Signaling & SS7 Components
Multimedia Platform for ATCA
®
Diva
®
Media Boards
Diva
®
SDK
Vision™ Servers & Gateways
NaturalAccess™ products
Diva
®
Client
Eiconcards (X.25)
Other Dialogic products
Downloads
Software Download wizard
Software Download listing
Manuals & Documentation
Document Finder
Contact Support
Select Support region
Americas Support
AsiaPac Support
EMEA Support
Online Service Request
Developer Forums
Developer Forums Menu
Dialogic
®
Global Call Forum
Dialogic
®
Diva
®
SDK Forum
SS7 and Sigtran Signaling Forum
Training
Training Menu
On-line training courses
Share
Home
Service Center
Technical Helpweb
Dialogic® DM3 & JCT Media Boards
Technical Helpweb
Dialogic® DM3 and JCT Media Boards
Setting Board Parameters via Native Configuration Manager (NCM) API
Summary:
This technote explains how to use the attached sample code to find unique names for Dialogic® devices and how to configure Dialogic® boards using the Native Configuration Manager API.
Symptom:
A common way to configure Dialogic boards is to use Dialogic® Configuration Manager (DCM) applet. This is a GUI-based application and requires user interaction in real time. Although suitable in most cases, the DCM applet cannot be used when some parameters need to be updated automatically or remotely and without user intervention. This technote provides sample code to illustrate how to use the Native Configuration Manager (NCM) API to configure Dialogic devices programmatically when user intervention is not possible.
Reason for the problem:
When a system is first installed or updated with Dialogic® software, the NCM framework automatically detects the installable devices it finds in the system. This happens at system startup. During the auto-detection process, the framework assigns a unique name to each Dialogic device it can detect, and sets default parameters for each such device. Those parameters are stored in the system registry database, and they are used to configure the Dialogic® System services.
The unique name assigned to each detected Dialogic device consists of a family name, a device name and device-specific information (such as PCI bus/slot where the device is installed, device logical or physical ID, etc). However, when a system gets upgraded, the names of some specific devices may change, even if a physical location of the device remains the same.
Since the user application must know the exact name of the device in order to access its configurable parameters, it cannot rely on a device name previously created, since this name may no longer be valid for the device. Therefore, it cannot rely on the Win32 API to change registry settings directly. Some features of the Native Configuration Manager (NCM) API address this problem.
Fix / Solution:
The attached sample code (see Attachment section below), provides a way to change the PCD and FCD file names of installed Dialogic® Host Media Processing (HMP) software, based on a license file that contains device family name. (Note: Although Dialogic HMP software is cited in this example, this sample code should be usable for any Dialogic® technology). Unlike the device name, the device family name never changes and is defined in NCMTypes.h file. For example:
#define DM3FamilyName "DM3".
Since we know that a Dialogic® HMP-based device belongs to the Dialogic® DM3 device family, we must find out if there are any devices with the Dialogic DM3 device family name installed in the system:
NCMFamily *pFamilies= NULL;
// Get all the installed families
NCMRetCode ncmRc = NCM_GetInstalledFamilies(&pFamilies);
The NCM_GetInstalledFamilies() allocates a list of NCMString structures and returns it as pFamilies reference. Note: It is the responsibility of the application to deallocate this list, so we need to preserve this pointer, and use another temp variable to iterate the list:
NCMFamily *pTmpFam = pFamilies; // preserve the head of the list
while(pTmpFam)
{
if(strcmp(pTmpFam->name, "DM3") == 0) // found DM3 family
break;
pTmpFam = pTmpFam->next;
}
Assume that the family is found. Now we can find all installed devices of this family:
NCMDevice *pDevices= NULL;
NCM_GetInstalledDevices(pTmpFam,&pDevices);
NCMDevice *pTmpDev = pDevices);
// Look for a device containing “HMP” in its name:
while(pTmpDev)
{
if(strncmp(pTmpDev->name, "HMP", 3) == 0) // found HMP instance
break;
pTmpDev = pTmpDev->next;
}
If the HMP device is found, the pTmpDev->name will contain its full unique name, such as “HMP_Software #2 in slot 0/65535”.
This name now can be used to set or retrieve configuration parameters using NCM_SetValueEx() or NCM_GetValueEx() API’s (see the attached code for details).
Finally, we need to deallocate a memory NCM created to store device family and device names lists. Note: Use original pointers returned by NCM functions, otherwise memory leak may occur:
NCM_Dealloc(pDevices); NCM_Dealloc(pFamilies);
Product List
Any Dialogic product supported by a specific system release and listed in NCM repository
Glossary of Acronyms / Terms:
GUI – Graphic User Interface
HMP – Host Media Processing (as in Dialogic® HMP software)
NCM – Native Configuration Manager
Attachments:
Sample Code
Feedback
Please rate the usefulness of this page:
0 - not useful at all
1 - potentially useful
2 - quite useful
3 - very useful
4 - exactly the information I needed
Please enter a comment about this page: