blog dds

2013.02.21

Systems Code

If I program in many high and low-level languages, but don’t write systems code, I am a quiche programmer or a code monkey. And if my code runs without errors, and I know the complexity of all algorithms; and if my servers have hundreds of cores and gigabytes of RAM, but don’t write systems code, I am nothing. And if I run the hippest kernel, and install the neatest apps, but don’t write systems code, it profiteth me nothing.

Continue reading "Systems Code"

2012.12.19

APIs, Libraries, and Code

Let’s say you want to display a JPEG-compressed image, calculate Pearson’s correlation coefficient, parse an XML file, or create a key-value store. You can often choose between using the functionality of the application’s platform (Java EE or .NET), calling one of several available external libraries, or writing the code on your own. It isn’t an easy choice because you have many factors to consider. Specifically, you must take into account the task’s complexity, as well as the licensing, quality, and support of competing alternatives. See how you can narrow down your choice by eliminating alternatives at the earliest possible decision point.

Continue reading "APIs, Libraries, and Code"

2012.10.21

Chemical Element Trump Cards

I can still remember the weight of the Lancia Stratos car that featured in the Top Trumps cards were playing as children in the 1970s: 870kg. It was the lightest of all the flashy cars in the set, and therefore a much sought-after card. Other card sets that kept us busy included airplanes, motorcycles, and tanks. Through them we learned tens of useless trivia, but also got a feeling of the compromises inherent in engineering. Wondering whether I could leverage such a game to make it even more educational, I created a set of trump cards containing properties of chemical elements.

Continue reading "Chemical Element Trump Cards"

2012.02.07

How to Decrypt "Secrets for Android" Files

Secrets for Android is a nifty Android application that allows you to securely store passwords and other sensitive data on your Android phone. Your data are encoded with your supplied password using strong cryptography and are therefore protected if your phone gets stolen. Although the application offers a backup and an export facility, I found both wanting in terms of the availability and confidentiality associated with their use.

Continue reading "How to Decrypt "Secrets for Android" Files"

2010.10.14

Synchronizing Thunderbird's Replied Flag

My main email client is Thunderbird, but I also use BlackBerry's and Apple's clients, all through the same IMAP account. Disconcertingly, email messages to which I have replied through the other clients don't show up in Thunderbird with the "replied" (replied icon) icon. This means that when I browse my email using Thunderbird, I waste time trying to remember whether I have responded to a particular message. Here is how I solved the problem.

Continue reading "Synchronizing Thunderbird's Replied Flag"

2010.05.20

Email Analytics

During the past six months I've been drowning in email. I spend a large part of my day responding to email messages and filing incoming messages I consider important. Yet I'm falling behind and this affects the quality of my work: I sometimes delay responding to important messages. Followng Peter Drucker's dictum "If you can't measure it, you can't manage it", I decided to write a tool to analyze my incoming and outgoing email messages.

Continue reading "Email Analytics"

2009.08.20

HP-200LX Remote Control Hacks

All my friends know that for the past 15 years I've been semi-attached to an HP 100LX palmtop PC (recently updated to a 200LX) for my personal information management and many other tasks. The device is extremely versatile, sturdy, and flexible. Amazingly, after so many years of hard daily use, I still find new applications for it.

Continue reading "HP-200LX Remote Control Hacks"

2009.07.01

Real-Time Google Earth GPS Tracking

In a recent trip I incorrectly assumed that real-time tracking of Google Earth's pre-cached maps with a GPS receiver would be sufficient help for navigating around the highways in Los Angeles. I therefore experimented with the way Google Earth's sparsely-documented real time tracking works, and wrote a small program to interface Google Earth with a GPS receiver. Fortunately, after seeing a colleague drive with a car-GPS device on the dashboard I came to my senses, and got a real Garmin Nuvi car-GPS device.

Continue reading "Real-Time Google Earth GPS Tracking"

2009.06.25

Greek Numerals in OpenOffice.org

OpenOffice.org doesn't support Greek numerals, and this is a problem for its Greek localization, because such numerals are often used for section and list numbering. As an exercise in large scale code reading and in the writing of code I'm supposed to teach to undergraduate students, I decided to contribute an implementation to OpenOffice.org.

Continue reading "Greek Numerals in OpenOffice.org"

2009.05.27

Revisiting the Antikythera Mechanism Emulator

Over the past few weeks I updated the Antikythera mechanism emulator I built in 2007. I was preparing for an invited talk on the subject, which I'll give at the 2009 USENIX Annual Technical Conference, and for this I wanted to include in the emulator the new findings recently published in Nature.

Continue reading "Revisiting the Antikythera Mechanism Emulator"

2009.05.07

Fixing the Orientation of JPEG Photographs

I used to fix the orientation of my photographs through an application that would transpose the compressed JPEG blocks. This had the advantage of avoiding the image degradation of a decompression and a subsequent compression.

Continue reading "Fixing the Orientation of JPEG Photographs"

2009.04.20

A Tiling Demo

Over the past (too many) days I've been preparing my presentation for the ACCU 2009 conference. At one point I wanted to show how loop tiling increases locality of reference and therefore cache hits. Surprisingly, I could not find a demo on the web, so I built one from scratch. Here are two applets demonstrating memory accesses during a matrix raise to the power of two operation.

Continue reading "A Tiling Demo"

2008.10.06

Suspend Windows from the Command Line

I used to leave my computer up all night, but I've come to realize that this is ecologically unsound. Now I suspend it before going to sleep, but this missed running a daily job that used to run at 03:00 am. The job marks my students' exercises and send me email with the next day's appointments. I thus decided to schedule the task to wakeup my computer at 3:00 am, run the job, and then suspend it again. The Windows scheduler allows you to specify a wakeup option, but not a subsequent suspend. Furthermore, it seems that Windows lacks a way to suspend from the command line (while maintaining the ability to hibernate), and the only free tools on the web are distributed in executable form, so I ended writing a small tool myself.

Continue reading "Suspend Windows from the Command Line"

2008.08.25

Saving the Editor's History

I recently spent a few days writing some tricky bit-twiddling code to implement a radix tree. I found myself making many programming mistakes, and I thought it would be interesting to study them, examine their contributing factors, and think how each of them could be prevented.

Continue reading "Saving the Editor's History"

2008.03.28

A Minute Minute Minder

Today I delivered the opening keynote address at the 4th Panhellenic Conference on Computer Science Education. For a number of reasons (more on that later) I wanted to keep track of my progress during the presentation. For this I put together a minute minder that displayed the time from the presentation's start and the slide I should be in. I could thus adjust my pace to finish as planned.

Continue reading "A Minute Minute Minder"

2007.02.04

How to Embed Citations in Diagrams

Diagrams in scientific publications occasionally link to other elements of the publication, such as bibliographic or section references. Maintaining consistency between the citations in the diagram and the publication can be tricky, but a small Perl script can automate this process.

Continue reading "How to Embed Citations in Diagrams"

2006.11.15

White Noise Calms Babies

A week ago I told my colleague Damianos Chatziantoniou that drying the body of a newborn baby with a hair drier keeps it consistently dry avoiding rashes, and also calms the baby down. Today he told me the advice worked wonders. Many parents have discovered that sources of white noise, like the sound of a vacuum cleaner or a hair drier, seem to calm down a baby's crying spell.

Continue reading "White Noise Calms Babies"

2004.08.11

Patching Framework III

Time warp. I needed to read some old files I wrote in 1992 using the Ashton-Tate Framework III program. Unfortunately, trying to run the program under Windows XP resulted in a "Divide overflow" error. A bit of searching on the web revealed that the problem was related to the system's speed (1.6GHz). Apparently, Framework tries to calculate the speed of the machine by dividing a fixed number with a loop counter; on modern machines this results in the overflow.

Continue reading "Patching Framework III"

2004.03.19

Binary File Similarity Checking

How can one determine whether two binary files (for example, executable images) are somehow similar? I started writing a program to perform this task. Such a program could be useful for determing whether a vendor had included GNU Public License (GPL) code in a propriatary product, violating the GPL license. After writing about 20 lines, I realized that I needed an accurate definition of similarity than the vague "the two files contain a number of identical subsequences" I had in mind.

Continue reading "Binary File Similarity Checking"


Creative Commons License Last update: Thursday, September 22, 2016 9:56 am
Unless otherwise expressly stated, all original material on this page created by Diomidis Spinellis is licensed under a Creative Commons Attribution-Share Alike 3.0 Greece License.