Technical Helpweb

- more articles

SDK & CAPI: Using Analog 4P card

The Diva Analog 4P is detected as a single controller with 4 bearer channels corresponding to the 4 ports, respectively.

Software developers can develop applications based on Diva Media Boards using either CAPI interface or the Diva SDK. 

Some applications may need to address a specific port, and not the controller itself, when issuing a CONNECT_REQ.

Developing using the CAPI interface, the selection of the port (i.e. the channel) requires the definition of the Channel ID Information Element, as indicated in the piece of code below: 


 

byte iepattpri[]={04,00,3,0xa9,0x83,0x85}; 
byte ie[20];
byte size;

// 'chan' = channel number 1..n

cx = (byte)chan & 0x7F;
ie[0] = size = sizeof(iepattpri);
CopyMemory(&ie[1],iepattpri,size);
ie[6] = 0x80 | cx;


When using the Diva SDK, the only addition to the code is the channel selection function below:

DivaCallPropertyValue *value = (DivaCallPropertyValue*) ie; 
res = DivaSetCallProperties( divacall, DivaCPT_B_ChannelInfo, value, size+1);


Note that the Information Element used for an Analog card is the same as that for a BRI ISDN adapter.




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:

First published: 09-Jun-2006
Last published: 16-May-2011
Open access: Product rule: ; Page rule: Auto

Service Center Logon