Scratch on Raspberry Pi

Hi guys. This is my 100th post on my blog and I am pleased to write about… Scratch!

True, I did say that I wouldn’t do too much about Raspberry Pi, but I use Scratch on my Raspberry Pi. If you are not using Raspbian on your Pi, or you have Linux installed on a different computer, use your package manager to install the package scratch. (Example: on Debian use sudo apt-get install scratch at the terminal)

Installers for Windows, Mac OS X and Linux are found on

Once done, run Scratch and a small window will open. It will look a bit like this:


Then click control and click Control, then drag the When flag clicked to the scripts. Then, click Looks and drag “Say Hello! for 2 seconds” to the scripts and it should connect to the When Flag clicked. Click on the Green flag. The cat should say Hello!

Now replace the When Flag clicked with When Space Key Pressed. Choose which key triggers the program and tap it.


While this is a good example, it fails to show Scratch’s power.

Lets make the cat sprite move:

Delete the Hello stuff (just drag the code relating to Hello! back into where you got it from).

The code is shown below:


Now lets add jumping:


These examples are basic. More powerful examples can be found at

Epic Chas Gamer 😀


3 thoughts on “Scratch on Raspberry Pi

Go on, you know you want to! Leave a comment

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s