Jokosher hackfest this sunday – gstreamer bods nee

Jokosher hackfest this sunday – gstreamer bods nee

This Sunday (21st May 2006) we are holding a [Jokosher](https://www.jokosher.org/) hackfest in the #jokosher IRC channel on Freenode. The hackfest is going to be attended by a number of Jokosher hackers, and the plan is to get the audio system into shape, fix bugs and add missing features.

I know this blog is aggregated on [Planet GStreamer](https://gstreamer.freedesktop.org/planet/) and I would like to invite GStreamer developers to the hackfest. It would be intensely useful for some experienced GStreamer developers to have a look through the Jokosher code and to advise on any silly mistakes we may be making. We are getting some very odd audio bugs and crashes, and any input from those of you who are more experienced with GStreamer would be incredibly handy. There is every possibility we are doing something wrong that many of you could identify in a few minutes poking through the code. If you want to have a look at the code, grab it from [https://svn.jokosher.python-hosting.com/JonoEdit](https://svn.jokosher.python-hosting.com/JonoEdit).

The hackfest takes place all day on Sunday, and I will be there (with [Aq](https://www.kryogenix.org/) from around 10am – 4pm. Hope to see you there.

Oh my

Oh my

Last night was the very first [PHP West Midlands](https://www.phpwm.org/) meeting in Birmingham. You know, when I considered the idea of setting up a PHP user group, it was a bit of a punt in the dark. I could see this collection of disattached PHP developers growing around me, many of which had been through OpenAdvantage’s doors, and it seemed to make sense to draw the connections and bring these people together. Although I had primarily been involved in setting up Linux related communities, setting up a language community was a whole different ball game, and I wasn’t sure if it would work. Luckily we now have 117 people on the mailing list, some thriving discussion, and last night we had 18 people attend the first meeting. It was a great night, with some nice friendly and social discussion and some great talks. Thanks to everyone who came along and got involved.

## Oooh, its out

Firstly, congratulations to [Elliot](https://townx.org/) for getting a patch in Ruby On Rails. He is a clever guy, and someone who deserves a medal of some variety. He is over the moon about this, and rightly so. I was also pleased to see the [XAMPP Control Panel](https://archivedblog.jonobacon.com/projects/xamppcontrolpanel/) get officially merged into XAMPP. You can access it in:

/opt/lampp/share/xampp-control-panel

Just run it like this:

./xampp-control-panel

The world has become a little brighter and one more duckling has been saved somewhere. For those of you with an interest in 1s and 0s, check out the code from [https://svn.jonobacon.com/svn/xampp-control-panel/trunk/](https://svn.jonobacon.com/svn/xampp-control-panel/trunk/) and send in your patches. The XAMPP Control Panel is actually official now, so lets make it rock!

## Jokosher

In [Jokosher](https://jokosher.org/) news, I recently checked out GStreamer from CVS to use some of the fixes Wim and Edward have worked on. This was pretty simple, and I [wrote a short guide](https://jokosher.org/trac/wiki/InstallingCvsGstreamer) of how to do this. I then tested my [recording while playing back test script](https://jonobacon.com/files/recandplay.py) and it worked great. Today I also tested my [playing multiple tracks test script](https://jonobacon.com/files/gnonlintest.py) with some [advice from Wim](https://bugzilla.gnome.org/show_bug.cgi?id=341431) and it worked great. I am hoping to fix up the events bits in the code and get the audio engine into shape soon. This is getting better all the time. 🙂

## Nokia 770

Yesterday, a [Nokia 770](https://europe.nokia.com/nokia/0,1522,,00.html?orig=/770) dropped on my desk. Overall its a pretty nice device, if a little on the skimpy side when it comes to memory. I doubt it is going to change the world any more than any other device of its kind, but the work the 770 team have done in getting the software environment right is good. The interface is attractive and smooth, and it feels intuitive and comfortable.

Now, in the past I have owned various next-gen Nokia mobiles, Sharp Zaurus, Handspring, Palms and other devices, and now is the time for me to get all excited by the possibilities, and never actually get around to using them. A good example of this is Python on the Nokia high-end phones. When I got one of these phones I got excited about how I could write some software to do mobile blogging and various other ideas. Of course, it never happened, but the potential was enough to get me wriggling like an excited kid on his way to Disney World.

The 770 offers a different level of opportunity though. Recently, I saw a report that the Sony PSP can be used with a Playstation 3 in different ways. The example cited was that with a racing game, the PSP can act as a rear mirror. This coupling of two devices is incredibly cool, and the wireless capabilities and GTK/GStreamer software stack in the 770 provide some interesting food for thought.

My main idea is that the 770 could be a great remote control for Jokosher. Imagine creating the project on your computer, then picking up the 770 and walking over to your guitar amp to record the track. You could then press a button the 770 to start the recording and use the 770 to see instrument specific details, a timeline or other details. The possibilities are endless, and it would be a really interesting and unique use of the technology. It is also something that is eminently doable – no audio would need to be transmitted over the network, just data. Again, this may never happen, but the potential is there, and potential is often the most important and treasured element in Open Source. It means we *can* do something – whether it happens or not is neither here nor there.

Phonon

Phonon

[Christian has blogged](https://blogs.gnome.org/view/uraeus/2006/05/11/0) about Phonon; the KDE multimedia framework touted for KDE4. A while ago at SCALE in Los Angeles I had breakfast with Aaron Seigo and aside from our usual exchange of nob-gags, we discussed Phonon in some detail.

One of the biggest problems that I think the KDE team have is the inability to make decisions about technology, and decide on one thing over another. Back when I was involved in the project, there was a tendency to place decisions in the hands of the user, and this position seems to have largely remained in KDE. Now, there are of course some good things with this approach – users get increased *choice* and control over how their desktop looks and works. The problem with *choice* is that it is only a good thing when the user actually understands the choices and is able to make an informed decision. Phonon seems another example of a KDE “we-won’t-make-a-decision-so-instead-provide-yet-another-framework-to-support-everyone-and-everything” plan.

I am not denying the fact that Phonon does solve some specific problems. One typical example is that KDE is designed to work on a range of Operating Systems, and not just Linux. If KDE is to work across Linux, BSD, Windows, Mac OS X and others, there may be problems in taking one consistent audio framework across these different systems. This may sound a reasonable plan, but I don’t think the solution is to either abstract it away or not make a decision.

One thing I am unsure about, and maybe someone can answer this, is how exactly you can create an abstraction layer such as Phonon and still ensure that it can make use of all the different backends and their full capabilities. As as an example, if I am writing an application and I want to play some audio, I am assuming that Phonon will include a `Play()` function or something. All backends support audio playback, so that is fine. Now, if I want to instead record some audio, feed it through a LADSPA plug-in and output it through the speakers while recording to the disk in MP3 format, this is probably not possible in all backends. How does Phonon cater for these situations? My assumption is that Phonon will bow to the lowest common denominator in the backends, and if so, this will only make Phonon suitable for simple playback applications.

I think the right solution is to simply decide upon a media framework. If it were up to me, I would probably choose GStreamer, but whatever it is, just pick one and instead make that framework better. If you want to make the integration of that framework better in KDE applications, fine, but at least focus on a single framework and direct your engineering at making that framework and its KDE integration better. I think GStreamer offers a pretty strong offering, with good support for a range of facilities, good codec support, commercial backing, language bindings and a strong and enthusiastic developer base. Until KDE starts making some decisions about using specific technologies, I think it is going to cause some real problems for the project.

Figuring out the bugs

Figuring out the bugs

Recently I have been exploring some odd bugs that seem to be getting in the way of [Jokosher](https://jokosher.org/) becoming the rock god application it is destined to become. After some discussions with wtay and bilboed, some bugs were fixed in gnonlin, and Jokosher much better without any modifications. As bilboed continued to bugfix and resolve problems, he made another commit which seemed to break Jokosher when playing back more than one track.

To find out what was going on, I knocked up the following script which represents a very simple Jokosher:

#!/usr/bin/python
import pygst
pygst.require(“0.10”)
import gst
import gtk

class Instrument:
def __init__(self, project, filename, insnum):

self.project = project

gst.debug(“Adding an instrument gnlcomposition”)
self.comp = gst.element_factory_make(“gnlcomposition”, “mycomposition” + str(insnum))
self.comp.connect(“pad-added”, self.project.OnPad, self)

gst.debug(“Adding a gnlfilesource”)
self.audio = gst.element_factory_make(“gnlfilesource”, “audio” + str(insnum))
self.audio.set_property(“location”, filename)
self.audio.set_property(“start”, long(0))
self.audio.set_property(“duration”, long(60) * gst.SECOND)
self.comp.add(self.audio)
self.project.pipeline.add(self.comp)

gst.debug(“Adding an instrument audioconvert”)
self.convert = gst.element_factory_make(“audioconvert”, “convert” + str(insnum))
self.project.pipeline.add(self.convert)
self.convert.link(self.project.masteradder)

class Project:
def __init__(self):
print “Running class”

self.pipeline = gst.Pipeline(“mixer”)

gst.debug(“Adding master adder”)
self.masteradder = gst.element_factory_make(“adder”, “masteradder”)
self.pipeline.add(self.masteradder)

gst.debug(“Adding alsasink”)

self.out = gst.element_factory_make(“alsasink”, “out”)
self.out.set_property(“device”, “default”)
self.pipeline.add(self.out)

gst.debug(“Linking masteradder to alsasink”)

self.masteradder.link(self.out)

# create the instruments

self.ins1 = Instrument(self, “/home/jono/media/audioforjokosher/boogle-like-the-wind.mp3”, 1)
self.ins2 = Instrument(self, “/home/jono/media/audioforjokosher/your-chin-or-your-life.ogg”, 2)
self.ins3 = Instrument(self, “/home/jono/media/audioforjokosher/fancy-pants-riverdance.wav”, 3)

# play

self.pipeline.set_state(gst.STATE_PLAYING)

def OnPad(self, comp, pad, instrument):
gst.debug(“Pad added”)
convpad = instrument.convert.get_compatible_pad(pad, pad.get_caps())
pad.link(convpad)

class Main:
def __init__(self):
self.project = Project()

start=Main()
gtk.main()

Grab the script [here](https://jonobacon.com/files/gnonlintest.py).

This script creates the `Instrument` and `Project` classes, instantiates some instruments and plays them at the same time. Each instrument creates a new `gnlcomposition` and stuffs the audio file into a `gnlfilesource` which sits in the composition. Each instrument is then connected to an `adder` which is in turn connected to an `alsasink`. So, when you set the state to `PLAYING`, the instruments are created, hooked up to the adder and it plays.

With the GStreamer in Dapper, this worked great for Ogg and MP3 files, but seemed to barf on WAV files. The interesting thing is that the problem only materialised on more than one WAV file – a single WAV file was fine. The natural conclusion was that there is something wrong with the `adder` hooking things together. This suspicion was also backed up by some work that Stefan Kost has been doing looking into problems I was having with my simultaneous record-playback script that I [blogged about](https://jonobacon.com/viewcomments.php?id=684). For those of you with a penchant for poking, you can grab the script from [here](https://jonobacon.com/files/recandplay.py). Stefan suspected problems with the `adder` there too.

Today Wim and Stefan were looking into these problems, and hopefully a fix should be committed soon. You know, it doesn’t surprise me that some of this hacking is uncovering bugs such as this – GStreamer has traditionally been used for playback applications, and we are now seeing a new breed of media production application such as [PiTiVi](https://pitivi.sourceforge.net/), [Diva](https://diva-project.org/), [Buzztard](https://www.buzztard.org/index.php/Main_Page) and of course, Jokosher.

All of this has been reported to slomo_, so hopefully we can see some of these patches make their way into Dapper.

Those of you who don’t care about this can now take your fingers out your ears. 🙂
—–

Phonon

Poor little banger

Well, took Banger to the vets and the poor blighter needs to go back for an X-Ray tomorrow. With mini-doxies you always have to be careful with their backs, so the vet is just checking everything is OK to be 100% sure. Feel free to send get-well cards to banger AT jonobacon DOT org. 😛

Our friend and yours, Mirco Muller, who has nothing to do with yogurt, has passed one of my fun little challenges. Every so often I think its a laugh to bet someone to do something stupid, and noting that Mirco was recently added to [Planet GNOME](https://planet.gnome.org/), I betted him to post a blog entry with the following content:

* A picture of the [Chinny Raccoon](https://chin.lugradio.org/)
* The words ‘Jono Bacon is a rock god with a rocket in his pocket”
* The words ‘I am going to boogaloo with my digeridoo’

The resulting can be seen [here](https://macslow.thepimp.net/?p=52), and you can see how the magic unfolded in this image that Mirco knocked up:

Impressed, I am, young padawan.

For those of you who don’t know Mirco, he has been working on some pretty awesome cutting edge desktop stuff in the form of [lowfat](https://macslow.thepimp.net/?page_id=18). He is doing some great work, and will be demoing lowfat at the worlds single greatest Open Source event since Mr and Mrs Torvalds put on a Barry White CD, [LUGRadio Live 2006](https://www.lugradio.org/live).
—–

Figuring out the bugs

Dog pipeline

This weekend has unfortunately been blighted by concern. Banger, one of our pooches has been in a lot of pain since Saturday, and we are not entirely sure why. He has been to the vets and even had a trip to the emergency vets last night. The poor little thing really isn’t very well, and I am taking him to the vets again tomorrow. Hopefully we can resolve this soon for his, and our sake.

In other, happier news, this weekend I started looking at implementing the ability to record while playing back existing tracks in Jokosher. This is quite a big change, and somewhat experimental on my part, so I decided to write this as a separate stand-alone script and then merge it in later. With this change I need to make Jokosher (1) record audio audio to a file (2) play the live recorded audio back and (3) play back the existing tracks. To do this I am working on the following pipeline:

I have got the code for this pipeline written, and it is recording fine, but I am having some problems with playback – the playback is insanely choppy, to the point of being barely audible. After sprinkling lots of debug statements in the code, I suspect I may be getting some problems that are related [this bug](https://bugzilla.gnome.org/show_bug.cgi?id=338711) and very likely [this bug](https://bugzilla.gnome.org/show_bug.cgi?id=331727) which has in turn resulted in a gnonlin fix. The problem is that the gnonlin fix requires a bug fix in core gstreamer. Despite this, Edward is going to work on a hack to incorporate the fix in gnonlin with an existing gstreamer. My hope is that these fixes go in and a new gstreamer is released that slomo_ can get into dapper soon.

—–

Gotta get a strong fence…oh yes

Gotta get a strong fence…oh yes

Took a half-day off to get our fence strengthened. While this was going on I had a poke into some [LUGRadio Live 2006](https://www.lugradio.org/live/) related business. I called the official hotel and enquired about how many rooms have been rented for LUGRadio Live. It seem that the vast majority of the hotel is filled with LUGRadio Live visitors, and that equates to around 60 rooms. Its awesome that we are already getting an feel that the event is going to be well attended.

Anyway, I have managed to organise another official hotel that is catered well for double and twin rooms. See the [LUGRadio Live Accomodation](https://www.lugradio.org/live/2006/index.php/Accomodation) page for details about the Holiday Inn. In addition to this, Aq and I are confirming final speaking times for our roster of too-cool-to-rule speakers at LRL06, and we are drawing all of these threads together. Man, its gonna be awesome. 🙂

## Jokosher now plays pretty well

Thanks to the efforts of Wim Taymans and Edward Hervey, gnonlin has now had some bugs fixed and Jokosher now doesn’t barf on second playback. There are still some quirks, but Edward is looking into some remaining `gnlfilesource` bugs that he has discovered.

As such, you now need a CVS copy of gnonlin to run Jokosher properly. I am hoping that once these bugs are resolved Edward can push out a new release and slomo_ can get it into Dapper. A core ambition behind Jokosher is to make it as easy to use as possible, and this includes the architecture that it uses. Part of the reason we picked GStreamer is because it is shipped my most distributions and provides a solid platform to build applications like Jokosher.

## Weetabix king

As [noted by Paul](https://www.devel.co.uk/article/166/the-weetabix-king) our friend and comrade [Elliot is a fountain of weetabix related knowledge](https://townx.org/blog/elliot/weetabix_craziness). Lets get him to the top of Google, so get blogging about his oracle like Weetabix powers.

Oh, and all the Guadec flights and accommodation is now booked – we are all set. 🙂
—–

OpenDocument an ISO standard

OpenDocument an ISO standard

Today is a great day for open standards, with [OpenDocument Format accepted as an ISO standard](https://www.consortiuminfo.org/standardsblog/article.php?story=20060503080915835). This is fantastic news, and news that adds extra validity for the OpenDocument format, particularly in government and education. This naturally means increased validity for OpenOffice.org and other suites that incorporate it.

Great work guys! 🙂
—–

Figuring out the bugs

Insanely tired

Long day today.

Woke up insanely and headed over to Birmingham to do a talk about Voice Over IP with [Paul](https://www.devel.co.uk/) and Group3. Despite getting stuck in traffic due to a smash up on the M6, the seminar went well and was fairly well attended. Nice to see lots of interest buzzing.

After the seminar I jumped in the car and drove to Manchester to speak at [Login](https://login.pbwiki.com/). I was invited to speak at this event after my first talk at Manchester Linux User Group, and Hamish (the guy who organised today’s event) was keen to help push Open Source in his part of the world. For a first shot at something like this, I was really impressed. Not only is the venue a really cool community training center that is entirely self sufficient, but the attendance was great. I was also pleased to see some familiar faces there including Chris Mills, Kier Thomas, Richard Smedley, James Wallbank and Ed Downs.

*The audience (forgive the blurry photo)*

*A huge stack of Yellow Pages books. These guys really do love the Yellow Pages…*

I delivered my *Open Source Reality Check* talk, and it seemed to go down well, with a nice receptive audience. There were also some really interesting questions, and further discussion points. This was the second time doing this particular talk, and I felt more comfortable to do this time around. Bits need trimming here and there, but I felt pretty happy with it.

Thanks to Hamish for his excellent work in building the event today, and thanks to everyone who stuck around for my talk. 🙂

After the event, I drove back home, and experienced an unbelievable level of tiredness on the way. As I was driving I literally felt like I was going to nod off, so, for the first time ever, I pulled into a service station and had a nap. I think I slept for about 30 minutes, and I then drove home, still tired. I have spent the entire evening in a zombified state with a pounding headache. I think some of my late nights, early mornings and busy schedule have caught up with me. This weekend…I sleep.

## GStreamer pan-tastic

A while back I noticed that there appeared to be no GStreamer element for panning audio; a feature that is pretty important in something such as [Jokosher](https://jokosher.org/). Well, it seems Stefan Kost has gone and written one. Nice one ensonic! 🙂

## Firefox take-up

[Simon has blogged about](https://beerandspeech.org/index.php?/archives/183-Advocacy-UK-is-falling-behind-in-Firefox-uptake.html) how the UK has been slower taking up Firefox than other countries, and he asks the natural question, why?

Personally, I think these sorts of demographics are difficult to track, quantify and explain. Sure, although there is some statistical information about Firefox usage, I question how accurate this is. This is not a pot shot at the statisticians, but a pot shot at recording *any* kind of accurate Open Source usage. I think the openly distributable nature of Open Source means that it becomes incompatible with accurate statistics about said distribution. The problem is also applied to pirate software – there is no centralised restricted authority that overlooks distribution to track usage.

Assuming for a second that the stats are true, I think there are many factors involved including social, technical, cultural and economical reasons. I could wax lyrical about such theories for pages and pages, but ultimately it would not contribute to solving the problem. I think we should therefore turn our focus on how we can help people advocate Firefox better. So, I open it readers of this blog and Planet Advocacy, how can we better advocate Firefox? I have a few ideas, but I am interested to hear your thoughts to see which ideas are most prominent.

In [Planet Advocacy](https://www.planetadvocacy.org/) related news, you can access the site at [https://www.planetadvocacy.org/](https://www.planetadvocacy.org/). Wow, doesn’t it feel all professional now? You can still access it at [https://planetadvocacy.jonobacon.com/](https://planetadvocacy.jonobacon.com/) so don’t worry too much about updating your RSS feeds straight away. 🙂

Jokosher hackfest this sunday – gstreamer bods nee

Updates

Wow, [The Increasing Importance of Community](https://www.oreillynet.com/pub/wlg/9330) got [slashdotted](https://linux.slashdot.org/article.pl?sid=06/05/01/110203). It also made an appearance on [OSNews](https://www.osnews.com/comment.php?news_id=14485) and [Newsforge](https://newsvac.newsforge.com/article.pl?sid=06/05/01/1449253). Thanks to those of you who mailed me your thoughts and comments – they are greatly appreciated. 🙂

A few events for the calendar:

* Open Source: A New Way Of Thinking (Open Source In The Voluntary Sector) – Wed 3rd May 2006

* Open Source: Deal or No Deal? (Microsoft DeveloperDeveloperDeveloper! Day) – Sat 3rd June 2006

* Riding by the seat of your pants: The Jokosher story (GNOME User And Developer Conference Europe) – Mon 26th June 2006

Tomorrow I will be giving a [Voice Over IP seminar](https://www.openadvantage.org/events/copy_of_oaevent.2005-11-07.5128062565/view?searchterm=None) with [Group3](https://www.g3t.uk.com/) in which you can come down and play with VoIP phones. Also, don’t forget the [first PHP West Midlands User Group meeting](https://www.phpwm.org/).
—–