linux-bluetooth.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* Problems with bt_io_listen
@ 2010-03-25 14:45 José Antonio Santos Cadenas
  2010-03-25 15:22 ` Luiz Augusto von Dentz
  0 siblings, 1 reply; 3+ messages in thread
From: José Antonio Santos Cadenas @ 2010-03-25 14:45 UTC (permalink / raw)
  To: linux-bluetooth

Hi all,

We are developing an implementation of HDP and MCAP for bluez. We are triying 
to perform many connections between two devices but when we make the second 
connection it is not created correctly.

We are using a defer connection (we passed a confirm callback to the 
bt_io_listen function) and we think that we are missing something but  we 
can't find what. If we used the connection callback (not defer) all the 
connections are done successfully.

We are listening with the following code:

static void confirm_cb(GIOChannel *chan, gpointer user_data)
{
	...
	node->chan = g_io_channel_ref(chan);
	...
	/* All is ok */
	return;
drop:
	/* Connection refused */
	g_io_channel_shutdown(chan, TRUE, NULL);
}

....
chan = bt_io_listen(BT_IO_L2CAP, NULL, confirm_cb, NULL,
				NULL, &gerr,
				BT_IO_OPT_SOURCE_BDADDR, &src,
				BT_IO_OPT_PSM, 0x1001,
				BT_IO_OPT_SEC_LEVEL, BT_IO_SEC_MEDIUM,
				BT_IO_OPT_INVALID);
...

Any ideas?

Regards and thank.

Jose.

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2010-03-25 16:13 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2010-03-25 14:45 Problems with bt_io_listen José Antonio Santos Cadenas
2010-03-25 15:22 ` Luiz Augusto von Dentz
2010-03-25 16:13   ` sancane

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).