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

RE: [bluetooth-dev] direct l2cap access in kernel mode

> -----Original Message-----
> From: Dennis Hromin [mailto:dhromin@xxxxxxx.edu]
> Sent: den 2 april 2001 07:01
> To: bluetooth-dev@xxxxxxx.com
> Subject: Re: [bluetooth-dev] direct l2cap access in kernel mode
> Hi,
>   I too have an application that only needs to access the 
> l2cap layer only 
> (as far as i can tell). All i need to do is establish a 
> connection with 
> another node and transfer a very small amount of data. I am 
> using the stack 
> in usermode as that seems to be much easier and my application is not 
> critical at this point. I am not an expert programmer and 
> need something 
> quick and easy to use, such as a direct function call rather 
> then using IOCTLs.

The easiest would probably be for you to only open the baseband and
use that to transfer data.

try 'bb_conn <BD>' in usermode stack

to send data create a bt_tx_buf in a similar manner as l2cap functions does
(e.g l2cap_connect_req) and use hci_send_data(bt_tx_buf *buf) to send the buffer.

I guess you have to add an option in the usermode stack to be able to control it
from there. 

>   I have been able to use the functions:  (from the btd.c 
> sample application)
>      l2cap_create_con(tmp_bd);
>      lp_connect_req(tmp_bd);
>   These functions only establish a Baseband connection. How 
> do I continue 
> if I want the remote end to send a few bytes of data to this master 
> (client) that just established the connection?
>   Are there any suggestions of what functions or sequence of 
> events (based 
> on the axis OpenBT stack) I could/should use? I know there are other 
> functions such as l2cap_recieve_data..etc.. but which is the 
> correct one to 
> use on the master and slave?
>    Thanks,
>    Dennis
> >For my application, I need to access the l2cap layer 
> directly; I have no 
> >need for features added by RFCOMM or higher layers.  I also 
> need to allow 
> >multiple devices to access the bluetooth interface 
> simultaneously, so I 
> >will need to use the stack in kernel mode.  As it sits in 
> cvs (as of a few 
> >days ago when I last updated), the OpenBT stack does not 
> allow direct 
> >access to L2CAP when running in kernel mode.  Do you intend 
> to add support 
> >for this eventually?   When the stack was designed, what

This might be added eventually yes.


> -
> To unsubscribe from this list: send the line "unsubscribe 
> bluetooth-dev" in
> the body of a message to majordomo@xxxxxxx.com
To unsubscribe from this list: send the line "unsubscribe bluetooth-dev" in
the body of a message to majordomo@xxxxxxx.com