Showing posts with label upnp. Show all posts
Showing posts with label upnp. Show all posts

Wednesday, December 15, 2010

I'm back. (Hopefully) For good.

Hi, everyone. It's been a long, long time since I posted something. I'm sorry for that.

Well, a couple of things happened in recent times:

1) I've finally met my fellows of kde-br. We had such a good time at Natal (RN) in the III KDE Forum - Northeast Edition (within IV ENSL). My talk was about GSoC, KDE, how to get involved, etc. It was pretty cool. My intent for the next events is to talk about more technical stuff (e.g. an introductory Solid tutorial or something like that)

2) Google funded me (thanks, Carol!) to attend Google Developer Day at São Paulo, and it was awesome. There were excellent talks about Android, Google App Engine, Cloud Computing, etc. Unfortunately, it lasted only one day.

3) I've got a partial-time job as a teacher (yes, who could tell?) in a city nearby (about 180km), called Patos. I'm lecturing two subjects: OO (with Java :p) and something like AI. It's being really nice, actually. Teaching is the better way to learn. :)

Well, that's the good news. The bad news is that my masters work is kind of stuck and it will take a few more months beyond the expected. I'm really not happy with that, believe me. From January on I expect some real progresses on this matter.

Other bad news I have to tell is about my Solid backend (UPnP). Seems like KDE is crashing because of something related with UPnP (yes, guys, I saw the bug reports, just a little bit of patience ;) and I'll investigate this ASAP (my KDE trunk install is really messed up). Actually, I've decided to change the whole underlying layer of UPnP backend. Currently, it's using a library called HUPnP. I've decided to change this library and replace it for another Qt-based UPnP stack called BRisa. In a few days I'll post another blog entry explaining my reasons to do that. Sadly, this change only will be seen in the 4.7 release, since the 4.6 branch is frozen now and the monthly releases are for bugfixes only.

Back to the good news, I'm intending to get back to the KDE work this weekend and address the bugs reported (btw, thanks to the ones who did it). I will try to manage my time properly from now on, I swear. :p

See ya.

Wednesday, September 8, 2010

Pong

Hey, all.

If you're wondering about the Solid UPnP backend state after the end of GSoC, here I am to satisfy your anxiety. :-p

Well, there is not so much to update, sadly. I've fixed some bugs on IGD and updated the code to be compliant with the most recent version of HUPnP (thanks, Nikhil).

The reason for the little flow of work has name, but no title: masters thesis. I have a workshop coming and really have to rush with this stuff. But I'll do my best to keep all the things running fine in parallel. :-)

That's it for now.

Cheers.

Sunday, August 22, 2010

emit remmus

This was a really cool summer. Actually, a really cool winter, since I live in the southern hemisphere (Brazil, for those whom don't know already). I believe that the most cool thing on this GSoC for me was finally get involved in the community, know the people behind and contribute with the KDE project after about 5 years using it. I'm really glad to see lines of code written by me in the tree and looking forward to do more cool stuff from now on.

As a not so much experienced Qt/KDE developer, I had some problems on the way. However, I think I can say that the basis for a consistent UPnP support on KDE is ready. Obviously, there is more things to do and refine, and I'm happy with that, because it means that I'll keep working with Kevin and the others 'metalworkers' :-D.

Today we have a nearly full media server support on Solid and the KIO slave developed by Nikhil with the Amarok people will help to get UPnP media servers available for browsing on Dolphin, for instance. As you can see, they are already appearing in the kfileplaces KPart (and in the device notifier as well). This is the actual user-visible part:

We have some IGD support, too. Given an UPnP router available, it's possible to add/remove port redirects (and other vendor-optional operations, like toggle the internet access in the router):

Solid::Device dev(deviceUdi);
Solid::InternetGateway *igd = dev.as();
igd->addPortMapping("192.168.0.1", 80, "TCP", 80, "192.168.0.136");

The API needs a little bit of refinements, but I think we are on the right way. My plan is to add more operations in the API soon and integrate the IGDs within the network manager.

So, what about the plans for the future? Well, along with the IGD integration, a debug app using BRisa framework and a plasmoid showing the UPnP neighborhood are intended, too. In the future, my desire is to implement other UPnP devices, like printers and media renderers. The HUPnP library (used in the project) need some adjustments, too. So, work is not lacking here :-). I'll keep you posted about how things are going here in the blog.

Finally, I want to thank Kevin Ottens, my mentor, for the support and patience in the past 3 months. I'd like to thank Bart Cerneels, Nikhil Marathe and Tuomo Penttinen, too, for the help, feedback, and hints. Honorable mention to Lydia Pintscher and Leo Franchi, the SoC managers. Thank you all, guys, you rock!

Oh, almost forgot. There will be the Solid sprint soon, in Madrid. Don't know if I will can attend in person, but I'll participate somehow. Looking forward to meet the Solid people personally and put some faces in the (nick)names. :-)

Cheers.

Friday, August 6, 2010

Moving out

Hello, all. This will be a quick (and late) post.

Oh, hell, I'm moving out the apartment. And it sucks. Really sucks. This week I've been pretty busy taking care of the process and stuff. My masters advisor also had an epiphany and asked me the first two chapters of the thesis. The work didn't flow much well this week. :-(

On Sunday I intend to keep you up about the integration of the Solid UPnP backend with Dolphin and Plasma Device Notifier. The pencils down date is approaching... May god (or anything similar) have mercy on my soul. :-p

See ya.

Sunday, July 25, 2010

(GSoC) And god said: "Let there be an Internet Gateway"

Hi, all.

Last week I said to you that HUPnP did not recognize UPnP internet gateway devices in the network. Now I think I can say it used to not recognize. :-)

Seems like Tuomo's patch fixed the problem and now the Solid UPnP backend is able to "see" my wireless router and finally invoke the UPnP actions available on it (like to do some port redirect and toggle the internet access, for instance). I have made some tests and seems like the action invocations are working well from the HControlPoint instance in the UPnPDeviceManager. Now it's time to refine the API and add more operations, probably.

However, "the world is cruel". This week Nikhil and Bart pointed to me and Kevin some problems with the media server stuff. Besides some mistakes on the HUPnP use from my part, seems like there is something wrong with the creation of the UPnPDeviceManager. According to him, due to the use of a QThreadStorage on the backends manager, a new HControlPoint is created for every thread using Solid, causing some inconsistent results. The expected behavior is only one control point across Solid stack (frontend -> iface -> backend). I'm working on the backend part, but the Solid thread-affinity stuff I prefer to let the more experts metalworkers to decide what's better.

Another thing Nikhil opened my eyes is about that I'm not running KDE trunk (I'm using that script development strategy from Techbase). I know, it's a blasphemy and I will build and use the SVN trunk ASAP. My unit tests are not enough and I need to do real system tests.

Well, I really hope this week to get the backend working fine to go into the little desktop integrations and the debugging app using an UPnP framework developed by some fellows here in the lab, called BRisa. I have to run a little bit with the schedule.

See ya.

Sunday, July 18, 2010

No, I'm not dead ;-)

It's been a while, right? Sorry for that. I'll try to post here once per week from now on, I swear.

Well, since my last post some things happened. Let's see... I've got a motorcycle. And I've got a motorcycle accident. My left arm is not so good but I will survive :-). I've began to write my master thesis, too. But I'm not here to talk about me, but about my GSoC project.

The midterm is gone now and Kevin granted me a "passed" status :-D. This is a motivation, indeed. About the work: I've implemented the media server (Solid::Backends::UPnP::UPnPMediaServer) and internet gateway (Solid::Backends::UPnP::InternetGateway) classes. The media server implements the Solid::DeviceInterface::StorageAccess interface, with the idea of treat UPnP media servers as remote folders or something like that. Actually, you can think in a media server as a remote pendrive, with some media there. The internet gateway (could be a router, an ADSL modem, etc.) implements an interface made by me to these kind of devices, so it can and will be improved with the time, since the actual API is pretty bounded with the UPnP forum specifications, and it is exactly what we can avoid in Solid (flexibility is the law).

I've made some unit tests with the media server and seems like the things are fine. Actually, Nikhil's work in Amarok will tell what we could improve on that part. Using the HUPnP library, the backend is able to detect UPnP devices available on the network, as you can see here.

The IGD tests are kind of stuck, because HUPnP has some problems in detecting UPnP internet gateway devices. I've been trying to test with two wireless routers, but without success so far. I'm in touch with Tuomo (library's author and maintainer) and in this afternoon we spent a good time debugging HUPnP and talking about heavy metal :-p. Looks like he figured out what is going on and will patch the library ASAP.

The next steps now is keep working in the IGD issue and in parallel work at the device notifier integration (at least with media servers). I'm having some difficulties in understanding the device notifier code, but nothing that we can't ask, right? :-)

Well, that's it for now. Next Sunday I'm back here. With a good arm. I guess...

Cheers.

Monday, May 31, 2010

GSoC Code Week #1: Prologue

Hello, KDE planet! :-)

I'm a little bit late with this post, but finally here I am. And for those who are not aware of my project, just read this post. ;-)

Well, last week was my first coding week on this GSoC and as a pretty newbie KDE developer I had some problems with some noob stuff like cmake, dependencies and these kind of things, but I think that I'm close to solve it all. As I said to Kevin (my mentor), I'm a Java programmer who knows some C++/Qt, but I can say that I'm having some progresses at all.

Right now I have a general class which represents an ordinary UPnP device, that I called Solid::Backends::UPnPDevice (pretty obvious, right?). I've implemented a control point too, through the Solid::Backends::UPnPDeviceManager class. My intent is to get able to list the available devices ASAP. I'm with some linking problems (here are the newbie problems again) with HUPnP, but Nikhil Marathe (who has a related GSoC project with the Amarok people) gently offered himself to help, and very soon I'll be in touch with him. :-)

Since the main library used by my project (HUPnP) is under some license incompatibility (it uses GPLv3) with the rest of libsolid (LGPLv2), I've not committed anything yet, but soon I'll do it and disable the backend of the builds and distribution, to avoid any license crime. Tuomo Penttinen, the HUPnP creator and maintainer is aware of it and is planning to change the license in a near future.

Well, that's it for now. As soon as I can list the available UPnP devices I could post some screenshots here, right? People really like screenshots :-).

Regards.