From Out There


Archive for January, 2008

Gbarcode Support for Ruby FPDF

Saturday, January 26th, 2008

I was going mad fixing a bug in a very convoluted barcode printing feature in the equipment management system we’re developing. After a while I gave up — we must have triggered something deep within Rails or Ruby, and it wasn’t going to go away soon. The details are complicated and boring, but just know this: Instead of fixing the bug, I completely rewrote our barcode handling and as a side effect developed an extension for Ruby FPDF to support Gbarcode 🙂

Please give it a try if you need barcode support in your PDFs and let me know what you want to improve and what fails horribly for you.

I wanted to send it to Brian Ollenberger to see if he likes it and would like to include it with Ruby FPDF, but his website appears to be down. Anyhow, I would have to clean things up and make it all elegant and sexxay first.

Still, standing on the shoulders of giants is just the beginning. With a dozen lines of code I managed to tie Gbarcode into Ruby, and through that into Rails, and I’m not even a good coder. Free Software rocks! Well, okay, FPDF isn’t technically Free Software, but still. All of this just feels very good, and it gives me a kind of productivity I could only dream of with proprietary software and complicated licenses. I had the whole thing hacked together in less than an hour.

Vow of Software Freedom

Wednesday, January 16th, 2008

I have taken a vow around September 1999, and it is sometimes hard to explain to people, so I’ll write it down here. I said to myself, "From this day on, I shall not use non-free software or secret file formats in my work, ever again." As you might notice, I’m still alive, which means that it’s possible to make a living without those two things. But it’s obviously not so simple, so here are:

Vow of (Software) Freedom: The Details

I will not use:

  • Software for which the source code is unavailable.
  • File formats for which the full specifications are not available.

When will I not use these?

  • When I produce a work product for myself, my employer or other humans.
  • When I share a file with my fellow human being.

Why will I not use these?

  • Because software for which you do not have the source is inherently suspicious.
  • Because software without the source often comes with very restrictive licenses, so I may not exercise freedom 2 and help my neighbor. I want to help my neighbor. I want to give away and improve software. I can’t do that with non-free software, so I see no reason to use it.
  • Because proprietary formats destroy information, stifle competition, are considered harmful, are impossible to implement and are just generally a bad idea, especially in today’s age of information sharing. Giving away files in secret formats only serves to strengthen these formats, so it isn’t wise.

How come this is doable?

Because of the efforts of millions of Free Software developers and yes, even those who call it Open Source. Because of the work of engineers that have their head screwed on properly and strive to publish specifications of their file formats.

Today, and since many years, you can have an entire PC operating system compile itself out of raw source code right in front of your eyes. In fact, several different systems are capable of this. You should be content with nothing less.

It’s your machine the stuff is running on, it’s your right to know what your machine is running and to decide about the formats you save your important information in. Don’t give this right away. It’s probably not a good bargain.

My New TV Runs Linux

Monday, January 7th, 2008

Oh yes, I broke down and bought a Full HD TV. What can you do, they’re practically giving them away after the Christmas price hike. And I have other excuses! Old set? A 16 inch one. Plus, I had plans to hook up a PC and watch HD content. Can’t very well do that on an SD TV. The new one is a Sharp LC-37X20E. I know it has red push and I know this has to be corrected either in the signal source or via the service menu, but once you do that, it’s an excellent set with good black levels, fast response and the ability to show a great amount of detail. I’m happy.

It does come with an extra feature though: it runs Linux. When reading through the manual, one of the last pages includes a references to the GPL and the LGPL, and it lists libpng, zlib, the Linux kernel etc. as being included inside your TV. Sharp provides the source at this website. This is a fantastic first step! Sharp sells hundreds of thousands of LCD TVs each year, and they all run Free Software. Sharp is not alone: I haven’t done a formal survey, but I hear that using Linux as kernel and some GNU utilities or busybox is becoming the norm with flat-screen television makers. It makes sense for everyone: They save billions of dollars in R&D because they don’t have to develop their own kernel, and the customer gains the stability and features Linux can provide. It’s certainly win-win.

Now I’m not all happy with the way Sharp is treating this. They are currently making the typical “Free Software newbie” mistake of just dumping their source somewhere on a website and leaving it at that. This makes me believe Sharp is primarily in this game because of the financial benefits they are gaining, not because of any social interests. In an ideal situation, Sharp would have set up a svn server or something where people can contribute changes and then roll out the firmware to new TVs. They do state somewhere that they will review and accept user modificiations, but the way their GPL website looks — it just doesn’t smell right yet.

I’m confident that companies like Sharp will become good players in the Free Software community over time, though. This is not something you can learn in just a few weeks, it takes an ideological shift on many levels of the company, and anyone who has ever worked for something medium-to-large knows how long this may take. At any rate: Thank you, Sharp, for choosing Free Software for my TV. I have it hooked up to an old PC I don’t need anymore. With GNU/Linux, it runs movies at 1920×1080 on that TV without breaking a sweat. It’s yummy to behold what a 100% Free Software stack can do nowadays in terms of media.