Posted by Rick on the 6th of May, 2008 at 2:43 am under Intellectual Property.    This post has Comments.

I got into a conversation recently about the events surrounding the liberalization of C-SPAN’s policy regarding the use of their videos on the internet. This initially became an issue in early 2007 when speaker Nancy Pelosi purportedly violated copyright law by posting a video of a committee hearing (not congressional footage, which would be in the public domain) to her blog, The Gavel.

During the conversation, the point was made that C-SPAN does not take any funding from the government, a notion even Wikipedia says is “contrary to popular perception”. Of course, the point is correct: C-SPAN does enjoy the right to film Congress, but is indeed a non-profit organization. Nevertheless, they have a history of guarding their copyright on the videos they produce of events in Congress. In December 2006, Brian Lamb wrote a letter, available in PDF from C-SPAN, requesting a number of limitations be lifted on the footage gathered during House sessions, and also promising to “to make our floor coverage fully available to accredited news media following established pool practices”, read: the coverage will not be made available to the public for reuse without restriction. Pelosi later denied the request.

In a widely reported switch, C-SPAN was lauded for their press release of 07 March 2007 stating a change in their policies. Most coverage of the event makes note of the temporally proximate controversy surrounding the use of C-SPAN video on the speaker’s blog, but few, if any, note Carl Malamud’s letter to Brian Lamb on 27 February 2007, a mere eight days prior to C-SPAN’s announcement. In it, Mr. Malamud makes a compelling argument that while C-SPAN does not take funding from the taxpayer’s directly, “C-SPAN is the primary beneficiary of considerable public largess.” And his point is well taken, and may have directly caused C-SPAN to change their licensing terms. As Lawrence Lessig points out, this all relates to the fundamental question of how we handle copyright on the internet, particularly when it relates to political speech. To leverage outdated copyright laws to stifle political commentary may be a new low. After all, C-SPAN has no way to financially leverage people wanting to see Colbert roast Bush.

This may be more than a year late, but as I had the conversation, I struggled to recall the important events that surrounded the issue, and I thought it would be good to capture them here. In particular, I wanted to document the failure of the mainstream media to capture Mr. Malamud’s role in the license change at C-SPAN.

Posted by Rick on the 4th of May, 2008 at 3:34 pm under Uncategorized.    This post has Comments.

In his latest post, Steve Yegge pointed out that Emacs’ biggest competitor wasn’t really IDEs, because Emacs isn’t really great because it edits text. Emacs’ biggest competitor is really Firefox, because what makes Emacs great is that it is so extensible, and so it is with Firefox as well (although I prefer ELisp to XML and Javascript anyday).

This didn’t really hit me clearly until I noticed that for many web-related activities like checking mail, updating twitter and posting to my blog, Emacs has solutions (VM for mail, twit.el for Twitter and weblogger.el for blogging), but so does Firefox (Gmail for mail, TwitBin for Twitter, and ScribeFire for blogging).

So, everytime I want to blog or update Twitter, or even check mail, I have to consider what I want to use, which is really dependent on what program I happen to be in at the moment. So, in a way, the race is on: will Firefox get a better extension language and text editor, or will Emacs embed a good browsing capability. Personally, I’d like Emacs to embed Gecko with the upcoming libxul, but we’ll see how hard that turns out to be.

Posted by Rick on the 4th of May, 2008 at 4:29 am under backup, howto and mac.    This post has Comments.

In the last post, I use the excellent SuperDuper! tool to make a
bootable clone of my hard drive. There are some (more advanced)
techniques that can be used that allow bootable clones to be created
on the command line using free tools. I had some trouble getting
clones to work on the command line, but finally worked through the
problems using the technique described below. Most all of this
information is in Bombich Software’s guide.

  • Use Disk Utility to set the drive to use a GUID partition table

Macs can boot without this being the case, but since the internal disk
uses this kind of a partition table, it’s good to have your clone use
the same setup. I’m pretty sure this isn’t necessary, but it worked for
me as I was trying to solve some issues with the clones working.

  • Ensure the volume’s “Ignore Ownership on this volume” is *not* checked

By default, external drives will set this option when OS X formats
them. This will ruin the clone, as the system will not boot if files
are set to a UID of 99. So, immediately after formatting your drive,
right click on it and open the “Get Info” option. At the bottom of
that panel, *uncheck* the option that says “Ignore Ownership on this
volume”. This will allow the copy you are going to make to boot.

  • Clone with a command like asr, ditto, rsync, etc.

I used ditto successfully:

sudo ditto -X / /Volumes/Clone

For incremental backups, rsync can be used as is described on Bombich Software’s guide to backups:

sudo rsync -xrlptgoEv –progress –delete / /Volumes/Clone

  • When booting, get diagnostic information with Command-V

During the first boot from the clone, you can hold down Command-V as
the system boots to get more information about the boot process. If
something goes wrong, at least you’ll have some error messages you can
use as a basis for a search on the internet.

Posted by Rick on the 26th of April, 2008 at 1:22 pm under Emacs and Programming.    This post has Comments.

Since I tend to work in Emacs no matter what computer I’m using, I got curious after reading Steve Yegge’s latest post about XEmacs instability what exactly my uptimes are on all my Emacs sessions (I use GNU Emacs, but I was still curious). This is some elisp I threw together to answer that question.

(require 'cl)

(defun duration (time)
  "Takes in a time-value and returns the number of seconds since
   the epoch that value represents."
  (+ (* 65536 (car time)) (cadr time)))

(defun uptime ()
  "Prints the current uptime of Emacs as recorded on startup in
   the value 'start-time'"
  (interactive)
  (let* ((total (duration (time-subtract (current-time) start-time)))
         (days  (floor (/ total 86400)))
         (hours (progn (decf total (* days  86400)) (floor (/ total 3600))))
         (mins  (progn (decf total (* hours 3600))  (floor (/ total 60))))
         (secs  (progn (decf total (* mins  60))    (floor total))))
    (message "%d days, %d hours, %d minutes, %d seconds" days hours mins secs)))

; Put this in your .emacs
(setq start-time (current-time))
Posted by Rick on the 24th of April, 2008 at 2:20 pm under backup, howto and mac.    This post has Comments.

The Macbook I bought back in May of 2007 has been getting a bit long in the tooth. Shortly after I bought it, I upgraded the RAM to 2 GB, so the memory and the processor have been holding up just fine for me, as I mainly program and use VMWare (not much gaming). But, after a while, the 70 GB hard drive starts to feel a bit cramped, as the Macbook is my main machine. I’ve mitigated the problem by buying various external drives, but nothing can replace a nicely sized internal disk.

So it was time for a disk upgrade. It turns out that upgrading the disk with command line tools (as was my original intention) like asr, rsync, or ditto copies the files intact, but won’t make the disk bootable unless the root file system is mounted read-only. I can get my Mac into single-user mode, but, coming from Linux, I’m not sure how to remount the root filesystem read-only on the BSD-based OS X. Plus, I can’t use my screen capture utility in single-user mode.

So, I ended up researching other tools, like CCC and SuperDuper! SuperDuper! seemed to fit the bill, so that is what I made the video with, but I’d be very interested to see what people’s experiences have been with CCC and/or command line tools making bootable clones for use in an upgrade. Anyway, the video is now posted on YouTube:

Macbook Hard Disk Clone & Upgrade

Posted by Rick on the 21st of April, 2008 at 1:51 pm under Programming.    This post has Comments.

Tad Williams had vision. He wrote an epic saga whose events unfolded in a hyper-connected world. In this Otherland of virtual realities existed an undernet, a virtual reality operated by those who populated it - it was an elusive place, a metaverse called Treehouse whose entrance was almost unlocatable - but it was owned by those that lived within. This made it completely unlike the Internet we use every day. We are the citizens of the internet, but we do not own it.

This was not the original vision. ARPANET was essentially peer-to-peer (they called it host-to-host), and when email was concieved in 1971, it was designed to be essentially peer-to-peer. Email has no central authority - it is a communication protocol between peers. But, we find ourselves surfing today in a hierarchical network of those who provide and those who consume. Once more, we are cast as the consumers.

With the penetration of broadband around the wold, we can finally realize a truly peer-to-peer web of connections between people, not corporations. We have seen a rise in the “social web” - a social gathering mediated by and on he property of a corporation.

This is convenient, until it isn’t. Until the service goes down, or mishandles your data and loses it, or worse, sells it, you might not mind. But even email, originally meant to belong to the users of the network is now “webmail”, and unsurprisingly is hosted on central servers that the users don’t own.

But it would be simple to change all that. We just have to figure out how. And I think I have a simple idea of how to start.

Posted by Rick on the 23rd of March, 2008 at 2:36 pm under Intellectual Property.    This post has Comments.

It occurred to me that the patent system was created to encourage innovators to release the results of their work to the public so that the society could benefit as a whole from the work of the individual. The obvious way to achieve this is to give the innovator exclusive rights to the innovation in exchange for making the innovation’s details public.

There are many arguments one can level against software patents. You can take the tack that software is essentially math (which it is), and is therefore not patentable (consider a patent on calculus, for example). You can claim that the source code to software is free speech, and it is therefore unconstitutional to limit it through the patent system. You can claim that software is fundamentally a creative art, and is protected by copyright, rendering the patenting of a piece of software akin to the patenting of a plot device in a novel.

But there is another argument that I’ve formulated recently that does not rely on an analogy. It is simply this: when the patent system was designed, its creators never considered that it would be used against those that might have only the best interest of society in mind, rather than their own personal gain. The mere notion that the patent system, a mechanism to promote knowledge sharing in a free society, would be used as a weapon against people and entities that would freely give away their work for anyone to use is absurd. And yet, this is where we find ourselves.

This is by no means a new topic (see Seth Shulman’s book Owning the Future), but the juxtaposition of the system’s goals with the way in which it is being used by today’s companies shed new light on the issue for me. The real innovators are being punished by the system, rather than rewarded. If a garage programmer comes up with a brand new algorithm for distributing data over the network, the software will likely contain a violation of some software patent, as most software does (things like scrollbars, clickable buttons, and one-click checkout have been successfully patented in the United States). The difference is that when a big company creates such software (IBM, Sun, Microsoft, etc.) they have big enough patent portfolios to use them to enter “patent deals” with those that would sue them. That is, the bigger company A’s patent portfolio is, the more likely it is that Company B, the company that wants to sue them, will have likewise violated one of Company A’s patents. In this way, software patents form a sort of “mutually assured destruction” between software patent super powers.

Where do independent developers fit in? Well, so long as they are not that successful, all is well, and they stay below the radar of the superpowers. But if they ever become a threat (GNU, Linux, etc.), then they attract attention and are threatened from the ever present “Patent of Damocles”. Microsoft has repeatedly made threats that they wish to come after GNU/Linux for patent violations, even though Linux is given away to everyone in the society - an asset for all to use freely. In short, the patent system has been perverted to punish the generous and to benefit the mercenaries.

It is, of course, much worse than this. Projects like FFMpeg seek to make media files available to play and edit on a wide variety of computers free of charge. This is a tremendous amount of work, is actively fought by commercial vendors, and has somehow been made illegal in the United States through patent law. In fact, established standards like MPEG4 cannot be implemented by free software authors because the algorithms outlined in the specification itself are patented. Authors who would give their software away free of charge cannot pay licensing fees, and therefore must implement their software in other countries.

Many will cite the United States patent system as rewarding innovators, and credit it with making the United States an intellectual capital in the world. The truth is that we are forcing bright talented software writers who would share their work freely to work in other countries because their work is illegal in the United States.

Perhaps the way forward is to grant those who release their work free a reprieve from prosecution under antiquated “intellectual property” laws until those laws can be updated to reflect the changing landscape of innovation in the software community.

Tags: ,

Posted by Rick on the 18th of February, 2008 at 11:41 pm under Emacs.    This post has Comments.

I wanted to write a simple function in elisp that would find the comment characters used in the current major mode. It is part of an effort to create a simple literate programming tool for Emacs (aka Slipcore - initial version to be posted soon).  The obvious way to do this is to leverage the current major mode’s syntax table and troll through it for comment-significant characters.

Emacs keeps track not only of the character class, but also several character flags (this stuff is described in the elisp manual’s section on syntax descriptors). There are no lisp functions to directly access this information, but in section 35.8 on syntax table internals, it mentions that the higher order bits (16+) encode these 6 flags. It turns out that the syntax table is in fact a vector, so using (elt (syntax-table) 53) where 53 is the ASCII code for the character number I care about, I can access the integer representation of the character class and associated flags.

As it turns out, using this method to determine  comment characters doesn’t really work all that well. There are a handful of languages that will simply break because they don’t use the model of commenting I’m assuming when I look at the syntax flags.  After I posted about this in comp.emacs, I received a nice reply explaining why, despite my notion that this would be a nice general approach to accessing comment syntax, it was in fact kind of misguided.

I am now using a simple alist matching major mode  string to a single-line comment character.  I don’t know if it will stay that way, but it works for basic testing.