280 likes | 394 Views
User Application. AoH API. GP API. AoB API. cPCI PrimeNet MM. IP NIC. Inline MM PCI. Digital Gateway. Daytona MM PCI. PrimeNet MM PCI. Requests. Data & Events. Low Level API Calls. Low Level API Calls. Group. Signaling. Channel. Media Processing. System. Conference.
E N D
User Application AoH API GP API AoB API cPCI PrimeNet MM IP NIC Inline MM PCI Digital Gateway Daytona MM PCI PrimeNet MM PCI Requests Data & Events Low Level API Calls Low Level API Calls
Group Signaling Channel Media Processing System Conference Call Progress and Analysis Call
Configuration Files PKX_SYSTEM_Open Group Definitions System PKX_ SYSTEM_GetConfig PKX_ GROUP_GetHandle Group Group Group Group PKX_ CHANNEL_GetHandle Channel Channel Channel Channel Channel Channel Channel Channel Channel Channel Channel Channel Channel Channel Channel Channel PKX_ CHANNEL_FullDuplexConnect Connection PKX_ CALL_GetChannel PKX_ CONF_AddMember Conference Media Processing Call Call Call
Media Processing System 1 N N N Connection 2 0/1 1 N Group Channel 1 N 0/1 0/1 Conference Call
Open Start Disabled Enabled Running Close Stop Group and channel handles can be retrieved Call events can occur at any time
Root Configuration File Included Configuration File AoH Configuration File AoB Configuration File Included Configuration File Included Configuration File Included Configuration File
[groups] group0=group name1 group1=group name2 [group name2] type=group type product=aoh channels=AoH group name [group name1] type=group type product=aob channels=type0 pikagp.cfg AoB Configuration file [product] [group type] [board] AoB=filename type0=AoB group name1 board0=board name1 AoH=filename board1=board name2 type1=AoB group name2 board2=board name3 [AoB group name1] interface0=board0,port range interface1=board1,port range [board name3] id=board id serial=board serial number [board name2] id=board id [AoB group name2] serial=board serial number interface0=board1,port range [board name1] interface1=board2,port range id=board id serial=board serial number AoH Configuration file
[ring_pattern] ringpattern0=ring name 1 ringpattern1=ring name 2 [ring name2] [call progress analysis name] states=n state0=duration faxdetect=no state1=duration modemdetect=no answeringmachinedetect=no staten-1=duration [ring name1] pattern0=pattern name1 states=m pattern1=pattern name2 state0=duration pattern2=pattern name3 state1=duration pattern3=pattern name4 statem-1=duration [tone_detection] tone0=291,24,485.1,-32.0 tone1=72,24,1300.0,-46.0 tone2=72,24,1500.0,-46.0 group0=0.88,0.01,80,80,2,1,2 group1=0.90,0.01,250,80,1,0 pikagp.cfg [group name1] [tonepatterns] tone_pattern0=tone pattern 1 type=group type tone_pattern1=tone pattern 2 product=aob tone_pattern2=tone pattern 3 channels=type0 callpa=call progress analysis name [tone pattern 1] repeat=r cadences=n cadence0=0 cadence1=1 cadence2=0 cadencen-1=2 [tone_generation] tone0=tone name 1 tone1=tone name 2 tone2=tone name 3 [pattern name1] type=pattern type [tone name 1] cadences=n on=80 states=m off=80 state0=2000 frequency1=941 statem-1=4000 amplitude1=-17.0 frequency2=1633 amplitude2=-15.0
[My group element] product=aoh type=isdn channels=isdn3 [My other group] product=aob type=sip channels=sip0 [isdn] isdn0=isdn_interface_3 isdn1=isdn_interface_7 isdn2=isdn_interface_2 isdn3=isdn_interface_1 isdn4=isdn_interface_4 [sip] sip0=aoh_sip_group AoH Product Configuration File Root Configuration File AoB Product Configuration File [isdn] isdn0=isdn_interface_5 isdn1=isdn_interface_6 isdn2=isdn_interface_8 isdn3=isdn_interface_9 isdn4=isdn_interface_0 [sip] sip0=aob_sip_group
Start PKX_SYSTEM_Start Start media and call processing PKX_SYSTEM_Open Open the system object Wait for event PKX_SYSTEM_WaitOnEvent PKX_SYSTEM_GetConfig Retrieve group names Initialize user application internal structures System shutdown event? More groups? End No Yes Yes No PKX_GROUP_GetHandle Retrieve group handle Timeout event? Yes No Process event PKX_GROUP_GetConfig Retrieve group type and number of channels
PKX_CALL_Make() Initiate a call Wait for event Switch on call event type CALL_DIALING CALL_PROCEEDING CALL_ALERTING CALL_CONNECTED Process dialling Process call proceeding Process alerting Process call answered
Wait for event Switch on Event type GROUP_INCOMING_CALL CALL_ALERTING CALL_ANSWERED CALL_CONNECTED PKX_CALL_ Answer() PKX_CHANNEL_ HalfDuplexConnect() Accept the call Destination ringing, answer the original call Original call answered, connect destination ringing to original caller PKX_CHANNEL_ FullDuplexConnect() Connect the calls PKX_CALL_ Accept() PKX_CALL_ Make() Call destination
Wait for event Switch on Event type GROUP_INCOMING_CALL CALL_ANSWERED Process incoming call Answer the call PKX_CALL_Answer PKX_CHANNEL_PlayAddData PKX_CHANNEL_Play PKX_CHANNEL_CollectDigits
Disconnect the call PKX_CALL_Drop Wait for event Switch on event type GROUP_INCOMING_CALL CALL_DISCONNECTED CALL_DROPPED CHANNEL_READY Reject the call Release the call Release the call Add channel to list of available channels PKX_CALL_Reject PKX_CALL_Release PKX_CALL_Release
Get bypass resource information PKX_[CHANNEL | CONFERENCE]_GetBypassInfo() Enable bypass PKX_[CHANNEL | CONFERENCE]_EnableBypass () Switch on type PKX_PRODUCT_LIBRARY_AOB PKX_PRODUCT_LIBRARY_AOH Perform AoB bypass functions Perform AoH bypass functions PK_xxx () PKH_xxx () PKX_[CHANNEL | CONFERENCE]_DisableBypass () Disable bypass
GP API function call Switch on product type Perform AoH function Perform AoB function AoH Thread Queue AoB Thread Queue Retrieve event from queue Process event Inject result event in main queue Retrieve event from queue Process event Inject result event in main queue Main Thread Queue Retrieve event from queue Process event
AoH Thread Main Thread Queue PKX_SYSTEM_ WaitOnEvent() Process event Retrieve event from queue PKX_SYSTEM_ InjectEvent() User Application AoB Thread
Outgoing Calls PKX_EVENT_CALL_ DROPPED NULL PKX_EVENT_CALL_ DISCONNECTED PKX_CALL_Make() PKX_EVENT_ CHANNEL_ IN_USE PKX_EVENT_ CHANNEL_READY PKX_CALL_Release() Dialing Idle PKX_CALL_Make() on a channel that is in use Remote reject Low level or protocol resources released Remote proceeding indication Remote alerting indication Disconnected PKX_CALL_Drop() Remote disconnect indication Proceeding PKX_CALL_Drop() Remote disconnect indication PKX_CALL_Drop() Remote disconnect indication PKX_EVENT_ CALL_CONNECTED Remote alerting indication Connected Alerting Remote answered indication PKX_EVENT_CALL_ ALERTING
Incoming Calls PKX_EVENT_ CHANNEL_ IN_USE PKX_EVENT_CALL_ DROPPED Call detected (CAS, Trunks) NULL PKX_EVENT_CALL_ DISCONNECTED PKX_EVENT_ CHANNEL_READY Detected PKX_CALL_Release() Idle Call detected (SIP, ISDN) PKX_EVENT_ CHANNEL_READY Dialing information received PKX_EVENT_GROUP_ INCOMING_CALL Low level or protocol resources released PKX_EVENT_ CHANNEL_ IN_USE PKX_CALL_Reject() Offered Disconnected PKX_CALL_Answer() PKX_CALL_Accept() PKX_CALL_Drop() Remote disconnect PKX_CALL_Drop() Remote disconnect PKX_EVENT_ CALL_ANSWERED Alerting Connected PKX_EVENT_CALL_ ACCEPTED PKX_CALL_Answer()
PKX_EVENT_CHANNEL_DOWN PKX_EVENT_CHANNEL_READY PKX_EVENT_CHANNEL_IN_USE Low level detection of a channel returning to service PKX_CALL_Make() PKX_EVENT_GROUP_INCOMING_CALL Down Ready In use Low level detection of a channel going out of service PKX_CALL_Reject() PKX_CALL_Drop() Remote disconnect indication
User Application GUI Processing Thread User Application Event Processing Thread GrandPrix API GrandPrix API GP Main GP Main AoB API AoH API GP Timer Thread Product Interface AoH Product Thread AoB Product Thread
pika.com Registrar Server John@pika.com ? Register John@pika.com (5.6.7.8) John@pika.com John@pika.com John@pika.com John@pika.com John@pika.com John@pika.com (5.6.7.8) (5.6.7.8) (5.6.7.8) (5.6.7.8) (5.6.7.8) Mary@yahoo.com (1.2.3.4) 2 4 5 1 PKX_EVENT_GROUP_ INCOMING_CALL 6 8 GrandPrix SIP Local User Agent pika.com Proxy Server 3 7
Add Buffer (Last buffer flag set) Scenario 3 Scenario 2 Scenario 1 PlayFile Play Play PKX_ERROR_CHANNEL_AUDIO_DATA_NOT_AVAILABLE PKX_EVENT_CHANNEL_DONE_PLAY PKX_EVENT_CHANNEL_DONE_PLAY PKX_EVENT_CHANNEL_DATAREADY_PLAY PKX_EVENT_CHANNEL_DATAREADY_PLAY Add Buffer (Last buffer flag set) Add Buffer (Last buffer flag set) Add Buffer (Last buffer flag set) Scenario 5 Scenario 4 Add Buffer Add Buffer Stop Play Play Add Buffer Add Buffer Add Buffer Add Buffer PKX_EVENT_CHANNEL_DONE_PLAY PKX_EVENT_CHANNEL_STOPPED_PLAY PKX_EVENT_CHANNEL_DATAREADY_PLAY PKX_EVENT_CHANNEL_DATAREADY_PLAY PKX_EVENT_CHANNEL_DATAREADY_PLAY PKX_EVENT_CHANNEL_DATAREADY_PLAY PKX_EVENT_CHANNEL_DATAREADY_PLAY PKX_EVENT_CHANNEL_DATAREADY_PLAY
Add Buffer (Last buffer flag set) Scenario 7 Add Buffer Play Add Buffer Add Buffer PKX_EVENT_CHANNEL_DONE_PLAY PKX_EVENT_CHANNEL_DATAREADY_PLAY PKX_EVENT_CHANNEL_DATAREADY_PLAY PKX_EVENT_CHANNEL_DATAREADY_PLAY PKX_EVENT_CHANNEL_DATAREADY_PLAY Add Buffer (Last buffer flag set) Add Buffer (Last buffer flag set) Scenario 6 Add Buffer Termination condition met Play Add Buffer Add Buffer PKX_EVENT_CHANNEL_TERM_xxx PKX_EVENT_CHANNEL_DATAREADY_PLAY PKX_EVENT_CHANNEL_DATAREADY_PLAY
Scenario 1 Scenario 2 RecordFile Record RecordGetData Termination condition met RecordGetData RecordGetData RecordGetData PKX_EVENT_CHANNEL_STOPPED_RECORD PKX_EVENT_CHANNEL_TERM_xxx PKX_EVENT_CHANNEL_DATAREADY _RECORD PKX_EVENT_CHANNEL_DATAREADY _RECORD PKX_EVENT_CHANNEL_DATAREADY_RECORD PKX_EVENT_CHANNEL_DATAREADY_ RECORD Scenario 3 Record Stop RecordGetData PKX_EVENT_CHANNEL_STOPPED_RECORD PKX_EVENT_CHANNEL_DATAREADY _RECORD PKX_EVENT_CHANNEL_RECORD_OVERFLOW PKX_EVENT_CHANNEL_DATAREADY _RECORD PKX_EVENT_CHANNEL_DATAREADY_RECORD PKX_EVENT_CHANNEL_DATAREADY_ RECORD PKX_EVENT_CHANNEL_DATAREADY_RECORD PKX_EVENT_CHANNEL_DATAREADY_ RECORD
DTMF 1 DTMF 9 DTMF 2 DTMF 3 DTMF 6 DTMF 4 DTMF 8 DTMF 5 DTMF 7 3 4 4 3 4 3 3 4 6 6 3 8 8 7 7 1 2 1 2 1 2 1 1 2 5 1 2 5 2 5 1 6 5 5 9 6 5 6 PKX_EVENT_CHANNEL_DTMF 7 PKX_EVENT_CHANNEL_DTMF PKX_EVENT_CHANNEL_DTMF PKX_EVENT_CHANNEL_DTMF PKX_EVENT_CHANNEL_DTMF PKX_EVENT_CHANNEL_DTMF PKX_EVENT_CHANNEL_DTMF PKX_EVENT_CHANNEL_DTMF PKX_EVENT_CHANNEL_DTMF CollectDigits maxDigits = 5 CollectDigits maxDigits = 3 CollectDigits maxDigits = 3 GetDigits (numDigits = 4) Stop PKX_EVENT_CHANNEL_TERM_MAX_DIGITS PKX_EVENT_CHANNEL_TERM_MAX_DIGITS Internal Digit Buffer PKX_EVENT_CHANNEL_STOPPEN_COLLECTDIGITS 7
State Ignored First Cadence Second Cadence Call Progress Analysis Starts First State Timing Starts Second State Timing Starts Call Progress Analysis Matches Pattern PSTN Ring Patterns User App Call Progress Analysis
Tone Detected Debounce Period Tone Detected Debounce Period Tone Absent Debounce Period PKX_EVENT_CHANNEL_TONE_OFF PKX_EVENT_CHANNEL_TONE_ON Nominal Frequency Energy Level dB A Detector Level Threshold C B D Frequency Filter Bandwidth