Sony PRS-300 Pocket eReader Review

Sony Pocket Reader PRS-300You may have noticed I haven’t posted in a while. One of the reasons is because I have been immersed in the world of digital books. In my previous post I mentioned that I purchased myself a new toy, namely the Sony PRS-300 Pocket eReader. Now I’ve had it almost 3 weeks so I feel I’m in a position to write a fairly accurate review and not one based solely on first impressions.

I’ll start with all the fluff that don’t relate to actually reading a book, then I’ll move on to what it is actually like to read.

I bought my Pocket Reader online from WHSmiths for a very reasonable £159. I had weighed up getting the more expensive PRS-600, but decided against it as I don’t need my book to play me music, and whilst it can hold 8000 books compared to “only” 350 of the PRS-300 I’ll be impressed if I read 350 books a year!


Two New Toys: First Impressions

Microsoft Natural Ergonomic 4000 KeyboardThis week I purchased myself two new toys. I always do something like this around this time of year because it’s my birthday! This year I decided to get an ergonomic keyboard and an e-reader.

The ergonomic keyboard was the easier decision and I went with the Microsoft Natural Ergonomic 4000.One of the main reasons for this was the Jeff Atwood blog post.

The e-reader was much harder to choose. After much deliberation, googling, reading of reviews etc I eventually landed myself a Sony Pocket Reader PRS-300. I chose this over other e-readers for a number of reasons. Firstly the price was right, I didn’t really want to spend over £200 on what is effectively a fancy book. Secondly I only wanted it for reading, I didn’t care about taking notes, listening to music that kind of stuff. Finally I wanted to to be portable – obviously all readers are portable, but I wanted something that I could easily keep in a coat pocket for when I’m on a bus etc. or generally waiting around for something to happen.

First Impressions

The keyboard was huge! Much more so then I expected, but fortunately I have a big desk, so there was no problem there. I’ve never used an ergonomic keyboard before and I was suprised how comfortable it felt. I really thought I’d be able to enjoy typing. However, the space bar is a nightmare. Really sticky, hard to press down and very “clacky” Others have experienced this problem, but most suggested it gets “broken in” within a few days or week, so I’m not overly worried (yet).

Sony Pocket Reader PRS-300The Sony e-reader is just beautiful. The text is clear, navigation simple, weight nothing to speak of and the size is perfect. I am in love with it. One problem was I said I had to use Windows to connect to it, so I fired up Vista for the first time in about half a year, and after about 20 minutes of installing it crashed. It did this again a couple of times, until I found out a fix – something so do with VB script and premissions. Rather stupidly I forgot to save the link  that helped me fix the problem otherwise I would have posted it here. Sorry about that. However, it turns out I can connect to it within Ubuntu, and transfer books onto it – so that is good news.

I’m going to write a more substantial review for both after a couple of weeks usage, so stay tuned – sign up to my RSS feed.

Emacs CSS-Mode Fix (adding to the chain!)

After my week with Emacs I’m still struggling along. One of my main annoyances is the default way some of the modes indent the code. I think the worst offender of this is the default CSS-mode. After frustration when, yet again, I hit the tab key and the cursor rockets about 80 places to the right I decided to Google for a fix.

The internet is great! Clearly it wasn’t just me having a problem, Guido Stevens was also suffering and posted a fix, which he himself found on another blog post by Chris Miller, which Chris in turn found on which had been found originally on a now dead post.

Not bad! Four people all having problems with the same thing and posting a fix for others to share. So I thought I’d join the chain, and write this blog post.

Oh yes, and the fix itself:

;; fix css mode
(require 'css-mode)
(setq cssm-indent-level 2)
(setq cssm-newline-before-closing-bracket t)
(setq cssm-indent-function #'cssm-c-style-indenter)
(setq cssm-mirror-mode t)

A week with Emacs: one week later

As promised in my last post, I have spent a whole week using Emacs.   Apart from the odd foray with Nano and Mousepad I  haven’t touched Eclipse or Netbeans or any other IDE and  managed to stick to Emacs for the full week.

How did it go?

To start off it was slow. Emacs has a notoriously high learning curve, and I pretty much started at the bottom. One of the reasons for doing this was so I could move away from the mouse and it turns out that the mouse is an extremely hard habit to break. So to are the keyboard arrow keys. I kept on finding my hands would instinctively  jump off the keyboard and try to double click on something, or try to navigate around the page with the arrows. This is clearly not the way it is done in Emacs!

The next thing I found is that Emacs doesn’t let you indent code files as you want. It seems to have a preferred method and forces it on you. This is very annoying and being a n00b I still haven’t found a way around this.

However, after a couple of days I began to get the hang of it. Still painfully slow, but navigating around the page, buffers and windows was becoming gradually quicker. I began to enjoy using Emacs, even though my right hand kept on unceremoniously lurching to the right from time to time.

By a complete coincidence, on Wednesday I was invited to C-Base here in Berlin for a beginners’ introduction to Emacs. Even though it was all in German, and my Deutsch ist nicht so gut I was blown away by not only the speed but also the huge amount of functionality within Emacs. To see someone who actually knew Emacs inside out was a revelation. I made a huge amount of notes (within Emacs before you ask!) ready to test out for myself. This insight into the “how the pros use Emacs” has really been an eye-opener and I am determined to learn just a fraction of what was on display at the tutorial.

Summing up my week with Emacs.

It was hard work, there was much and is even more left to learn. It is a vast landscape to negotiate, with many nooks and crannies. But once it is mastered I have no doubt that my productivity will be greatly increased.

Other people diving into Emacs

Some useful sites

A week with Emacs

EmacsI have been toying around with the idea of using Emacs for a few months now. Emacs isn’t exactly a stranger to me, as I’ve been using it on and off for years, but I’ve never really tried to fully know it properly. However, recently I have been in front of the computer so long I feel like my hands are going to fall off! Which is why I’ve decided to try to move away from this point and click mouse nonsense towards a more streamline keyboard only work environment.

So I have decided to give Emacs a go for a full week as my single development editor. Previously I’ve been using Eclipse PDT – which became so slow – and Netbeans – which I like a lot, but it is still point and click. One of my inspirations for this was a blog post by Bradley Wright. Poor Bradley’s experience must have been so horrifying that he hasn’t posted a follow up for his weeks usage, and this is from several months ago. Brad, if you can hear me, please let me know how it went, I am dying to know! But until then, I am going to try it out for myself.

Wish me luck, and if you have any tips for PHP development within Emacs, please drop a comment below and help me along.

See you in a week.

Update: My week is up – read how I did.

Getting a Windows Refund

I’ve just read quite an interesting article on the Linux Mint blog courtesy of Linux Today. It describes how Clem, a Linux Mint user, managed to get a refund on Windows that was pre-installed on a Dell laptop they purchased, and then donated the money to Linux Mint!

One of the comments tries to argue that Clem shouldn’t have been entitled to a refund as they knew what they were buying. I don’t hold with this argument as last time I tried to purchase any laptop that wasn’t a netbook I found it impossible to buy one without Windows pre-installed – and to make it worse they were pretty much all Vista!

With people like Clem engaging in this kind of action, and with Ubuntu trying to make Linux more accessible to the average user, hopefully one day I’ll be able to purchase a laptop and have a choice of what I put on it.

Upgraded WordPress

In my small and meandering steps to improve this blog I have now upgraded to the latest version of WordPress. I has been about a year since I installed this blog, so I thought it was about time – and also I felt increasingly guilty as the WordPress admin was screaming for me to upgrade. We’ll I’ve done it now, and hopefully everything is up and running and back to normal.

If you spot any oddities, please drop me a comment and let me know!

Thinking About Database Revision Control

In a current database driven project that has multiple developers the single biggest issue we have is version control for the database.

For us at ibrow, the number one practise that we engage in is Version Control/Revision Control. I personally use version control for almost everything and not using it when having multiple developers working on a project sends shivers down my spine.We currently use Subversion, however I’m thinking of moving over to Git, but there is also Bazaar and Mercurial plus many, many others.

Whilst there is this vast array of version control system for code, there doesn’t seem to be the focus on version control for database schemes. Jeff Atwood has a couple of posts espousing the virtues of version control for databases. There is Rail’s Migrations which seems to be the most advanced version control for databases to date and there is a project to make a PHP version of Migrations. However, Migrations still has it’s flaws, which are discussed in Adam Wiggins’s blog post about this very subject. Adam offers some good insights into the problem and has a brain storm about possible solutions. But I think I’m coming to the problem from a slightly different angle to him.

As most of our projects are in constant development we do not, as such, have versions, but instead revisions. This is a key difference here. If we check in a database change to the version control, we don’t yet know it’s revision, especially if we have multiple developers working on the same project and possibly changing the scheme of the database at the same time.

The ideal solution would use the following steps:

  1. Developer finishes their chunk of code with any database changes, and are ready to commit. The database changes include UP and DOWN changes.
  2. Developer commits their code changes, a revision number is assigned
  3. Based on this revision number, the database changes are committed.

Obviously the developer should update their working copy before committing, just to see if there are any conflicts and to make sure they have the latest copy of the code.

On the updating side, the following steps should occur when the developer updates their  code:

  1. The update process makes a note of their current revision number
  2. Downloads all code changes via the SVN update command
  3. Downloads all the database changes since their last revision
  4. Update process applies all database changes to developer’s local database

This process can be reversed for reverting or merging backwards.

Currently I can’t find anything out there that does this – which probably means one of 2 things:

  1. My Google-fu isn’t up to scratch
  2. It is actually a lot harder than I think!

I really need to get this right, as this is possibly the most important thing to get right for us at the moment. It would be great to hear any possible solutions or existing implementations out there.

Maybe this will be an interesting sub project for me over the next few weeks?

(And obviously I haven’t even considered trying to keep the data up to date – but I guess that will be for another day.)

VMWare Server: Connecting to Guest via SSH

I have recently been playing around with an old laptop and it’s give me the taste for delving deeper into the world of Linux. For this I normally use VirtualBox, but a friend of mine (who is an avid Mac fan) was recently raving about VMWare’s Fusion. I decided to see if they had anything similar for linux and give it a whirl. I toddled along to the VMWare site, couldn’t find anything, so Googled VMWare Server and went straight to the relevant page!

I downloaded, installed and connected to the VMWare Server admin via Firefox. All well and good. So now I wanted to actually use it. I decided to test it out using Debian as the Guest. I chose Debian simply because I know it, and I know it has a net install, meaning I could test out a minimum system.

I downloaded the ISO, and then set about creating my new Debian Guest. First problem, I couldn’t find the Debian ISO! After reading the docs (which always takes second place to proding and poking around) it turns out that you need to add a Data Store, using the Commands menu on the right hand side of the VMWare admin home.

Once I had sorted this out I then created the new Guest specifying NAT networking, attached the Debian ISO and started it up.I selected NAT networking because Host Only will not let me get access to the outside world from the guest – obviously a pain as I was using the Debian net install – and I have always found Bridge Networking to be as flaky as a delicious if not slightly dry Cadbury’s chocolate bar.

Hmm, VMWare is clearly very different to VirtualBox because it didnt open a window where I could see the new guest booting up. How do I communicate with the guest. Again, after some poking I found a tab for the Console, which at first asked me to install a Firefox plugin, but once that was installed I could see the Guest.

I then installed Debian and restarted the Guest server.

Once rebooting I then tried to install OpenSSH. Slight problem, I couldn’t get an outside line! I couldn’t even ping Google. Hmm. After some searching I found out that the problem was DHCP was not starting up. I ran the command (as root)

$ dhclient eth0

This allowed me to connect to the outside world, and to ensure it would always start up I followed the commands from this post within Debian Help:

Add the line

auto eth0

to /etc/network/interfaces

After this I managed to successfully install Open SSH server, by running the following command as root:

apt-get install openssh-server

So now it was already to I tried to connect via SSH from my Host Ubuntu system to my Guest Debian system. But how? Again, after some searching I found out that you had to forward some ports. On the host, edit /etc/vmware/vmnet8/nat/nat.conf. Uncomment the line under the SSH section that says:

# 8889 =

the restart the VMWare networking services:

sudo /usr/lib/vmware/ restart

You can see from the nat.conf file that you can also forward other ports such as Web and FTP

Finally, you can now connect to your Guest from your Host with the command:

ssh -p 8889 root@localhost

It took some effort, but I can now successfully connect to any number of Guests from my Host.

Installing PHP5.3 on Ubuntu Jaunty

Update: I have added a new tutorial for installing PHP5.3 on Ubuntu Karmic.

I have recently dusted off an old laptop to play around with and do some “fun” development. One of the things I have done to this laptop is to install a LAMP stack using PHP 5.3 so I can play around and see what’s new and exciting.

I had a quick Google on how to install PHP 5.3 on Ubuntu and found Brandon Savage’s post on the very subject! Whilst he has a great write up it was one or two of his comments mentioning the DotDeb.Org package repository.

This was a breeze to use and in about 5 minutes I have PHP 5.3 running with Apache and MySQL on my clean Jaunty system.

The first thing to do is add the repositories to your sources list:

$ sudo nano /etc/apt/sources.list
# php5.3
deb stable all
deb-src stable all

Now update and upgrade Ubuntu

$ sudo apt-get update
$ sudo apt-get upgrade

Now simply install apache mysql and php as usual

$ sudo aptitude install apache2 apache2-mpm-prefork mysql-client-5.1 mysql-server-5.1 php5 php5-cli php5-mysql libapache2-mod-php5

You will get a warning about untrusted packages being installed but this simply means that the PHP5.3 stuff is not signed, so I typed in “yes” and carried on. Obviously you can cater this line to your specific needs, but this is the basic stack up and running

When it was all complete I tested out my system:

$ php -v
PHP 5.3.0-0.dotdeb.8 with Suhosin-Patch 0.9.7 (cli) (built: Aug 12 2009 18:11:27)
Copyright (c) 1997-2009 The PHP Group
Zend Engine v2.3.0, Copyright (c) 1998-2009 Zend Technologies

and tested out my apache installation using a phpinfo() script:

$ sudo nano /var/www/info.php

then fired up http://localhost/info.php

and saw as the main header of the page:
PHP Version 5.3.0-0.dotdeb.8

All done. Simple!