Archive for the ‘morrigan’ Category

Morrigan on Android

Wednesday, December 22nd, 2010

In an idle moment in a spot of vacation leading up to Christmas and while everyone else does battle with The Snow, I though I would knock up a prototype Android app to work with my media player Morrigan. A couple of days later (don’t worry, I did remember to sleep) I have a something that is working rather better than previously expected. Actually building this app was only 60% Android development. The other 40% was beating Morrigan’s HTTP interfaces into shape – a worthwhile exercise as they are looking much more robust now (though there is still more functionality to add). Screen shots below:


In order, the 5 screens are:
1) Home screen – server list. Use the + button to add new servers. Long-hold servers to get a delete option.
2) Server screen – lists the artefacts on that server. First it lists players (there is usually only one, but can have more) followed by media databases.
3) Player view – get to by clicking a player item on the server screen. Should be self-explanatory. The search button allows you to search the DB currently being played from.
4) Media list view – shows some details about a specific database and the results of the last query.
5) Clicking a media item brings up a prompt to either play the item or add it to the queue.

It is purely a remote-control at the moment, but hopefully soon it will also you to pull media files to the phone, manage them there, and sync meta-data back to the server again. My current object is to get the mobile interface usable to the point that a head-less Morrigan can be run without too much command-line-for-everything faf.

No download-links yet as everything is still changing on daily basis as I add new function. But if anyone does want to have a play, please let me know and I will be happy to hook you up with working builds… and a development environment if desired :).

Morrigan on GitHub

Tuesday, November 30th, 2010

I have finally settled on using GitHub to manage Morrigan’s source code long term and to that end have begun to get properly acquainted with using git for development. I have always liked git’s approach to managing code and my first experience with GitHub’s support staff sold me on it – supported ticket resolved and closed in 7 minutes flat.

Moving Morrigan’s code from SVN to git is fairly straight forward. The more interesting challenge is going to be moving from private source to public source. I am going to licence the code under Apache 2 licence (this plays best with my employers’ interests) and I would like to be sure that the first copy of the code to hit the public is correctly marked, attributed etc. This means the fun of adding headers to all code files… but that’s ok as I already have a script for that.

I also want to come up with a clean method of separating my code from the binary dependencies it depends on.

As I am figuring this out I am initially only going to put one simple bundle on GitHub – once everything is cool the rest will follow. The initial bundle is just a crappy eclipse-ui-calender thing I wrote as a port of the app I was using on Windows before I moved to Linux. Its not as good but uses the same data files. Its really very crap. _._;;

The GitHub project can be found here: https://github.com/haku/Morrigan

Morrigan’s CLI

Tuesday, September 7th, 2010

One really handy feature of OSGi is the ability to supplement the OSGi console with extra commands. This is particularly useful for creating very quick test/debug interfaces for each of you OSGi bundles. The console is only shown to the user when the OSGi environment is started from the CLI and and “-console” parameter is specified, so for general usage this can be left neatly hidden. So when things start to go a astray, you can just dive in and start poking around to see what is going on. In more advanced setups, the console can be tunnelled to a port and accessed via telnet or ssh.

As part of the headless version Morrigan, I have now added a handy CLI interface for testing / configuring it – essential until all this functionality makes it in to the WUI. Below is a summary of all the currently supported commands (copied form the help text).

For now I have grouped all the commands under a top-level command of ‘mn’ (short commands are easier to type). I am still working on this and trying to decide the best command structure, so suggestions are very welcome!

As an initially usability test, try and guess what all of these do. :D


mn media
mn media create <dbname>
mn media add <dir> <q1>
mn media scan <q1>
mn media <q1>
mn media <q1> <q2>
mn players
mn player 0
mn player 0 play
mn player 0 play <q1>
mn player 0 play <q1> <q2>
mn player 0 queue
mn player 0 queue <q1>
mn player 0 queue <q1> <q2>
mn player 0 queue clear
mn player 0 pause
mn player 0 stop
mn player 0 next
mn player 0 order <order>
mn play
mn play <q1>
mn play <q1> <q2>
mn queue
mn queue <q1>
mn queue <q1> <q2>
mn pause
mn stop
mn next
NOTE 1: <q1> = list, <q2> = item in <q1>.
NOTE 2: Only omit player ID when there is only one player.

I will be posting a build of the headless version in the next couple of days for general testing.

Morrigan alpha 3 somewhat delayed

Wednesday, March 24th, 2010

My current dev build of Morrigan has a lot of new stuff compared to the a2 release. In theory it now matches all major functionality of terra and I have indeed now migrated to using Morrigan as my primary media player. And for the most part it is going well.

I would really like to now make another release, but I am hesitating for 2 reasons:
1. So far as I know, the only people who are going to test it use Linux, and the Linux build has a load of what I would class as really annoying defects, listed here.
2. I keep finding more bugs. Fixed 3 more tonight.

But it is working quite nicely on XP. So in light of point 2, I will keep using it myself and resist adding new features (I need a brake anyway) until I have gone a good length of time (5 days to a week) without finding any further serious defects. Then I will package up what ever I have and call it “alpha 3”, regardless of the known issues.

I guess this is how all software releases end up – its about know that none of your existing defects are blocking and that no new issues are arising.

Not that I really expect anyone else to really care about Morrigan, and I say this without sarcasm or remorse. This project was never intended to be any more that an opportunity for me to upgrade terra and get better at developing an actual product. Oh, and to prove to myself that I could do it. :D

When to deviate from conventions

Sunday, February 28th, 2010

When following conventions of working within a framework, it is import to know when to follow and when to deviate. As was once famously said, “Rules are there to make you think before you break them.”.

Previously I mused on the possibility of creating a fixed control bar across the top of Morrigan’s main window. This is, surprisingly, a completely supported feature of RCP and some experimentation this afternoon yielded this:

It is not wired up yet, but that should not take too long. I will also remove the menu bar and re-home the few unique commands it contains. The toolbar buttons that controlled lists will be moved to the top the list editors themselves. The video can then be shown in either a view, an editor or full screen (or as a last resort, at the right-hand end of the control bar).

Also Morrigan now has global hotkey support on both Windows and Linux. Well, on windows at least. Linux global hotkey support still has a fatal bug I have yet to solve.