ArchivePage 2 of 52

Wordpress, k2, openid

I use the k2 theme for this wordpress blog. I used to write my own, but k2 is much, much neater. I also use the openid plugin for wordpress. (I wrote about openid’s before)

To get the two to play together, you need to turn off live commenting.

In my case, as my blog is also my openid url (see this tutorial in delegating your open id if you want to use your blog or website as your openid url, and any provider), I had to add some code the the k2 style’s functions.php

add_action('wp_head', 'custom_header');

function custom_header () {
        ?>
        <link rel="openid.server" href="...openid provider url..."/>
        <link rel="openid.delegate" href="...openid provider url..."/>
        <?php
}

Now you have your own blog as your openid url, and your blog accepts openid’s for comments with the k2 theme :)

The Decisive Photograper - Bert Stephani

Bert Stephani (Confessions of a Photographer) has done two very interesting posts as part of a workshop he ran titled “The Decisive Photograper” - Live Shoot Outdoor and Live Shoot Indoor make for fantastic reading if you want to know more about balancing a portable flash with natural light for that perfect portrait.

I have bee following Bert’s blog for a while now, and it really is fantastic - I strongly recommend reading through his archive, particularly for the videos he’s done during shoots.

Petition to reduce fuel duty

I suppose it was only a matter of time given the current prices of petrol in the UK
Petition to: Reduce Fuel duty to bring fuel prices back to an acceptable level
[petition.pm.gov]

PIC Microchip programming under debian

A while ago I bought a PICkit2 programmer, including 16f690 PIC. I installed piklab and sdcc (in Debian repositories) and got it working pretty easily. I did play with the programmer that came with it (mplab, windows only), which upgraded my firmware. piklab cannot use the new firmware, so if you need to get an old firmware, then try the old firmware downloads page

There is quite a difference in programming between mplab and piklab. Although there is support for a large number of chips in piklab, they are not supported as well as mplab. The big problem is that in mplab most special bits (i.e. each bit for an output port, one per pin) have a defined name so you can set them on or off individually. Piklab on the other hand has support for only a few of these, so if you want to turn on a pin, you have to set a value on the whole port (byte). Saying that, I prefer the piklab editor as it seems to do a better job with syntax highlighting etc.

Below is some code examples to help you get started if you are finding the learning curve steep

Continue reading ‘PIC Microchip programming under debian’

iPod Classic with Amarok on Linux

When I first bought my iPod classic, Amarok hadn’t yet got support for the new SHA1 hashing that was being done in the song db. Then it was only in cvs, and while I remember compiling from source I don’t think I ever got round to running that code.

Of course I found out the hard way that Amarok didn’t have support for my iPod, and nearly bricked the thing. Thankfully a windows box and iTunes could reset it.

I now have it working, however it took a little fiddling. If you are trying to get it working, you absolutely must read http://amarok.kde.org/wiki/Media_Device:IPod before starting, especially #My_iPod_does_not_show_any_music, as this explains how to set up the magic ID number. Unfortunately earlier pages didn’t say whether to add the 0x in from of the ID, and I remember having lots of difficulty just with libgpod and gtkpod. While I am mentioning it, the versions you need for an iPod Classic are: Amarok 1.4.8 and libgpod 0.6.0

So you have them installed, and you want to get Amarok managing your iPod - Well, I plugged it in, amarok detected it popped up a window asking if it should mount it as an iPod. I said yes, copied some songs, ejected it and BANG! - My iPod wouldnt show any songs.

It seems that the data uploaded by iTunes isn’t the same as by Amarok, and the iPod doesnt like that. Deleting the contents of the iPod_Control folder from the iPod seemed to make Amarok and the iPod happy. Of course Amarok needed to recreate some folder structure, but it asked nicely. Also, if you do this, don’t forget you have to recreate your SysInfo file again before Amarok uploads any songs.

Anyway, I now have an iPod that I can upload to with Linux (which is a hell of a lot faster than iTunes - iTunes took about 30 hours to copy ~30G of music, Amarok took about 3 hours), podcasts work and even some cover art has been copied.

If you have any problems, you can reboot the iPod by holding the Menu and select button down together for a few seconds. If the songs list comes up blank, then you have something wrong and Amarok didnt write the hash correctlty - check the SysInfo file, delete all music from the iPod in Amarok, and copy a few test tracks, disconnect and check if you have it right.

You can also use the Smart Playlists to sync to the iPod - Favourite tracks, Newest tracks and All Collection are good ones to use. Of course you can create your own custom smart playlists too.

Best of all, Amarok is properly multi-threaded so I can copy my entire music collection to my iPod, while playing music and Amarok and writing blog posts - on windows syncing an iPod used to make the system struggle, and iTunes became rather unresponsive…

Mottisfont Abbey

A few weeks ago, when the weather was excellent, I went to Mottisfont Abbey trying to make the most of my National Trust membership. In case you want to go, the following point on the map is a little more accurate than on the national trust page (the rough coordinates from my gps module)

Unsurprisingly, I took a camera - This is what happened

img_14556

img_14533 img_14597 img_14507 img_14476 img_14480

img_14464

crw_10217

The rest of the photos are in the set Mottisfont Abbey on flickr