gsoc2011

Batisseur Check-in

Blog post by jrabbit on Wed, 2011-06-22 19:47

A lot of commits have happened since I last blogged on my GSOC Project. The big hitters are:

  • the framework of a rankings website for users’ point totals
  • A non-regex parser I wrote because I’m impatient (I’m going to test its speed.)
  • The begining of the http server that will inform user’s builddrones of availible jobs (builds) [Basically it tells you if packages have been updated so you can build them]
  • Verified that Camlistore (on python) can work on Haiku.
  • A Jenkins API wrapper for magic to happen (I think it may be the perfect thing to handle build logs and results)
  • Redis
  • Redis
  • Redis

Progress is coming along, I recently [On the 15th] returned from a tour of France. There is a second period later in the summer I’ll have unknown-connectivity, but I’ll still be coding then.

ZFS Port: Quarter Term Report

Blog post by GeneralMaximus on Fri, 2011-06-17 03:32

My quarter term goals for the ZFS port included porting all the libzpool dependencies to Haiku. Out of four major dependencies -- libavl, libnvpair, libuutil and libumem -- I already have two -- libavl and libnvpair -- building on Haiku. libumem and libuutil will take another few days, which puts me at least a week behind my original schedule.

I'm currently working on porting libuutil, which is presenting a few roadblocks but nothing that can't be fixed in one day's work.

When I have some free time, I want to take a break from working on the port and do some cleanup. So far I've indiscriminately copied all the Solaris headers I need into my own repository. This is bad. I eventually want to use as many Haiku headers as possible, only importing those definitions from Solaris that are missing from the Haiku headers.

After all the libraries are working, the next step is porting libzpool itself.

My source repository is located at http://github.com/GeneralMaximus/zfs-haiku.

VBox guest additions: status; second quarter goals

Blog post by scgtrp on Fri, 2011-06-17 01:49

During the first few weeks of GSoC, I've gotten vboxsf, the shared folders module, mostly working, though I'm a bit behind where I'd like to be due to unexpected things repeatedly coming up both in physical-land and on my development setup. All supported functionality is working when accessed from the terminal - at this point I'm just optimizing and working on a bug where looking at a shared folder the wrong way in Tracker causes the kernel to panic. Mouse pointer integration, the other thing I had in my schedule for the first quarter, is now working; therefore finishing up the last few bits of vboxsf will be one of my main goals in the next few weeks.

The other goal I have now is time synchronization. It turns out this is more important than I thought - I didn't take into account how many things depend on timestamps being set to reasonable values, and my Haiku installation is at this point very confused as to what the current date and time are.

Several new features, including symlink support, were added in VBox 4, which I was completely unaware of until recently despite it having been released several months ago. I have now upgraded my laptop's copy of VBox so the Haiku port of the guest additions will be able to use these new features.

GSOC 2011: Quarter-term Milestone Report

Blog post by antifinidictor on Tue, 2011-06-14 22:49

As anticipated, I was able to do little more than set up my environment during the first stretch of GSOC and the last few weeks of school and my previous internship. I was able to find computer with a compatible network and graphics card, which should hopefully be faster than running Haiku on a virtual machine on my normal computer. I also successfully installed haikuporter, although I am having some trouble using it. I am also trying out an IRC account.

I plan to install SDL 1.2 by the end of this week in order to make sure my environment is properly set up. I am currently having problems with haikuporter, which is complaining that the ports I wish to install do not exist. I'm not sure whether there is something else I need to download first or not to get this working; I posted a question about this on the HAIKU-GSOC mailing list. I hope to also make a stab at writing a .bep file for SDL 1.3; I admit I am not completely certain as to what this involves, but from reading the wiki it looks like it can be described as a python makefile?

Since school and my previous internship are completed, I should make much greater progress over the next few weeks. I look forward to finally being able to put my full time and effort into this project.

Contacts Kit, Quarter-term

Blog post by Barrett on Tue, 2011-06-14 22:46

These weeks were prolific in terms of design and experiments but due to university commitments i am a bit late with the expected goals.
At this point i have an implementation of BContact / BRawContact and i'm working to get the VCard translator functional. In these hours my focus is the communication part between the raw contacts and translators.

One of the latest design decisions was to make BRawContact own a translator that is suitable for writing the format specified by the user, otherwise it will use the default B_CONTACT_FORMAT (a flattened BMessage) for the final file. The passage of the data between the object and the translator will be done every time the programmer want via the Commit() method. If a path is not passed, the BRawContact will be virtual and stored in memory.

An example of how the api will look approximately :

	BContact contact = BContact(new BRawContact(B_VCARD_FORMAT, "/boot/home/"));
	status_t ret = contact.InitCheck();
	BContactField* field = new BContactField();
	field->Add(new BPhoneNumber(..));
        ...
        contact.AddData(field);
        ...
	ret = contact.Commit();

Most of you probably already know that one of my major inspiration sources was the Android's ContactsContract API. It is already giving some ideas, like the BContactField object. In fact they use a class named ContentValues, that is similar for some aspects to BMessage as a generic data container, i'm thinking to make a wrapper for BMessage in order to provide an object (BContactField) that makes comfortable passing data fields to BContact / BRawContact. It will help also internally, since as said a flattened BMessage is the common translation format (B_CONTACT_FORMAT).

In the immediate future i'm also planning to implement a set of functions in TranslationUtils.h able to convert a BPositionIO or a file into a BContact in a similar manner as the already existent functions for BBitmap and other formats but using the provided Contact API.

There is a new osdrawer project at http://dev.osdrawer.net/projects/contacts-kit, i'm planning to update here some code during the next days.

At this point i expect to get a first working version of both translators in 7 days, in order to begin working on the services_server part. The first goal will be getting the BContactRoster class up, then to add some functions like unique ids for translator (only BContactRoster will be able to edit the id of a BContact because the first goal of the class will be to provide a centralized management of the contacts) and then focusing on the implementation of the services add-on hosting server including an add-on API. My major idea about that is to implement it using a BMessage protocol and some basic hook functions for the services server -> add-on communication.

UVC Driver -- GSoC Quarter-term Report

Blog post by gabriel.hartmann on Mon, 2011-06-13 20:45

On June 7, I turned in my dissertation and my semester ended. On June 10, I had my first final exam. Now it's time to produce a progress report for Haiku. Almost miraculously, I've actually managed to squeeze some Haiku development time in and am making progress of a kind.

The most tangible progress is mostly in the form of debug messages and crashes into Kernel debug land, but I consider anything that I do which has a measurable effect to be progress. So far all my efforts are aimed at trying to understand how all the different pieces of a userland driver component come together. I've had a lot of help with this from my mentors and from people in IRC and on the haiku-development mailing list. Michael Lotz and Anevilyak (IRC nick, I don't know a real name) were particularly helpful.

My current understanding of the task is this:
1. I should detect the connection of a camera.
2. I should detect its capabilities.
3. I should expose those capabilities in a MediaNode.

In reality two and a half out of three of these have already been done for me. The USBKit is successfully detecting my camera. Furthermore listusb lists all the relevant interfaces, configurations, and endpoints the camera provides (there are many). In a similar way, a first draft of the UVCCamera driver (written by Jerome Duval) is also parsing this information and placing it in appropriate data structures. These data structures even make their way to encapsulation in a MediaNode which is visible to the Media server...sometimes. No capabilities are presented to the media server and CodyCam still claims that no video device is available, but I have seen something named "USB USB[sic] Video Device" in the Media preferences menu. However the behaviour of the node is a little strange. It's appearance is not stable at all. It tends to appear on an initial media server restart, then never appear again. This isn't always the case, so it's not exactly a reproducable bug which is irritating. Also attempting to test code by plugging and unplugging my camera or even a flash drive is a bad idea as it leads to Kernel panics and trips to a frozen Kernel debug land.

I do not yet understand the precise journey information takes from its extraction in the current UVC driver back to a Video Provider MediaNode. I know that a VideoProvider constructor takes a CamDevice. I know that a UVCCamDevice extends CamDevice. So presumably passing a UVCCamDevice to the VideoProvider constructor is how a MediaNode is created. I even see code which could do this in the USB webcam add-on directory, but I'm a little fuzzy on the exact set of operations which lead from the current UVCCamdevice code back to MediaNode creation. I'd like to understand exactly how that works.

Now that I've got a clearer if still hazy view of what's going on and what's needed I have some short term goals. First of all I'd like to understand exactly what a VideoProvider node needs in order to expose capabilities to interested applications. So far all my reading of code and documentation has focused on USB, but I really need to understand what the ultimate goal is before extracting data from the camera. Second (or perhaps in a shared first position), I'd like to not only detect camera capabilities but actually invoke a command which returns some data. I understand that Jerome Duval has done this recently and I'd like to either reproduce what he has done or extract some new kind of data. Third I'd like to actually expose whatever capability I am able to extract to the media server. My thinking is that if I can expose a single feature from end-to-end then the repitition of this task for more features should be fairly straightforward.

I'll be spending all day today working on the first two goals. Tomorrow I have to study for an exam as it takes place on the day after tomorrow. Then I've got a long break before my last exam in which to focus on the UVC driver. I feel like I am starting to get a handle on the structure of the problem and am able to poke and prod the current code to learn new things. That makes the problem solvable. I suppose my biggest medium-term worry is how to deal with compressed video streams. I don't know what decompression facilities are available or if they're applicable to this situation, but that's a problem for later.

Language Bindings for the C++ API: First Quarter Report and Second Quarter Goals

Blog post by jalopeura on Mon, 2011-06-13 16:46

During the first quarter, I defined an interface language to use for creating the bindings. I had to create my own for several reasons. Probably the biggest factor was the need to know whether the target language has the right to destroy an object. Most of the target languages has some kind of automatic garbage collection; the programmer never needs to worry about whether to delete an object to free up memory. I didn't want to force programmers to worry about it when they don't normally need to. Therefore, I had to be able to mark whether an object was delete-able, so the generated bindings could delete it automatically if necessary.

I also defined preliminary bindings for a minimal test program, wrote a preliminary generator to create the bindings, and wrote the program itself (a simple application with a window which has a single button). The preliminary generator and the test program targeted Perl.

I also tried changing some data from the test program (with the interpreter running in the main thread) while in the MessageReceived method for the window (which should theoretically lock the window's thread). I was unable to make the program block, so I will need to continue testing for thread issues as I go along. Suggestions are welcome.

I in an earlier post that I would make a decision on target languages based on two criteria, popularity with the Haiku user base and ease of writing extensions. The popularity, based on a poll on the Haiku home page, is as follows:

42 51% Python
14 17% Ruby
12 14% Lua
06 07% Haskell
04 05% Perl
03 04% Scheme
02 02% Squirrel

As you can see, Python won in the popularity category, with over half the total votes and three times as many votes as the next highest language. Extension writing looks like it will be relatively easy as well. With good scores in both categories, Python will be one of the target languages. (In fact, I've already started work on them.)

I already know how to write extensions for Perl, which means it wins in the ease category. Since I did my initial tests with Perl, it will continue to be one of the target languages as I expand the number of bindings.

However, Perl scored quite low in popularity, so I would like to add another of the more popular languages as well. Ruby and Lua both scored more than 10%. If I am able to get the Python bindings working in time, I will research extensions for those two languages. Their scores were close enough that ease of writing extensions will be the deciding factor here.

Report on first-quarter goals:

- Define an interface definition language (Done)
- Define preliminary bindings for a minimal test program (Done)
- Write a preliminary generator to create the bindings (Done)
- Write the minimal test program (Done)
- Test threading issues (Will continue into the second quarter)
- Make a final choice on target languages (Done)
- Expand preliminary bindings and add new bindings (Not done)
- Write test programs for the bindings (Not done)
- Write documentation for the bindings (Not done)

My goals for the second quarter (including the ones brought forward from last quarter) are:

- Bring the Python bindings to minimal functionality
- Write a minimal Python test program
- Continue to test threading issues
- Expand preliminary bindings and add new bindings
- Write test programs for the bindings
- Write documentation for the bindings
- If there is sufficient time, select a third target language

Syndicate content