February 08, 2010

whats in drm-radeon-testing?

I'll try and post these regularly when I make major additions/removals.

drm-radeon-testing is the cutting edge KMS radeon branch, it is going to be rebased and things will be added/removed as they are worked on by developers. So you can base patches on it but you should talk to the developer who owns the area first.

git://git.kernel.org/pub/scm/linux/kernel/git/airlied/drm-2.6.git drm-radeon-testing

I've just pushed a rebased tree now with the following:

latest i2c algo + hw i2c engine code + all fixes squashed: This adds support for hw i2c engines found on radeons and
exposes them + sw i2c buses to userspace so i2c tools can use them. (agd5f).

pll algorithm reworking + quirks: cleans up the code to allow for the selection of the old pll algorithm on some hardware. (agd5f)

pm support so far: Adds all the current PM patches - just does engine reclocking so far using the power tables from the BIOS. (Zajec/agd5f)

Evergreen (Radeon HD 5xxx) support: basic KMS support for the evergreen range of devices - no irqs or accel yet. (agd5f)

radeon unlocked ioctl support (airlied)

bad CS recording (glisse)

misc cleanups/fixes - Dell/Sun server support ported from userspace hopefully.

The tree did contain Jerome's r600 CS checker but I've dropped it for now at his request as he has newer patches
in testing.

Bringing things up to the here and now

Okay, lets see. In the last week, I've sold my house, added a healthy baby boy to our family, had our first choice house fall through, had our second choice house fall through, and finally, bought a house. Oh yeah, and the Bruins broke their losing streak. :)

Pam did an excellent writeup about the baby's birth, so if you're interested, please go read it here: Pam&aposs Baby Birth Story
If you just want to look at baby pics, go here: http://spot.fedorapeople.org/baby/

While we were in labor on Monday, our Arlington condo was being shown, and the person decided they wanted to buy it and put an offer in. After a little back and forth, we got to a final offer, which we accepted. The only catch was that now we needed to find suitable housing to move to. We've been looking for 2 months now, so we had our short list narrowed down. We put in an offer on our first choice, which was an estate sale. It was a smallish house on 2 acres of beautiful land, we had already started planning out how we would expand and improve the house over time and where Pam would plant her garden. The house was priced very high, but the realtor assured us that it would never re-appraise for that value, so we put in a lower price offer. We assumed that they would provide a counter offer, but they refused! They were unwilling to move from the price at all. Our realtor strongly recommended that we not even consider paying their asking price. In fact, the seller's broker got so fed up with this decision that he dropped the listing entirely. Apparently, the sellers saw what the town had tax appraised the property for a few years back and intended to get exactly that much out of it and not a penny less. This was very sad, because the MLS listing had "MAKE AN OFFER!" as its first line.

Pam and I moved on to our second choice, but we wanted to go out and walk through it one more time to make sure, so we scheduled to go out with our realtor this past weekend. Our realtor was out of town, but her backup agreed to make the arrangements... but then she called us back to tell us that our second choice had gone under agreement the day before! Again, we'd gotten our hopes up, and now we really didn't know what to do. We did have a few more houses on our short-list, but they were honestly, not ideal for what we wanted. The backup realtor pointed out a new house that had just come on the market in Ayer, and encouraged us to go and check it out. It looked good on the MLS listing, but we'd been fooled before.

On Super Bowl Sunday, Pam, Baby Jimmy (we haven't decided exactly what we're calling the baby yet, James/Jim/Jimmy, so I'm trying nicknames out), Pam's parents (who flew down to help us out with the baby), and me all got into the car and went to see the house in Ayer, and wouldn't you know, it was just great! It had the space we wanted, nice high ceilings and wide hallways and a very open layout. There are a few places where it needs some work, the kitchen really needs to be redone and expanded, the finished office in the basement is a bit of a DYI job and it shows, but there is space to expand/fix it. Also, because it is in Ayer, there is no FIOS yet (the town website says it will be coming to Ayer in 6 months). :( But, we can have chickens (with permit)! It has an awesome yard with lots of gardening space and wooded areas. The lot backs up to protected land that the town owns that isn't buildable. The house is in a lovely little neighborhood, so Jimmy will have lots of other kids to play with when he gets older. I wanted to check out one other house that we hadn't yet seen, so we went to go look at it, but it had severe water damage, so I didn't get much past the front room before I knew it wasn't right. We headed back to the realty to meet our regular realtor (who was back in town) and we put in an offer on the Ayer house. During the Super Bowl, we went back and forth with counter offers, but they gave a verbal agreement to our second offer! Finally, we have a house!

My back is killing me! Babies involve so much bending and lifting. I haven't hurt this much in a really long time, but the baby is worth it. Today, we have more doctors appointments for Pam and Baby Jimmy. I'm going to try to get some small pieces of work done. I'm hopeful I can get back to work, at least part time, tomorrow. If you're waiting on me to do something, please be patient!

February 07, 2010

ncld is here, and what it is for

I sent out the "ncld" (a pun on ncurses) that I mentioned before. It is tested, and I already have tabled switched over to it. All is left is to get Jeff to apply it.

Savings in the code size are pretty good, but more importantly it is not impenetrable spagetti from 1968 anymore. And this is important if we want anyone ever hack on CLD voluntarily. People actually pay attention to shit code. To quote:

Fedora uses yum, which originally was developed by Yellow Dog. I forgot who told me this (I think it was either Jeremy [Katz] or Notting [Bill Nottingham]), but the story was that they (e.g. MSW [Matthew Wilson], Notting, and Jeremy) looked at things like apt-rpm, urpm, and yum as a base for [the] next up2date. Only yum passed the test "not to puke while looking at the source". That's how it came to be.

If you tilt your head just right, CLD is somewhat similar to Zookeeper in function (or so I heard), and one time someone asked why not just use Zookeeper. Jeff answered, "Zookeeper's API is too complex". I was concerned that someone would look at the code and think we were NIH hypocrites, because CLD's API before ncld was complex too (for no good reason - it was assembly-level complexity). Well, not anymore. What Jeff actually meant, I think, was that Zookeeper intrinsic architecture was too complex for what we want in Hail.

Why 1e100.net?

Jon Masters posted a somewhat ambiguous twit: "Why does Google use 1e100.net?" Obviously, 1e100 is the exponent syntax for gugol, but aside from that, why is it necessary to use a separate domain? It seems like a trick that is done often. Here's a short list:

Youtube uses ytimg.com. They started doing it before the acquisition by Google, and apparently it was used to host the static content. Youtube used 3-rd party CDNs for hot videos back then, but always with youtube.com for a domain. They continue that practice, except that ytimg.com now serves other random stuff now.

Google uses 1e100.net, which seems to pop randomly.

Facebook uses fbcdn.net. Obviously it means "Facebook CDN".

So, using a second SLD is clearly a common practice of some kind, that everyone in the business agrees is valuable. But how exactly does it work? Is it about the performance or security? Why only 2 domains and not 10 or 1000?

UPDATE: I have two friends called "Jon M." and other of them says:

It's for security. If you don't fully trust the security of your CDN, then you put it on a separate domain, so that content served from it can't access your users sessions.

Presumably it's because cookies are matched by domain. And Peter Jones adds:

It cuts down on http headers - especially cookies. If you put images on a second domain, it means /far/ fewer headers transferred, and fewer db lookups for the things /in/ them.

Those cookies!

February 06, 2010

the fosdem dance

February 05, 2010

Shaping young minds

I'm off to CMU at the weekend, in order to do a couple of talks on Monday (the 8th). I'll be giving an introduction to ACPI to the operating systems class in the morning, and an open presentation on Fedora, some of the challenges we face and how to get involved in Linux in the afternoon. This is as a result of our cooperation with CMU, which has led to things like the request on the right. How could we refuse?

Telling numbers

I’m currently reading a book on modern legal drafting (read: ‘plain english for dummies, I mean, lawyers’). It is very good so far, but I think this is a telling stat about lawyers: 127 pages are devoted to why clear, modern english is a good idea. That is 22 pages more than are devoted to how to write clear, modern english.

Modern Legal Drafting

Modern Legal Drafting, by Peter Butt and Richard Castle

This imbalance isn’t as insane as it sounds at first; there are some not-crazy reasons to re-use old language in legal documents, and explaining why they aren’t actually correct is a useful service. Still… given that some of the complaints about legalese cited by the book are over 200 years old, you would think the profession might at least by now realize that much legalese is a bad idea, even if we haven’t yet learned how to get rid of it…

(Favorite sentence from the book: “My client has discussed your proposal to fill the ditch with his partners.“)

February 04, 2010

video of GPU switching

Here's a really badly shot video of GPU switching in action ;-0 - whiteouts are mostly be logging out and in ;-)

February 03, 2010

The Quest for Python 3

Well, I’ve gone and done it. Thanks to David Malcolm’s excellent 2to3c tool and some hand wrangling with PyUnicode objects I was able to get D-Bus Python compiling and working on Python 3. Grab the patch and start testing it out.

I’ve also tested this under Python 2.6 but it would be nice to see if it also works under Python versions 2.6 since 2.6 has a couple of compatibility layers built in.

[read this post in: ar de es fr it ja ko pt ru zh-CN ]

DEV300_m71

DEV300_m71, svx, soltools and accessibility all 0 unused methods now. ucb reportdesign and sal nearly unused free. sc and sw creep up again. Over all count -17

hybrid graphics : the story continues (part 3)

v6 of the patch + another patch which needs some work before I can merge it are available now.

This mainly cleans up the patch architecture a lot and allow for Matthew to put his nvidia code in easier hopefully. Its moves the ATPX specific code to the radeon driver.

The second patch is from an experiment that I videod on a webcam but am now failing to upload, I'll probably get a better video tomorrow, the lighting was fairly bad for it today.

It basically allows for a delayed gpu switch ( it changes the debugfs API ), and allows gpu drivers to block the switch.

The switch file now takes ON/OFF like always, but the PCI IDs input is gone. There are 4 commands

IGD - try and switch now to the integrated device - can fail if drm drivers block it (mainly if X has the device open)
DIS - try and switch now to the discrete device - can fail if drm drivers block it (X again).
DIGD - try a delayed switch to integrated device
DDIS - try a delayed switch to discrete device.

So with X running you can echo DDIS to the file and log off X, it'll then switch as soon as X closes the drm device, and when
gdm restarts X it'll be running on the discrete GPU. If we had a shiny GUI on top of this it'd be as close as MacOSX can do it.
When you select to do a delayed switch we power up the other GPU straight away so the switch is quicker.

It needs more debugging, some open issues include:

after a few switches it can die on its ass
powering up the Intel glitches the display even when running the AMD
there may be race conditions in the patch, probably need a mutex around device open + this stuff
suspend/resume - since we D3 the card, if you do an s/r cycle it'll resume it, we need a flag in the
driver to say its powered off by the mux and to ignore s/r cycles - I've started adding this to radeon.

mjg59 has access to an nvidia laptop and is looking closely at how to make that all work.

Engaged

February 02, 2010

depcheck

As discussed at FUDCon, I've been working on a automated test to perform dependency checks for new package builds/updates, so we stop having broken Rawhide/updates/updates-testing repos.

I've been working on it for a couple weeks now, and spent a while writing code to manually examine all the PRCO (Provides, Requires, Conflicts, and Obsoletes) data for new packages and compare it to the previous version of that package. It's been a helpful exercise for straightening out in my mind how dependency resolution works, and what kinds of changes we need to worry about. For example, it's basically harmless for a new package to Provide something new, but a new Requires entry will cause problems if there isn't a matching Provide somewhere in the repos. That kind of thing.

But now I've realized that I'm really just rewriting the depsolving algorithms already in RPM and yum, and trying to ensure that my version of the algorithm is complete and correct would be really complicated and painful. So with some help from skvidal and geppetto (thanks, guys!) I've managed to rewrite it as an extension of the existing yum objects - and it seems to be working (yay!) and typical runs take 15-20 seconds, which makes it feasible to run this test for every new build and update (double yay!).

I still need to write some proper test cases to ensure everything is working as expected, but hopefully I'll have some good news on that front in the next week or two.

..On the other hand, my wife and I are heading to New Orleans this weekend. We were just going for the various Mardi Gras parades but, uh, now there's this whole Super Bowl thing going on? And it's the first time the Saints have ever been in the Super Bowl and basically the entire town appears to be going completely bonkers. Schools are cancelling classes, trials have been delayed, thousands of men in dresses and parading through the streets, dogs & cats living together, mass hysteria, &c.

So if you don't hear from me for a while, well.. I'm sure I'll be drawn back to the incredibly exciting world of RPM dependency checking in due time.

We’ve come a long way, baby

Linux Magazine March 2010 is full of GStreamer goodness: one article reviewing 4 media players, all of them using GStreamer (Banshee, Rhythmbox, Amarok 2, Songbird), and a three page article on your favourite video editor, PiTiVi!

hybrid graphics on Linux (Part 2)

Okay v4 of the patch is available at

http://people.freedesktop.org/~airlied/vgaswitcheroo/
http://people.freedesktop.org/~airlied/vgaswitcheroo/0001-vga_switcheroo-initial-implementation-v4.patch

First thing I added was power up/down methods. This calls the DRM suspend/resume methods + along with the cut power for discrete GPU. I'm not sure dynamic Windows ever does this as it seems to take a bit of work, I suspect they just run the second GPU in really low power modes. This is slow because we have to repost the ATI card after turning it back on.

I then talked to mjg59 and worked over the ATPX detection. I removed all the DMI code and it should detect *any* laptop that uses ATPX (i.e. ATI/ATI and Intel/ATI) from what I can see. I've tested on Lenovo W500 and T500 now and it appears to work on both. Would be nice if someone on a ATI/ATI and/or ASUS ATI/ATI or ATI/Intel machines could give it a whirl. I think the main problem with ATI/ATI is the poweroff methods have a hardcoded Intel PCI ID. I've no idea yet how to tell on an ATI/ATI which device is the IGD and which is discrete. Its probably more than likely the IGD is the one with the ATPX method on it.

It doesn't switch off at boot yet but I've added commands to let you do it.

echo "OFF" > switch - turns off the not in use card, so if Intel and ATI are on at boot, it will turn off ATI
echo "ON" > switch - turns back on not in use card
echo "PCIID" > switch - causes a switch with full off/on cycles.

nvidia combos appear to use a DSM method and in theory nouveau_acpi.c should be detecting that, so it might be possible for someone to hook that up.

I've also started looking at some desktop integration via gdm or logout - but its not my usual place to code so going is a bit slower ;-)

February 01, 2010

hybrid graphics on Linux

So someone thought it would be a good idea to make laptops with two graphics chips in them and switch betweem them to save power.

Now other OSes support this to varying degrees, I think XP + MacOSX require a logout cycle and Vista/Win7 can dynamically switch while running, while Linux basically falls over in a heap.

So I sat down today with a Lenovo W500 which has an Intel GM45 and AMD Radeon 3650 Mobility in it, and I wrote a patch to try and get closer to the XP/MacOSX level.

The result of one days straight hacking is at:
http://people.freedesktop.org/~airlied/vgaswitcheroo/

The patch is totally focused on the Lenovo W500, other switchers will need to add stuff to this codebase.

So what works?
Boot in switchable graphics - which boots with intel and radeon turned on
KMS drivers load for radeon and intel, radeon BIOS stored in start of VRAM (driver hacked to read it)
bind to both drivers + fbs for both.
mount debugfs - cat /sys/kernel/debug/vgaswitcheroo/switch
2
0 :0000:01:00.0
1+:0000:00:02.0
shows the 02.0 (intel) device is in charge of the MUX.
goto runlevel 5, play with X under the Intel driver, goto runlevel 3 kill X
at fbcon echo "0000:01:00.0" > /sys/kernel/debug/vgaswitcheroo/switch
barely glitches console and switches
goto runlevel 5, play with X under the ATI driver, goto runlevel 3 kill X
echo "0000:00:02.0" > /sys/kernel/debug/vgaswitcheroo/switch
goto runlevel 5, play with X under intel again.
wash and repeat.

What does it do?
So far its just switching the MUX using the ACPI method and remapping all the console to the other framebuffer device,
it also reset the bits that denotes which devices is the boot vga device which X uses to pick the primary GPU. This
means X doesn't need an xorg.conf to switch. (I think all those patches are in upstream X server).

What does it not do?
It doesn't powerdown the radeon when its not in use yet. I know the ACPI call to power it off/on, and since I have
the BIOS I should be able to repost it. So I'll try adding the callbacks into the KMS driver to do this soon.
It doesn't poewrdown the intel when its not in use yet. Not sure what I can do here, since there is no ACPI method to turn
it off. I think I can just D3 the GPU, and use the normal s/r paths to bring it back. Again requires more investigation.
The whole what ACPI + methods map to what device, how the mux ids match etc will probably all need to be stored in the DMI table.
Anything not a Lenovo W500 - probably not that hard to add other Intel/AMD variants to this, add DMI and mux switching method.
nouveau isn't hooked up - this could probably be done by some interested party - the driver hooks so far aren't very hard.
No idea about ATI/ATI or NV/NV ones either.

I'm really hoping interested community people can make this actually useful to them on other hw, I won't have permanent access to the W500 to keep this all tested in the future.

Can we do dynamic switch without restarting X?
No. X needs a lot of work, a lot more than the day it took to hack the kernel.

How do we go forward?
We probably need to add gdm support to move this forward. A logout button that is "Switch GPU", that gdm kills the X server,
then hits the switch port and starts a new X server. I'll try and talk to some gdm hackers over the next few days.
I'll try and push this into a git tree against Linus current, and we can add tested patches for other machines as they go in.
Also the DMI section is only imaginary of what I think others might need, we might have to rip it all out. Also I've no idea
if there are ACPI methods to query the switchable modes etc.

January 31, 2010

Something smells on Wall St (and/or Washington)

Wait a moment... The bailout of AIG was so critically important to the stability of the financial system, that neither Paulson, Geithner or Bernanke were involved in the process?! If something is important, surely all the top people would be closely involved? What is really going on? Some interesting facts (and speculation) Bloomberg and Zero hedge on suspicious AIG transactions before the fall. Please pay attention to the facts in-between the speculation, the truth appears to be quite ugly.

read more

My 2009 in music

I feel no need to get cynical about the state of the music industry. My perception is that each year we’re getting more great new music, not less. Where do all these bands and people and records keep coming from ? I also still don’t believe in The Death Of The Album. How can I with what I’ve been listening to this year ?

Let’s jump into the albums, more or less in order of preference. Let’s start with the four I’ve listened more to than any other album, some of them for weeks straight.

Fanfarlo – Reservoir

This was a discovery made on T61, an excellent music discovery site (now sadly hampered by a hard-to-use redesign). There were a few weeks where I only listened to this site, and this band and record is the best thing I got out of it. I ordered their debut album online the day it came out, in the nice deluxe version that includes a bonus disc and a board game (!).

As for the music, think a happier Beirut, a less tense Arcade Fire, a hint of Talking Heads in the attitude, and well-crafted dynamic uplifting songs. Lovely trumpets, xylophones and other instruments are sprinkled throughout. Infectious is the word. I have a longer record review half-done that I should post, but for now this will have to do. ‘Finish Line’ is the track that hooked me, with those trumpets racing, and there’s not a single bad track on the whole album.

Saw them play live finally yesterday, a short and sweet set that left me longing for more.

Antlers – Hospice

No other album in 2009 hurt so sweetly as this one. The story of a man losing his loved one to cancer. Both deeply depressing and uplifting at times; but always interesting. The guitars drift between shoegaze and Buckley, and that voice etches into your soul. After much internal debate, my favourite track has to be ‘Kettering’ – when those drums crash in and the guitars start washing, my heart tears up. But it’s a close tie with the ethereal heavenly last minute of ‘Thirteen’ – after the guitar noise, a female voice rises up begging us to pull her out.

The whole album is a fever trip start to finish, and best listened to as an album entirely. Let it sit in a few times in a row; it takes a while to dip in but it’s worth the ride.

The XX – XX

Judging from the end of year lists, a very popular choice, but well-deserved in my opinion. Just like my favourite band ever, Afghan Whigs, they fuse rock with R&B, but come out on the completely opposite side of the spectrum. The album ends up being a spacious glacial volcano. Simple guitar licks, soft bassy drum beats, open air, and two very complementary voices. Favourite moment on the album is around 1:40 in ‘Heart skipped a beat’, when her voice falls over going up on ‘left me waiting’. I was bored out of my mind the first time I played it. I left it on regardless, listening to it passively, and it clicked forever since as soon as I signposted each track mentally.

Phoenix – Wolfgang Amadeus Phoenix

I don’t think this band will ever be able to do wrong by me after their previous third album – even if I started liking them by proxy because of the opinion of a friend of mine about them. She was right all along. And this album confirms it. While I’m still not sure about the middle parts ‘Love like a Sunset’, the album is full of strong tracks. The first time I heard ‘1901′ I was depressed about their change in style, but a few listens later it was clear I should have listened better. I was disturbed only by the wallpaper – but the beating heart of song underneath was still classic Phoenix. Phoenix is one of the few bands who manage to blend the modern day style with an 80’s nostalgy, ending up sounding both uplifting and melancholic at the same time.

For some reason, although it doesn’t have the strongest Phoenix lyrics ever, ‘Rome’ is the standout track for me. The song has so many good moments, from the sad high notes before the break, over the bouncy guitar notes, to the shimmery guitars that build up in the payoff, to the way every Rome sounds different when he strings along five or six in a row – everything fits, and makes you long for something you didn’t even know you were missing.

Not a flawless record for sure, but irresistible nonetheless.

Other excellent albums of the past year:

  • Gossip – Music for Men. Gossip makes the jump from punk rock with soul to soul rock with punk. Songs like Heavy Cross and Love Long Distance are pretty much perfect. The whole album is good too, but not enough surprise to make the above list.
  • Patrick Watson and the Wooden Arms. Worth the wait, excellent album. Some excellent concerts as well. ‘Big Bird in a small cage’ is probably the prettiest song of the year. I’m a sucker for beautiful voices and excellent harmonies. Opener ‘Fireweeds’ is pretty amazing too.
  • Yeah Yeah Yeah’s – It’s Blitz. Although a strong shift in musical direction, I had hoped for more boundary pushing. But there’s no arguing with the airy beauty of a track like ‘Skeletons’, especially when the sound of a bag pipe guitar brings in the hordes in the second half of the song. And Karen O still has the sexiest most animal female voice on the planet.
  • Plants And Animals – Parc Avenue. Discovered at Primavera sound, making an equal parts indie equal parts psychedelic sun-baked desert road rock, much like Delta Spirit or Walkmen. Especially excellent live.
  • The Veils – Sun Gangs. Third album, rock with a poetic twist, sound like the after-effects of getting snakebite. A review on Drowned In Sound completely slagged off my favourite track, ‘The house we lived in’. How anyone can hate those beautiful harmonies and swirling vocal lines is beyond me. Seeing them next week!
  • Florence and the Machine. Man, that woman can belt! Rabbit Heart, Kiss with a Fist, awesome songs. Not to mention that heavenly ‘You’ve got the love’ cover, both in its original cover form, and as a reworking combined with the XX. I just don’t know which of the two to choose.
  • Mew – No more stories today. This album may still prove to be too weird for me. How many albums do you have where a track can be played back in reverse to reveal another track ? If I have to pick one track, I’d go with ‘Introducing Palace Players’, with that weird bouncy unnatural bass line that still proves to be robotically danceable, before it morphs into a slowed-down disco stomper. These guys are quite simply crazily beautiful.
  • White Lies – To Lose My Life. Can an album be more by-the-book teenage angst? As my sister says, how many bands do we really need that sounds like Joy Division ? Well, the answer, for someone who has never been able to really get into Joy Division, is – as many as we can. White Lies may be cheesy, but they pull it off so well. I might throw up if I see the singer shake his fist to the sky one more time (every single goddamn song), but each song on that album just simply works. I doubt they can pull it off again.

Runners-up:

  • Fever Ray. I’m definitely not a huge electronica/trip hop/… fan, but some of the things The Knife has done are awesome, and while it’s not a record for every day, the Fever Ray album has some very strong moments.
  • Arctic Monkeys – Humbug. I’ll never be their biggest fan, but these guys are the real deal music-wise. They deserve all they’re getting. ‘My propeller’ is my stand-out.
  • Editors – in this light and on this evening. Was I mentioning Joy Division before ? Definitely a change in direction, and it works well, but ultimately doesn’t grip me as much. Happy to see they made ‘You don’t know love’ the new single – easily the best track; the tension release of that guitar lick at the end right after the pause is killer.
  • Drive like Maria – Elmwood. A Belgian/Dutch band. A certain Flemish expression roughly translates to ’swings like a tit’, and that’s what this album does. Nothing inventive here, in a style that’s not particularly my favourite, but just really well executed. Something between AC/DC and Queens of the Stone Age. Bonus points for having the best female guitarist in our area – it’s amazing to see how she transforms on stage, and enjoys every note and chord she’s wrestling out of that guitar.
  • Isbells. Another Belgian band. We don’t have the roots for country folk, but this album just works. Simple and beautiful. If you really need references, Bon Iver, Fleet Foxes and Iron and Wine seem to crop up a lot.
  • Customs – Enter the Characters. As long as we’re talking Joy Division… I was expecting them to be a one hit wonder, but I have to admit I quite like their whole album. It’s not always as strong, especially lyrically, and you can probably tell it’s not a native English band, but overall they pull it off really well. I guess I’m just a sucker for this kind of sound. Most of all I’m surprised to see it reach the lists of so many Belgian people I know as well.
  • Emiliana Torrini – Me and Armini. Jungle Drum was one of my favourite tracks of the year.

Not sure yet:

  • Low Anthem – Oh My God Charlie Darwin. I wasn’t particularly impressed when I first heard the album, but I was so impressed by last night’s show that I’m going to have to give it a few more spins.
  • Dirty Projectors – Bitte Orca. I saw them open once for Explosions in the Sky, and they were, uhm, “different”. I’m still not sure if I like this album, and I should give it a few more chances.
  • Bat For Lashes – Two Suns. One of the albums I looked forward to most, but doesn’t grip me in the end. But there’s no denying the world class of songs like Glass and Daniel.

One album I couldn’t get at all (and everything tells me I should have) – Animal Collective, Merriweather Post Pavillion.

Special mention to one late discovery – I’ve been addicted to ‘She Wants Revenge’ for the last two months. They had always been on my ‘to listen’ radar on the strength of one song, but I had no idea they already had two albums out. Did I mention Joy Division yet ? Even though they’re only a duo, they lay down quite a sound. Personally, I don’t really get why for all these bands (including Interpol) the Joy Division name keeps cropping up – I can tell them apart without any problem. They each bring something of their own to the mix, and She Wants Revenge – while at times a little juvenile, but endearingly so – is very physical and danceable. Perfect gloomy day music!

As for concerts, in no particular order:

  • Antlers, Bush Hall, London. There were at best 500 people there, and it felt very much like a last concert before the big discovery. I’ve never seen Jeff Buckley live, but what I felt that night must have come very close to it. Live the music was even more haunting and painful and searing. It’s amazing that that voice comes out of that small body. Looking forward to seeing them again in Belgium in a few months!
  • The XX, Razzmatazz, Barcelona. I didn’t have a ticket, and queued with 30 other people that all were trying to get in without a ticket. It was worth the wait, although watching a band with as much space in the music as this one in a country like Spain is not ideal. Sometimes I just want to yell at people to please shut the fuck up.
  • Patrick Watson, Depot, Leuven. There simply aren’t that many real through-and-through musicians. This guy is the real deal; he lives and breathes and whispers music. The shy giggle and laughs aren’t an act, and they work. But the way he changes his vocal lines to suit the mood of the evening… And the encores, going into the audience with five speaker horns strapped to his back, the whole band following and making the audience quiet down as they perform in the middle of the room…. just excellent.
  • Explosions in the Sky, Luchtbal, Antwerpen. These guys give it all. There is still something about the music coming from Texas… I’m not a fan of instrumental music, but explosions keep it interesting all the way through. Adding vocals would only ruin it.
  • Spiritualized performing Ladies and Gentlemen we are floating in space, Royal Festival Hall, London. Well, not much more I can say. One of the albums that defined my young adult life, still in my top 20, performed in its entirety with about 30 people, including horns, strings, and choir. It’s still a strange concept to know exactly what’s going to be played, but this was performed to perfection.

As mentioned before, the best musical site I discovered the past year is The Sixty One. Feel free to ask me to invite you or befriend me if you know me and you’re on that site.

And with the National releasing in May, I have a feeling this is going to be another awesome year for music.

A Google ad with the National in it ?

Weird. But good weird. Here it is.

Thanks to Ticketmaster I have 0 tickets for their show in London. But I’ll still be buying their new album come May.

January 29, 2010

Andrey Savochkin on Rusty Russell

Just saw Jon Masters quipping on Facebook: "netfilter scares me", and someone commented that nftables look promising. Apropos those, some years ago (in 2000 or so), I touched bases with Andrey, who was probably more known as a maintainer of eepro100 driver than any number of bigger things he did. I think he invented the beancounter. These days he's gone into the depths of Parallels, never to be seen again. Anyway, Andrey said (approximately):

I have an enormous respect for Rusty. That guy worked on the problem of firewall in Linux for years. And he had the fortitude to throw away his own old crap and write it again from scratch. Twice! [e.g. rejecting ipfwadm and ipchains — zaitcev])

Is Rusty trying to do it again? Need to google nftables one day.

January 28, 2010

kamaloka-js 0.9.0 released

I am proud to announce the second release of the kamaloka-js AMQP bindings. This release brings with it a high level API modeled after the new Sender/Receiver and addressing API’s being developed in the Qpid project. It is intended to bridge the gap between the 0.10 protocol and the upcoming 1.0 protocol. I have also simplified the code base and improved the code generator. Because we are getting so close to implementing the complete 0.10 protocol spec, we have bumped the version to the 0.9.x series to indicate a redefined focus on stabilizing the current code base. You will notice significant API changes from 0.1.0 to 0.9.0. We hope to not have to make too many more changes during the current cycle of development and hope to get a 0.10 version out once we have completed coverage of the entire spec.

Some of the highlights of this release are:

  • Rework API to conform to the new Sender/Reciever API and addressing format
  • Supports multi-channel/multi-frame parts of the spec
  • Uses js.io class infrastructure
  • Generated code now easier to read with decoders implemented in a class hierarchy
  • Rewritten dispatch layer – event code now works on the message layer instead of the frame layer even for low level dispatching
  • Much closer to implementing 100% of the 0.10 spec
  • Infrastructure in place to start working on the 1.0 spec

Give me the code

About Kamaloka-js

Kamaloka-js is an implementation of the AMQP messaging protocol in native JavaScript. It is setup to be used with Orbited but can be used with any library which produce TCPSockets in the browser similar to Orbited. Kamaloka bindings are generated from qpid XML protocol description files.

[read this post in: ar de es fr it ja ko pt ru zh-CN ]

thousands of one – hidden treasure – march, 2009

I took this video with a Flip-cam back in Alllston, MA in March, 2009. I just found it on my hard drive and thought others might like it. It’s low-fi, but a lot of fun. (I would pay quite a bit of money for a handy camera that actually had good sound pick-ups – makes up for poor video quality.)

The band is Thousands of One. My brother is the drummer and they are based out of Ithaca, NY.

Thousands of One – Hidden Treasure from Christopher Blizzard on Vimeo.

January 27, 2010

Flattening the model

In my quest for cleaner code in Kamaloka-js I have been working on simplifying the dispatch model.  AMQP has some interesting features built into it to facilitate real-time functionality along with message prioritization.  To accomplish this messages can be sent on different queues and tracks, and also be broken up into segments which can be further broken up into frames.

Frames

Frames are the basic building blocks of the AMQP data stream.  They contain complete headers that describe queue, track and segment that is currently being constructed.  The payload of a frame (the segment being built) can be broken up into arbitrary sized byte arrays which are then reassembled based on the channel and track they are sent on.  In this way applications with memory constraints can request that frames be no bigger than what the application can fit in memory.  A typical frame header looks something like:

{
  channel: 0,
  track:1,
  is_first_frame: 1,
  is_last_frame: 1,
  is_first_segment: 1,
  is_last_segment: 1
}

Segments

Segments are like frames but instead of an arbitrary split on a data size, each segment is split on struct boundaries. That is to say, when you receive a complete segment you can be sure that it can be fully parsed. There are currently four segment types: A control segment, command segment, header segment and body segment. Command messages are currently the only type that can contain a header and body segment. For instance, the transfer command is used to send messages to and from a queue. It would contain header segments which could be used to route the entire message and it would contain a body segment which contains arbitrary data the user application cared about. Each segment is broken up into at least one frame. Multiple segments would never be sent in a single frame.

Channel and Tracks

A channel is just an integer that denotes related frames and segments. One can think of each channel being a list of incoming frames which are ordered correctly. Once the last frame in a channel is seen, the message is constructed and the channel is flushed and ready to receive a new message. In this way, multiple messages can be received at the same time by utilizing different channels but only one message can be sent on a single channel at a time.

Tracks are an exception to the one message per channel rule. There are two tracks in the current spec. The control track (track 0) and the command track (track 1). Controls preempt commands on a channel, so you can be in the middle of receiving frames on the command track and a control can come in on the control track and you must respond to that first.

This all sounds complicated but you can just think of the channel/track combination as being one entry in an hash. For instance frames coming into channel 0 and track 1 would be given the hash “0.1″:

message_channels["0.1"].add_frame(incoming)

First pass – Frame dispatching

At first it was easier to think of the frame and segment issues as different layers. At the lowest layer I would decode and dispatch each frame and then pass it off to the segment layer once a complete segment had been decoded. The segment layer would then collect the segments, relate them to each other, and then construct the full message. The frame layer looked something like this:

Flowchart showing the frame decoding layer of the kamaloka-js AMQP bindings

Flowchart showing the frame decoding layer of the kamaloka-js AMQP bindings

The dispatch would then pass it off to the segment decoder.

This became overly complicated because each segment had varying degrees of metadata and the body and header segments didn’t map to the message object very well. I could have gone ahead and created a segment object but I wanted to simplify the code.

Flattening the frame and segment layers

As it turned out flattening the model only added a couple of more steps to the current frame layer. Since frames and segments are just two different ways of breaking up a message for transfer over the wire, combining the two in the same layer made sense. What I ended up with was this:

Flowchart showing how the Kamaloka-js AMQP bindings decode frame and segments into a message

Flowchart showing how the Kamaloka-js AMQP bindings decode frame and segments into a message

If you notice I now only create a new message if it is the first frame and first segment on a channel. When I see it is the last frame I incrementally decode the segment but I only dispatch the message once the last segment is seen. In the end, these minor adjustments allowed me to strip out a whole layer of redundant code. It also simplified the low level event code as I used to have to manage callbacks for each segment in order to construct a message. Now events only trigger once a full message is received and not when each frame or segment is received.

[read this post in: ar de es fr it ja ko pt ru zh-CN ]

January 26, 2010

spamassassin-3.3.0 RPM Packages for Fedora or RHEL-5

spamassassin-3.3.0 release on January 26th, 2010 by the Apache Software Foundation.  This is a very important upgrade for mail administrators as this is the first major version upgrade in nearly 3 years.  While many improvements were made to the rules, for the most part it is almost a simple matter of a drop-in replacement for spamassassin-3.2.x.  3.3.0 trunk has generally of better quality in both stability and spam detection capability than 3.2.5 for many months now. I personally have been running snapshots leading to this beta release on my production RHEL5 server since early 2009.

Picture for no particular reason except that any picture makes a blog post more interesting.

While 3.3.0 is much improved, the most exciting part of the 3.3.x series is improving upstream processes to enable more frequent rule updates, in order to better combat changing spamming patterns.
  • Rule development and auto-promotion to stable rule updates happen in the same source control, encouraging new and updated rules to land in the sa-update channel far more regularly.
  • Expanded recruitment of additional volunteers for the Nightly MassCheck.  While any volunteers willing to sort mail are helpful, non-English speakers are in high demand.  More variety of types of ham and spam used in nightly automated checks of SpamAssassin helps to improve the quality and safety of rules.  A larger sample size allows for Rescore MassChecks to happen more often, allowing for more frequent balancing of new rules and greater overall safety.  If you can sort mail into separate ham/spam folders, you can help to improve spamasssasin.

Major Changes Specific to Fedora/RHEL SpamAssassin 3.3.0 RPM Packages
  • See upstream's release notes for complete details of this new upstream release.  Many of the rules were made safer especially for a few non-English languages (Japanese and Italian tested), while many other rules were improved or added since the 3.2.x series.
  • Rule updates are now ENABLED BY DEFAULT on a nightly basis.  As of 3.3.0 upstream considers rule updates mandatory.  You may edit /etc/cron.d/sa-update if you wish to modify or disable the scheduled time where update occurs.  /usr/share/spamassassin/sa-update.cron is the script that runs.  Channel definitions are defined in .conf files contained in /etc/mail/spamassassin/channel.d/ where you can see the simple config format and make your own .conf file if you wish to add additional channels.  You will note that the script updates by default only if it sees a spamd, amavisd or mimedefang daemon running.
  • Justin Mason's SOUGHT anti-fraud channel is enabled by default for nightly updates.  From personal testing SOUGHT is the only non-default channel that I personally trust as safe and effective.  Read about its interesting auto-generation methodology.
  • Subscribe for Spamassassin RPM News at Warren's announce-only mailing list.  You will occasionally receive news and helpful tips to improve your spamassassin configuration.

Upgrade Notes (some stuff that I'm aware of that may effect Fedora or RHEL users)
  • amavisd-new-2.6.2 is the minimum compatible version with spamassassin-3.3.0.  This ticket contains a possible quick workaround to make your old version of amavis compatible.  This is only an issue for EPEL5 users which currently has an older version of amavisd-new.  Steve is aware of the issue and will be upgrading the EPEL5 version soon.
  • maia-1.0.2a is INCOMPATIBLE with spamassassin-3.3.0.  Upstream is aware of the issue and said they are working on this.
  • mimedefang versions in EPEL5 and Fedora are reportedly good.
  • STOP USING SARE or OpenProtect.  They died a long time ago.  Some of their rules are dangerous or redundant.  Many of the better rules were integrated into spamassassin upstream.

Download RPM Packages

  • Packages for Fedora 12 or Fedora 11.
  • RHEL5: I personally use these scratch builds.  You will need some new perl module dependencies from EPEL5. The plan is to push spamassassin-3.3.0 final + new perl modules to RHEL-5 sometime early 2010 after extensive testing.  But for now these are unofficial test packages.  Please file bugs if you see any problems.
  • Optional packages: These packages are not required, but they probably will improve your spam filtering results.
    • yum install perl-Mail-DKIM perl-Mail-SPF pyzor perl-Razor-Agent

File Bugs
  • SpamAssassin Bugzilla for most issues.  If you report upstream please indicate the exact package version you are running as reported by rpm -q spamassassin and where you obtained that package.
  • Red Hat Bugzilla if you are having an issue specific to my Fedora or RHEL5 package.

Subscribe for Fedora/RHEL SpamAssassin RPM News
  • Warren runs this announce-only mailing list.  You will occasionally receive news and helpful tips to improve your spamassassin configuration, or warnings of new problems and workarounds, or news about how you can help to improve spamassassin.

Help Wanted: Non-English Volunteers

  • Do you receive lots of non-English legitimate mail?  Want to help to improve SpamAssassin upstream for your language?  While we need help from speakers of any language, we especially need volunteer participants from China, Hong Kong, Taiwan, Korea or other Asian countries. 
  • Volunteering is easy, you only sort mail into folders then run a script on your folders every night in a cron job, which then uploads your logs to the central server.  Your mail remains private.
  • Contact Warren Togami or Fedora's auto-mass-check recruitment coordinator Nick Bebout if you are interested in joining.

Brain damage

Tim pointed me to a bug report about GStreamer. I couldn’t resist from commenting on a comment that questioned my mental capacity :)

(In reply to comment #4)
> I still wonder who invented such ugly naming scheme for gstreamer plugins?

I don’t think you wondered really hard because it’s not that hard to find who
did. It was me.

> Who
> is this completely braindamaged guy, who combines all plugins into several
> packs, which names says nothing about their actual content.

If memory serves, the same guy that you met in person some years ago.

> I still hope, that sometimes there will be a great developer, who will split
> these good/bad/ugly/etc packages into something more suitable for end-users.

And I still hope that some people will not assume everyone else is stupid just
because they’re talking on the internet.

Whether or not the GStreamer plugin-split and its naming was a good idea is obviously debatable. I still think that we did the right thing there, and he could have read the explanation.

But regardless, people, seem to think that because it’s the Internet, common courtesy isn’t necessary. Especially in our communities, people can get abrasive online where they wouldn’t be in real life because they have a real person in front of them.

Often, these people emulate people like Linus Torvalds, who is known to have a certain abrasiveness. Linus gets away with it because he’s made undeniable and genius contributions to the community. The problem are the disciples, taking him as an example, confusing correlation with causality, and copying his abrasive style thinking it will lead to genius.

I’m extrapolating this particular bug report here – I can’t or won’t comment on his contributions, which are many as well. I know about a lot of them, since he interviewed here for a job a year ago. I’m mentioning this to make sure you know that the Internet is not always as anonymous or isolated as you think it is. You can’t delete stuff from the net, and people will evaluate you by your online presence, for better or worse.

And if the person commenting is really interested in the plugin split, feel free to talk to me, but let’s keep the chatter out of the bug report.

Now excuse me, I’m late for my CAT scan. Better safe than sorry!

UPDATE: someone commented that I breached etiquette; so I removed some details like the bug report and a part of the comment. I should have thought it through, I had no idea what I did was considered as such. My excuses.

January 25, 2010

HTML5 video and H.264 – what history tells us and why we’re standing with the web

For background on the free software angle on this story please check out Robert O’Callahan’s post on this topic. Also check out Mike Shaver’s shorter background post as well. This post differs from theirs in that I want to talk about network effects, why codecs should be considered a fundamental web technology and what the long-term effects of the choices at this inflection point might look like.

Recently Youtube announced that you could test out an HTML5-enabled version of their site. They said that they were doing this partially based on people’s “number one request” that Youtube do more with HTML5. (They left out the other half of that #1 request – that the implementation be based on open codecs, but more on that later.) Not to be outdone, Vimeo rushed to announce a beta version of their player based on their site that claims HTML5 support as well.

To be clear, this is great news. This is just the latest in a long string of changes for video on the web. We started with a raw “player” delivered by Real Media. Then on to media embedded directly in pages via Windows Media + Quicktime. More recently video on the web has been a a platform play by Flash. And finally to a place where media becomes a first class citizen on the web without a single source provider. These moves by Google and Vimeo (and before either of them, DailyMotion) show that things are changing for the better, and faster than I think anyone could have imagined.

The players from Google and Vimeo do present a pretty serious problem, though. Each of these require a proprietary H.264 codec to be able to view them. These codecs aren’t compatible with the royalty-free web standards that the rest of the web is built on. The fact that they are being so unabashedly hyped along with the new darling of the web – HTML5 – means that most people don’t understand that something very dangerous is taking place behind the scenes.

If you think that this isn’t an issue that’s worth worrying about you need to read the rest of this post. In particular the history of GIF shows us what happens when patented technologies are used on the web and what happens when network effects over-run the natural drive to royalty-free technologies at scale. MP3 pricing gives us a glimpse into the strategy around H.264 licensing and what the landscape might look like 5 years from now, assuming H.264 were baked into the web platform as a requirement. I’ll also talk about other options that might be coming in the near future that most people don’t know about.

The Web Exploded on Royalty-Free

The web has always been based on the assumption of Royalty Free. In fact, participation in a working group at the W3C requires that any parties disclose and make available any essential claims on the technology covered by that working group.

But that’s just a technicality. The truth is in the tests: you can still build a web browser, spider, client, web server, image editor, a JS library, a CSS library, an HTML editor, a web publishing system, commerce system – anything that is based on fundamental web technologies – without asking anyone for permission. This is a fundamental reason why the web has spread everywhere. Because everyone had the chance to add to the mix.

It’s worth saying twice. Anyone can create technology or services on the web and they don’t have to ask anyone for permission to do it. This is why we’ve had billions of dollars of investment and a fundamental shift in the way that western society acts and communicates – all in the course of a very short period of time. The web grew up on Royalty-Free.

Learning from GIF

The web in 1999 was a lot smaller than it is today, so a lot of people don’t remember what happened back when Unisys decided to start to enforce their GIF-related patents. GIF was already widely used on the web as a fundamental web technology. Much like the codecs we’re talking about today it wasn’t in any particular spec but thanks to network effects it was in use basically everywhere.

Unisys was asking some web site owners $5,000-$7,500 to able to use GIFs on their sites. Note that these patents expired about five years ago, so this isn’t an issue today, but it’s still instructive. It’s scary to think of a world where you would have to fork up $5000 just to be able to use images on a web site. Think about all of the opportunity, the weblogs, the search engines (even Google!) and all the other the simple ideas that became major services that would never have been started because of a huge tax being put on being able to use a fundamental web technology. It makes the web as a democratic technology distinctly un-democratic.

We’re looking at the same situation with H.264, except at a far larger scale.

So let’s talk about what makes a fundamental web technology, and how they should be licensed. First, the licensing. I think that Apple said it best:

After careful consideration of the draft patent policy, Apple believes that it is essential to continued interoperability and development of the Web that fundamental W3C standards be available on a royalty-free basis. In line with the W3C’s mission to “lead the Web to its full potential,” Apple supports a W3C patent policy with an immutable commitment to royalty-free licensing for fundamental Web standards. Apple offers this statement in support of its position.

(The post then goes on to talk about an opt-out mechanism for participating members.)

This leads to the obvious question: is the codec a fundamental web technology? The HTML5 working group argued and punted on the issue. Given that the standard is mum on the issue it falls to the actors in the market to determine what’s required to support HTML5. Given the state of online video today this basically boils down to one actor: Google.

Google has a near-monopoly in online video thanks to the ubiquity of Youtube. This means that they are the effective arbiter of codec choices for HTML5 video. If you want Youtube to work, you have to support whatever they are using. (Right now that’s Flash or a native Youtube app for mobile devices, but it’s clearly changing.) Let’s set up a strawman and say that it’s going to be H.264. (I’ll discuss later why I don’t think that this will be a requirement, but let’s say that it is.)

Their choice for H.264 had an immediate effect. It’s a signal to the market that it’s OK to start using H.264 as the main codec for HTML5 video. This is proven out by Vimeo’s HTML5 beta player launch. Vimeo is a secondary player, but were perfectly happy doing what Google did. The effects of that move have spread quickly and you can see it in people’s reactions: John Gruber getting angry at Mozilla as a result of Google’s actions, people on twitter claiming that we don’t support HTML5 at all because of Google’s use of a proprietary codec (Not true! Firefox actually leads in HTML5 support in a huge number of areas.) and Gizmodo’s choice comment: “Luckily, YouTube accounts for a hefty chunk of said architecture, their catalog is rendered in HTML5-friendly h.264 format. This is what network effects look like in real time.

So if you think that Google has settled on H.264 as the only codec they will support (unlikely) it would appear that they have set us up to have another GIF-like situation. Note that I think that this will not actually be the case, as I discuss later, but it’s worth thinking about as a framework. So instead let’s talk about what that situation would look like, with MP3 as the model for the H.264 licensing strategy.

Rising Costs and Unpredictable Licensing

So what can we learn about H.264’s licensing strategy as it pertains to pricing? Much like GIF we already have a model to look at that is already near the end of its cycle: MP3. Network effects and goverment-sponsored monopolies make a very powerful combination. But getting the most out of them requires a very specific strategy, one we saw with MP3 and we’re seeing again with H.264.

History is instructive. We know that MP3 was licensed quite liberally early in its lifespan. Before 2002, “no license fee is expected for desktop software mp3 decoders/players that are distributed free-of-charge via the Internet for personal use of end-users”. They changed that after the network effects had already taken their toll. Not only were decoders free for free software, but bulk flat rate licenses were available to large distributors. That’s how widely distributed software picked up with ability to play back MP3-encoded files.

But as the cycle continued and MP3 became a requirement for playback the pricing changed to where we are today. So let’s talk about what it looks 8 years later.

If you look at the public published rates for a couple of the MP3 licensors (and there are more than just two) someone who wanted to use it would be looking at a royalty rate of about $1/downloaded unit. So if you were doing, say, two million downloads a day you would be looking at about $2,000,000 per day just to have permission from those companies to include an MP3 decoder. Could you negotiate a lower rate? Probably. But that gives you a sense of the scale if you’re a small provider in a world where getting started on the web is hard and you don’t have much negotiating power.

People casually say that we should support licensed codecs like MP3, but they haven’t done the research. We have.

Much like MP3, H.264 is currently liberally licensed and also has a license that changes from year to year, depending on market conditions. This means that something that’s free today might not be free tomorrow. Like sending an H.264 file over the Internet.

In fact there are already royalties charged to some people using H.264 for streaming, according to Jan Ozer. Some quotes from that article:

Whenever I speak at industry groups about H.264, and detail the upcoming royalty obligation, some attendees are invariably surprised that using H.264 will generate royalties. Here’s what you need to know about H.264 and royalties, in an except from an article that I wrote for StreamingMedia.com [ed: full article here.]

When I spoke with Harkness, he stated that the patent group hadn’t yet decided the license provisions for internet broadcast, or even if there would be a license, though he conceded that it would make little sense for the patent group to forego this revenue. The only thing certain is that the royalty provisions must be announced by January 2010 for royalties that would be payable the following year.

OK. This paragraph hits all of the big points:

  • Right now there aren’t any fees for “internet broadcast.”
  • But there might be in the future
  • The license changes from year to year.

Remember, this is still very early in H.264’s history so the licensing is very friendly, just like it used to be for MP3. The companies who own the IP in these large patent pools aren’t in this for the fun of it – this is what they do. They patent and they enforce and then enjoy the royalties. If they are in a position to charge more, they will. We can expect that if we allow H.264 to become a fundamental web technology that we’ll see license requirements get more onerous and more expensive over time, with little recourse.

Selective Enforcement

One reason why a lot of this isn’t known is because patents can be selectively enforced. And because it’s still early in H.264’s lifespan it’s extremely advantageous to lightly enforce the patents in the patent pool. MP3 and GIF both prove that if you allow liberal licensing early in a technology’s lifespan, network effects create much more value down the road when you can change licenses to capture value created by delivering images and data in those formats. Basically wait for everyone to start using it and then make everyone pay down the road. (Three words: unpredictable business costs.)

The other problem is that the Internet, because of it’s global nature, hides many of these costs. Everyone – and I mean everyone – uses tools from parts of the world where there are no software patents to transcode and edit videos. (One of the world’s largest free software downloads after Firefox? VLC. 111M last time I checked.) This grey area for tools means that these heavily patented formats gain much of the same advantage as free formats – lots of free tools and tons of ad-hoc support from free software people – but with the ability to still enforce and monetize in parts of the world where patents are enforced. It’s actually a brilliant strategy, even though the outcome is that the true costs of patents are hidden from the view of most people.

So What Now?

Remember that my setup for this was that Google’s choice was going to be H.264-only and that their decision would have network effects on the web, setting up another GIF-like situation for the web.

But I, like many others, have reason to believe that H.264 will not be Google’s final choice. There’s good reason to believe this: they are purchasing On2. On2 has technologies that are supposed to be better than H.264. If Google owns the rights to those technologies they are very likely to use them on their properties to promote them and are also likely to license them in a web-friendly (i.e. royalty-free) fashion. Google actually has a decent history of doing this. In particular you can get a sense of this from their post on The meaning of open:

If there are existing standards for handling user data, then we should adhere to them. If a standard doesn’t exist, we should work to create an open one that benefits the entire web, even if a closed standard appears to be better for us (remember — it’s not!). In the meantime we need to do whatever we can to make leaving Google as easy as possible. Google is not the Hotel California — you can check out any time you like and you CAN, in fact, leave!

In this case they were talking about user data, not video formats. But it’s the same set of principles at work. It’s also very hard to imagine Google licensing proprietary codecs as a revenue stream. It just doesn’t align with how they have worked in the past.

So it’s very likely that Google will be using a codec that’s superior to H.264 in terms of bandwidth usage and will also have web-friendly licensing attached to it. I know that at Mozilla we would support that and would very likely incorporate that technology into our browser, much like we did with Theora and Vorbis.

In Summary

So that’s the case for supporting free formats and also describes why we should be avoiding H.264 as a fundamental web standard. We don’t want to set ourselves up with another GIF situation and set up licensing like MP3 where we’ll be dealing with increased costs and restrictions over time. Google is likely to support something other than H.264 on Youtube and we’re likely to end up with something that’s better on a royalty-free basis as a result. And as I mention below, Theora and Vorbis are still excellent alternatives even if they for some reason don’t do as we expect.

Mozilla and Firefox continue to stand with the web on this topic. We don’t think that fundamental web technologies should be encumbered with patents and our actions and messages reflect that. We hope that you will stand with us on this.

A Note About Theora and Vorbis

Many of you might notice that I haven’t talked much about Theora or Vorbis. In fact some of you might read this post as me throwing them under the bus. That couldn’t be further from the truth. What I’ve really been talking about is one part of a larger ecosystem. What the web is really asking for is a codec that is implemented everywhere, that competes well on quality and doesn’t come with GIF-like surprises. Theora and Vorbis fit every part of this bill. You can actually use them on all of the desktop browsers, either via native support or via a Java plugin that actually works pretty well.

On the quality side what we’ve been able to do at Mozilla, with the help of the rest of the Xiph community, is to show that even though Theora is based on older, royalty-free technology, most people can’t really tell the difference between a video encoded with a decent Theora encoder and a video encoded with H.264.

But given the situation with submarine patents it would actually be a good idea for us to have more than one royalty-free codec available for browser vendors, site owners and content publishers. That way if one of them turns out to have issues, you just turn one of them off and continue to use the other one That’s why I think that if Google did offer a new codec that it would make a wonderful addition to the list of codecs we could use on the web. And if they want to use it on Youtube and other Google sites, that’s great. But it’s good to have other options in the wings.

So this means that Theora and Vorbis aren’t going anywhere. There are other reasons to continue to support (and promote!) Theora and Vorbis as well:

  • There’s a growing corpus of Theora content on sites like the Internet Archive, Wordpress and Dailymotion, not to mention all the private sites that are out there starting to use it.
  • Vorbis is far better quality than MP3 for the same bandwidth and I would expect that Google would use it as the audio codec of choice to match a free video codec.
  • Vorbis is actually supported in a large number of hardware devices, often quietly. My phone supports it, for example.
  • Theora with Ogg as a container actually is a fantastic live streaming format for HTTP. This is often overlooked. While Apple has had to add a bunch of code and description files trying to get live streaming to work with their proprietary H.264 codec and MPEG containers, we’ve been doing live streaming over HTTP out of the box ever since Theora and Ogg were part of the browser without any changes to standards. This is largely a function of history. Vorbis and Ogg were originally built as a radio streaming format. It’s possible to jump into the middle of a stream and start decoding. (As a side note it will be interesting to see if Google ends up trying to build their own container format. Ogg is simple, and it works.)

So I wouldn’t expect these formats to go anywhere. Instead I would expect to see them implemented everywhere either as backups or to support existing content and streaming.

January 23, 2010

How to build a slingshot antenna launcher

Slingshot antenna launcherSlingshot antenna launcher Slingshot antenna launchers are used to launch a line over a tree branch, so antennas can be suspended from high up trees. They can be purchased from various sources. However, I like home brewing so I thought it would be fun to build one from scratch. In order to create a nice how-to document for hams on a budget, I built my slingshot antenna launcher with only the cheapest components - total price just under $20. The total assembly time was about half an hour. The end result is satisfactory, with the fishing weight (and line) nicely clearing even the tallest trees in my yard.

read more

Flumotion streaming Slamdance’s Filmmaker Summit

As a collaboration between Mozilla, OpenVideoAlliance, and Flumotion, we’re streaming the Slamdance Filmmaker summit.

The stream is in Ogg/Vorbis/Theora, and I’m happy to see an event like this being streamed with an open codec, using our open source technology, on our platform.

Go read the full press release.

And I owe Javier from our support team some Champagne Truffles for setting up the stream between the cracks of our usual process – Javier, the box of chocolates is next to the big pinguin’s feet at work!

January 22, 2010

Getting kamaloka-js ready for a new release

Those who are following AMQP know that work on version 1.0 of the protocol spec is happening right now. Previous versions of the API were heavily dependent on the protocol itself but with 1.0 around the corner a new messaging API has come along to help bridge the gap between 0.10 and 1.0 for the most common use cases.

In kamaloka-js, the JavaScript AMQP bindings, I have been working on implementing this API along with cleaning up the codebase significantly. Today I put the final touches on multi-part frame decoding as well as the dispatching code and hope to have a brand new release next week. Here is a look at both the old and new API:

Old kamaloka-js API as used in release 0.1.0

<script src="/static/Orbited.js"></script>
<script src="/javascript/amqp.protocol.js"></script>
<script src="/javascript/amqp.protocol_0_10.js"></script>
<script src="/javascript/qpid_amqp.js"></script>

<script>
    amqp_conn = new amqp.Connection({host: 'localhost',
                                     port: 9000});
    amqp_conn.start();

    // You should have your server generate a UUID since browser methods
    // are unreliable at best
    session = amqp_conn.create_session('not_a_great_id' +
                                       (new Date().getTime() +
                                        Math.random()));
    var remote_queue =  settings.remote_queue + session.name;
    session.Queue('declare', {queue: remote_queue});

    var queue = session.create_local_queue({name: '0'});
    var output_cb = function(msg) {
        console.log(msg.header.delivery_properties.routing_key +
                    ' sent ' + msg.body);
    }

    queue.subscribe({exchange: 'amq.topic',
                                remote_queue: remote_queue,
                                binding_key: 'com.j5live.#',
                                callback: output_cb});
    queue.start();

    // test a multi segment transfer
    setTimeout(function(){
        session.Message('transfer',{accept_mode: 1,
                                    acquire_mode: 1,
                                    destination: 'amq.topic',
                                    _body: 'Test Transfer From Browser',
                                    _header: {delivery_properties:{
                                                 routing_key:'com.j5live.test'
                                              }
                                             }
                                    });
         }, 10000);
</script>

New kamaloka-js API as used in the upcoming 0.9.1 release

<script src="/static/Orbited.js"></script>
<script src="/javascript/jsio/jsio.js"></script>
<script>
   jsio("import qpid_amqp as amqp");
   jsio("from amqp.protocol import register");
   // load the 0.10 version of the protocol
   register("amqp.protocol_0_10");

    amqp_conn = new amqp.Connection({host: 'localhost',
                                     port: 9000,
                                     socket_cls: Orbited.TCPSocket
                                    });
    amqp_conn.start();

    // You should have your server generate a UUID since browser methods
    // are unreliable at best
    session = amqp_conn.session('not_a_great_id' + (new Date().getTime() + Math.random()));

    var output_cb = function() {
        msg = this.fetch();
        console.log(msg.get('_header').delivery_properties.routing_key +
                    ' sent ' + msg.get('_body'));
    }

    var receiver = session.receiver('amq.topic/com.j5live.*');
    receiver.onReady = output_cb;
    receiver.capacity(0xFFFFFFFF);

     // test a multi segment transfer
     var sender = session.sender('amq.topic/com.j5live.test');
     sender.send('Test Transfer From Browser');
</script>

The new API will offer a lot more control, better dispatching and a simplified interface. Further integration with js.io is planned as well as full support for transactions and flow control.

[read this post in: ar de es fr it ja ko pt ru zh-CN ]

LCA 2010 talk

So I originally was going to attend LCA 2010 for the week, but real life interjected and I couldn't abandon family commitments for that long, so I ended up doing a crazy cross-Tasman dash. As well as the change in flights, Isabel came down with a virus and Gia also got it, I think I got a milder version of it, but they both seem alright by the time I left but I had little sleep the previous two nights.

So I flew on Wednesday morning, got in Wed afternoon, met up with ppl, had a couple of beers, wrote slides, slept, finished slides, went to Thur morning, drugged myself up on Nurofen Plus to combat viral effects, gave my talk, went to see ajax talk, went to professional network dinner, went for beers with ajax + benh (listening to an American and a Frenchman speaking about wine while listening to drum n bass in a Wellington pub was a bit wierd). Decided to push on through, so got back to room at 3am or so, checked out/left for airport at 4:20am, flew at 6:20am, into BNE at 7am, home, bed, sleep for a few hours and mind Isabel for afternoon.

So my talk was "So you've put kernel graphics drivers in the kernel... what next? can I haz ponies?". My slide deck is off the 0-content style + lots of pictures of various ponies, which I've found, they'll be on the LCA site soon and I'll upload them when I plug that laptop in again.

(a) stop people reading ahead of your bullet points so they don't doze off while you are catching up
(b) gives them something to look at apart from me while they actually have to listen to me :-P

It seemed well received, the room was pretty packed out (ppl standing/sitting - LCA schedulers you listening?) and I don't think the sickness or lack of decent preparation made a big difference. I'd like to apologise for not even mentioning SGX/poulsbo, I'm not sure how but it totally slipped my mind, but the situation hasn't really changed in terms of how screwed it is.

January 21, 2010

DEV300_m70

DEV300_m70 callcatcher results show four new unused methods arising out of the (cool) new printing changes.

Stop Using the Word &#8220;Cloud&#8220;

The more I see it, the more I want to just completely see the usage of the word “cloud” go away. While it’s somewhat of a cliche to say so, it’s a term that has a very hazy and non-concrete meaning. So whenever you start to use it, you immediately end up in the “well, what is a cloud” discussion. And thus, I have a set of suggestions for those places where you might have wanted to use the word “cloud” to instead use something which actually has meaning.

  • If you’re using cloud to refer to EC2, use EC2 instead. It’s concrete and it means very real things about your deployment and scaling models as well as how you’re managing your infrastructure.
  • If you’re using cloud to refer to some service which runs over the Internet, either refer to the service or just say the Internet. You don’t store your mail “in the cloud”, you host it with Google apps. You don’t backup “to the cloud”, you have your backups stored over the Internet with Mozy or Carbonite.
  • If you’re using cloud to refer to the idea of some hosted application platform, just say the platform. You don’t run your python app “in the cloud”, you run it on AppEngine (or something else).
  • If you’re using cloud to mean that you are using virtualization and have some management stack on top of it, then please just say you’re running in a virtualized environment.
  • If you’re using cloud to refer to having your server infrastructure hosted in a virtualized environment by someone else, again, just say you’re running in a virtualized environment.
  • If you’re using cloud to refer to a “visible mass of little drops of water or frozen crystals suspended in the atmosphere”, then congratulations, you can continue to use the word cloud. And thanks to Wikipedia for the definition

Following this simple idea will let you avoid the otherwise impossible to avoid discussion of the semantics of the word “cloud” and what you happen to mean about it and how you might be wrong and … This then means you’ll be that much closer to achieving whatever goal you hoped to achieve as you’ll spend less time talking and more time doing. And as an added benefit, you’ll avoid getting grumpy emails from me about the fact that you’ve used such a terribly over-used and under-meaninged term.

Comments

January 20, 2010

hair

hair in movement

hair in movement

Wanted: Samsung SWC-E100 WiMAX ExpressCard

Yota's Samsung SWC-E100: $65 (1,990 rubles)

Yota's Samsung SWC-E100: $65 (1,990 rubles)

XOHM's SWC-E100: $55 (when you could buy it)

XOHM's SWC-E100: $55 (when you could buy it)

Do you have either of these devices?  Or do you want to buy one?  And then send it to me?  I’ll even PayPal you up to $100 for it.  Let me know!  I believe the Yota device can still be purchased, but the XOHM variant stopped being sold last year after the XOHM/Clear merger.

January 19, 2010

India, 360 Degrees at a Time, Part Seven

Here's the seventh and final part of my ongoing series.

One of the grandest sights in Delhi is Humayun's tomb, a predecessor of the greatest mausoleum of them all, the Taj Mahal:

Humayun's Tomb

A little bit further down a view on the garden:

Humayun's Tomb

From a different corner:

Humayun's Tomb

We'll finish with our last panorama that shows the courtyard the Jama Masjid of Old Delhi:

Jama Masjid

That's all panoramas from this trip. Thanks for your interest.

more fun with houses

We had another open house this past Sunday, 12 people came through, but so far, no offers. A condo that was a comparable to ours in Arlington (and which went on the market about the same time as ours) just went under contract, which is a little disappointing, but hey, less competition. Our realtor assures us that there is no need to worry. We have another showing scheduled for Wednesday, so we're keeping our hopes up.

Sunday, while our open house was happening, we went to our last "class" to prepare for the baby, Newborn Essentials. It was good, but I am quite happy to be done with the classes, as they are rather long. Then, we headed out to Westford and Chelmsford to look at some open houses, but they weren't very compelling. We did drop in on an advertised open house just to see what $455K gets you in Westford, and were rather unimpressed.

Today, since Pam had the day off, I took the afternoon off and we went out with the realtor again. We saw one house which Pam really loved, another house which was identical in floor plan to another one we had already seen (they sure do love that split-level ranch layout up here), and a house which had a 2 ft wide staircase coming off the master bedroom (converted from a living room) to the second floor, where the landing had a 7 ft clearance, but the two doors into the "bedrooms" were only about 4 ft high. Also, we visited one house which was nice, except that I briefly thought it was haunted. I was looking around the basement on my own, while Pam was upstairs with the realtor, when I heard a child laugh. This was odd, because I knew the house was empty, so I stopped and listened for the sound again, and sure enough, a minute later, I could make out a child saying something. It sounded like it was coming from the storage part of the basement, so I wandered over there. Turns out, it was an electronic doll buried somewhere in a box of toys, which was randomly "saying" things like "Come play with me!" and "Are you my mommy?". A little creepy. :)

After looking at a ton of houses, Pam and I sat down with the realtor and narrowed it down to our top 4 choices. The realtor pulled comps for each of them, and we were able to narrow it down to 3. After we left, we talked over dinner @ Applebee's, and wrote down pros/cons for each of the 3 houses. When we got home, Pam turned it into a color coded spreadsheet. I went online and looked up the important details we didn't know: Does the town permit homeowners to keep chickens? (Westford: Yes, Tyngsborough: Probably yes, but not clear, Chelmsford: Not unless you have 40,000 sq. ft of empty yard, which means No.) Is that house able to get FIOS? (Two could, one couldn't.)

It is a bit frustrating to be at this point, because we really can't make an offer or even choose because we haven't gotten any offers on our current place yet. We're watching the market to see what comes on this week, and we're going to try to look at new open houses this coming Sunday. Pam is due in 27 days, and even though we hadn't planned to move until after the baby arrives, we're both freaking out a little bit.

January 18, 2010

India, 360 Degrees at a Time, Part Six

Here's the sixth part of my ongoing series.

Leaving Jodhpur we continued our journey to Jaisalmer, a sand castle of a town in the Thar desert:

Jaisalmer

In the vicinity of Jaisalmer you'll find cliche sand dunes like you'd expect from a grown-up desert:

Jaisalmer

Our next station after a long, cold and dusty train ride was Delhi. The principal mosque of Old Delhi is the Jama Masjid:

Jama Masjid

That's all for now, tomorrow I'll post the rest of my panoramas from this trip, all from Delhi.

happy mlk day

Here’s some joy from The Gregory Brothers.

Don’t see a video above? Try the original at Youtube.

January 17, 2010

India, 360 Degrees at a Time, Part Five

Here's the fourth part of my ongoing series.

After Udaipur the next stop on our trip was Jodhpur, the blue city. Which is called that way due of the blue colour of many of its houses:

Jodhpur

On a hill next to Mehrangarh Fort, one of the biggest Forts in India (the big sand castle on the hill in the panorama above), you find the Jaswant Thada, a memorial of the Maharajas of Jodhpur:

Jodhpur

Inside the fort you'll find highly decorated courtyards:

Jodhpur

That's all for Jodhpur, tomorrow I'll post more panoramas, from other stops of our trip.

desktopcouch on N900

It took quite a bit of blood, sweat, tears, and dirty hacks, but finally:

Nokia-N900-42-11:~# apt-get install desktopcouch
Reading package lists... Done
Building dependency tree
Reading state information... Done
The following extra packages will be installed:
couchdb-bin erlang-base erlang-crypto erlang-inets erlang-mnesia
erlang-public-key erlang-runtime-tools erlang-ssl erlang-xmerl libjs
python-desktopcouch python-desktopcouch-records python-keyring
Suggested packages:
couchdb erlang-tools erlang erlang-manpages erlang-doc-html
python-keyring-gnome python-keyring-kwallet
Recommended packages:
erlang-syntax-tools
The following NEW packages will be installed:
couchdb-bin desktopcouch erlang-base erlang-crypto erlang-inets
erlang-mnesia erlang-public-key erlang-runtime-tools erlang-ssl erlang-xmerl
libjs python-desktopcouch python-desktopcouch-records python-keyring
0 upgraded, 14 newly installed, 0 to remove and 9 not upgraded.
Need to get 0B/12,5MB of archives.
After this operation, 27,9MB of additional disk space will be used.
Do you want to continue [Y/n]?
WARNING: The following packages cannot be authenticated!
erlang-base erlang-crypto erlang-mnesia erlang-runtime-tools
erlang-public-key erlang-ssl erlang-inets erlang-xmerl libjs couchdb-bin
python-keyring python-desktopcouch python-desktopcouch-records desktopcouch
Install these packages without verification [y/N]? y
Selecting previously deselected package erlang-base.
(Reading database ... 27651 files and directories currently installed.)
Unpacking erlang-base (from .../erlang-base_1%3a13.b.2.1-dfsg-3maemo2_armel.deb) ...
Selecting previously deselected package erlang-crypto.
Unpacking erlang-crypto (from .../erlang-crypto_1%3a13.b.2.1-dfsg-3maemo2_armel.deb) ...
Selecting previously deselected package erlang-mnesia.
Unpacking erlang-mnesia (from .../erlang-mnesia_1%3a13.b.2.1-dfsg-3maemo2_armel.deb) ...
Selecting previously deselected package erlang-runtime-tools.
Unpacking erlang-runtime-tools (from .../erlang-runtime-tools_1%3a13.b.2.1-dfsg-3maemo2_armel.deb) ...
Selecting previously deselected package erlang-public-key.
Unpacking erlang-public-key (from .../erlang-public-key_1%3a13.b.2.1-dfsg-3maemo2_armel.deb) ...
Selecting previously deselected package erlang-ssl.
Unpacking erlang-ssl (from .../erlang-ssl_1%3a13.b.2.1-dfsg-3maemo2_armel.deb) ...
Selecting previously deselected package erlang-inets.
Unpacking erlang-inets (from .../erlang-inets_1%3a13.b.2.1-dfsg-3maemo2_armel.deb) ...
Selecting previously deselected package erlang-xmerl.
Unpacking erlang-xmerl (from .../erlang-xmerl_1%3a13.b.2.1-dfsg-3maemo2_armel.deb) ...
Selecting previously deselected package libjs.
Unpacking libjs (from .../libjs_1.8.0-rc1-1_armel.deb) ...
Selecting previously deselected package couchdb-bin.
Unpacking couchdb-bin (from .../couchdb-bin_0.10.0-0maemo3_armel.deb) ...
Selecting previously deselected package python-keyring.
Unpacking python-keyring (from .../python-keyring_0.2-3_all.deb) ...
Selecting previously deselected package python-desktopcouch.
Unpacking python-desktopcouch (from .../python-desktopcouch_0.5.1-0maemo1_all.deb) ...
Selecting previously deselected package python-desktopcouch-records.
Unpacking python-desktopcouch-records (from .../python-desktopcouch-records_0.5.1-0maemo1_all.deb) ...
Selecting previously deselected package desktopcouch.
Unpacking desktopcouch (from .../desktopcouch_0.5.1-0maemo1_all.deb) ...
Setting up erlang-base (1:13.b.2.1-dfsg-3maemo2) ...
Searching for services which depend on erlang and should be started...none found.
Setting up erlang-crypto (1:13.b.2.1-dfsg-3maemo2) ...
Setting up erlang-mnesia (1:13.b.2.1-dfsg-3maemo2) ...
Setting up erlang-runtime-tools (1:13.b.2.1-dfsg-3maemo2) ...
Setting up erlang-public-key (1:13.b.2.1-dfsg-3maemo2) ...
Setting up erlang-ssl (1:13.b.2.1-dfsg-3maemo2) ...
Setting up erlang-inets (1:13.b.2.1-dfsg-3maemo2) ...
Setting up erlang-xmerl (1:13.b.2.1-dfsg-3maemo2) ...
Setting up libjs (1.8.0-rc1-1) ...
Setting up couchdb-bin (0.10.0-0maemo3) ...
Setting up python-keyring (0.2-3) ...
Setting up python-desktopcouch (0.5.1-0maemo1) ...
Setting up python-desktopcouch-records (0.5.1-0maemo1) ...
Setting up desktopcouch (0.5.1-0maemo1) ...
Nokia-N900-42-11:~# dbus-send --session --dest=org.desktopcouch.CouchDB \
> --print-reply --type=method_call / \
> org.desktopcouch.CouchDB.getPort
method return sender=:1.516 -> dest=:1.515 reply_serial=2
int32 53864
Nokia-N900-42-11:~#

Among other things, I had to:

  • port desktopcouch to use python-keyring as suggested by the desktopcouch hackers, although I’m not sure what they now want to do with it since there’s no way to make it compatible with their current way of storing in gnome-keyring
  • Build the arm parts of erlang and couchdb on my phone in a chroot, since qemu-arm-sb actually hangs when executing erlc. Had to build it in an actual maemo chroot as well; the easy-deb chroot was not a solution since it comes with newer C and ssl libraries.
  • figure out how to package spidermonkey, instead of depending on xulrunner the way the debian couchdb does
  • package lots of missing packages; for example, while maemo has avahi, it didn’t have the python bindings built.

For the adventurous, I think you should be able to download tao.install on your phone, then go to console and run the same apt-get install command as I did. Please let me know if it worked for you !

Now, need to figure out (or get told by the desktopcouch hackers) how I can set up pairing with UbuntuOne for my data without needing to port the whole gnome applet…

January 16, 2010

India, 360 Degrees at a Time, Part Four

Here's the fourth part of my ongoing series.

After Hampi we went to Bangalore to attend foss.in. (Fantastic conference, btw. The concerts at the venue are unparalleled.) From there we flew up to Udaipur, in Rajasthan. Udaipur is (among other things) famous for being the place where the central scenes of Octopussy were filmed. Octopussy's famous white palace is on Jagniwas Island in Lake Pichola:

Udaipur

This panorama was taken from another island in the lake, Jagmandir Island, which is visible in the following shot on the left:

Udaipur

Udaipur's scenery, seen from the Maharaja's City Palace down onto Pichola Lake:

Udaipur

That's all for Udaipur, tomorrow I'll post more panoramas, from other stops of our trip.

Announcing udev-browse

It's easy to get lost in /sys and not much fun typing long udevadm info command lines all the time. Today, when I had enough of that I sat down and spent an hour to write a little UI for exploring the udev/sysfs tree: udev-browse. I wrote it for my own use, but I am quite sure I am not the only one who wants a little bit simpler access to the device tree. So here you go.

And since everybody loves screenshots here you go:

udev-browse

Two usability hints: if you run udev-browse from a directory in /sys udev-browse will automatically present the device of that path on startup. And if you know the name of a device you can just type it into the device listbox (which is focussed by default). The usual Gtk+ live search will then find you the right entry right-away. It's pretty nifty.

It's written in Vala with minimal dependencies.

I want to keep the maintainership burden for this minimal. So no tarballs, no releases, and I won't reply to your emails regarding this tool, unless they include a good, clean, git formatted patch. Thank you for your understanding.

Anyone wants to package this for Fedora? I'd be very thankful if someone would pick it up.

Have fun.

A multi-band HF loop antenna

Amateur radio has 10 HF (shortwave) bands, from 1.8 MHz (160 meters) through 28 MHz (10 meters). The different bands are great for talking to amateur radio operators (hams) at different distances, different times of the day, different seasons and different times during the solar cycle. Only one problem: most hams do not have space in their yard for 10 different antennas. Fortunately it is possible to build one antenna that can be used effectively on most of the bands, for example this 80 meter loop antenna.

read more

January 15, 2010

The evils of event-driven programming in CLD clients

I wanted to fix a small bug in tabled where the server conflicted with its own lock and hung if restarted too quickly. But before I was able to write the patch, I had to fill a Letter format piece of paper with pencil scratches. And that's for the code that a) I wrote myself and b) is only 1000 lines long. It's like the return to 1972 kind of programming.

The root of the evil here is that the event-driven API of CLD forced a regression to the programming with GOTO, because the mechanics of CLD consumed what C programmers use for abstraction otherwise: functions. And CLD is event-driven because it processes the protocol in a library, but someone else decided that spawning a processing thread would be too bourgeouse.

Until today I suffered this silently, but enough is enough. I will not rest until a sane API for CLD is established.

January 14, 2010

India, 360 Degrees at a Time, Part Three

Here's the third part of my ongoing series.

Still in Hampi here's another 360 from the Hills in Hampi down to the Achyutaraya Temple:

Matanga Hill

A little further down, before dawn, here's a shot from the rocky path leading up the hill:

Matanga Hill

Our last picture for today is a view down from Hemakuta Hill which is covered with old temples and other structures. In the middle you'll see the large Virupaksha Temple which is still in full use. In that temple you'll find an amazing camera obscura, a physics teacher's dream that projects the temple tower onto a wall (projection, subject, more interesting in reality. Really.)

Hemakuta Hill

That's all for Hampi, tomorrow I'll post more panoramas, from other stops of our trip.

N900, GooSync and SyncEvolution

Zaheer pointed me to a temporary solution for my calendar sync problem while he (hopefully) keeps working on his more final solution which would allow full multiple-calendar synchronization.

I have a previous

GooSync account that I used happily with my E51. GooSync supports SyncML, so it can be used with SyncEvolution on the device, which was recently ported.

I’ve put full instructions on my wiki if you’re in the same boat as me. Let me know if it works for you! And thanks again Zaheer for pointing the way.

That Google

Regarding the Google's decision not to censor their search results anymore and Ted's praise of it, it strikes me as notable how they thought nothing of censoring until the agents of Chinese government directly attacked them (among other American companies and organizations). That sort of deducts the points Google receives for this decision. Also, since it was shown they were willing to censor results until something drastic happens to them, what else do you think they censor, even now? Tried to enter "Obama" or "Mormons" or "Net Neutrality" into Google lately?

yum blooper of the day

The "yum update" said:

kernel-PAE-devel-2.6.32.2-15.fc13.i686 is a duplicate of kernel-PAE-devel-2.6.31.9-174.fc12.i686

What does that even mean? How can different kernels be "duplicates"? Of course it's nothing that one little rpm -e cannot fix, but still.

Sun F5100

Seen at Axboe's:

Sun F5100 flash array [] packs 80 SLC flash modules (or FMods, in Sun speak) into a 1U box. Each module is essentially identical to the ones on the F20 card, which I already have used a lot for testing. It's 24GB in size, has a sequential throughput of approximately 200MB/sec reads and 150MB/sec writes, or 25K/15K IOPS. That's pretty fast by itself, multiply that by 80 and you are now burning holes in the fabric of time - 1.6 million IOPS, or well over 10GB/sec throughput.

This box has John Corbin's feel to it. John understood why MB/s were not everything and why IOPS mattered. I wonder if he was actually involved. The litmus test would be to verify if something clever is done to support 4KB blocks (flash usually has 64KB blocks and its small-block write performance is suboptimal; striping when chasing MB/s can easily make it worse).

UPDATE: LinkedIn says John is at NetApp now, so someone else made F5100.

Cross platform perf.data analysis support

There are still some problems related to loading vmlinux files, but those are unrelated to the feature implemented in this patch, so will get fixed in the next patches, but here are some results: 1. collect perf.data file on a Fedora 12 machine, x86_64, 64-bit userland 2. transfer it to a Debian Testing machine, PARISC64, 32-bit userland acme@parisc:~/git/linux-2.6-tip$ perf buildid-list [...]

January 13, 2010

What's in my HTML folder?

I had a rule that throws all HTML mail into a folder for years now, and as every year rolls by I wonder if it's still useful. Is the HTML mail all spam still? Aren't we supposed to switch to "rich" mail? Well... Let's look. Bryan Clark is a captive of Mozilla policies. He probably uses the brain-dead defaults in his Tbird for the sake of "eat own dogfood" testing. And Mr. Marie uses a @live.com account, due to unavoidable personal circumstances, no doubt. That's it, I've not received other human communication in HTML for months. Small observations like that restore one's faith in humanity.

It’s all about the API

If there is one thing I learned when working on D-Bus is that if you build a decent API, people will use it. Right now I am working on Kamaloka-js – JavaScript bindings for building JavaScript native AMQP clients. As AMQP starts moving towards 1.0 a new high level API, based loosely on JMS, is emerging to bridge the gap between 0.10 and 1.0. Previously with AMQP you pretty much worked with patterns on the protocol level which meant when the new specification came out you would pretty much have to rewrite to the new API. The new messaging based API seeks to decouple the protocol from the API for the most common use cases.

As I implement the JavaScript API there are some decisions I must make regarding how closely I stick to this new API as implemented in other bindings. Lets look at how the new API receives messages in Python:

...

conn = Connection.open(url.host, url.port)
ssn = conn.session()
rcv = ssn.receiver('amq.topic/org.j5live.demo')

while True:
    try:
        msg = rcv.fetch(timeout=timeout)
        process_message(msg)
        ssn.acknowledge()
    except Empty:
        break
    except ReceiveError, e:
        print e
        break

If you notice the API is very much mainloop based. With every loop we fetch a message off the local queue. If there are no messages, fetch works very similar to the way poll does for sockets – sleep until woken up by network traffic or a timeout. The issue is if we did this in JavaScript we would block the UI and event propagation (newer browsers do expose threading but that feature can not be relied upon in all browsers). If you have ever mistakenly created an infinite loop in JavaScript you will understand how bad this is.

There are two options I see here, keep the fetch method and require the programmer to use timers to read from the local queue or, as currently implemented in my own high level API, attach callbacks to receivers.

The timer/fetch method has a couple of advantages. First it more closely resembles the API of the other bindings. Also it allows tighter management of the local queue. Since each time the timer is triggered we can determine how many messages we wish to process we can give some performance guarantees based on how long it takes to run operations in response to the messages. In this way we can dictate when a message is processed and tweak applications to run smoother. This comes at the price of added complexity which could be even more of a detriment to performance when in the wrong hands.

The callback API has the advantage of being more in line to what JavaScript developers expect. JavaScript is highly event/callback based with onFoo handlers everywhere. We currently work this way. When a message is decoded from the socket we dispatch it immediately to any callback registered to listen for it. The issue here is an application can get hammered with messages with no way to defer processing (except by implementing their own processing queue).

Why not implement both? This is an option but that doesn’t mean it is a good option. Multiple ways of doing the same thing often confuse new users. Understanding the differences between the API’s and the nuances between usecases are often more complex than either API alone. This could be daunting to a new user.

The trick is to make the API’s build on one another. For instance I could add an onReady handler which then allows the user to use the fetch API to grab any messages inside the handler. We would then set up an internal timer if the queue was not completely drained. This would require users be familiar with the fetch API without having to set up their own timer. If they wanted to have more control, they could set up their own timers instead of using the handler.

Any JavaScript developers have any insight as to the best way forward?

[read this post in: ar de es fr it ja ko pt ru zh-CN ]

Credit where credit is due (more Google tea leaves to read)

One of the very first things that made me skeptical about Google was their approach to censorship in China, which I thought deeply compromised their supposed ‘don’t be evil’ approach to the world. It struck me that their position- summarized as “the benefits of increased access to information for people in China and a more open Internet outweighed our discomfort in agreeing to censor some results” bespoke a fair amount of arrogance about the value of Google and a discounting of the value of uncensored information. I didn’t mention that issue in my recent post about Google and reading their tea leaves, but it certainly is one of the big tea leaves to be read.

And so they’ve added another layer to the tea leaves with this announcement that Google will be backing out of censorship in China and possibly abandoning China altogether. Go read it.

It is hard to imagine any other American company having the cojones to make a public statement like it, and I have to applaud them for it. Google is different; anyone who tells you otherwise doesn’t understand them very well. The question we must continually ask is ‘how different, and for how long will they remain different?’ Schmidt’s quotes the other day suggest they are becoming more like others, and that is troubling, and worth writing about and reflecting on (not least by people within Google.) But to even post this is a reminder that they are still very different from most of their peer large corporations. I suppose for those of us who continue to read the tea leaves the followthrough after this post will say a lot as well.

January 12, 2010

Public Service Announcement: Beware of xmlCleanupParser()!

Everyone and his dog seem to call libxml2's xmlCleanupParser() at inappropriate places. For example Empathy does it, and Abiword does it too. Google Code Search seems to reveal at least Inkscape and Dia do it as well.

So, please, if your project links against libxml2 verify that it calls xmlCleanupParser() only once, and right before exiting! And if it calls it more often or somewhere else, then please fix that!

For more information see my post on fedora-devel.

Thanks for your time.

India, 360 Degrees at a Time, Part Two

Here's the second part of my ongoing series.

Climbing down the hills, on the banks of the Tungabhadra river you find people washing laundry and bathing, and coracles waiting to be used for a trip through the river.

Tungabhadra River

The greatest of the ancient temples in Hampi is the Vitthala Temple:

Vitthala Temple

Set in in lush green scenery you find the Achyutaraya Temple, which you already might have seen, from above, in yesterday's series:

Achyutaraya Temple

That's it for today, tomorrow I'll post more panoramas, both from Hampi and other stops of our trip.

January 11, 2010

India, 360 Degrees at a Time, Part One

Yes, I won't spare you my panorama shots from my recent trip to India. After arriving in Goa Badami was our next stop. It's a very pretty little town in northern Karnataka, and here's a panorama shot from the entrance of the town's famous caves:

Badami

Next step was one of the most amazing places on earth, Hampi in central Karnataka. It is definitely one of the greatest sights I have ever seen, and I guess I can say I have seen quite a few in my life. A vast landscape of hills covered in boulders, lush mango and banana plantations, rice fields, dotted with age-old temples and impressive ruins. Locals crossing the river in coracles that look like they belong in a time centuries ago. Women washing colourful laundry in the river, pilgrims wading across the river in their black clothes. An India that delivers every bit of that promise it makes to its visitors. The ruins rival the grand sites in Greece and the landscape sometimes looks like a Crysis in-game scene.

Taken from one of the hills in Hampi this is the sunset:

Hampi Sunset

And then, the next day at dawn make your way up the hills again and you can get an even greater view on the whole scenery:

Hampi Dawn

That's it for today, tomorrow I'll post more panoramas, both from Hampi and other stops of our trip.

Also, if you haven't seen them yet, don't miss my panoramas from my India trip the year before.

Searching for a place to live

In case our lives weren't stressful enough with a baby on the way, Pam and I decided that it would be the most sensible thing for our budget if we sold our condo in Arlington and moved. Our criteria are pretty simple:

* 3 Bedrooms
* Master Bedroom must not be smaller than what we have now (10x13).
* 1+ Bathrooms (with an emphasis on the plus)
* Some land for Pam to go wild with Gardening/Chickens/Nature
* A basement that I can stand in, which is either finished or can be finished

Now, we're not rolling in dough, and Pam says I'm not allowed to make counterfeit currency anymore. What this practically means is that there are a lot of houses in the Boston area that meet this criteria, but we cannot afford. In fact, it really means that we're priced out of every town on the T, and that we're heading to suburbia. We know we're not going to get a super-awesome new house with our budget, and we're willing to put some sweat equity into it, but... well, so far, we've not had any real luck.

We've been looking at houses for a while now, both in person with our buyers agent, and online. Here are some observations I have gathered from our exploration to date:

* First, here is a translation dictionary of realtor terminology to English:
- Has potential = Is a dump
- Lots of potential = You may need to burn it down before you could live in it.
- As is = If it can be broken, it is broken, and you should not even consider asking for it to be fixed.
- Contractor's Dream = Your contractor will be able to retire once you pay his bill.
- Estate Sale = You get to keep all the rotting junk that is filling this house from floor to ceiling.
- Close to major roads = This house is actually in the median of 495.
- Close to public transportation = The Commuter Rail runs through your backyard.
- Great for first time home buyers = Only an idiot who didn't know any better would think this is a good deal.
- Great for kids = Kids don't need ceilings above 5 feet.
- Subject to bank approval = Short sale.
- Subject to seller approval = House is haunted.

* If you're selling your house, you should clean it. All of it. The number of houses that we have seen so far where the owners clearly gave up on cleaning sometime in 1987 has been staggering. It makes it practically impossible to think about what it would look like with my stuff in it. My gag reflex has been triggered waaay too often.

* Dogs destroy houses. We've seen several houses with cats, but none of them were at all damaged). Every house we've seen with a dog has suffered serious injury including:
- Scratched floors (tile, wood, laminate, you name it)
- Eaten, stained, or otherwise violated carpet
- Doors which have been shredded as the dog made its way to freedom
- The lovely smell of urine
- The yard is almost always a mixture of mud pit and dog shit.

* Smokers destroy houses. I don't care what you do, short of a flamethrower or a controlled detonation, that smell isn't coming out.

* The combination of smokers and dogs is lethal. We should put captured terrorists in those houses until they talk.

* Don't be home when your house is being shown. Also, don't have anyone else at home when your house is being shown. If I feel like I'm trespassing, I'm not going to give it any serious investigation, I'm just going to want to get out of there. Also, it tells me that you're not really serious about selling your house.

* A toilet with no walls around it in the basement is not a half bath. It's just a toilet.
* An inground pool where the sides have collapsed is not a pool. It's a landfill.

* Don't put laminate countertops on the kitchen walls.
* Don't put a fridge intended for a large restaurant into a kitchen the size of a chinese take-out box

* Perfectly level floors are a plus, but a slight bump here or there is okay. When the head of the bed is 6 inches higher than the foot, you've done it wrong.

* Storing books and magazines in massive piles for 30 years in an unfinished basement room with water damage and dirt floors is a bad idea.

* The following colors are never appropriate:
- Teal
- Lavender
- Neon *
* If you have any of these colors in use in your house, paint them before you put it on the market.

* Your master bedroom should not be:
- In the basement
- In the living room
- In the attic
- In the garage

* You should never pave your backyard.

* If you have a shed-like building on your property, make sure it looks nice and is in good repair. If it looks like it might blow over with the slightest breeze and give everyone in the New England region tetanus, you should get rid of it.
- One house we saw had a ramshackle shed like this in its FRONT YARD, with a fence going "through" it in the middle.

* If any of the following rooms in a house is not pictured in the online listing, beware:
- kitchen
- bathroom
- master bedroom
- basement

* If there are two sump pumps running 24 x 7 and french drains in the basement, it isn't a house, it is a submarine.

* Online listings suck. I'm having to go to at least two sites, if not more, to determine the full range of useful information.

*****
House-hunting like this is disheartening. Whenever I see something nice, I have to look for the horrible thing that I've overlooked, like the ruptured septic tank or the chupacabra in the basement. But, we will persist! There has to be a mostly decent and affordable house in MA for us... right? Right?

Modeling compact 160 meter antennas

I am a recently licensed amateur radio operator, callsign AB1KW. Like many other ham radio enthusiasts, I have a yard big enough to fit a nice antenna for 80 meters and the higher HF bands, but not quite big enough for a full size dipole antenna for 160 meters. Furthermore, I have no desire to dig up the yard to lay dozens of radials for a vertical antenna. There is about 5 meters of woods between me and the neighbors on the sides and about 15 meters of woods between me and the neighbors in the back, so there is space for an antenna. I have used xnec2c to model 4 different antennas for the 160m band and found some interesting results.

read more

January 09, 2010

QSL cards ... "soon"

AB1KW QSLAB1KW QSL In the few months that I have been on the air, I have made a little under 700 contacts, and received a handful of QSL cards. Because I want to send back something nice, I ordered QSL cards from UX5UO QSL print. Once I get the cards, I will send one to everybody who sent me a card, as well as a few people who requested a paper QSL card on the air. If you sent me a card, please wait a little because the UX5UO print queue is long. I have received a few UX5UO printed cards and can assure you they are worth waiting for.

read more

January 08, 2010

DEV300_m68/DEV300_m69

callcatcher results for DEV300_m68 and DEV300_m69

Down to 864 unused methods, unused svx mostly moved into new cui lib. svtools split into svl happily removed all unused svtools methods, leaving svtools unused-free. (x86_64) bridges also unused methods free as well.

sd now accounts for 25% of all low-hanging fat