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

RE: [bluetooth-dev] bt stack function calls




This is possible as of today using the functions in the apps/bluetooth/experimental directory.

For an example of a small application that does stack only initialization you can 
see the btinit.c which works in both usermode stack and kernel mode stack.

When compiled for usermode stack bt_if.c interfaces kernel code using direct
function calls and when compiled 'normally' it uses ioctls.

In order to compile for usermode stack you need to define BT_USERSTACK 
(not BTD_USERSTACK as in the old code...) in your makefile (this will be 
added later on, for now look in the apps/bluetooth/userstack Makefile).

There are still more to do in order to make _all_ functions work 
seemlessly together with both usermode stack and kernel stack but the most 
important stuff is there. You can see for yourself in bt_if.c what need to be 
done. However, as stated in the kernel readme file the usermode stack is still 
only intended for testing purposes and works a bit differently compared to 
the kernel mode stack.

brgds
Mattias

> -----Original Message-----
> From: Patrick Clauberg [mailto:pat@xxxxxxx.de]
> Sent: den 17 april 2001 16:03
> To: bluetooth-dev@xxxxxxx.com
> Subject: [bluetooth-dev] bt stack function calls
> 
> 
> Hi everybody,
> 
> as far as I saw the btd source, even on top of the lower 
> layer, I have to
> distinguish if I write a usermode or a kernel mode app.
> 
> I think some time ago I saw a mail on this list where someone 
> was talking
> about a library for the stack.
> 
> I personally would need direct access to the l2cap and hci 
> functions, and
> probably i am not alone.
> 
> 
> I would like to write an application, where I can step by 
> step inititialize
> the device, do an inquiry, establish a baseband-link and an 
> l2cap channel
> and send data over that channel, without having to care about that
> kernel/usermode thing, just using  the functions of the 
> different layers.
> 
> Is that possible right now in any way?
> 
> Can it be made possible especcialy in kernel mode, or are there some
> restrictions due to the fact that there is no straight access 
> to the kernel
> module ?
> 
> Will there be problems with the callback functions?
> 
> 
> Bye and thanks
> 
> Patrick
> 
> 
> -
> 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