Search Results: "spa"

6 June 2009

Enrico Zini: Recording audio on the FreeRunner

Recording audio on the FreeRunner The FreeRunner can record audio. It is nice to record audio: for example I can run the recording in background while I keep tangogps in the screen, and take audio notes about where I am while I am doing mapping for OpenStreetMap. Here is the script that I put together to create geocoded audio notes:
#!/bin/sh
BASENAME=~/rec/rec-$(date +%Y-%m-%d-%H-%M-%S)
alsactl -f /usr/share/openmoko/scenarios/voip-handset.state restore
echo "Getting GPS info..."
getgps > $BASENAME.info
arecord -D hw -f cd -r 8000 -v -t wav $BASENAME.wav
echo "Setting wav timestamp to GPS start of recording"
TS=$(cat $BASENAME.info   grep time_tstamp   cut -f2 -d' ')
touch -d "@$TS" $BASENAME.wav
echo "Done"
It works like this:
  1. It loads mixer settings to record from the handset, but the same could in theory be done for the headset.
  2. It gets all sort of information from the GPS and stores them into a file.
  3. It records audio until it gets interrupted.
  4. It retrieves the GPS timestamp from the beginning of the audio recording, and uses it to set the file timestamp
And the following is the getgps script, adapted from a mailing list post: it can be generally useful to save information about a fix from the GPS.
#!/usr/bin/env python
import dbus
from time import gmtime, strftime
obj = dbus.SystemBus().get_object('org.freesmartphone.ogpsd', '/org/freedesktop/Gypsy')
constatus = obj.GetConnectionStatus(dbus_interface='org.freedesktop.Gypsy.Device')
print "connection_status:", constatus
print "connection_status_name:", (constatus and 'TRUE' or 'FALSE')
fixstatus = obj.GetFixStatus(dbus_interface='org.freedesktop.Gypsy.Device')
print "fix_status:", fixstatus
names = ["INVALID", "NONE", "2D", "3D"]
if fixstatus < 0 or fixstatus > len(names):
    print "fix_status_name:", names[0]
else:
    print "fix_status_name:", names[fixstatus]
def yesno(val):
    return val and "yes" or "no"
(fields, tstamp, lat, lon, alt) = obj.GetPosition(dbus_interface='org.freedesktop.Gypsy.Position')
print "pos_fields:", fields,
print "pos_tstamp:", tstamp
print "pos_time:", strftime('%F %T', gmtime(tstamp))
print "pos_lat: %f" % lat
print "pos_lat_valid:", yesno(fields & (1 << 0))
print "pos_lon: %f" % lon
print "pos_lon_valid:", yesno(fields & (1 << 1))
print "pos_alt: %f" % alt
print "pos_alt_valid:", yesno(fields & (1 << 2))
(fields, pdop, hdop, vdop) = obj.GetAccuracy(dbus_interface='org.freedesktop.Gypsy.Accuracy')
print "accuracy_fields: %d", fields
print "accuracy_pdop: %f" % pdop
print "accuracy_pdop_valid:", yesno(fields & (1 << 0))
print "accuracy_hdop: %f" % hdop
print "accuracy_hdop_valid:", yesno(fields & (1 << 1))
print "accuracy_vdop: %f" % vdop
print "accuracy_vdop_valid:", yesno(fields & (1 << 2))
(fields, tstamp, speed, heading, climb) = obj.GetCourse(dbus_interface='org.freedesktop.Gypsy.Course')
print "course_fields:", fields
print "course_tstamp:", tstamp
print "course_time:", strftime('%F %T', gmtime(tstamp))
print "course_speed: %f" % speed
print "course_speed_valid:", yesno(fields & (1 << 0))
print "course_heading: %f" % heading
print "course_heading_valid:", yesno(fields & (1 << 1))
print "course_climb: %f" % climb
print "course_climb_valid:", yesno(fields & (1 << 2))
time = obj.GetTime(dbus_interface='org.freedesktop.Gypsy.Time')
print "time_tstamp:", time
print "time_time:", strftime('%F %T', gmtime(time))
satellites = obj.GetSatellites(dbus_interface='org.freedesktop.Gypsy.Satellite')
for satIndex, sat in enumerate(satellites):
    print "sat%d_prn: %u" % (satIndex, sat[0])
    print "sat%d_used: %s" % (satIndex, yesno(sat[1]))
    print "sat%d_used_value: %u" % (satIndex, sat[1])
    print "sat%d_elevation: %u" % (satIndex, sat[2])
    print "sat%d_azimuth: %u" % (satIndex, sat[3])
    print "sat%d_snr: %u" % (satIndex, sat[4])

Wouter Verhelst: NBD, TRIM, and sparse files

Ever since I read about the ATA TRIM command, I've been thinking that something like that would make a lot of sense for things like NBD. Currently, it's possible to serve a sparse file using NBD. I often do this, for example, testing things like the fix for Bug #513568 (nbd-server choking on a >3 TB RAID device) which would otherwise require me to spend significant amounts of money so that I get enough disks to test. Obviously that's not going to happen. If we're using sparse files, that means we claim to export more than we actually do. This is obviously useful for testing, but there are other cases where this kind of behaviour could be useful; for instance, when exporting swapdevices to several diskless clients, it would be a rare case indeed where all those clients need all of their available swapspace; it might be safe to slightly overcommit the disk space on your hard disk, on the assumption that none of your clients is going to use all that space at the same time. Similarly, when a file is removed on a filesystem on an NBD device, the kernel might use the generic TRIM layer described by Ted in the article above to relay that removal to the nbd-server process, which could then make sure the diskspace is deallocated. However, unfortunately, there currently is no way for an nbd-server to tell the kernel to create a new hole in a sparse file. Creating sparse files is done at file creation time; if you later want to add more holes than you did when creating the file, you need to recreate the whole file from scratch in order to do so. Additionally, when we're talking about a large amount of data that needs to be removed, it's usually much faster to say 'remove this block of data' rather than 'overwrite several megabytes with zeroes here' not just in API, also in kernel-side implementation, provided the filesystem supports extents. I think it might be nice if there were a public (userspace) API to tell the kernel that particular bits of a file or a block device are no longer required, and that they may thus be removed. But then, I'm not very experienced with kernel code, and it might be that I'm just plainly missing something here. Anyone?

5 June 2009

Biella Coleman: 70s Wndsurfer (with matching sailboat)



70swindsurfer, originally uploaded by the biella.
So as part of my efforts to work in PR, I bought a printer. The one that was 1) the cheapest 2) worked with the Linux (an HPJ4550) also had a scanner. I thought it would never work on Linux, or not without some series fiddling and tweaking. But I bought the postcard, pictured above, to do a test run, and the run of test worked immediately. Go Linux! Now on to the postcard: love the postcard because it is so 1972-1982 or so. It would be hard to find such a scence today. Not only are windsurfers a dying breed (kite surfing is the new kid on the block), well, current windsurfers are definitely not so 1970s orange, yellow, and blue. And so you have to ask: are there just truckloads of these postcards printed decades ago or do they actually print them anew? Can t answer but at least I know the scanner works!

Gunnar Wolf: RubyCamp Mexico

RubyCamp UNAM logo Today I attended RubyCamp (schedule available), organized by my friends at Instituto de F sica, at my University. I presented three plugins I made and regularly use. The organizers followed a short, more informal scheme than most conferences I am used to Talk slots range between 5 and 15 minutes, so we attended a whole day of semi-lightning talks. Of course, many people have run late, and although there was quite a bit of free space in the schedule, it has been practically non-stop I was thinking on also giving a talk on encodings (as many people really still don't understand what is UTF-8, what is Latin1, why all that mess People, please learn at least The Absolute Minimum Every Software Developer Absolutely, Positively Must Know About Unicode and Character Sets (No Excuses!)), but the schedule is full by now. Interesting and successful experiment, I'd say. The talks are being taped, and the organizers say they will be soon made available online. There are many cultural details to note here. First of all, yes, the Rails Fanboys _are_ a cult/sect. I think we have ~90% of MacBooks... I still fail to understand why a coder feels at ease on MacOS. I deeply despise it! Also, most of this community have bitten the Twitter plague. This is also a community very much into businessspeak, speaking a word in English for each two words in Spanish (I try to be consistent, not mixing languages at least). Some conferences have been quite business- and enterpeneur-oriented. Although I should not complain too much about this, as it is an important aspect for many people But I still don't feel at ease having talks on how to run a business if we were asked for presentations on technical aspects! Anyway - I was quite happy to be here. This is the first real technical, code-oriented conference I have attended in a long time in Mexico. And we need more like this! We have too many entry-level, evangelization-oriented conferences, but very few like this one. [update]: Group photo!

Paul van Tilburg: Iceland, Here I Come!

I am all set for my trip to Iceland! (Well, except for the actual packing of stuff.) The purpose of the trip is a work visit and holiday combined. In the first week (maybe extended to 9 days), I will be working at the Reykjavik University on some process algebra things and possible present my past work. During my time there I can stay at the appartment of Arnar, whom I ve met when he was attending our university for his Master s. Thanks for providing me with accomodation and congrats with obtaining your Master s degree! When my days at the RU are over, I will explore, tour, hike around the island with him and some of his friends. Very much looking forward to that! Some travel information for Sunday June 7 (travelling with Iceland Air):
09:45 Leaving by foot/bus/train to the airport
14:00 Departure from Schiphol with flight FI503 (UTC+0200)
15:00 Arrive at Keflavik Airport (UTC+0000)
I will be returning on Sunday June 28:
16:30 Departure from Keflavik Airport with flight FI504 (UTC+0000)
21:30 Arrive at Schiphol (UTC+0200)
I will attempt to keep you all updated via this journal and/or the usual microblogging sources: Twitter / Jaiku / Luonica.

Ren&#233; Mayorga: June and July two events to attend, DebConf and ECSL

and http://ecsl.sl-centroamerica.org/ Being a lot time without any post but finally I see the things more clear, I changed my $paid-job on March, I leave my sysadmin job on a midle-range local ISP, to go on a sort of similar job in another one, more big company, first I though that this will give me more spare time but I was wrong, at least for the first months, but at this time I m finally getting enough time to rest, but not enough time to devote to some Debian tasks(but things will change!!). but looks like everything is going better, I get my $paid-job permission to go to DebConf, and I will also attending just 2 days to ECSL; ECSL is Encuentro Centroamericano de Software Libre , it is actually the first gathering with people related to Free Software communities on this small area(Central America), we expect about 100 people from Central America, Mexico, and some other places, this is could be a nice opportunity to create efforts on a region that is having political and social efforts to integrate all countries in a political/social block. So, see you all at C ceres and Gunnar, see you on ECSL at Estel :)

4 June 2009

Eddy Petri&#537;or: Solution: E: Cannot get debconf version. Is debconf installed?

If you ever get this error when running apt-get or aptitude:

E: Cannot get debconf version. Is debconf installed?

Then your go to /var/lib/dpkg/ and make sure the files status, available and diversions are not empty. If they are, copy the corresponding *-old file into the proper file and be happy.


This is how they looked in a cowbuilder chroot of mine which refused to build packages (I highlighted the important zero-ed files):

root@twix:/# cd /var/lib/dpkg/
root@twix:/var/lib/dpkg# ls -l
total 280
drwxr-xr-x 2 root root 4096 Apr 13 2008 alternatives
-rw-r--r-- 2 root root 0 Jun 3 13:46 available
-rw-r--r-- 2 root root 99608 Jun 28 2008 available-old
-rw-r--r-- 2 root root 0 Jun 3 13:46 diversions
-rw-r--r-- 2 root root 2501 Feb 28 2008 diversions-old
drwxr-xr-x 2 root root 32768 Apr 13 2008 info
-rw-r----- 2 root root 0 Dec 10 20:27 lock
drwxr-xr-x 5 root root 4096 May 26 2005 methods
drwxr-xr-x 2 root root 4096 May 26 2005 parts
-rw-r--r-- 2 root root 47 Feb 28 2008 statoverride
-rw-r--r-- 2 root root 0 Feb 28 2008 statoverride-old
-rw-r--r-- 2 root root 0 Jun 3 13:46 status
-rw-r--r-- 2 root root 115966 Jun 28 2008 status-old
drwxr-xr-x 2 root root 4096 Jun 29 2008 updates


Hmm, that looks fixable ...

root@twix:/var/lib/dpkg# cp available-old available
root@twix:/var/lib/dpkg# cp diversions-old diversions
root@twix:/var/lib/dpkg# cp status-old status
root@twix:/var/lib/dpkg# ls -l
total 508
drwxr-xr-x 2 root root 4096 Apr 13 2008 alternatives
-rw-r--r-- 1 root root 99608 Jun 4 16:10 available
-rw-r--r-- 2 root root 99608 Jun 28 2008 available-old
-rw-r--r-- 1 root root 2501 Jun 4 16:10 diversions
-rw-r--r-- 2 root root 2501 Feb 28 2008 diversions-old
drwxr-xr-x 2 root root 32768 Apr 13 2008 info
-rw-r----- 2 root root 0 Dec 10 20:27 lock
drwxr-xr-x 5 root root 4096 May 26 2005 methods
drwxr-xr-x 2 root root 4096 May 26 2005 parts
-rw-r--r-- 2 root root 47 Feb 28 2008 statoverride
-rw-r--r-- 2 root root 0 Feb 28 2008 statoverride-old
-rw-r--r-- 1 root root 115966 Jun 4 16:10 status
-rw-r--r-- 2 root root 115966 Jun 28 2008 status-old
drwxr-xr-x 2 root root 4096 Jun 29 2008 updates


Now it works :-)

Steve McIntyre: Keep libel laws out of science

The "Sense about Science" group have written about a ridiculous lawsuit currently happening in the UK. The British Chiropractic Association has sued Simon Singh for libel, based on an article he wrote in the Guardian newspaper in 2008. There is a campaign to express support for Simon and call for an urgent review of English law of libel, and I have signed the petition myself. The right place for scientific debate is out in the open, not shut down by cowards who refuse to show evidence for their claims and instead pay for lawsuits. Keep libel laws out of science

Kurt Roeckx: Software used in Belgian elections.

Like Machtelt Garrels points out, the source code for the software used on the voting computers for this year is not yet available. It only is made available to the general public the day of the election after the voting has closed. The government has a FAQ about it here (available in Dutch, French and German). As it says, software from previous years is available, but you need to be able to find it. So here are the links: 2003 2004 2007 There are 2 pieces of software that can be used: Jites or Digivote. They're not compatible with each other, so it depends on the municipality you have to vote in which one is being used. Here you can find a study of Belgian voting system and a comparison with other countries. It's available in Dutch, French and English. Update: The sources is available before the vote, just not to the general public. It's available to the politcal parties and the parlement can appoint a specialist to inspect the source code.

3 June 2009

Pablo Lorenzzoni: Keysigning Party at FISL10

We ll be holding a Keysigning Party at FISL10. This will be a good opportunity to renew my key, given I ve been using it since 2001 and it s an old 1024 DSA key. I have to thank An bal Monsalve Salazar and Alexander Wirt for sharing their expertise in organizing this kind of event. More information on the KSP can be obtained from the announcement.

Chris Lamb: Checklist for configuring a Debian system

In the spirit of Thomas Limoncelli's Time Management for System Administrators, this is my checklist for setting up a new Debian system. I have added a few notes to the original list to justify their existence and to provide some background information. Whilst you should avoid performing repetitive interactive configuration and defer to the multitude of tools designed for this task, constructing and sharing a checklist can still be an instructive step. It can also be useful in situations where a machine has already been partly configured for you.
Software
  • /etc/apt/sources.list

    • Choose a sensible primary mirror
    • Ensure use of release codenames (eg. "lenny") instead of synonyms
    • Confirm security mirror is enabled
    • Remove references to contrib and non-free
  • Disable installation of Recommends:

    echo 'APT::Install-Recommends "0";' > /etc/apt/apt.conf.d/90recommends
    
  • Ensure we are up to date security-wise:

    apt-get update && apt-get dist-upgrade
    
  • Setup and configure locales first to avoid annoying Perl warnings. Don't choose All locales; you almost certainly don't want that.

    apt-get install locales
    dpkg-reconfigure -plow locales
    
  • Install some essential utilities:

    apt-get install vim-nox ntp openssh-server screen most tree bzip2 unzip moreutils dnsutils htop pwgen telnet manpages manpages-dev vrms acl gawk strace curl tcpdump
    
Users
  • Before we create any real users, we configure PAM to reject weak passwords. Custom banned passwords can be added to the dictionary by editing /usr/share/dict/cracklib and running update-cracklib.

    apt-get install libpam-cracklib
    sed -i -e 's ^password # \0 ' /etc/pam.d/common-password
    echo 'password required    pam_cracklib.so retry=3 minlen=6 difok=3' >> /etc/pam.d/common-password
    echo 'password required    pam_unix.so use_authtok nullok md5' >> /etc/pam.d/common-password
    
    (Edit: Please read this response from Steve Langasek regarding this modification on squeeze and Ubuntu 8.10)
  • Configure sudo. I prefer to create a new group instead of re-using adm as that is already used by logfiles.

    addgroup rootusers
    adduser myuser
    adduser myuser rootusers
    apt-get install sudo
    echo 'User_Alias ROOTUSERS  = %rootusers' >> /etc/sudoers
    echo 'ROOTUSERS, root     ALL=(ALL) ALL' >> /etc/sudoers
    
Mail relay Email remains the primary method to asynchronously inform the system adminstrator that their attention is required. It is assumed that the machine will not handle your day-to-day email (or indeed accept any external mail) but will instead simply forward it elsewhere. We also assume a preference for Exim, but the configurion for Postfix is almost identical.
  • First, install the mail packages:

    apt-get install exim4-daemon-light bsd-mailx
    dpkg-reconfigure exim4-config
    
  • During the Exim configuration, choose Internet site and follow all the defaults, ensuring that you only listen on 127.0.0.1 and you are not relaying mail for any other domains.

  • We then configure forwarding to another email address so we don't have to continually poll this machine for issues:

    echo 'root: you@example.com' >> /etc/aliases
    newaliases
    
  • Finally, we test mail delivery:

    echo "Test 1 from $(hostname)"   mail root -s "Test 1 from $(hostname)"
    
The d-i manual has some further advice on this, including the use of "smarthosts".
Miscellaneous
  • Stop Emacs creating backup files everywhere:

    mkdir -p /etc/emacs/site-start.d
    echo '(setq backup-inhibited t)' > /etc/emacs/site-start.d/10no-backup.el
    
  • Configure Munin:

    apt-get install munin-node
    echo 'allow ^123\.123\.123\.123$' >> /etc/munin/munin-node.conf
    /etc/init.d/munin-node restart
    
    For baroque network configurations, you can generate the regular expression line with this script.
  • Configure molly-guard, a tool for preventing accidental shutdowns. As molly-guard cannot detect shutdowns initiated within a combination of GNU screen and SSH, we configure it to always query the hostname:

    apt-get install molly-guard
    echo "ALWAYS_QUERY_HOSTNAME=true" >> /etc/molly-guard/rc
    
  • Monitor disk S.M.A.R.T. attributes:

    apt-get install hddtemp smartmontools
    sed -i 's ^#start_smartd=yes start_smartd=yes ' /etc/default/smartmontools
    /etc/init.d/smartmontools start
    
  • Setup backups - I'm quite partial to backupninja because it automates most of the tedious SSH configuration. I adjust the time of the backup to when I'm likely to be around to fix issues and cut down on email noise by not reporting successful backups:

    apt-get install backupninja hwinfo debconf-utils rdiff-backup
    sed -i -e 's ^when = everyday at 01:00 when = everyday at 9:30 ' /etc/backupninja.conf
    sed -i -e 's ^reportsuccess = yes reportsuccess = no ' /etc/backupninja.conf
    ninjahelper
    
  • Filesystems

    • In /etc/fstab, check noatime is enabled on all filesystems, and acl where needed.
    • Use tune2fs to adjust how much of the disk is reserved for the superuser - the default of 5% is excessive for large volumes.
  • Reboot. You should be prompted by molly-guard before your computer restarts.

2 June 2009

Christian Perrier: On localization

An old friend is ranting about localization. I first considered not really reaction to Joey's post, mostly because he has very true points...and particularly when he has about the same reaction than mine about a recent post in ou mailing lists. So, I will stick to react to one part of Joey's post...the one I consider really inaccurate. "everyone uses the software in English anyway" Really, Joey, really, that's completely untrue. Of course, I do live in a country that very well known (or at least that has the reputation) for being deeply ignorant in English language. But, really....*all* computers I see around me, both in my personal life *and in my professionnal life* are nearly completely localized. It's probably now well know that I spend most of my professionnal time....providing desktop systems (or managing the people who provide them) to users in ONERA, "the French Aerospace Lab". That means about 2000 users in a scientific environment where the use of English is much more developed than the average environment. Most of these users speak a fairly decent English and are perfectly able to understand that language in some way. About 80% of these systems are Windows-based and 20% are Linux-based. Probably more than 95% of them are localized in French. Even on Windows systems, we mostly integrate free software. And for *each* of them, the most important feature we need, besides software being free, is it to be localized in French. I bet our friends from Extremadura can say the same. The success of Linux-based free systems there also happened because the software is available in Spanish. And, of course, there are tons of similar stories and counter-examples (M nchen, Bhutan, Venezuela, etc.). So, really, please don't spread out that idea. Oh, yes, geeks *do* use their software in English (and, even here, I need to be convinced if I remember well what I saw at conferences in Germany or Spain, for instance). And, yes, it's very well widespread among geeks that using software in English is "better" or "easier". Which I indeed always fight and will fight until I die..:-). We certainly agree that these l10n needs put a high load on development and sometimes slow it down. and, for sure, we sometimes need to make a balance and I really thank you for giving me the credit to try doing that balance. Anyway, all this (including your rant) had to be said and it's interesting to have that small discussion (I just should not start writing down a blog entry at 23:00...:-)) See you soon, hopefully, Joey !

Biella Coleman: (Pobre) Shorty va ser sinbolico



shorty, originally uploaded by the biella.
As part of my reading bonanza, I am currently reading and enjoying Ellen Ullman s The Bug. She has a short section on puns and programmers which I like:

Puns, I would say, represented a human being s pent-up need for ambiguity. That a word could signify two things at once! And these double meanings could be simultaneously understood! What a relief from the flat-line understanding of a programmer s conversation with the machine! p. 59
Last night, I heard a Spanish pun that I particularly liked, having to do with my sister s dog, Shorty who is an odd creature (being a mix of Pit Bull, which is for certain, and legend goes, Chihuahua) will be as of the end of the day > sinbolico. I bet the Spanish speakers know what is happening to Shorty today. Anyone want to take a guess?

Biella Coleman: (Pobre) Shorty va ser sinbolico



shorty, originally uploaded by the biella.
As part of my reading bonanza, I am currently reading and enjoying Ellen Ullman s The Bug. She has a short section on puns and programmers which I like:

Puns, I would say, represented a human being s pent-up need for ambiguity. That a word could signify two things at once! And these double meanings could be simultaneously understood! What a relief from the flat-line understanding of a programmer s conversation with the machine! p. 59
Last night, I heard a Spanish pun that I particularly liked, having to do with my sister s dog, Shorty who is an odd creature (being a mix of Pit Bull, which is for certain, and legend goes, Chihuahua) will be as of the end of the day > sinbolico. I bet the Spanish speakers know what is happening to Shorty today. Anyone want to take a guess?

Neil Williams: Geany 0.17

I've been using (and recommending) geany for some time, it's a far nicer and far lighter editor than gedit and has excellent syntax highlighting and symbol browsing support. One feature it was lacking has now been fixed in 0.17 - clear, simple handling of debian/control files. It's a real bonus for packages that have lots of binaries built from a single source - each Package: stanza is a separate section in the symbol browser and makes it trivial to skip between stanzas. gedit doesn't have a symbol browser available, even as a plugin, the perl syntax highlighting in gedit is unusable to me and anjuta is just too heavyweight and bulky for perl packages.

I've always liked the embedded terminal in geany (much cleaner than the equivalent in gedit) and the embedded scribble pad which is far more useful than having to create a unwanted file window and then being nagged to discard it. The iterative search in geany is simply the easiest I've found anywhere. Simple tools like ChangeLog template insertion, date stamp and licence text insertion, tab to space bidirectional conversion and easy indent control make editing so much nicer in geany.

So now I exclusively use geany for all my perl and shell work and anjuta for all my C/C++ work. gedit has finally been purged. :-)

1 June 2009

Junichi Uekawa: Trying to clap.

Trying to clap. I've tried making a 'crowd claps' kind of sound. I recorded myself clapping, 12 times, and mixed the sound with ecasound: ecasound $(for A in $(seq 1 12); do echo -a $A -i "$A.wav" -y $(( A / 5 )).$(( A % 5 * 2 )); done ) -a 1,2,3,4,5,6,7,8,9,10,11,12 -o alsahw,0,0,0 However, it doesn't sound quite right, it is too sparse. I tried mixing the same sound 12 multiple times, but it seems to make the sound stiffer but not in the way I wanted. Delay and echo doesn't get me the right tone. Hmmm.. ecasound $(for A in $(seq 1 3); do echo -a $A -i "hakushu.wav" -y $(( A / 5 )).$(( A % 5 * 2 ))$(( A % 2 * 2 )); done ) -a 1,2,3 -o hakushu2.wav

31 May 2009

Russell Coker: Expectations and Fandom

Russ Allbery has written about the hostile reactions of sci-fi fans toward the delay of a book release [1]. Russ makes some good points regarding the issue of whether paying $100 for some books entitles a reader to have the rest of the series written (in summary - no, the author owes the fans nothing). Russ also notes that when someone makes a public promise to do something (such as writing a book) they will probably be feeling bad about being unable to live up to that, and harassing them about it is not going to make them feel any better - or make them better able to do the work. Charles Stross has written a blog post about this topic, he makes some interesting points and the comments illustrate most of them [2]. One comment claims that the author of the delayed book in question flaunts his NFL watching while the same person also criticises the author for writing a blog. This level of contempt for the author amazes me. In case anyone is interested I watch The Bill and Desperate Housewives every week. Anyone who wishes to criticise me for watching soapies instead of documentaries is welcome to do so. But I will not make any apologies for spending some of my time doing things other than coding. If I watch Desperate Housewives instead of fixing a bug that inconveniences you then you just have to deal with it. I believe that taking a regular break from work is a basic human right, apart from which there is evidence to show that working excessive hours decreases the quality and quantity of work that is completed [3]. It seems to me that members of the free software community are in a better position regarding fans than most creative people, and that this is largely due to how transparent the development process is. The most influential members of the user (fan) base are software developers. While people will be disappointed when software is not released on time or has some bugs many users know what is involved and understand that no testing will find all bugs. Even some basic shell scripting can teach people the difficulties of programming and convince them to have a little more patience than they might otherwise have. So the typical user of free software will have some idea of what is required to write software while the typical reader of a novel has no idea of what is involved in writing a book. Another benefit for the free software community in this regard is the open development process. When users are unhappy about release delays (as some Debian users were before Lenny was released) they can easily look at the bug list. If a user is pushy they can be invited to fix some bugs themselves, if they investigate the matter and discover that the bugs are too difficult for them to fix then they will probably feel compelled to stop hassling the people who can fix the bugs. Complaints from users regarding the release process can be turned around with the software is late because YOU haven t fixed any bugs . Please note that submitting bug reports is NOT criticism, it is in fact helping the development process (particularly when the bug reports contain information on how to fix the problems). This exposes another significant difference between writing software and writing a book. Even if I was a talented author I would not be able to offer any assistance to an author who had trouble completing a work simply because I wouldn t have the same vision for the plot of a book. But it s not uncommon for software development projects to be forked if the users are unhappy with some aspect of how they work, and it s also not uncommon for a programmer to voluntarily give one of their projects to another developer - sometimes developers try and convince other people to take projects from them when they don t have enough time. Even without changing the ownership of a project, anyone can submit a patch. The patches that I have received from users of my software have generally been of a high quality and it has taken little work to merge them. A final difference is that any programmer can produce a private fork of a project. I have lost count of the number of times that I have produced custom versions of free software for my own personal use or for the use of my clients. Sometimes the modifications that I made were unsuitable for wider use (IE they broke things for usage cases that I didn t care about) so I just privately made the software do what I needed. This makes the upstream developer (or team) and other contributors irrelevant to fixing the problem in question. Now this is not to say that the free software community is perfect. But it seems that certain types of bad behavior that we see demonstrated in the sci-fi fandom circles are uncommon and the people who demonstrate them are significantly outnumbered by people who oppose such actions. Publicly criticising a programmer for watching the NFL in their spare time is akin to holding a sign saying kick me . As I am a fan of science fiction (and hope to write some in the near future) I wonder whether the sci-fi community could be changed to have a culture more like that of the free software community. The web site 365tomorrows.com publishes a short sci-fi story every day [4], they have been doing this for a few years now. They started out publishing work by a small team of authors with the aim of writing a story a day for a year. Now they also take submissions from users and they have a forum for budding authors to discuss their work. The site Protagonize.com is based on the idea of collaborative fiction [5]. I wonder whether the increasing number of sci-fi fans who join such forums will change the nature of the community. Maybe when a book is delayed the fans could take comfort in an increasing amount of fan-fiction based on characters from that book, I expect that the fan fiction will probably not impress all authors - and some may be offended by having their characters used in pornographic fan fiction. But that might just lead to a market shift towards authors who are not overly concerned about such things. When attending sci-fi book signings I ve noticed fans who appear to have stalking tendencies. I have been wondering how much of this is another symptom of the same problem and how much of it is due to science fiction attracting some people who don t understand the concept of personal space and who haven t considered the mathematics of interactions between famous people and fans - as one of many fans the famous person will not remember your fan letters or whether they have met you before, it s not possible. I look forward to the day when a well known author can have lunch with some fans after a book signing and not be afraid of weird fans. I wonder if Cory Doctorow [6] already has such cool fans, Cory seems to be one of the leaders in the new open way of writing and releasing sci-fi so it seems likely that he would be among the first to reap the benefits. I m sure that most authors would like to have lunch or dinner with their fans if they could be assured that the probability of getting stuck with a nutty fan was extremely low.

Wouter Verhelst: COBOL

According to The Registry, COBOL is now slightly over 50 years old. I wish I could say I never wrote a single line of COBOL, but I can't. In college, I was taught COBOL for three long years. Even though I've managed to purge most of that knowledge from my brain (good riddance), I still have nightmares about the horrible way in which one writes COBOL. I wish I could say COBOL is dying, but it isn't. People still write new COBOL today. I mean, seriously, there's a standard called 'COBOL 2002. 'Nuff said. I wish I could say COBOL isn't a problem, but it's the sole source of most of the Y2K issues way back when. Its features invite many of the kind of horribly wrong coding styles which cause bugs; Y2K is just one. I wish I could say COBOL code is pretty, but it isn't. Just to give one example: the first 7 characters of every line of code in each and every COBOL program are 0x20. That is, space. Nothing. Utterly useless. There is no reason for this in modern environments, yet it's still there. Note why I dislike significant whitespace. Another example is the fact that you can't just say 'foo = 1 + 1'. Instead, you have to say 'MOVE 1 TO FOO', and then add a second statement that says 'ADD 1 TO FOO'. I'll just use english if I want to write a novel, thank you. I wish I could say I didn't care about COBOL anymore, but for some weird reason, I do. And just in case you were confused: no, I do not have warm, fuzzy feelings for COBOL. If there was a button that would nuke all the COBOL code on the planet, would I push it? Probably not immediately. I'm sure it would take time for me to recover from the sheer joy of knowing that this button actually exists, before I'll be physically capable of keeping my hands steady for the amount of time required for me to actually be able to push it. COBOL is proof of either the absense of any deity, or the existence of the devil. Given the chance, no sane person, let alone a sane deity, would allow the creation of such an abomination. At least I don't have to deal with it anymore. That part is not going to change. Ever.

Russell Coker: LG U990 Viewty

I have just got a LG U990 Viewty mobile phone [1]. It s a 3G phone and came free on the $29 monthly cap plan from Three (minimum monthly spend is $29 - but this is free if you use $29 per month). My previous plan was the $29 cap but had a minimum spend of $20 per month, as I never happened to use less than $29 per month I am not paying more. For a modern mobile phone the actual phone functionality is a sideline. If a device was strictly designed to be a phone then I think it would be very similar to the Nokia phones that were available 5+ years ago - the Nokia I had in 1999 performed every phone function that I desired of it. Like most modern phones the LG U990 Viewty suffers in it s phone functionality from the desire to make it do non-phone tasks and from the desire to cripple it to meet the desires of the carriers (not the desires of the users). For example the home screen will always have at least two buttons for paid Three services and I have no configuration option to remove them. Replacing them with speed dial options for a couple of numbers that I regularly call would be handy. As the main screen is a touch-screen there is no excuse for this, they should allow the software to be reconfigured with more useful options. Eventually the Android will kill most of the other phones and this problem of phones being designed to suit the telephone companies instead of the users will be solved. One of the most annoying mis-features of the phone is that it doesn t properly handle address book entries with multiple phone numbers. One of my friends turns his mobile off when he is at home, so I regularly call his mobile and then immediately call his home number if the mobile is unavailable. With my previous two mobile phones I could press the dial button to bring up the list of previous calls and then use the arrow buttons to select from the other numbers that are attached to the same address-book entry, so with three button presses I would be dialing his other number. With the Viewty I have to go back to the address book. The compelling feature of the Viewty is the camera and display. It has a 5MP camera which makes it the second highest resolution camera-phone offered by Three - the LG Renoir (KC910) has 8MP but needs a $99 plan for it to be free. It also has a 240*320 resolution touch-screen display (in a quick search in January when I bought my phone the best resolution display I could find on a phone is 240*400 in the LG Renoir). While the camera is documented as being 5mp there are no specs available about the resolution of the CCD. I want to use the native resolution of the CCD for pictures (I think interpolation is a waste of space). The CCD might actually be 5mp, a picture of the 1400*1050 resolution screen on my Thinkpad allows me to read all the text even when small fonts are in use, so the CCD resolution must be significantly greater than 1400*1050. This is a really important feature as the Viewty will work well for making screen-shots for bug reports about crashed computers (several of my clients have expressed interest in getting one after seeing such a demonstration). One annoying problem is that the camera software takes a while to load, my trusty Sony digital camera starts a lot faster and the LG U890 phone I used for the past two years is also a lot faster and more convenient. This won t work well for photographing unexpected events. When I am traveling by public transport I will photograph the relevant pages of my street directory as I can zoom in to photos of the maps and read the street names, it saves some weight when traveling. The 2G micro-SD card (which incidentally cost $10 from OfficeWorks) will allow me to store a lot of maps. One interesting feature is the video recording capabilities. It can do 640*480 resolution at 30fps (which is pretty good) and 320*240 resolution at 120fps (they claim that you can film a balloon popping). In my quick tests the standard 640*480*30fps mode works well, but the 120fps mode requires much brighter light than most of my test environments, so I have not yet got it working properly. The phone has a reasonable voice recording function, it can record considerably more than 34 hours of audio and the quality is reasonably good if you use an external microphone. It is however quite poor if you use the built-in microphone for a dictaphone function, it seems that quality is poor at any distance. I had wanted to record my LCA mini-conf talks with my phone but unfortunately forgot to bring the adapter for the external microphone. It s a pity that the phone doesn t have a standard microphone socket as I have misplaced my Viewty microphone, when designing the phone they should assume that misplacing attachments is a common occurrence and design it to use common parts. I recently spoke to a journalist who uses his mobile phone to record interviews. He said that his phone supported phone calls, voice recording, and taking pictures - all the essential tasks for his work. It seems that the Viewty would be better than most phones for journalistic work apart from the issue of low quality voice recording when you have misplaced your external microphone. The text editor is unfriendly in the keyboard mode (I have not tried hand-writing recognition), one thing I don t like is the fact that the letters jump when you press them. This does allow changing a letter by moving the stylus before releasing the press (some people consider this a great feature). There are no cursor control keys (which is a serious omission), and the keyboard doesn t resemble a real keyboard. My iPaQ is far better for writing (I once wrote a full-length magazine article on an iPaQ). The stylus is quite strange and interesting. In the picture of the front of the phone the stylus is compacted with it s lid on. In the picture of the back of the phone the stylus is extended with the lid off. The end of the stylus clips in to the lid so that removing the lid drags the central part out of the body. It s an interesting design and with the string on the lid allows the stylus to be attached to the phone when it s not being used. But I have never used it. Even with an iPaQ (which had a proper stylus that attached firmly inside the body of the device) I often used a fingernail on the touch screen. I have not felt the need to ever use a stylus with my Viewty. One final noteworthy thing is the support for Google services. It seems to have client support for YouTube, Google Maps, GMail, and Blogger. This seems to be a major win for Google, the Viewty is one of the most popular phones at the moment and I expect that lots of people who buy them will now have an incentive to use the Google services. Between these sorts of deals and the Android I think that it will be necessary to have some sort of anti-trust action against Google. Google are generally doing good things for the users. I have been quite satisfied to use Google search, Google advertising on my blog, and Gmail. Also I have been moderately happy with Blogger (it was good when I started blogging) and Google Maps is useful on occasion. So generally I am happy with Google, but monopolies are bad for the users so I think that if things continue on their current trend then Google may have to be split into several little Googlets some time in the next few years.

30 May 2009

Christine Spang: microblogging

At some point in the recent past I gave in and signed up for Identica and Twitter. I'm now simultaneously posting to both these services and Facebook via Gwibber. (I grabbed the Ubuntu package from Launchpad since the Debian ITP has been stalled for some time.) In one way, I've been microblogging for some time via Zephyr. But I sometimes feel limited by the fact that it only puts me in touch with the MIT community (and only a subset of that, even), so perhaps Twitter/Identica will prove a better solution.

Next.

Previous.