FW: Problem in creating conference

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Dear Srivatsan,

Any updates on this issue?

Thanks & Regards,
- Senthil

-----Original Message-----
From: pjsip-bounces@xxxxxxxxxxxxxxx [mailto:pjsip-bounces at lists.pjsip.org]
On Behalf Of senthil at gotouchpoint.com
Sent: Tuesday, June 09, 2009 8:57 PM
To: pjsip at lists.pjsip.org
Subject: Re: Problem in creating conference


Dear Srivatsan,

Thanks for the valuable information. Conference is working fine now. By the
way I'm using asterisk PBX and trying to connect conference. Just look into
the modifications mentioned below and let me know whether I'm doing
correct. 

I've inculded the following in extensions.conf file:

[TPS]

exten => rooms,1,MeetMe(arul|bhavani|rajeev)


Also I've included the following in meetme.conf:

[rooms]

conf => arul,bhavani,rajeev

Onceagain thanks for the help.

Thanks & Regards,
- Senthil

Original Message:
-----------------
From: Srivatsan Deenadayalan srivatsan@xxxxxxxxxxx
Date: Mon, 08 Jun 2009 21:02:35 +0530
To: senthil at gotouchpoint.com, pjsip at lists.pjsip.org
Subject: Re: Problem in creating conference


<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
  
</head>
<body text="#000000" bgcolor="#ffffff">
<pre wrap="">Senthil,

I suggest to just dial all the calls first and leave rest to take care by
call back methods. Just connect the ports in call back methods and will
work fine.

Here is how i do in my application,

1. Getting the SIP address from user (multiple address).
2. Check the address valid.
3. Make call using each valid address and get the call ID.
4. Rest would be taken care by <b>on_call_media_state</b> call back method.
5. Based on call ID you can track each call and do necessary operations.

Note: You need to make <b>max_calls</b> to 3. Default is 2 in PjSIP.

Suggestion : To have more members in in conferencing, i suggest to try
<b>Asterisk, </b>i have connected upto 15 mobiles to the conference room.
This will help better performance of mobile since audio mixing is happening
in server itself. Also u cannot feel the audio lag.
 
Here is the code snippet which works fine for me.

1. For each time a call gets active, i am establishing full duplex sound.

/* Callback called by the library when call's media state has changed */
static void on_call_media_state (pjsua_call_id call_id)
{
pjsua_call_info ci;

pjsua_call_get_info (call_id, &ci);

if ( ci.media_status == PJSUA_CALL_MEDIA_ACTIVE)
	{
	
	/*
	// When media is active, connect call to sound device.
	pjsua_conf_connect (ci.conf_slot, 0);
	pjsua_conf_connect (0, ci.conf_slot);
	*/

	pj_status_t status;
	pjsua_conf_port_id id[PJSUA_MAX_CONF_PORTS];
	unsigned c, i, j;

	c = PJ_ARRAY_SIZE( id );
	status = pjsua_enum_conf_ports (id, &c);

	if ( status != PJ_SUCCESS)
		c = 0;

	for (i = 0; i < c; i++)
		{
		for (j = 0; j < c; j++)
			{
			if ( i != j)
				{
				pjsua_conf_connect (id[i], id[j]);
				}
			}
		}
	}
}
</pre>
<br>
<a href="mailto:senthil at gotouchpoint.com"
class="moz-txt-link-abbreviated">senthil at gotouchpoint.com</a> wrote:
<blockquote type="cite"
cite="mid:380-22009618143956282 at M2W103.mail2web.com">
  <pre wrap="">Dear All,

I'm trying to perform conference having totally three members, but it is
not working. Please find the code snippet below. Can anyone please look
into the code and input some clue to get it work.

static void confconnect(pjsua_call_id call_id)
 {
     pjsua_call_info ci[4];

     pjsua_call_get_info(call_id, &ci[call_id]);

// When media is active, connect call to sound device.
     if (ci[call_id].media_status == PJSUA_CALL_MEDIA_ACTIVE)
      {
         pjsua_conf_connect(ci[call_id].conf_slot, 0);
         pjsua_conf_connect(0, ci[call_id].conf_slot);
      }
      else
       cout<<"\n\n\n\n\t\t\t\t\t*******Error in Media Status***********";
 }


/* Conference Call */
  
void pjconfcall()
{
        char *confuri1[0];
        char *confuri2[0];
        pjsua_call_id call_id1;
        call_id1 = 1;

      for(;;)
       {  
        cout<<"\nDial the SIP number-> ";
        cin>>confuri1[0];
 // Check for valid SIP URL
        status = pjsua_verify_sip_url(confuri1[0]);
        if (status != PJ_SUCCESS)
          cout<<"\nInvalid URL!!!! ";
        else
          break;
        }
        pj_str_t uri = pj_str(confuri1[0]);
        status = pjsua_call_make_call(acc_id, &uri, 0, NULL, NULL, NULL);
          if (status != PJ_SUCCESS)
            error_exit("Error making conference call", status);
          else
           {
            confconnect(call_id1);
            call_id1++;
           }
        sleep(5);

 // Now place second call
      for(;;)
       {  
        cout<<"\nDial the SIP number-> ";
        cin>>confuri2[0];
   // Check for valid SIP URL
        status = pjsua_verify_sip_url(confuri2[0]);
        if (status != PJ_SUCCESS)
          cout<<"\nInvalid URL!!!! ";
        else
          break;
        }
    pj_str_t uri1 = pj_str(confuri2[0]);
        status = pjsua_call_make_call(acc_id, &uri1, 0, NULL, NULL, NULL);
          if (status != PJ_SUCCESS)
            error_exit("Error making second conference call", status);
          else
           {
            confconnect(call_id1);
           }
}

Thanks & Regards,
- Senthil

--------------------------------------------------------------------
mail2web.com - MicrosoftR Exchange solutions from a leading provider -
<a href="http://link.mail2web.com/Business/Exchange";
class="moz-txt-link-freetext">http://link.mail2web.com/Business/Exchange</a>



_______________________________________________
Visit our blog: <a href="http://blog.pjsip.org";
class="moz-txt-link-freetext">http://blog.pjsip.org</a>

pjsip mailing list
<a href="mailto:pjsip at lists.pjsip.org"
class="moz-txt-link-abbreviated">pjsip at lists.pjsip.org</a>
<a href="http://lists.pjsip.org/mailman/listinfo/pjsip_lists.pjsip.org";
class="moz-txt-link-freetext">http://lists.pjsip.org/mailman/listinfo/pjsip_
lists.pjsip.org</a>
  </pre>
</blockquote>
<br>
<pre cols="72" class="moz-signature">-- 
Regards,
Srivatsan.D,
</pre>
</body>
</html>

--------------------------------------------------------------------
mail2web - Check your email from the web at
http://link.mail2web.com/mail2web



_______________________________________________
Visit our blog: http://blog.pjsip.org

pjsip mailing list
pjsip at lists.pjsip.org
http://lists.pjsip.org/mailman/listinfo/pjsip_lists.pjsip.org




[Index of Archives]     [Asterisk Users]     [Asterisk App Development]     [Linux ARM Kernel]     [Linux ARM]     [Linux Omap]     [Fedora ARM]     [IETF Annouce]     [Security]     [Bugtraq]     [Linux]     [Linux OMAP]     [Linux MIPS]     [Linux API]
  Powered by Linux