[Google]

Control your Music player via bluetooth

I don’t need no steenking iphone with its fancy apps. I have a fairly low end phone, a Motorola RIZR Z3 but it can run Java J2ME apps. The other day I found an awesome one that lets me control my music player MPD via bluetooth, with a nice little GUI and everything (it also apparently works for XMMS and Winamp).

I was going to twitter about it, but it is so frickin awesome that it deserves more than 140 characters about it. The app is called JAM SE and it looks like it will run on just about any phone that supports J2ME and has bluetooth.

There is a Debian package for the computer-side which makes installing on Debian/Ubuntu a doddle. For others you can grab the program from its own site Bemused-MPD bridge.

With a little bit of extra work I can even get it to control the other music playing computers in the house (all running MPD), mpdproxy on the laptop with the bluetooth connection will redirect all MPD clients to my currently active server.

It is so cool to be able to control my music playback from anywhere in the house just by whipping out my phone, geektastic. :-)

My top 10 WordPress plugins

The following are a list of plugins I either use, have used or plan to use in the future to improve this blog.

In no particular order:

  1. Contact Form 7 – Just another contact form plugin. Simple but flexible. By Takayuki Miyoshi.

    Putting your email address on the web these days is just an invitation to be spammed to death, but it is nice for your readers to be able to contact you privately. This is a nice contact form for that purpose.

  2. Dean’s Code Highlighter – This plugin using Geshi to highlight source code in your posts. . By Dean Lee.

    If you ever put up source code snippets in your blog entries, it is far nicer to have the syntax highlighted as it is in a modern editor or IDE. This plugin provides that.

  3. del.icio.us for WordPress – Displays your recently listened links. Based on Pownce for WordPress by Cavemonkey50. By Ricardo González.

    Does exactly what it says on the tin.

  4. Google XML Sitemaps – This plugin will generate a sitemaps.org compatible sitemap of your WordPress blog which is supported by Ask.com, Google, MSN Search and YAHOO. By Arne Brachhold.

    Improve your search rankings by giving the search engines more information about your site, totally automatically.

  5. Sociable – Automatically add links on your posts, pages and RSS feed to your favorite social bookmarking sites. By Joost de Valk.

    Want to make it easy for readers to link your site into various social bookmarking sites. This plugin covers pretty much all of them, including some that no longer exist. :-)

  6. Twitter Tools – A complete integration between your WordPress blog and Twitter. Bring your tweets into your blog and pass your blog posts to Twitter. By Alex King.

    The plugin you need if you want twitter in your blog or vice-versa.

  7. WP Super Cache – Very fast caching plugin for WordPress. By Donncha O Caoimh.

    An essential plugin you need if your site is to have any hope of surviving a slashdotting, or even if you just want to improve performance for the ten people who visit your blog.

  8. Bad Behavior – Deny automated spambots access to your PHP-based Web site. By Michael Hampton.

    Prevent 90% of the spambots out there from even attempting to post comment spam.

  9. OpenID – Allows the use of OpenID for account registration, authentication, and commenting. Also includes an OpenID provider which can turn WordPress author URLs into OpenIDs. By DiSo Development Team.

    OpenID is what I hope will become the standard for online authentication, every site should support it.

  10. Who Sees Ads – An advanced ad management plugin that lets you decide who will see your ads, depending on user defined conditions. By Ozh.

    Want to place ads on your site but don’t want to bother your regulars (who will likely never click on them anyway), then give this plugin a try and set it to only show ads to visitors who came to your site from a search engine.

Hope these are useful. If you use some wonderful plugin I haven’t mentioned then please tell me. Adding more and more plugins until something breaks is what I do. :-)

Poor mans offsite backup

Before I got some proper offsite backup space* I used to make tarballs of files and dump them in my gmail. Not the most elegant solution but it worked and is free (I know about gmailfs, but I could never get it to work reliably).

This is the script I used to send the files:

#!/usr/bin/env python
import getpass
import optparse
import smtplib
import sys

from email import Encoders
from email.MIMEBase import MIMEBase
from email.MIMEMultipart import MIMEMultipart

opts = optparse.OptionParser()
opts.add_option(‘-u’, ‘–username’)
opts.add_option(‘-p’, ‘–password’)
(options, args) = opts.parse_args()
if len(args) < 1:
    print "Usage: send_file_to_gmail.py [-u user] [-p pass] filename"
    sys.exit(0)

if options.username == None:
    options.username = raw_input("Username: ")
if options.password == None:
    options.password = getpass.getpass()
if options.username[len(options.username)-10:] != "@gmail.com":
    options.username += "@gmail.com"

msg = MIMEMultipart()
msg[‘Subject’] = "Backup of %s" % args[0]
msg[‘From’] = options.username
msg[‘To’] = options.username

msg.preamble = "Backup of %s" % args[0]
msg.epilogue = " "

fp = open(args[0], "rb")
atfile = MIMEBase("application", "octet-stream")
atfile.set_payload(fp.read())
fp.close()
Encoders.encode_base64(atfile)
atfile.add_header("Content-Disposition", "attachment", filename=args[0])
msg.attach(atfile)

s = smtplib.SMTP()
#s.connect("localhost", "8025")
s.connect("smtp.gmail.com")
s.ehlo()
s.starttls()
s.ehlo()
s.login(options.username, options.password)
print "Sending %s" % args[0]
s.sendmail(options.username, options.username, msg.as_string())
s.close()
 

The above code is made available under the MIT license.

* While I am writing this the Dreamhost backup space I use has been down for about two weeks (it came back briefly a couple of days ago but is back down again now). I can’t complain too much as it is a free extra they throw in with the hosting package but I may have to restart my gmail sending if this keeps up.

Virgin Media are petty scumbags

For a few days now I’ve been working (a few minutes at a time) on writing a post about how to monitor your bandwidth usage using munin by directly querying your cable-modem. Today however, when I checked my nice munin graph I found it had stopped working at about 8AM. Some further diagnostic procedures revealed that the cable modem was no longer responding to SNMP requests.

After a bit of googling I discovered the reason for this is that my ISP, Virgin Media, have deliberately disabled SNMP access. Reports vary on the reasons for this, some claim “performance” others “security”, but both are utterly bogus reasons. All this does is deny customers basic information about their connection like bandwidth usage, and I can only conclude that Virgin Media want to make it more difficult for people to dispute their figures.

This isn’t enough to make me ditch VM, but it has pissed me off, and the next time I move house VM are going to be waaay down the list of providers I’ll look at.

PS. My router doesn’t support SNMP either so I can’t use that.

Who-T: Synaptics 1.1 and what your touchpad can do now

The synaptics driver. So, here’s a list of things that have changed recently with version 1.0 and 1.1.

Perhaps the most important changes have to to with auto-scaling. Synaptics obtains the touchpad dimensions from the kernel and adjusts speed, acceleration, the edges and more depending on these dimensions.

via Who-T: Synaptics 1.1 and what your touchpad can do now.