Skip to main content

I’ve got Pi(3) brain

Do robots think?  Do they have emotions?  …Do they prefer broccoli or asparagus?

Time to find out; and let’s start by giving Rosie a brain.  A (Raspberry) Pi brain.

Brains need to make sense of all the information that it receives, and do something useful with it.  It also needs to be able to memorise useless stuff, like Christmas cracker jokes to keep humans amused.

As we aren’t yet able to buy actual human brains from Amazon, we have decided to purchase a Raspberry Pi 3 instead.  It has a quad-core ARM processor to do the processing.   It has 1GB of RAM and an optional SDHC card to do the memorising (I think as I can’t quite remember).  And it has seven million other letters worth of acronyms to do what robot brains should do.   Observe the world.  Be smart (sometimes).  But most importantly, impress humans with silly robot dancing.

You will need to have these:

  • Computer (we are using a Windows 10 laptop).  Apples are fine too (of the computer variety, not the fruit), you will just need to use different software to write the Raspbian OS image to the SDHC card.
  • Raspberry Pi 3, with power supply
  • Micro SDHC card
  • SDHC card reader (many new laptops have these built-in).  But you may need an adapter for a 'micro' SDHC card, especially if your computer only has a slot for a larger card.
  • USB keyboard and mouse
  • Monitor (with HDMI connection), and a HDMI cable 

You will need to do this:

  • Install software that allows you to write image files to SDHC cards.  We used Win32DiskImager (  Then, insert the blank SDHC card into your computer (not the Pi!).
  • Download the official Raspbian Operating System (OS) image file from here.  We used the '2017-07-05 Jessie' version.  Newer versions may be available.
  • Write the Raspbian OS image onto the SDHC card using the SDHC card writer software
  • Remove SDHC card and insert into the Raspberry Pi
  • Connect a USB keyboard, mouse and monitor.  Power up the Pi.
  • Have a look around 'the brain'

What do you get after all this?

Our Raspberry Pi will run the 'Raspbian' Operating System (OS).  Mainly because it is Raspberry Pi Foundation’s official supported Operating System, and we aren't particularly imaginative.  Did we also say it's free?

An Operating System (often called OS for short) is a piece of software that is most often installed on computers first to allow us to interact with the computer's hardware.  You probably would have heard of Windows, Android or iOS, amongst many others.  Raspbian is just another one of those, and is based on Linux, which is a very popular type of operating system.  Also, OSs need storage to run on as they consist of a bunch of files.  Most run on disks: hard disks, USB disks, spinal discs, brake discs, etc.  Here, we will be using a SDHC card.  It will perhaps become the most important part of Rosie's brain - because it will be used to store everything (data).  We can replace the Pi.  But if we lose the SDHC card, we lose months - maybe years - of Rosie's precious memory.

Going forwards, our Raspbian OS will be the nerve centre from which we make everything happen.  Create code.  Install drivers and programs.  Create more code.  That's why you better get used to it... it will be both your best friend and your worst enemy.

This is simply too much detail:

You will need a SDHC card.  First and foremost, it will be used to store the Operating System, from which the Pi can boot up and do its clever stuff.  Pi 3 requires a 'micro' SDHC card.  8 or 16GB seems to be an appropriate size for Rosie's brain.  Of course, we don't want her to have too big a brain - otherwise she might just get too geeky (and take over the world).

Firstly, you will need to insert the SDHC card into your computer so that you can write the Raspbian OS image file to it.

Download and install a program that allows you to write image files to SDHC cards.  We used Win32DiskImager ( but other tools are available (or so Google reliably tells us).  Then, download the official Raspbian OS image file from here and write the file to the SDHC card.

Once your chosen program helpfully informs you that it has finished writing the file, carry out the brain implant.  Remove the SDHC card from the computer and insert it into the SDHC card slot of the Pi.  It is a good time to connect the power cable as well (but don't connect it to the mains just yet).

Insert your USB keyboard, mouse and monitor (using a HDMI cable) into your Pi.  You'll need these to instruct Rosie what to do.  Until we make her accessible remotely of course.  She won't recognise your frantic hand gestures or your shouting - not just yet

Now, you're all set for the magic moment.  It's like that moment when someone walks into the room with candles lit on your birthday cake - and hopefully not like when it is accidentally dropped and sets fire to the carpet.

We are powering on Rosie's brain.

Connect the other end of the power cable to the mains, and watch the Pi (and its Raspbian OS) come to life before your very eyes.  You will eventually see the Raspbian desktop appear in your monitor.  In this version, there's a random road, some clouds, maybe even a sun in the horizon but we're not quite sure.

Isn't this cool?

But that's not how serious roboticists (if that is actually a word) rock and roll.  Like in science fiction movies, they demand that ineligible texts scroll rapidly across a black screen.  Time to say goodbye to the pretty desktop.  We're taking this party to another level.  Things have just become serious.  It's time... for the command line prompt.  Or terminal as it's confusingly called.

Click on the terminal prompt icon in the top left.  A scary black box will appear, instantly making the experience more bleak.

Now, Rosie's brain will take you seriously.  She's awaiting your instructions.

Run a few (totally uninteresting) Linux commands to navigate around the contents of Rosie's brain.  Let's also create a folder called 'rosie'.  Why?  Well, where else would we want to store Rosie's secrets going forwards?

Here are a few of the many Linux commands available that you'll type in (always with the 'enter' key pressed after each command):

...shows current directory (folder)
...shows what's in current directory
mkdir rosie
...creates a new folder in current directory called 'rosie'
...shows what's in current directory (again).  Only this time, you should see the 'rosie' folder.
cd rosie
...navigate 'into' newly created 'rosie' folder
...remember this command?  It checks that our current directory is now 'rosie'.

All in all, you should see something like this:

Now store away these commands (and many more that will follow) in YOUR brain.  They are beyond just useful.  They are essential when navigating around Rosie's brain (which of course by now you know is a Linux-based Operating System, running on the Pi's SDHC card).

And believe it or not, this is it.  No more, no less.  Rosie's brain is fully operational.

Update 1 - March 2020

There is now a handy Raspberry Pi Imager that allows us to install the operating system directly onto the SD card. Give it a go, why don't you?

Even more reading:

Raspberry Pi Foundation's official instructions on how to get started can be found below:



LoRa-Wan Kenobi

In the regurgitated words of Michael Bublé: It's a new dawn .  It's a new day .  It's a new Star Wars film .  For me .  And I'm (George Lucas, and I'm) feeling good .  Unfortunately for Canadian Mike, the Grammy that year was won by the novelty disco classic with the famous refrain: We love IoT, even in Planet Tatooine * . *Not true. Clearly, the Star Wars producers didn't sincerely mean the last Jedi the previous time around.  Return of the Jedi, released during the decade that spearheaded cultural renaissance 2.0 with the mullet and hair-metal , was less economic with the truth.  Either way, we're going to take inspiration from the impressive longevity of the money-spinning space-opera and reboot our franchise with some Jedi mind tricks.  Except this particular flick doesn't require an ever-growing cast of unrecognisable characters, unless ASCII or UTF counts.  In place of an ensemble gathering of Hollywood stars and starlets, we will b

Battle of BLEtain

The trolling . The doxing . An army of perplexing emojis. And endless links to the same - supposedly funny - viral video of a cat confusing a reflection from a dangling key for a golden hamster, while taking part in the mice bucket challenge. Has social media really been this immense force for good? Has it actually contributed significantly to the continued enlightenment of the human (or feline) race? In order to answer these poignant existential questions about the role of prominent platforms such as Critter, StinkedIn and Binterest, employing exceptional scientific rigour equal to that demonstrated by Theranos , we're going to set up a ground-breaking experiment using the Bluetooth Low Energy feature of MicroPython v1.12, and two ESP32 development boards with inexplicable hatred for one another.  And let them hurl quintessentially British expressions (others call them abuse) at each other like two Wiltshire residents who have had their internet access curbed by the co

Hard grapht

You would all be forgiven for assuming that bar , pie and queue line are favourite pastimes of the British .  Yet, in fact – yes, we did learn this back in GCSE maths – they are also mechanisms through which meaningless, mundane data of suspect origin can be given a Gok Wan -grade makeover, with the prime objective of padding out biblical 187-page PowerPoint presentations and 871-page Word reports (*other Microsoft productivity tools are available).  In other words, documents that nobody has the intention of ever reading.  But it becomes apparent over the years; this is perhaps the one skill which serves you well for a lifetime in certain careers.  In sales.  Consultancy.  Politics.  Or any other profession in which the only known entry requirement is the ability to chat loudly over a whizzy graph of dubious quality and value, preferably while frantically waving your arms around. Nevertheless, we are acutely conscious of the fact that we have spent an inordinate amount