Intel 05-2352-005 manual Following example is for Windows applications

Page 38

/* Set up DX_XPB structure */ xpb.wFileFormat = FILE_FORMAT_VOX; xpb.wDataFormat = 0; xpb.nSamplesPerSec = 0L; xpb.wBitsPerSample = 0;

/*Set up DV_TPT structure */ dx_clrtpt (&tpt,1); tpt.tp_type = IO_EOT; tpt.tp_termno = DX_MAXDTMF; tpt.tp_length = 1; tpt.tp_flags = TF_MAXDTMF;

/* Set up DX_IOTT structure */ iott[0].io_fhandle = fd; iott[0].io_type = IO_DEV; iott[0].io_offset = 0; iott[0].io_length = MAXLEN; iott[0].io_offset = IO_EOT;

/* And record from both voice channels */

if (dx_mreciottdata(devh3, &iott[0], &tpt, &xpb, RM_TONE, &tsinfo) == -1) { printf("Error recording from dxxxB1C1 and dxxxB1C2\n"); printf("error = %s\n", ATDV_ERRMSGP(devh1));

exit(2);

}

/* Display termination condition value */

printf ("The termination value = %d\n", ATDX_TERMMSK(devh1));

/* And close three voice channels */ if (dx_close(devh3) == -1){

printf("Error closing devh3 \n");

/* Perform system error processing */ exit(3);

}

if (dx_close(devh2) == -1) { printf("Error closing devh2\n");

/* Perform system error processing */ exit (3);

}

if (dx_close(devh1) == -1) { printf("Error closing devh1\n");

/* Perform system error processing */ exit (3);

}

if (close(fd) == -1){ printf("File close error \n"); exit(1);

}

/* And finish */ return;

}

The following example is for Windows applications.

#include <windows.h> #include <fcntl.h> #include <stdio.h> #include <stdlib.h> #include <srllib.h> #include <dxxxlib.h>

#define MAXLEN 10000

HMP Linux 1.2 Release Update, Rev 05 — September 2006September 2006

38

Image 38
Contents Release Update SeptemberHMP Linux 1.2 Release Update, Rev 05 September Intended Audience How to Use This PublicationPurpose Related Information Document Rev 04, published December Updated for Service UpdateDocument Rev 05, published September Document Rev 03, published JuneDocument Rev 02, published January Document Revision HistoryDocument Rev 01, published October Service Update Software Installation Release DevelopmentsOrder of Procedures Assumptions and PrerequisitesInstalling the Service Update Following messages are displayedHMP Verification Demo Environment VariablesSupport for 120 Low Bit Rate Channels Support for Red Hat Enterprise Linux UpdateSupport for Suse Linux Enterprise Server Transaction RecordHMP Linux 1.2 Release Update, Rev 05 September Defect Number PTR Number IssuesIssue Type Product or ComponentIssues Resolved in HMP DescriptionFcdgen error while loading shared Dataformatmulaw General Known Issues in HMPRestrictions and Limitations Global Call, IP, and Ipml ConferencingFax Resolved Restrictions and Limitations VoiceDemos Host-based H.323 Protocol StackConfiguring UDP/RTP Port Range Echo Cancellation With Continuous Speech ProcessingEcho Cancellation With Conferencing Compatibility NotesConfiguring T.38 Service Port Range Example Coder Negotiation with Third Party StacksSIP Call Control Solutions Using Multiple NICs Under Heavy LoadsElvtune Using Ioctls Operating System NotesDocumentation3 Updates Release DocumentationIncorrect Correct, Development Software, the following apply , Release Documentation, the following applyInstallation Documentation Operating Software DocumentationHost Media Processing Diagnostics Guide Development Software Documentation Original RevisedGlobal Call IP for Host Media Processing Technology Guide Fax Software Reference for Linux and WindowsGlobal Call API for Host Media Processing Library Reference HMP Linux 1.2 Release Update, Rev 05 September 2006September Voice API for Host Media Processing Library Reference Dxmreciottdata „ Description „ Cautions„ Errors „ Example Following example is for Linux applicationsFollowing example is for Windows applications HMP Linux 1.2 Release Update, Rev 05 September 2006September „ See Also Voice API for Host Media Processing Programming Guide Transaction RecordDemonstration Software Documentation Audio Conferencing API for Host Media Processing Demo GuideIP Media Server for Host Media Processing Demo Guide $INTELDIALOGICDIR/demos/IPMediaServerGlobal Call API Demo Guide