Review of the second Milton Keynes Geek Night (#MKGN)

This content is 12 years old. I don't routinely update old blog posts as they are only intended to represent a view at a particular point in time. Please be warned that the information here may be out of date.

A few months ago, I wrote about the first Milton Keynes Geek Night and, last night saw my return to a converted bus station (now a community arts centre) in the centre of Milton Keynes to join around 200 geeks from the creative industries to talk about design, technology, and other such “stuff”.

Once again, Richard Wiggins (@RichardWiggins) and David Hughes (@DavidHughes) did a fantastic job of recruiting speakers and sponsors (free geek events still need someone to pay for drinks, pizza, and the venue) and I really think that the mixture of short (20 minute) and lightning (5 minute) talks, with some “one minute wonders” (for sponsors, recruitment opportunities and community activities) works well. Every three months seems like a good interval between geek nights too.

The speaker line-up obviously changed somewhere along the way as the content strategy talk from Relly Annett-Baker (@RellyAB) that was mentioned previously didn’t happen and changes were still happening on the night as Microsoft’s Martin Beeby (@thebeebs) had to leave early for personal reasons – maybe we’ll get his four-minute-fifty-eight-second slot on Windows 8 development at another geek night? There were, however, some great talks and I’ll try to give a quick summary here.

Patterns generate relationships between people and things

First up, Cole Henry (@cole007) spoke about patterns generating relationships between people and things.  I wondered where he was going with his discussion of a previous career as an archaeologist looking at patterns on pottery but he described four fundamental elements about the process of craftsmanship:

  1. A craftsman is a conduit through which products are made but they may not have a preconceived idea of what they are creating. Their craft is a marriage of tools, medium and meaning.
  2. Craft is transformative – it takes something and makes it something else – instilling meaning and imparting the craftsman’s personality into creating a product.
  3. Craftsmanship is inherently social – it exists for people.
  4. Crafting binds people and things.

Fast forward to today and we can see that web design has progressed enormously from the work of 1997 with table based layouts to transform text sites into something more visual. Today’s websites use CSS for a presentation layer and JavaScript for rich Internet applications. They also need to work on a variety of devices and form factors. Yet, Cole says, the process (design, visualise, get signoff and bill for the first milestone, hand over to developers to create) has not moved on – it’s the same as the process used for early website designs (often by former graphic designers) – and these increasingly rich designs don’t necessarily work in all contexts. Web design is still concerned with visual products rather than the process of creation – the “cult of the aesthetic” – and Cole suggests that designers need to learn from the craftsmen of the past:

  1. The designer is a conduit to marry tools and funnel them – they need to understand which HTML elements work well, what happens when you hover over a button or submit a form, etc.
  2. Because design is transformative – designers need to consider meaning, not just visuals.
  3. Design is social – the web involves people.
  4. Design is binding – the whole function is to bring together people and materials.

Five minute lightning talks

The lightning talks are designed as “tasters”, or for people will less experience (or confidence) as speakers and Rachel Shillcock (@MissRachilli) spoke about understanding what makes us special – how to overcome a lack of confidence and to aim high (something that was echoed in a later talk) – summed up with a quote [which may or may not be from Michelangelo]

“The greatest danger for most of us is not that our aim is too high and we miss it, but that it is too low and we reach it.”

Food for thought? Aim high, push yourself and work to your limits, says Rachel – and remember that failure can be a learning experience.

Penetration tester Nick Draze (@SonOfSunTzu) gave 10 pieces of advice from his 12 years in information security – and it was an interesting talk, even if it also stretched the boundaries of a 5 minute lightning talk (10 minutes!), without really giving much away. I think I’ll hold the details on this one back to include in another post but if ever I needed convincing that security guys are paranoid, this was the talk to do it. Nick asked (and I think the audience respected his request) not to be photographed, claiming that there are only three pictures of him in existence on the web… I’d like to know how he avoids CCTV, random street shots (from photographers or even just passers by using their mobile phone to take a picture of something else) but that misses the point somewhat – we all need to take care what happens in our digital lives in order to protect our information, and our identities.

Next up, Emily Heath (@gradualist) talked about bringing site maps to life, visualising web site structures to: test information architecture; audit competitor websites; and to provide a deliverable to impress clients who can’t see the full picture and experience of working through a site. It’s an interesting idea – one that I’ve tried from another angle (an architecture-led approach to re-designing a system that I work with), but I’ve also been accused of it being too technical… I guess it all comes down to understanding your audience!

One minute wonders

I didn’t note the details of all the one minute talks (except that the event was sponsored by Oxford Computer Group and All Your Base) but I did take the Opportunity to plug Peter Onion (@PeterOnion)’s work setting up Milton Keynes Raspberry Jams. The next jam (on 30 September) is full and operating a wait list but there is an online forum for local Raspberry Pi enthusiasts – that’s a good place to watch for details of upcoming events (and to get in early for tickets next time around).

Departing the Comfort Zone

The final keynote was from Ben Bodien (@bbodien) who gave an inspirational talk on stretching our boundaries to get out of our individual “comfort zone” – something I’d been discussing only a few hours earlier with my wife (is that serendipity?)!

If you ask someone who they are, after giving their name, they will typically respond with something built around a job title. Ben suggests that people like to organise and classify things – to put things into virtual boxes and label them – but that we are also doing ourselves a massive disservice by simply defining ourselves based on a job role.

The “nine dots” puzzle is the origin of the term to “think outside the box”, joining nine dots in a 3×3 grid with four straight lines, by moving outside the constraints of the (perceived) box that the dots form.  We define ourselves by the things around us – daily tasks, routines, etc. – but reality is more complex.

We also fall into habits and cycles – taking on a new project, which is exciting, until it’s not. Typically, we persist with the project until we are able to “kick it out of the door” and the cycle starts all over with a new (exciting!) project. We blame clients, or the projects but really we’re stuck in a pattern.

The key to breaking this cycle is to never stop learning – multiple projects lead to stress but we tend not to get bored – so avoid working on the same things over and over. If we do the same things, we’ll find ourselves inside our comfort zone but we’ll also become stagnant and won’t develop or grow. Instead, we can branch out and shift our focus – to work outside our comfort zone to have more influences, push our craft forward, unblock hidden talents and diversify.

Recognition is the first step to solving the problem and departing the comfort zone – after which Ben suggests:

  1. Start saying “yes” to the scary things…
  2. Set weekly goals (you might try other timeframes, like fortnightly – but a month may be too long) with things that are new to you and you want to try out. They might be work related, or they might not. Write the goals down and stick them close to your workplace so they are in peripheral vision. Writing it down lodges it in one’s memory. Sticking it nearby makes it harder to forget…
  3. Embrace experiments “not working out” – sometimes new things just don’t work. Learn from this (may be they were not interesting to you, or not part of your skill set) and use the experience to guide the path to the next experiment. And talk to people about how things work out.
  4. Benchmark realistically. It’s easy to follow people on the web who are producing outstanding work. The chances are that they have been following their craft for years (In his book, Outliers, Malcolm Gladwell suggested it takes 10,000 hours to become expert in something [others dispute the meaning of this quote]) – so figure out how you’re doing based on where you are coming from – and look back at your own journey. Set your goals high so that, even if you miss, you are still doing well. In another anecdote, Ben spoke of Ira Glass’  storytelling videos and how part 3 talks about “good taste”, pushing across a “desert” before you produce work that you feel proud of. Do the best you can, get feedback, set deadlines, and you will eventually get to other side and produce work that you can be proud of.
  5. Note your accomplishments – and use that to redefine yourself.

And the next time someone asks “who are you?” you can tell them, and it’s won’t just be framed around a job title!

When’s the next MKGN?

The next geek night is scheduled for 6 December – watch out for details on the Milton Keynes Geek Night website, or on Twitter @MKGeekNight.

Reducing website errors with HTTP 301 redirects

This content is 12 years old. I don't routinely update old blog posts as they are only intended to represent a view at a particular point in time. Please be warned that the information here may be out of date.

A couple of weeks ago, I wrote about a WordPress plugin called Redirection. I mentioned that I’ve been using this to highlight HTTP 404 errors on my site but I’ve also been using the crawl errors logged by Google’s Webmaster Tools to track down a number of issues resulting from the various changes that have been made to the site over the  years, then creating HTTP 301 redirects to patch them.

Redirections as a result of other people’s mistakes

One thing that struck me was how other people’s content can affect my site – for example, many forums seem to abbreviate long URLs with … in the middle. That’s fine until the HTML anchor gets lost (e.g. in a cut/paste operation) and so I was seeing 404 errors from incomplete URLs like http://www.markwilson.co.uk/blog/2008/12/netboo…-file-systems.htm. These were relatively easy for me to track down and create a redirect to the correct target.

Unfortunately, there is still one inbound link that includes an errant apostrophe that I’ve not been able to trap – even using %27 in the redirect rule seems to fail. I guess that one will just have to remain.

Locating Post IDs

Some 404s needed a little more detective work – for example http://www.markwilson.co.uk/blog/2012/05/3899.htm is a post where I forgot to add a title before publishing and, even though I updated the WordPress slug afterwards, someone is linking to the old URL.  I used PHPMyAdmin to search for post ID 3899 in the wp_content table of the database, from which I could identify the post and  create a redirect.

Pattern matching with regular expressions

Many of the 404s were being generated based on old URL structures from either the Blogger version of this site (which I left behind several years ago) or changes in the WordPress configuration (mostly after last year’s website crash). For these I needed to do some pattern matching, which meant an encounter with regular expressions, which I find immensely powerful, fascinating and intimidating all at once.

Many of my tags were invalid as, at some point I obviously changed the tags from /blog/tags/tagname to /blog/tag/tagname but I also had a hierarchy of tags in the past (possibly when I was still mis-using categories) which was creating some invalid URLs (like http://www.markwilson.co.uk/blog/tag/apple/ipad).  The hierachy had to be dealt with on a case by case basis, but the RegEx for dealing with the change in URL for the tags was fairly simple:

  • Source RegEx: (\/tags\/)
  • Target RegEx: (\/tag\/)

Using the Rubular Ruby RegEx Editor (thanks to Kristian Brimble for the suggestion – there were other tools suggested but this was one I could actually understand), I was able to test the RegEx on an example URL and, once I was happy with it, that was another redirection created.  Similarly, I redirected (\/category\/) to (\/topic\/).

I also created a redirection for legacy .html extensions, rewriting them to .htm:

  • Source RegEx: (.*).html
  • Target  RegEx: $1.htm

Unfortunately, my use of a “greedy” wildcard meant this also sustituted html in the middle of a URL (e.g. http://www.markwilson.co.uk/blog/2008/09/creating-html-signatures-in-apple-mail.htm became http://www.markwilson.co.uk/blog/2008/09/creating-.htm-signatures-in-apple-mail.htm) , so I edited the source RegEx to (.*).html$.

More complex regular expressions

The trickiest pattern I needed to match was for archive pages using the old Blogger structure.  For this, I needed some help, so I reached out to Twitter:

Any RegEx gurus out there who fancy a challenge, please can you help me convert /blog/archive/yyyy_mm_01_archive.htm to /blog/yyyy/mm ?
@markwilsonit
Mark Wilson

and was very grateful to receive some responses, including one from Dan Delaney that let me to create this rule:

Source RegEx: /blog\/([a-zA-Z\/]+)([\d]+)(\D)(\d+)(\w.+)
Target RegEx: /blog/$2/$4/

Dan’s example helped me to understand a bit more about how match groups are used, taking the second and fourth matches here to use in the target, but I later found a tutorial that might help (most RegEx tuturials are quite difficult to follow but this one is very well illustrated).

A never-ending task

It’s an ongoing task – the presensce of failing inbound links due to incorrect URLs means that I’ll have to keep an eye on Google’s crawl errors but, over time, I should see the number of 404s drop on my site. That in itself won’t improve my search placement but it will help to signpost users who would otherwise have been turned away – and every little bit of traffic helps.

Redirection – an essential plug-in for WordPress users

This content is 12 years old. I don't routinely update old blog posts as they are only intended to represent a view at a particular point in time. Please be warned that the information here may be out of date.

Last year, a combination of a loss of service from my hosting provider and my appalling backups meant that this website was temporarily wiped off the face of the Internet. It’s never recovered – at least not in terms of revenue – and it taught me an important lesson about backups (it’s all too easy to forget the hours of effort that go into a “hobby” site like this one…).

Whilst the blog posts were restored, and I took the opportunity to apply a new theme to the site (it’s probably due another one now…) but some of the images had got AWOL along the way. I’ve been ignoring that (mostly) but decided I really should do something about it when an old post was picked up by a journalist today and I realised it had a missing graphic.

I remembered a WordPress plugin that I used on another site recently, for managing redirects when access to the .htaccess file is not available. The plug-in, written by John Godley, is called Redirection, and one of its modules will report on HTTP 404 errors, like the ones that my missing graphics will create. I know there are other tools that can do this for me (Google’s Webmaster Tools, for example, or trawling through the web logs) but it’s an easy way to see when a 404 has been returned in order to investigate accordingly.  So far this afternoon, I’ve tracked down and replaced around 8 missing graphics and one broken permalink using the logs from Redirection.  I’m now scanning through the rest of John’s plugins to see what else I’m missing and will certainly be donating later…

Three trips to London just to get one image right: I hope it was worth it!

This content is 12 years old. I don't routinely update old blog posts as they are only intended to represent a view at a particular point in time. Please be warned that the information here may be out of date.

Unless they’ve been living under a rock, it would have been difficult for anyone in the UK to miss the fact that the Olympic Games took place in London recently and that Team GB and Northern Ireland (Team UK surely?) did rather well.  In true British style, many of us (myself included) were deeply cynical about many of the decisions made by the Olympic organisers (I still think that the ticketing was a mess, and that sponsors got a little too much brand exclusivity for their money) but, as the medals came flowing in, our positions softened and the nation came together as one in a way that I honestly don’t think I’ve seen before.  Strangers spoke to one another in the streets (where I live in rural Buckinghamshire that’s normal – at least on weekdays when the commuters are at work – but not in London) and the universal common denominator of comment was no longer the British weather but the success of Bradley Wiggins, Jessica Ennis, Katherine Grainger or one of the many other athletes who have become household names this summer.

Less broadly publicised (although the Mayor of London Presents website is a good resource) were some of the surrounding events taking place in London during the Olympic (and Paralympic) Games and it was purely by chance that I attended a London Bloggers Meetup for a photo walk along the Thames taking in the light shows on many of London’s landmarks.  Actually, I didn’t really manage to attend – I started out with the group but, because I’m a photographer first and blogger second, I fell behind, missed the boat and ended up on my own photo walk (I still got a set of photos that I was pretty pleased with). Except for one of them, showing the Union Flag projected on the side of the Houses of Parliament, which looked OK in camera but was pretty awful when I got it loaded into Lightroom.

I know a bad workman blames his tools but that image is really fuzzy on one side – spoiled by my 24-85mm f2.8-4D lens which seemed good when I used to shoot on film, or on a cropped-sensor DSLR (my old D70) but which has shown itself to be very soft around the edges (especially at zoomed out and at wide apertures) since I switched to a full frame D700. Nikon say this there is nothing wrong with the lens (they still charged me a chunk of money to service it though) but Ken Rockwell also found it lacking in sharpness in his review so I’d have to say it’s a design “feature”, not a “bug”.

A return trip to London a couple of days later with my family (sans DSLR and tripod but with my Coolpix P7100) gave me another go, which was better, but the P7100 just doesn’t have the low-light performance of my DSLR. With a couple of trips to the Paralympic Games planned (as well as a photography weekend coming up in North Yorkshire), I decided to splash out on a new lens (Nikon 50mm f1.4D) but only had one opportunity to shoot the projections on Parliament again.  The original Olympic show ended with the Olympic Games, but a re-worked version is currently running for the Paralympic Games, except that I’m busy at the weekends, and it’s not on this week because Parliament is in session. That left me with two possible evenings to try and get the shot and, as Amazon delivered my new lens so quickly, last Wednesday I was back in London for a wander around Westminster, culminating in lots of night shots on and around the Thames. This time I think I nailed the shot (I hope so anyway!) but it took two hours (8 viewings of the projection on a 15 minute loop) before I was confident I had the image(s) I wanted in the bag.

The final problem is that, when shooting the projection, the clock face of “Big Ben” is just too bright and the highlights are burned out. Unfortunately, the minus one stop exposure that suited the projections onto Parliament was not enough for Big Ben – and that needed to be underexposed by closer to 4 or 5 stops. Thankfully I was able to take two images in the few seconds during which the Union Flag was projected onto Parliament, grabbing shots at -1EV and -4EV (both at an aperture of f4 and using the same focus point). Then, working in Photoshop, I layered the two images, with the darker one on top, and created a mask to hide all but the clock face of Big Ben, allowing the main elements of the -1EV image to show and the composite image to be correctly exposed.

Union Flag on the Houses of Parliament/Paralympic Projections (9)

This is the resulting image and, although a wider angle would have been preferable (as would have been twilight rather than a pitch black sky), I can’t have everything, the weather was kind to me, and I’d rather have a sharp, correctly exposed, image!

Useful Links: August 2012

This content is 12 years old. I don't routinely update old blog posts as they are only intended to represent a view at a particular point in time. Please be warned that the information here may be out of date.

A list of items I’ve come across recently that I found potentially useful, interesting, or just plain funny:

Setting a blank value in a SharePoint workflow

This content is 12 years old. I don't routinely update old blog posts as they are only intended to represent a view at a particular point in time. Please be warned that the information here may be out of date.

I spent far too much of yesterday fighting with SharePoint workflows… including trying to cancel some that have run away on a list with almost 400 items in it…

Some idiot (initials MW) created a workflow to auto-populate a column based when a record was created or updated. Then, thinking that was successful, he created another one to update a different column. He was so pleased with himself that he didn’t stop to think of the consequences of one workflow updating an item, which would then trigger another workflow because the item had been updated… the resulting event from which would then trigger another workflow… and so on…

The long and short of it, is that I found SharePoint 2007 doesn’t have the ability to bulk remove errant (or otherwise) workflow tasks. Not from the user interface, at least – and I didn’t want to do it, twice, for each one of 377 items (there weren’t quite that many runaway workflows but it was well into three figures). I found some code on a blog post from SharePoint MVP Brian Farnhill (@BrianFarnhill) to cancel a workflow programmatically but I’ll need to put the code  into an app and I’m not really sure how to do that (my limit is probably opening Visual Studio). Besides which, I figure that the administrators of our SharePoint platform, who have probably spent the last 3 weeks wondering why it was running out of memory (or running more processes, or something similar) won’t appreciate me running unsupported code against their servers – even if it is client side…

Although it would be gratifying to create the app, in the end I settled for removing the workflow from the list, which has the side effect of ending all running workflows (unless you select the “no new instances” option). Unfortunately I still have a bunch of items that generate an error message when I try to open them – goodness knows why.

I decided to fight fire with fire and given that I’m clearly some sort of SharePoint Destroyer Designer workflow deity (not), I created another workflow to nuke all the column settings I’d created with the first two workflows (since neutered).

The logic goes like this:

Condition: If columnname is not empty
Action: Set columnname to null

Unfortunately it’s not possible to leave a null/blank value when setting field values but, like so many things in SharePoint, there is a workaround. That workaround is to set a workflow initiation parameter (imaginatively, I called mine Blank) of type single line of text, with an empty default value.

Now, the workflow action can use the value Initiation: Blank (i.e. null) to clear the contents of a column.

Unfortunately, it still hasn’t fixed the problem with the items that will not open. And, in case my manager is reading this post (which I doubt), hopefully this now puts to bed the running joke whether it’s he or I that is our team’s “SharePoint guru”. Clearly my infrastructure background does not lend itself to being a “guru” in an application platform (as I have always maintained!)…

Book review: Microsoft Office 365: Exchange Online Implementation and Migration, David Greve/Loryan Strant

This content is 12 years old. I don't routinely update old blog posts as they are only intended to represent a view at a particular point in time. Please be warned that the information here may be out of date.

Every now and again, I get asked to review a technology book. My response is usually something along the lines of “sure, send me a copy and I’ll take a look”. Experience suggests that dead tree editions are more likely to get read than a PDF but sometimes I’m just busy and it takes a while. That’s not because I’m lazy – it’s because if I review a book I want to take the time to review it properly and write a considered response – not just bang out a blog post because the publisher is nagging me for a review…

Unfortunately, this particular publisher was chasing me just 48 hours after they ordered me a copy (and several days before I’d received the book!) and, just a month later (in the middle of the summer holiday season) they are still pushing…

So, here goes. A very short, not very thorough, view on Microsoft Office 365: Exchange Online Implementation and Migration, by David Greve and Loryan Strant (@TheCloudMouth).

As I’d expect from a book written by a couple of MVPs, this book covers all of the basics of implementing the Exchange Online elements of Office 365. Importantly, it doesn’t just concentrate on the enterprise elements, including information for those getting started with the Office 365 plans for small business and professionals, highlighting some important limitations (although not all – as I found recently, the P1 plans don’t include two factor authentication, which is something that users on competing platforms are being encouraged to use).  The book continues to take a logical approach, working through the administration portal and on to integration options – even considering the practicalities involved when the available options from Microsoft are less than desirable,  recommending some alternatives to consider.  Unfortunately the space given to working from the command line in PowerShell (a useful tool in the Office 365 administrator’s arsenal) is very limited.

Moving on through enterprise integration options, preparing for, and performing both simple and hybrid migrations (including supporting infrastructure, such as Active Directory Federation Services), it seems that the authors have covered a variety of scenarios, with many screen shots and diagrams provided to illustrate key points in the process. One criticism is that the screen shots can, in places, feel as though they are being used to pad out the text – presumably the target audience consists of experienced administrators and they shouldn’t really need screen shots of EULA dialogues – after all, this is not “Office 365 migration for dummies”! Finally, the book examines some important post-migration considerations and highlights additional resources.

When I previously reviewed a book from the same publisher, I remarked on the high cover price. Well, I’m pleased to say that this one is a much more reasonable £24.99 ($39.99) and that there are online discounts and free shipping, as well as reasonably-priced eBook options. Indeed, very sensibly, the print and eBook bundle only costs a little more than the print copy on its own.

If you get the chance to read the book properly and you have some comments (perhaps even based on experience of following its advice, as I would have like to have done), then please leave a comment below. Maybe, together, we can crowdsource its review!

Microsoft Office 365: Exchange Online Implementation and Migration by David Greve and Loryan Strant is published by Packt Publishing.

Raspberry punnets

This content is 12 years old. I don't routinely update old blog posts as they are only intended to represent a view at a particular point in time. Please be warned that the information here may be out of date.

Much as I like the rawness (is that a word?) of the naked Raspberry Pi, it does feel like it would be very easy for me to break and, with huge waiting lists to get a replacement as demand massively outstrips supply, I really don’t want to break mine. Consequently, I decided that a some sort of case would be appropriate (a punnet?).

Punnet v1.0 (or maybe it was v0.1) was the brainchild of freind and neighbour Jon Cowell, who took a plastic box that had originally been used as packaging for a set of business cards (I’m told that Graze boxes work well too) and used a Dremel multitool to cut out holes for connectors. I also had a few spare business card boxes so, after an evening in Jon’s garage, I had a case for my Pi – and very happy with it I was too!

Unfortunately, I also have a penchant for shiny things and, at around the same time as Jon and I created Punnet v1.0, I saw a Raspberry Pi blog post highlighting Paul Beech’s Pibow. You can learn more (and place an order) on the Pibow website and, whilst I’ve noticed that the price has gone up slightly since I bought mine it’s still great value.

I had a chuckle at the the Ikea-inspired instructions and my son had fun putting it together.

My Piböw has arrived :-) Love the IKEA-inspired instructions
@markwilsonit
Mark Wilson

It also seemed to go down well at last weekend’s Milton Keynes Raspberry Jam. So that was Punnet v2.0.

Another option would be to build a case out of Lego but the chances of my boys letting me raid the Lego box to take parts on a semi-permanent basis (even the Lego that dates back to my own childhood) is best described as slim. Thankfully, you can buy a kit of Lego parts to build a Raspberry Pi case, based on a design from a 12-year old Scout called Biz.

Alternatively, for those with a flat-screen monitor that’s not fixed to the wall, SK Pang’s VESA mount for Raspberry Pi looks interesting. Who needs an iMac when you can fix a Raspberry Pi to the back of a cheap monitor, eh?!

Handling camera raw images on old versions of OS X

This content is 12 years old. I don't routinely update old blog posts as they are only intended to represent a view at a particular point in time. Please be warned that the information here may be out of date.

I use Adobe Lightroom for most of my digital photography workflow but as our family takes more and more pictures on a variety of cameras, other family members need to process images – and I’m not letting them near my Lightroom catalogue!

As we tend to use iPhoto every year to product yearbooks, calendars, etc., the solution we decided on was for me to copy unprocessed images over onto an old Mac Mini, which is running OS X 10.6 (Snow Leopard) with iPhoto (still version 6, part of the iLife suite shipped with OS X 10.4, which was what originally installed on the Mini).

Old software doesn’t support raw formats

All seemed good until I we tried to import the the first batch of photos that I’d sent over. iPhoto was happy with JPGs but didn’t like the raw images (.NEF from my Nikon D700 and .NRW from my Nikon P7100). Apple’s advice on supported digital camera RAW formats for OS X 10.6 suggested that the D700 should be OK (presumably not with old versions of iPhoto – one forum post suggested I’d need at least iPhoto ’08) but that I needed to install the Digital Camera RAW Compatibility Update 3.9 for the P7100, which would also need me to upgrade to iPhoto 11 (v9.3.2). The iPhoto upgrade was no big deal (£10.49 in the Mac App Store)  but it will only run on OS X 10.7.4 or later.  Lion is no longer in the Mac App Store but OS X 10.8 (Mountain Lion) is (and it’s only £13.49). Unfortunately, Lion and Mountain Lion will not run on Core Solo or Core Duo Macs (like my Mini).

I refuse to buy a new Mac for this – the whole point of the exercise was to provide a fit-for-purpose solution using the kit we already have – and a new machine doesn’t come into that (heck, I might as well just put Photoshop Elements on my wife’s Windows laptop), so it was back to the drawing board.

If my combination of OS X and iPhoto won’t read my raw files, I’ll just need to batch convert them to something else first…

Compiling and installing dcraw on OS X

Dave Coffin’s dcraw is a Linux utility for raw file conversion and I decided to use that on the Mac Mini but it needs a bit of work to get it installed. I found a blog post that describes the process to get the latest version of dcraw working on OS X 10.7 (Lion) but the process is slightly different for earlier versions of OS X.

First up, I installed Apple’s developer tools – XCode.  These are found on the operating system DVD for OS X 10.6 (in the Optional Installs folder) but are a free load from the Mac App Store for 10.7 and later. I did register for a developer account and started downloading version 3.2.6 but then realised that it was a 4.1GB download and retrieving the DVD from the loft was easier. After installing XCode from the DVD, I updated to 3.2.6 using the OS X Software Update utility although other versions of OS X might have a slightly different XCode upgrade process.

The Unix Command Line tools are an install option on XCode 3.2.6 (they can be downloaded from inside XCode from version 4 onwards) but, once these were installed, the next step was to download and install MacPorts.  Again, there are different versions according to the release of OS X in use but I downloaded the .DMG for OS X 10.6 and then kicked off a Terminal session.

Once in Terminal, I entered the following commands:

su admin
sudo port install dcraw

following which MacPorts did all of the work to download and install dcraw and all of its dependencies.

Batch converting raw images on the Mac

With dcraw installed, there are many options for processing images but the basic syntax may be found by opening Terminal and typing:

\opt\local\bin\dcraw

Camera Hacker has some examples of dcraw use but I used the following commands to bulk convert batches of .NEF and .NRW files to .TIFF format:

dcraw -a -w -v -T *.NEF
dcraw -a -w -v -T *.NRW

One final tweak before import the files to iPhoto was to set the file dates to match the camera timestamp (without this, iPhoto seemed to think that the images were taken on the day they were imported):

dcraw -z *.tiff

The resulting files were ready to import to iPhoto for family use, with no risk to the master copies that are stored on my MacBook.

A beginner’s guide to getting started with Raspberry Pi (#RasPi)

This content is 12 years old. I don't routinely update old blog posts as they are only intended to represent a view at a particular point in time. Please be warned that the information here may be out of date.

I’ve written before on this blog about my experiences getting started with Raspberry Pi (attempt 1 and attempt 2) but, in my post about the inaugural Milton Keynes Raspberry Jam this morning, I highlighted something that became very apparent within the assembled group of Raspberry Pi enthusiasts at Bletchley Park:

“It’s all to easy to forget that, although the current version of the Pi was intended for developers in preparation for a broader educational release, it’s been massively popular with 350,000 boards shipped (and on target for a million by the end of the year!). Add to that, the Raspberry Pi foundation is 20 guys and girls who don’t get paid and who have day jobs – that’s a very limited resource pool to support an awful lot of people! Even so, the Raspberry Pi is not necessarily the most user-friendly experience for those who are not used to hacking around in a command line interface […]”

With that in mind, this blog post is intended as a basic guide for those who don’t have 20 years of experience working in IT, or are not bedroom coders, but do fancy getting stuck in to creating new and exciting things with a small and inexpensive computer. Regular readers may find that I explain things in more detail than usual but I’m assuming the audience are complete beginners when it comes to using a Raspberry Pi and that they do not spend their time geeking out with bits of hardware or bytes of software. If I’ve missed anything – or made some invalid assumptions – please leave a comment on this blog post, or tweet me (@markwilsonit) but please bear in mind that I have a day job too (so my response might not be immediate) and I can’t answer every single question about getting started with a Raspberry Pi!

What’s in the box – and what else do I need?

At its most basic level, the Raspberry Pi is a single board computer. Some distributors may sell bundles with mice, keyboards, etc. but many people will just get a board like the one shown here:

That means there are some essentials to buy:

  • A 5V power adapter with a micro-USB type B connection (I use the one that came with my mobile phone but not all phones have these):
  • A USB keyboard – i.e. a keyboard with a USB type A connection like the one below:
  • A USB mouse (if you want to run a graphical user environment – i.e. one that is not just text-based)
  • An SD card with an operating system. I recommend that beginners start out with one that comes pre loaded, for example with Raspbian Linux.  If you are going to “roll-your own” then that can be more complex and my earlier post based on Debian “Squeeze” might help but that’s a lot more technical and certainly outside the scope of this basic guide.
  • A television or digital computer monitor with either an RCA component, DVI, or HDMI input. VGA will not work. See below for details of what these connections look like.
  • A cable to connect to the Raspberry Pi to the television or computer monitor. The type of cable will depend on the type of connection.
    • RCA cables look like this (normally red and white are used for audio and yellow is used for video, but it doesn’t really matter – the cables are identical):
    • DVI cables look like this (the picture shows the “male” format, with the pins sticking out – the “female” version has holes and is normally found on the back of a computer):
    • HDMI cables look like this:

      You can also get a cable to connect from HDMI to DVI (and a connector to connect two “male” DVI cables) – these are not expensive and are what I use with my Raspberry Pi.
    • VGA connectors look like this (these are very common on both old and new monitors but the Raspberry Pi does not have a VGA output):
  • An Ethernet cable with an RJ45 connection to connect to your home broadband router/modem (Wi-Fi on the Raspberry Pi can be tricky – a cabled connection is often easiest to start with) – often these are supplied by your ISP with the router/modem:
  • Some headphones or speakers with a 3.5mm stereo TRS connection (if you want to hear any sound from your Raspberry Pi):

You might also want to buy a case for your Raspberry Pi but that is by no means essential.  Many people will already have the components listed above but if you need to buy them, they shouldn’t be too expensive.  Probably the most expensive parts are the keyboard and mouse but I picked up a wireless mini keyboard and mouse from Maplin today for £14.99 and they worked out of the box with my Pi.  You might also want to get a powered USB hub if you plan to use more than two USB devices (for example if you want to plug in a webcam, a USB flash drive, or a hard disk).

Putting it together

All of these components are different sizes and shapes so should be pretty easy to plug in. It doesn’t matter which of the two USB plugs are used for the keyboard and the mouse but this diagram (from the Raspberry Pi Foundation’s quick start guide) should help:

Just make sure that the power is coming directly from a 5V supply plugged into the mains and don’t be tempted to run a cable from a USB socket on a PC!

The operating system

Remember that I said I wasn’t going to show you how to prepare your Raspberry Pi with an operating system? There are other guides on the Internet (the Raspberry Pi website is a good place to start) but I strongly recommend you buy an SD card with Raspbian pre-loaded.

If you don’t know what an operating system is, don’t worry – it’s the software that runs on a computer when you turn it on and performs basic functions like driving the screen, keyboard, etc. (like Microsoft Windows on most PCs or Mac OS X on Apple Macintosh computers). Modern operating systems tend to include other functions, like web browsers and media players. Other applications can then be installed on top of the operating system to carry out more specialised tasks (like a word processor, an image editing package, or communications software like Skype).

Raspbian is a Linux operating system – that means that it is freely available (although some organisations might charge for supporting Linux distributions) and that the operating system is similar in many ways to a system called Unix that has been around for over 40 years and is used on many computer systems all over the world.

Logging in and getting going

After all of the “peripherals” (screen, keyboard, etc.) have been plugged in and the power has been switched on, you should see some characters appear on the screen and a prompt to login.

At the login prompt (which will say something like raspberrypi login: followed by a flashing _ cursor) type the username pi and press the Enter key, then type raspberry and press  Enter at the password: prompt.

Once you are logged in, the prompt will change to pi@raspberrypi:~$ followed by a flashing _ cursor. This is username@machinename so you can see that your user is pi and the computername is raspberrypi.

These are the default username and password settings but you really should change the password to something that only you know (I’ll tell you how to do this in a moment).

The first time you start your Raspberry Pi (the first “boot”, as us geeks like to say), your Pi will prompt you for some setup information. It’s important to select the options to expand_rootfs (expand the operating system to use the whole of the memory card) and change_pass (change password).

If you ever need to run this setup programme again, then the command to type is:

sudo raspi-config

Press  the  Enter key after typing the command (and for any other commands in this blog post). Then, just follow the instructions on screen.

Many people will find the command line interface (text-only, also called a CLI) unfriendly, so you can load a graphical user interface (GUI) to see something a little more familiar, driven by a mouse, and with applications in windows. To do this, the command is:

startx

This will slow down the Raspberry Pi a bit but it should be OK. There is a status indicator towards the bottom right of the screen (a green/black bar graph) that shows how busy the Raspberry Pi is. There are many applications pre-installed on the Raspberry Pi, accessible via the start menu (just like on Windows) and you can download others from the Internet (I’ll leave that for now – there’s plenty to get started already pre-loaded in Raspbian). Here are just a few ideas to get going with your Raspberry Pi:

  • You could try some programming in Scratch, or Python.
  • Or if that sounds a bit much for now, just browse the Internet (the browser is called Midori).
  • And, if you need to run any more commands from the CLI, then you can launch an application called LXTerminal.

Updating your Raspberry Pi

Before I sign off, it’s probably worth mentioning some commands that might be necessary to update the software on your Pi. Before I do that, I’ll explain something else – remember the command to run the Raspberry Pi Configuration Utility?

sudo raspi-config

The sudo part of this is worth remembering. Your username on the Raspberry Pi (pi) is what we call a standard user. It runs with a lower level of permissions to prevent any unintended consequences from running applications that might change the configuration of your system. When we want to make deliberate changes, we use sudo to run a command as a super user (like an  administrator in Windows or Mac OS X).

So, to update the software on the Raspberry Pi, run:

sudo apt-get update
sudo apt-get upgrade

APT is the Advanced Packaging Tool – so apt-get is getting details of available software. update downloads details of the available packages (a “resync”). upgrade is updating the operating system.

Finally, there is a tool called rpi-update that can be used to update the firmware (that’s the really low-level code that drives the components on the Raspberry Pi board, underneath the operating system).  This isn’t installed by default and is written by a programmer called Hexxeh.  You can find more details on Hexxeh’s blog and download rpi-update with these commands:

sudo wget http://goo.gl/1BOfJ -O /usr/bin/rpi-update
sudo chmod +x /usr/bin/rpi-update

This will download the  rpi-update program and then change the permissions so that it can be executed (run) on the local computer. I found that I also needed to install git before I could use rpi-update:

sudo apt-get install git-core

Then type:

sudo rpi-update

to update the firmware on your Raspberry Pi.  Generally you will only need to do this if you are having problems getting something to work.

Wrapping up

So, we’ve seen:

  • What you need to buy/find to get your Raspberry Pi working.
  • How to logon to a Raspberry Pi running Raspbian and how to get past the command line and into a more familiar (graphical) environment.
  • Some basic commands to keep your Raspberry Pi up to date.

If you want to learn more, check out the Raspberry Pi Foundation website and there are also other resources available on the Internet. You could also read a book like Meet the Raspberry Pi by Gareth Halfacree and Eben Upton.

Acknowledgements

Much of the information in this post is from a talk given by Peter Onion (@PeterOnion) at the Milton Keynes Raspberry Jam, with additional input from Rob Bishop (@Rob_Bishop) of the Raspberry Pi Foundation.

The illustrations used are taken from Wikipedia and elsewhere as follows:

Due to the licensing conditions of the images listed above, this blog post (but not the rest of this website), is licensed under the Creative Commons Attribution-Share Alike 3.0 Unported license.