lunes, 24 de noviembre de 2008

5th/6th Milestone, Phase 1 reached.

It has been since our first Google Summer of Code, back in spring 2007, that I wanted to write this post.

After achieving l2cap signalling communication in both ways, the test was to force the mobile phone to initiate any kind of communication with Haiku. Concretelly it was a SDP(service discovery protocol) session, in which the mobile asks Haiku, about which bluetooth services is Haiku providing.

There are some signals that needed to be replied and some issued by our side, after getting the first portion of data that actually belongs to the next upper protocol(SDP in this case).

Here in the kernel syslog we can see some traces:



Basically these 2 lines with HEX data, is the SDP packet traced at l2cap Layer. The packet is fragmented in 2 ACL frames so somehow the ACL segmentation could be tested here.  Eventually the target was to drop this packet, to an application that was creating a L2cap socket with the SDP psm(protocol service multiplexer).

So a small application was created faking a SDP server(mobile was acting as a SDP client) creating a l2cap socket listening in the SDP psm(similar to tcp/ip ports) and here we could see the first read of that app:




My mobile was actually freaking out not receiving any SDP response after all the successful pairing and the l2cap signalling configuration. Having many times to remove the Battery, or wait around 10 minutes to expire all connections.

So thats all for the moment. The  proposal document  is updated. In another post I will comment about what is my plan post-Phase1/Arce.

Thanks to all for support, but... there is still more to come:)

lunes, 17 de noviembre de 2008

L2cap Signaling / 2 ways

Already passed one month. Was expecting to be back at starting the month, but amazingly was sent again again last week.

The responsed l2cap signals Haiku was sending to the test mobile phone where a bit malformed. Wrong size in the ACL and L2cap fields and a misunderstanding the source and destination Channel ID.

After some KDL's and playing with the layers interconnection, the remote device understood my l2cap response signal and the phone replied requesting to initiate a configuration session....

near near...

martes, 14 de octubre de 2008

1 month shift (Sorry)

As some of you know the Bluetooth bounty had 1st November as Deadline.

We are still behind schedule and the status prevision given the last week progress is that the next milestone could be reached in the following 2 weeks(counting this one).

So we had 1 week free as security, but seems is not gonna be enough, I was expecting a business trip sooner or later, and it arrived NOW which will keep me occupied the rest of the month.

I am gonna be in a German Town/City called Kronach somewhere around Munich according to the flight my company booked. It is really a pity that I dont have any development env setup in a laptop because it is gonna be boring, as I dont really know much people around...

Therefore I am forced to shift the bounty 1 month, sorry.

sábado, 11 de octubre de 2008

Call to Arms: Most Complete BeOS Software Database

Karl from Haikuware has done a prodigious job, collecting all software around the www related with BeOS. Please read his post here.

http://www.haikuware.com/downloads/registered/haikuware.zip

He posted here the list of the still missing software. So I beg you all to look into those CDs and all those BeOS software archive files and let them arrive to Karl.

Some requested the list in txt format get it here. (Formatted thanks to Meanwhile)

If you even have its sources or are the developer of the app, I encourage you to use the chance to opensource your app to ensure it stays in Haiku Forever.

I propose community to share its archive/sources during the next week in BeShare. I will try to be online as much as possible.

Thanks to all

martes, 7 de octubre de 2008

L2cap signalling / 1 way

The testing of all the l2cap lower layer has started.

After pairing, we are ready to receive ACL packets, that after reassembling them, become L2cap frames, which the ones of type G, are already user/application data.

But first of all are the C type frames (signals), which will establish a L2cap Channel, this channel will be the carrier of  those G type frames.

So after theory the facts: the ACL data is reassembled(not well tested as the first L2CAP frame I got could be fitted in 1 ACL packet :-/) and forwarded to L2CAP layer parsing it and handling the first L2cap C Frame, which is the major achievement these last days.

This first signal requests us to open a channel, so the next step is to check whether there is a l2cap bound socket for accepting it and replying with another signal frame, which will need to be segmented(if big enough) and sent as ACL...

sábado, 27 de septiembre de 2008

Whisper BeNet documentation released

The Documentation written to convert the old version of BeNet into Whisper has been released in the OsDrawer project page.

It is an extract of the whole tesis written in 2004 in PDF format.

The sources are not yet committed. But I have been collecting them and ensure that they build and all resources are available(bitmaps). I still need to make a full review of all code to avoid any legal issue.

Whisper BeNet runs in ZETA 1.2, due to Haiku proximity there is no plan(for me) to make efforts to bring it back to R5 but to switch to Haiku directly.

The sources will be available during November.

miércoles, 24 de septiembre de 2008

Bluetooth update & Hardware donation

It has been a long time without any update on the bluetooth Stack.

During these 2 months all the activity has been centered in implementing the L2cap protocol (and of course, going to the beach). The analog protocol in a TCP/IP Stack would be the TCP and UDP protocol, So it is not a trivial task.

The good point in all this is that after having some license conversation with the main FreeBSD developer(Maksim Yevmenkin) and the Haiku developers maillist, I am reusing some BSD code adapted to the Haiku kernel API, which is saving a lot of development time.

I divided the l2cap protocol in 2 sublayers (lower/higher). The whole lower is finished and currently I am completting the higher, which will merge with the final sockets interface accomplishing the last milestone.(FINALLY!)

By other hand Ineed to thank another hardware donation from......


With a huge delay thanking him, Luroh sent me a couple of bluetooth PCMCIA cards and one Wireless. When I got them I was almost ready to stop the development of the stack to code the transport drivers for those  cards, but Haiku hasnt PCMCIA support :(... so something more in my TODO-list. But anyway the cards will be useful as they duplicate the number of bluetooth devices I own.

 Thanks Luroh!

miércoles, 23 de julio de 2008

Pairing! 4th milestone


Yes, another of my fuzzy and unreadeable pics. The camera just run out of batery this time and could not get a better pic.

Remember about Mavin? this time it is added(if readeable) in the Trusted devices list of my phone after passing through a parinig process, typing pincodes and exchanging an encryption key.

In the screenshot can be seen the pincode window for the user(to type the pincode that has to match the phone typed one) and another litte window which is meant to inform that the pairing Connection has been successful.

This time I have to thank Monni that has been sending me patches with some code supporting part of the pairing process :)

domingo, 29 de junio de 2008

ESPAÑA, CAMPEONES


jueves, 12 de junio de 2008

VoIP back to platform?

Since it has been announced the completion of my final studies project, who involved in the URV, Berufsakademıe Karlsruhe and yT, in bebits was released the sources of the application in which Whisper was based BeNet

I was wondering if I was able to publish the thesis document in public. So that may be people try to take it further from the benet sources with the help of the document. The document is explained more or less all steps I did to convert that old version of BeNET to Whisper.

I contacted my university in Spain, but they could not give me all the rights as there were more parts implied. In Karlsruhe more or less they told me I could do whatever I want, but for some reasons I waited to contact the last part, with Bernd Korz. And although this conversation with him happened  several months ago, I got green light!!  And we will not have to start over again, as the final Whisper sources will be released!! thanks again Bernd!
 
So what in Germany was called "Mein Diplomarbeit" will be published sooner or later when I have time to gather the sources and host them somewhere.

For those who dont remember Whisper was an app derived from BeNet who was capable to keep VoIP conversations. It used an own point to point protocol, sort to say it was not following any standard. Which was the bad part as it could not connect to any other server nor application in another platform.

So one of the first steps would be give the application an standard & popular protocol to operate with another people from other platforms. Where in gTalk/libjingle is where my mind is directed to, (being Skype closed source and Jabber sources released also not long ago...).

Something for the lack of news lately...

Was hard to get some old screenshots, yahoo images was better than google this time!



lunes, 28 de abril de 2008

Haiku Bluetooth Stack Release

I promised Andrea a Xmas gift and I have already delayed it enough. So let's zip all we showed in the last posts and give some instructions on how to deal with it. Now the kit has some functionality implemented so it makes more sense a release for people that wants to play a bit with it, As some application as a Preference could be actually written.

Before proceeding please, read this other article about the possible risks.

[инструкция на русском]
[Auf Deutsch]
Installation steps for R5(not tested under Haiku or ZETA):

Install the driver (/h2/h2generic) :

Place the driver in:
/boot/home/config/add-ons/kernel/drivers/bin

And make a link to it, placing it in:
/boot/home/config/add-ons/kernel/drivers/dev/bluetooth

Most likely you dont have the folder, just create it. Ensure your dongle is recognized by the USB stack. Use usb_dev_info command. After this, make sure the device is published correctly by:

$ find /dev/bluetooth/
/dev/bluetooth/
/dev/bluetooth/h2generic
/dev/bluetooth/h2generic/0

If not, a restart or $ rescan h2generic might help.


Intall the library (/lib/libbluetooth.so) :


Place the lib in :
/boot/home/config/lib/

Run the bluetooth_server (/server/bluetooth_server) :

You can place this component in any place.
E.G: /boot/beos/system/servers/

Run any of the provided apps (/apps/*) :

These are command line applications. You can place this component in any place, just ensure you run them from terminal to see the results

Functionlity available:

    Everything used by command lines applications under:
/haiku/trunk/src/bt_*.cpp

    LocalDevice::SetDiscovery();
Which is not used by any of the applications in point 1


Download Bluetooth for Haiku (Arce.4.1)


note: If anybody creates any nice script or "Drop me here link folders", with pleasure, I will publish it here.

sábado, 19 de abril de 2008

Milestone 3, Discovering Remote devices

Being discovered was the second milestone, but the capability of discovering another device (a bit more complicated) is what I had proposed as the third milestone.

Some may have seen the commits, all methods to perform a basic inquiry process are implemented. So nothing more, I have just got all mobile phones with bluetooth capabilities around at home:



Activated its visibility, and:



At the end you can see the names of the 3 phones and its addresses :)


As note I could not make the WiiMote getting discovered, I guess it has to be handled some other way...

miércoles, 9 de abril de 2008

First post for a new writer


Hello !

I am Adrien Destugues ("PulkoMandy"), and this year I am willing to participate into Google Summer of Code for Haiku. One of my projects proposals is writing a preference application for the bluetooth stack.

I started by adding the stack to the default haiku.image to test it under Haiku, and it seems to be working well. I tested everything under qemu so I was just able to check if the program runs... can't connect to a bluetooth dongle from inside qemu.

Next step is getting haiku to boot on real hardware and with a bluetooth dongle attached to it...

Here is a picture of the bluetooth stack running under haiku :). Nothing very exceptional, but it's a good start to build the prefs window around it :)

lunes, 17 de marzo de 2008

Haiku discoverable!

I implemented the SetDiscoverable() method in the kit and I have got from my brother his dongle, as he got my Wii for easter  (my dongle due a failure is not discoverble I will detail later this)

And ...





The phone discovered Mavin which is the name of the bluetooth dongle plugged in the Haiku Box
(was hard to match the camera settings to show this clear)

jueves, 6 de marzo de 2008

Milestone 2, circle closed

The circle | driver - bluetooth_server - bluetooth kit - application | has been closed. Quite long ago I showed how the driver was replying to some request, which is more or less what I can show in the following screenshot. But that was accessing directily to the driver sending raw data and dropping to the screen any reply from it.

What we have here is an app(bt_dev_info) that uses an API defined by the bluetooth kit (libbluetooth.so). The kit is keeping a BMessaged comunication with the bluetooth_server requesting information and waiting for a reply. The bluetooth_server is the one keeping track of all the bluetooth devices we have connected in our system and is the only one who will perfom the real hardware requests to the driver(h2generic) issuing a HCI command to the driver. The driver replies with a given HCI event to the server, the server searches who was actually waiting for the reply information, releasing the data back to the kit again, so the application gets the needed info.

All a huge background that is not bringing us new spectacular things. But its the skeleton and the base of all the Haiku bluetooth subsystem. From now on, new bluetooth functionalities are some lines of code far
(in HCI layer terms).

A BMessenged HCI layer implemented totally in userland which Linux or FreeBSD has in kernel land(almost all) Lets see how it goes with us.






domingo, 10 de febrero de 2008

Second Testing stage

These were the first evidences that bluetooth could actually work in Haiku , that was the result of a first code testing after the coding of the driver. Now finally I could compile the three entities which are to compose the young haiku bluetooth stack:

H2 Transport(Hardware independency):

$HAIKU/system/add-ons/kernel/drivers/bluetooth/h2/h2generic

Partial HCI Layer(Network establishment and handling):

$HAIKU/system/servers/bluetoth_server

UserLand kit interaction(Bluetooth Kit):
$HAIKU/system/lib/libbluetooth.so


At the first run the server runs in Haiku without crashing for the moment, so lets see how all this parts get on well together... test again...


martes, 5 de febrero de 2008

BT Boosted

Some weeks ago I requested in haikuware about the possibility of someone having any old RAM simms for a Pentium 2 or 3.

Since my AMD literally burnt, I was dealing with 128MB RAM pentium 3 for the development, and the build process was often failing due lack of memory. Moreover, the heater was not really doing a good job... as the CPU temperature was around 60ºC therefore I had to even underclock it, delaying all stuff. (Anyway I am the kind of persons using always old hardware)

But today I got a nice packet from Canada !!! two 128 RAM sims which I inmediatelly plugged:



64+64+128+128 And now even its possible to use actually the system while buidling!
no need anymore to kill even the debug_server for saving memory:D




THANKS DENNIS(theNerd)

To update a bit the status of the bluetooth project: The USB tranport driver Driver and kit are currently comitted & building in the Haiku the svn and currently I am tailoring the bluetooth server, expecting commiting and the end of the week for starting the test of the whole system.



lunes, 14 de enero de 2008

End Xmas

No escuse, end of christmas.. even that we end at 6th Jan regarding the kings day, nor the orthodox which ends on 7th.
Something to test will need to wait at least 1 month more, Although most of the code is there I still could not have time to join it and test it...

here is the screenshot of the debugging tool... nothing impressive...