mcwalter.org and mcwalter.net : The homepage of Finlay McWalter.
Or you can create our own barcode, and maybe mess around with it. The Parkrun runner barcode is just the runner's unique ID number, encoded as a Code 128 (code set B) barcode - as far as I know the format is a single letter and 6 or 7 digits. There's plenty of software that can print barcodes - for example, you can use GNU barcode to generate one:
barcode -b A9876007 -e128b -o barcode.ps
Just for fun, you can write your name on top of the barcode - as long as you leave enough space unmolested for the barcode reader to scan. This script uses Imagemagick to do that:
#!/bin/bash
barcode -b A9876007 -e 128b | \
convert -density 300 \
- \
-flatten \
-crop 630x360+0+2920 \
-font Ubuntu-Bold \
-fill DarkRed \
-stroke white \
-strokewidth 4 \
-pointsize 21 \
-annotate +14+3010 'Parkrun Paul' \
\
out.png
which produces a barcode like this
You can print that out (on an A4 printer), to the same scale as the official Parkrun barcodes generated by their website, with this command:
lpr -o scaling=14 out.png
One needs to wrap PyCrypto's own HMAC with a little function that handles the password and salt given by PBKDF2 and which emits the digest of the resulting hash. This example illustrates using the basic hash functions available from PyCrypto itself (several of which aren't suitable for practical use, and are just included here as examples):
#!/usr/bin/python3
from binascii import hexlify
import Crypto.Protocol.KDF as KDF
from Crypto.Hash import HMAC, SHA, SHA224, SHA256, SHA384, SHA512, MD2, MD4, MD5
import Crypto.Random
password = "A long!! pa66word with LOTs of _entropy_?"
for h in [SHA, SHA224, SHA256, SHA384, SHA512, MD2, MD4, MD5]:
hashed_salted_password = KDF.PBKDF2(password,
Crypto.Random.new().read(32), # salt
count=6000,
dkLen=32,
prf=lambda password, salt: HMAC.new(password, salt, h).digest())
print ("{:20s}: {:s}".format(h.__name__,
hexlify(hashed_salted_password).decode('ascii')))
In a speech on TV in 1993, three years before A Game of Thrones (the series' first book) was published, Yeltin said "You can build a throne with bayonets, but it's difficult to sit on it" (reference). The normally pretty thorough TV tropes doesn't have like it that predates either (trope: Throne made of X) - obviously both Yeltin's and Martin's thrones owe a lot to the Sword of Damocles.
To Martin, of course, it's a fun fantasy in a magical land of boobies and dragons. To Yeltsin thrones were no abstract plaything - for him, as for Henry VI, uneasy lies the head that wears a crown. Perhaps uneasy sits the bum underneath it too.
A lot of the driving you do in your car is ancillary to owning a car, rather than being to service the things you want. If the car can drive itself around, some of that goes away. And there's some routine stuff it can do too. Consider these possibilities:
This last part is maybe the best part. Why does your office, or your apartment building, even have parking next to it? With self-driving cars, it doesn't need to - it can contract parking from some parking lot blocks, even miles away. And valet parking (which is what happens when all the cars in the lot are self-driving, and are controlled by the lot's valet manage system) can manage where every car is kept. With cars parked millimetres apart (no need to open the doors) bumper to bumper, it can manage double or triple the density of a normal lot. You tell it when when you'll need it, and the system can make sure the car is shuffled around when it's time. If you have a genuine emergency (which means you can't wait five minutes for an emergency shuffle to occur) the lot will send a taxi.
With self-driving cars, particularly electric ones, the future may spell bad news for parking attendants, taxi drivers, and filling station cashiers.
Adapted from my reddit post of yesterday.
Pono promises high quality, high definition digital portable music. CD-DA isn't a perfect format, and munged through mp3 codecs it's a bit worse, with data compression, loudness, range compression, and simply there (usually) being only two channels. In an ideal listening environment, with decent speakers and a quiet room, this might possibly matter. But in a portable environment it just doesn't.
The track record of better-than-CD-quality digital audio isn't a good one anyway. HDCD, SACD, and DVD-A never made much of a dent. In part people just don't care enough (perhaps they're ignorant of the wonders they're missing, perhaps not), and in part copyright holders are reluctant to put such a high-quality stream in their customers' hands (knowing how readily media DRM schemes have been cracked). Perhaps it's time for another crack at getting a high quality digital music standard off the ground. Perhaps iTunes and SoundCloud and Facebook have altered the music marketplace enough that there's room to market better product right to the consumer. A coalition of musicians, technologists, and business people maybe can establish a new format, one that can be adopted across a range of digital devices and can displace mp3 (which is, I'll happily admit, rather long in the tooth).
But portable media is a dumb space in which to do it. And building your own media player is dumberer. People listen to portable players when they're in entirely sub-optimal listening environments. They're on the train, in the back of the car, they're in the gym or they're walking or their running down the road. There's traffic noise, wind and rain, other people's noises, and the hundred squeaks and groans of the city. And they're listening on earbuds or running headphones or flimsy Beats headphones. The human auditory system is great at picking out one sound source from the miasma, but it can only do so for comprehension not for quality too. High quality audio in all these enviroments is wasted - it's lost in the noise.
When I started running, I had a hand-me-down Diamond Rio PMP300. It came with only 32MB of internal storage - that's barely enough for a single album encoded at a modest compression level. So I broke out Sound eXchange and reduced my music to the poorest quality I could manage, and eventually reduced it to mono too. With that done, I could get a half-dozen or so albums on the player, enough that I could get enough variety that each run didn't just follow the same soundtrack. With skinny running headphones, the wind and the rain, the traffic noise, and the sound of my own puffing and panting, it just didn't matter that the technical qualities of the sound were poor. And now, a decade later, when I have a decent phone that plays high quality mp3s, it doesn't really sound any different in practice.
So even if people buy Ponos, even if media executives decide to sell them high-definition digitial audio, if they pay (again) for all the music, in the environments most people will be using their Pono, the difference will be, in practice, inaudible.
For each entry I show the time (into the UK DVD edition of the film, in minutes:seconds), the line of dialog roughly about that time, a description of the streets shown, and a Google Maps link (you might need to rotate the camera in a few of them):
The photo archive contains a number of photos of landscapes, buildings, nature, and animals with silly expressions on their faces. There's also some high-resolution digital pictures of various natural and artificial textures, which may be of use for texture mapping applications.
New: I've added some of my favourite closeup photographs, prepared in nice large sizes, to the new backgrounds section.
The source for a tiny java web server (HTTPd), together with some commentary, is available under the GNU General Public Licence (GPL). With some help from various people I've gotten this down to just over 15 lines of (horribly unreadable) java code. Can you make it any smaller?
Are you tired (or embarrassed) of that uncomfortable delay between launching a large java application and it actually appearing? Help overcome your feelings of inadequacy by wrapping your application in this handy java application splashscreen application, which can show a logo or other graphic while the main application loads.
This page also contains a few weird tricks you can do in the java programming language (but shouldn't).
A discussion of optimisation, in the context of a simple java text processing program is presented in the the java hexdump page. Surprisingly, this shows we can write text processing programs (which are generally IO bound) as fast as decent C language programs.
I've made some notes on webdesign, including:
As almost any user of UNIX and its workalike environments knows, there's really no point in writing your own utilities - as soon as you're finished you'll find someone already wrote a better, simpler, faster solution to the same problem, probably in about 1970. Here are some UNIX shell programming gems that I discovered, shortly after writing my own versions.
Like its ID Software predecessors, Activision's game Return to Castle Wolfenstein contains a number of secret areas, cunningly positioned throughout the game to divert the player's attention from how interminably dull and criminally derivative this rather average game is.
Tim Schaefer's Day of the Tentacle is one of the best computer games of the lost "second age". It worked (with an unpleasant amount of that nasty config.sys
wrangling) under DOS and older versions of Windows but it really doesn't work properly under
Windows XP. One might think Lucasarts might have released a DirectX version for windows, but perhaps moths have eaten the tape their only copy of the sourcecode is on (or something like that).
This site contains some mystical instructions for playing DoTT on Windows XP and (I think) on Windows 2000. Kindly multi-lingual readers have produced translations of this page into norsk, and nederlands. If you'd like to contribute a translation, even into something mad like Klingon, then I'd be happy to host it.
Although it's not very hard, and it's impossible to get it "wrong", some folks have asked me for a walkthrough of DoTT. As it rather spoils the game, I'd strongly recommend you read it only if you're really really stuck.
For your convenience, there are also the answers to some DoTT frequently asked questions.