Presentation is loading. Please wait.

Presentation is loading. Please wait.

The Postman in your PC Today you are going to learn how a computer’s CPU works to handle data. Teachcompsci.co.uk.

Similar presentations


Presentation on theme: "The Postman in your PC Today you are going to learn how a computer’s CPU works to handle data. Teachcompsci.co.uk."— Presentation transcript:

1 The Postman in your PC Today you are going to learn how a computer’s CPU works to handle data. Teachcompsci.co.uk

2 Learning Objectives.. Have an understanding of the fetch execute cycle …Be able to identify how the pigeon holes in the little man computer, relates to memory locations. …understand that an instruction set is use to give the postman instructions.

3 C at and P ats sorting U nit (CPU) In box Out Box Counter 1 Pigeon hole 1 Pigeon hole 2 Pigeon hole 3 Pigeon hole 4 Pigeon hole 5 Pigeon hole 6 Pigeon hole 7 Pigeon hole 8 Pat has a series of pigeon holes each with a piece of paper in Pat has an In box which information arrives on Pat has an outbox to send letters on with. Sam has a counter to help him remember which pigeon hole he is on. Pat has a Calculator

4 The rules Each pigeon hole has a piece of paper in it which will have one of the instructions on the side on it. It will also contain a number in some cases (e.g. ADD 4, STORE 3) Pat follows a process called the fetch execute cycle to work through the pigeon hole sections.

5 In box Out Box Counter 1 Pigeon hole 1 Pigeon hole 2 Pigeon hole 3 Pigeon hole 4 Pigeon hole 5 Pigeon hole 6 Pigeon hole 7 Pigeon hole 8 C at and P ats sorting U nit (CPU) Pat reads the next Pigeon hole from the location counter

6 In box Out Box Counter 1 Pigeon hole 1 Pigeon hole 2 Pigeon hole 3 Pigeon hole 4 Pigeon hole 5 Pigeon hole 6 Pigeon hole 7 Pigeon hole 8 C at and P ats sorting U nit (CPU) He walks over to the Pigeon hole that corresponds to the location counter

7 In box Out Box Counter 1 Pigeon hole 1 Pigeon hole 2 Pigeon hole 3 Pigeon hole 4 Pigeon hole 5 Pigeon hole 6 Pigeon hole 7 Pigeon hole 8 C at and P ats sorting U nit (CPU) He carries out the instruction (either adding a number to a pigeon hole or the calculator)

8 In box Out Box Counter 1 Pigeon hole 1 Pigeon hole 2 Pigeon hole 3 Pigeon hole 4 Pigeon hole 5 Pigeon hole 6 Pigeon hole 7 Pigeon hole 8 C at and P ats sorting U nit (CPU) He reads the instruction on the slip of paper (Pat puts it back in case he needs to read it again)

9 In box Out Box Counter 2 Pigeon hole 1 Pigeon hole 2 Pigeon hole 3 Pigeon hole 4 Pigeon hole 5 Pigeon hole 6 Pigeon hole 7 Pigeon hole 8 C at and P ats sorting U nit (CPU) Pat clicks the counter to say he is finished and ready for the next task

10 A volunteer to be Pat A similar situation is set up at the front of the class room. You have an IN box, a OUT box, a COUNTER, a Calculator and some PIGEON HOLES. Work through the fetch execute cycle until told to HALT. But first you need to know what the instructions mean…

11 Copy these down! LOAD = put the number after it in the calculator (Wiping what's there already) STORE = Put the number in the calculator into the pigeon hole after the word store (store 4 = pigeon hole 4) ADD = add the number after add, to the number in the calculator SUB = Subtract the number HALT = Stop.

12 Pigeon Hole 1 Pigeon Hole 2 Pigeon Hole 3 Pigeon Hole 4 Pigeon Hole 5 Pigeon Hole 6 Pigeon Hole 7 Program:

13 Task This may be done in small groups or in the centre of the room. Role-play working through a selection of little man computer programs.

14 A couple more instructions INPUT = Take the number in the IN BOX and put it in the calculator (Deleting what is already there). OUTPUT = – If there is no number after output, write the number on the calculator down and put it in the OUT BOX. – If there is a number after OUTPUT place the number in the pigeon hole with that number in the OUT BOX JUMP = Get a screwdriver out and change the COUNTER to be the number after jump.

15 Why have we just done this? The Fetch Execute cycle that Pat followed is identical to how a computer CPU works. The pigeon holes are Memory locations, and PAT is the computer itself. Could you write a simple little man program?


Download ppt "The Postman in your PC Today you are going to learn how a computer’s CPU works to handle data. Teachcompsci.co.uk."

Similar presentations


Ads by Google