is it possible to support bluetooth OBEX?

1,884 views
Skip to first unread message

tainy

unread,
Apr 20, 2009, 11:16:34 PM4/20/09
to Android Linux Kernel Development
Hello everyone!
I know nothing about kernel development, but I have a requirement.

Android dose not support bluetooth OBEX for file transferring, so is
it possible to change the source code of android and compile it for
supporting OBEX in android platform?

thanks in advance!

Jackson Fan

unread,
Apr 22, 2009, 9:21:02 PM4/22/09
to Android Linux Kernel Development
You can, but no need to change kernel.
OBEX is a relatively higher level protocol on top of RFCOMM. Following
Android Bluetooth architecture http://source.android.com/projects/bluetooth-faq,
feature can be either built on BlueZ+OpenOBEX in user space (native),
or even built in pure Java space.

Jackson Fan

unread,
Apr 22, 2009, 9:28:01 PM4/22/09
to Android Linux Kernel Development
To correct. Only for Bluetooth profiles like OPP/FTP, etc, OBEX
communication is based on RFCOMM channel.
Actually OBEX is an general protocol not necessarily bound to
Bluetooth, and can be used for any channel's object transmssion. For
example, one can use TCP/IP to do OBEX transfer as well. It is
reasonable to add such service within Android framework, so that
different user cases can share same functionality.


On Apr 23, 9:21 am, Jackson Fan <xy...@motorola.com> wrote:
> You can, but no need to change kernel.
> OBEX is a relatively higher level protocol on top of RFCOMM. Following
> Android Bluetooth architecturehttp://source.android.com/projects/bluetooth-faq,
> feature can be either built on BlueZ+OpenOBEX in user space (native),
> or even built in pure Java space.
>
> On Apr 21, 11:16 am, tainy <tainy.zh...@gmail.com> wrote:
>
>
>
> > Hello everyone!
> > I know nothing about kernel development, but I have a requirement.
>
> > Android dose not support bluetooth OBEX for file transferring, so is
> > it possible to change the source code of android and compile it for
> > supporting OBEX in android platform?
>
> > thanks in advance!- Hide quoted text -
>
> - Show quoted text -

tainy

unread,
Apr 22, 2009, 11:46:57 PM4/22/09
to Android Linux Kernel Development
Thank you Jackson Fan!

According to android bluetooth architecture, Java API will be provided
to support GAP and RFCOMM..
So, I can use RFCOMM api to fulfill file transferring ? is GAP API
enough for that task?

and before those apis provided, what can i do to transfer something
between android devices and other bluetooth devices? Sorry that I am
not clear about the way you sai, how to do it in a native way? and in
pure java space need Java API provided?

thanks!

tainy

On 4月23日, 上午9时21分, Jackson Fan <xy...@motorola.com> wrote:
> You can, but no need to change kernel.
> OBEX is a relatively higher level protocol on top of RFCOMM. Following
> Android Bluetooth architecturehttp://source.android.com/projects/bluetooth-faq,
> feature can be either built on BlueZ+OpenOBEX in user space (native),
> or even built in pure Java space.
>
> On Apr 21, 11:16 am, tainy <tainy.zh...@gmail.com> wrote:
>
>
>
> > Hello everyone!
> > I know nothing about kernel development, but I have a requirement.
>
> > Android dose not support bluetooth OBEX for file transferring, so is
> > it possible to change the source code of android and compile it for
> > supporting OBEX in android platform?
>
> > thanks in advance!- 隐藏被引用文字 -
>
> - 显示引用的文字 -

Erin Yueh

unread,
Jun 18, 2009, 11:13:15 PM6/18/09
to Android Linux Kernel Development
Hi there,

I am very interested in OBEX file sharing via bluetooth in Android.
After reading bluetooth spec, related source code and above emails, I
finally understand how to make it in a native way. In the protocol
stack, RFCOMM is bound to L2CAP and OBEX is bound to RFCOMM. Check
Android bluetooth architecture image, we can see RFCOMM is implemented
in bluez. It means we can use RFCOMM protocol to connect with two BT
devices. Therefore, I use openobex + obexpushd to support OBEX in
Android. Both openobex and obexpushd are c programs, so I made some
Android make files to build it. I only tried it in Android Dev Phone,
and it works on both receiving and receiving OBEX file via BT.

OBEX (object exchange) is like client-server programming. One BT
device is a server to receive files and the other one is a client to
send files. For example, I run obexpushd in Android Dev phone, and it
becomes an OBEX server. It would start to LISTEN rfcomm connections.
Then you can use other BT devices to send files to this phone.
Furthermore, I can run obexftpd in Android Dev phone, and it becomes a
client. It would CONNECT with a rfcomm connection and it can send file
to that connection.

I wrote my experiment in my blog. If you have interest, perhaps you
may visit it. http://i-miss-erin.blogspot.com/2009/06/bluetooth-obex-file-sharing-in-android.html

Regards,
Erin

On Apr 23, 11:46 am, tainy <tainy.zh...@gmail.com> wrote:
> Thank you Jackson Fan!
>
> According to android bluetooth architecture, Java API will be provided
> to support GAP and RFCOMM..
> So, I can use RFCOMM api to fulfill file transferring ? is GAP API
> enough for that task?
>
> and before those apis provided, what can i do to transfer something
> between android devices and other bluetooth devices? Sorry that I am
> not clear about the way you sai, how to do it in a native way? and in
> pure java space need Java API provided?
>
> thanks!
>
> tainy
>
> On 4月23日, 上午9时21分, Jackson Fan <xy...@motorola.com> wrote:
>
> > You can, but no need to change kernel.
> >OBEXis a relatively higher level protocol on top of RFCOMM. Following
> > Android Bluetooth architecturehttp://source.android.com/projects/bluetooth-faq,
> > feature can be either built on BlueZ+OpenOBEX in user space (native),
> > or even built in pure Java space.
>
> > On Apr 21, 11:16 am, tainy <tainy.zh...@gmail.com> wrote:
>
> > > Hello everyone!
> > > I know nothing about kernel development, but I have a requirement.
>
> > > Android dose not support bluetoothOBEXfor file transferring, so is
> > > it possible to change the source code of android and compile it for
> > > supportingOBEXin android platform?

Nick Pelly

unread,
Jun 23, 2009, 1:00:09 PM6/23/09
to android...@googlegroups.com
Hi Erin,

Just wanted to say good work on your open obex hacking!

Nick

2009/6/18 Erin Yueh <erin...@gmail.com>
Reply all
Reply to author
Forward
0 new messages