Archives for February 2007

Bluetooth and Computer Locking

Occasionally, I’ll think of something so good I have to rush and implement it on the spot. Last week I had one of those moments; Martin had mentioned to me that he’d bought a Wireless PC Lock, which is a little thing you plug into the USB port, and which locks your computer when you walk away with its ‘key’ transmitter.

Being quite cheap, and not wanting to wait for any sort of delivery, it occurred to me that the same thing could be achived with Bluetooth; as long as a device was broadcasting its presence, you could detect when it came into bluetooth range and went out of it again. Having a nice bluetooth dongle, I installed python-bluez, and set to work.

Shortly afterwards, I had a nice scanning script that continuosly probed the local area, matched the resulting MAC addresses to an internal list, and then ran lock and unlock scripts. A few minutes more, and I tied in amaroK, Kopete, the screensaver, and even DPMS (display power management).

Now, I can walk out of my room, and a few seconds later the computer will lock itself, turn off the screen, pause any music and set my IM status to Away. Walk back in, and the computer unlocks, I get set to Available, and the display turns back on.

It’s like living in the future - the feeling of walking into a room and having the computer recognise your presence is wonderful.

There are, of course, a few problems. This only works, currently, with devices that broadcast their presence. For me, this is fine, since my n800 will happily sit in “visible” mode. Many phones, however, only support this for finite periods of time, and in general some people don’t like to have it on.

I’m looking into some sort of solution involving pairing; in the meantime, you can find an initial copy of the script here.

27 February 2007 | General, Python | 6 Comments

Thumbnails

I’ve literally just finished implementing thumbnail support in ByteHoard/e. Unlike previous versions, they’re not generated on the fly, but rather whenever the file changes - the same goes for all the file metadata ByteHoard uses, like mimetypes (which now work, too) and file sizes.

Thumbnails and Icons

As a supplement to the thumbnails, two other features have appeared. Firstly, files now have relevant icons and type descriptions, and secondly, the administrator interface has a button to entirely rescan all the files a user owns, for those cases where you’ve managed to confuse ByteHoard.

I’ve also closed a few bugs, including quota usage not changing when you delete directories, and not being able to remove administrator abilities from users.

9 February 2007 | ByteHoard | 8 Comments

The Aftermath

Well, the ByteHoard/e first alpha seems to have gone quite well. There were, as I expected, a few bugs - thanks to the people who found them, and I encourage anyone who finds anything slightly off to go and make full use of the new bugtracker at bugs.bytehoard.org.

I’m now working on the second alpha, and I’ll be releasing it… when it’s ready. Expect filemail, registration, thumbnails, search, and more in this new release.

8 February 2007 | ByteHoard | No Comments