Scratching the Surface of the Digital Age

It’s here. I’ve been waiting for as long as I can remember for the moment where my life becomes completely digitized. It’s a switch on an unprecedented scale where the advantages of leading a digital life blow away that of any analogue system. It’s also a switch that certainly doesn’t come overnight, and it’s a switch that must fit with your personal lifestyle.

When I was at school, teachers demanded a paper-based system whereby you handed in sheets of paper, exercise books filled with homework, and completed final exams on paper. Everything I seemed to do involved paper, yet by the time I’d reached my final year of A-Levels, aged 18, I’d concluded that paper-based systems had been completely holding me back. Without a digital device, it’s incredibly hard to look up a spelling, perform a calculation, find the definition of a word, record and playback a lecture, create beautiful documents and presentations, find information, get help with a problem. Without a digital aspect to learning and studying, you’re completely and utterly limited.

And it doesn’t stop with studying. Continue reading

Apple Inc.

Unbelievably, this is my first post related to the technology legend, Apple. Here goes…

I’d never used a single Apple product up until the age of 18. For my 18th birthday I was gifted with an Apple MacBook. I’d used Windows since Windows 95, and I’d wanted a change, besides, the Apple product looked charming and inviting, and the Mac “find out how” website provided some really well-produced and captivating demo videos. I wanted to find out more, and so I asked for a MacBook.

When I first starting using the MacBook things seemed very alien to a long-time Windows user, and at the time I was the crazy sort of person who enjoyed not knowing what to do to use a computer – it made a change for me! So over the first few months, I didn’t really know too much about how to use a Mac computer, compared to using Windows, and I was still using my Windows desktop as my main computer. In fact, one of the first things I did was install Windows on my MacBook using bootcamp! But whenever I used the MacBook I’d find some new cool feature. I can install any printer at any time after merely plugging it in. Spaces allows me to organise the layout of my desktop. Spotlight allows me to find anything on my computer, from files to calender events, to emails using a simple shortcut and search box. I can beautifully arrange, edit and keep my photos organised using iPhoto. I’m able to scroll pages merely by hovering my cursor over the page and smoothly swiping two fingers across the trackpad. Just a few of my favourite features. So over time, gradually and slowly

I’d say it took me a year before I would say that the operating system, Mac OS X is better than Windows. That’s probably a quite long time for a Mac user (I’ve never met a Mac user that prefers Windows). After a year I realised I could do everything I’d ever want to do on Windows on Mac, and doing it on Mac was always more fun, elegant, reliable and secure. Once I realised Mac was better, I’ve never gone back, and only realised it more and more every day. Every few days I find a cool new thing I can do with Mac that I can’t do in the same way on Windows. These are most often little things, and hard to account for, but when these 100s of little things add up, they equate to me to be the superior system. Everything is so immaculately designed to be user-friendly and provide the most rich computing experience. Mac OS X has so much depth that could only have the surface scraped by an entire book. On the outside the system is warm and inviting, and on the inside is a deep masterpiece of functionality. There is literally nothing you can’t do on a Mac.

Nothing you can’t do I say? Well… perhaps this isn’t quite true. There is still one area of computing that Windows systems are better for… Video gaming. Game developers are still using Microsoft’s Direct X to build their video games, a framework locked to the Windows operating system, meaning that the games have to be ported in order to work on either the Mac OS X or Linux operating systems. So for now, Windows still holds one card high in the air. But with companies such as Valve announcing their up-coming port of their entire catalog of games, will it be long before other game developers follow? Will OpenGL (a graphics framework supported by around 100 of the top technology companies of the world) become the new platform for gaming graphics, allowing development across all operating systems? I hope so.

As a computer scientist, and having studied Apple Development for a short period of time, I can also see the design and attention put into the software development side of things – even underneath the hood, the Mac OS environment and design principles look incredible! Then the Mac system extends to other products such as the phone with the iPhone, and the mp3 player with the iPod, where the company has revolutionised and led the way in these fields, bringing new technological advancements and creating an all-round, synchronised consumer electronic experience.

Apple creates products with incredible care and attention to the tiniest of details. They’re a company constantly striving to improve and rescale existing products to all-new levels of “perfection”, whilst continuously contemplating the next big feature, or brand new idea, concept or product. Apple is a company that, in my opinion, and as far as technology is concerned, they are “doing the right thing“, and they’re “doing the thing right” – and that is why I’d love to get involved.

I’m now also writing for ‘Computer Science: Source’.

I’ve joined a team of Manchester computer science students and will be writing for Computer Science: Source, a blog that aims to provide computer science related information, with a particular emphasis towards clarifying and revising topics from the University of Manchester computer science course.

My first post attempts to begin summarising the Objective-C programming language, a language used to write applications for the Apple Mac and iPhone.

Do check it out if you’re interested. Particularly interesting posts by myself will also be available here. 🙂

Understanding the MU0 Processor

In hopefully a single page…

The MU0 processor is a very basic processor used at the University of Manchester to teach students the fundamentals of a CPU architecture. It is abstract design used for teaching purposes. The MU0 features at the start of the 2nd Year Computer Science COMP25111 Operating Systems course. I’m just going to run through how I understand this processor to work in my own terms. I’m not going to mention low level gate stuff because as far as I can see we don’t need to be concerned with that low level an abstraction for the Operating Systems course! Please try and follow this through with the diagrams provided by the University.

MU0 is a single-address processor, which means that each of the instructions only ever have one address in the instruction at most (the other two are implied). The effect of this is that it may take a considerable amount more instructions in order to achieve the same thing you could do with two-address architecture. It’s more basic. The processor is also only 16 bit. This means that each instruction can have, at most, 16 bits to it. Hence, it’s only a one-address processor – there’s only enough space in the instruction for one address. Of the 16 bits, 4 of them are allocated to the instruction type and are known as the ‘f’-bits, leaving 12 bits for instruction information, known as the ‘s’-bits.

The processor has three registers;

  • IR (instruction register for storing the current loaded instruction)
  • ACC (accumulator for storing a working value)
  • PC (program counter for storing the current position in the instruction set).

It also has an adder for doing all it’s computation (also known here as the ALU, or Arithmetic Logic Unit, and not to be confused with the ACC register). Here are the seven instructions available for use with this processor design:

Sorry for poor quality – couldn’t work out how to do a table in WordPress!

This is great so far. We can now understand how to write a program using this processor as we have all the instructions in front of us. This is also the specification for the processor design, and our problem is how to implement these registers and instructions. So what we need is a design that incorporates the features we’ve just outlined. The design will be achieved using two sections to the processor, a datapath and a control. The datapath is responsible for following the instructions and interpreting them, and the control is responsible for controlling components by enabling and disabling them, and setting those with options to the right state (the adder/ALU will need three states). These two sections of the processor will be synchronized using a global clock. A reset will be wired up to both too so that if the reset is flicked, the whole processor resets, not just one section.


On each clock cycle (each pulse of the CPU where everything happens), the MU0 processor will be in one of two states; fetch and execute. On the fetch “pulse” the MU0 ‘fetches’ (gets) an instruction from the memory (instructions begin at the first address in memory i.e. #000) as indicated by the PC (initially set to #0000) and loads it into the IR. The ACC/ALU side of the datapath does nothing. For simplicity we can say that the PC auto-increments without going into the lower levels, which happens at the end of the Fetch cycle.


Now we wait for the next clock strike. When this happens, the MU0 switches to the execute state, and depending on the instruction that’s just been loaded, the ALU may do one of three things with the ‘s’ bits of the instruction. It will either perform an addition of s to the ACC, make a similar subtraction, or simply bypass (pass through unchanged) s. Any necessary change to the ACC (if it’s an add/sub) or PC (if it’s a jump) will be performed, and after the execution of the Execute state, the processor will wait for the clock to strike again, and then return back to the Fetch state. The PC has been incremented from the last time the processor was in the Fetch state, so the next instruction will be loaded, and so on.

If the reset is switched, the state returns to Fetch, and if the stp instruction is processed, the state remains in Execute (not further processes are ‘fetched’).

The control of course is key, and I can’t write too much about it, as it’s the basis of the first lab exercise. Although I will say this. Each instruction needs to use the components of the CPU in a slightly different way (there’s no two same instructions). The control basically lets each component (including memory as it needs to be read or write enabled) needs to know what way to act differently for that instruction. The eight control bits outlined on the diagram below of the MU0 datapath design display eight different ‘options’ for controlling the components. If you’ve managed to follow how the CPU has been put together and what each instruction does, it should be clear which settings the control needs to set in order for each instruction to perform the right thing. Note that the control’s main input from the datapath is the four F bits (data out on the diagram). The datapath tells the control at this point which instruction it’s working with, and the control sets the the eight control bits accordingly.


Just to let you know I spoke to some other student’s whilst writing this for clarification on some issues.

We’re all learning! There may well be errors so please let me know if you find one. If anyone has any issues or something’s not clear let me know and I’ll make changes, and I hope this helped and please leave comments!