Chapter 9

Programming with Scratch

Scratch is an easy-to-learn toy programming language for kids. Scratch is preinstalled on the Pi desktop, so you can start learning how to make simple games and animations right away.

Understanding Scratch

Import a Costume

Switch a Costume with Blocks

Create a Loop

Move a Sprite

Add a Bounce

Check for Collisions

Respond to the Mouse and Keyboard

Edit a Costume

Change the Stage Background

Play Sounds

Work with Variables

Using the Pen

Understanding Scratch

You can use an application called Scratch to learn programming on your Pi. Scratch is a toy language created at MIT for use in schools. It introduces many basic features of programming and software, and is also fun to play with.

Understanding the Stage

Get Teach Yourself VISUALLY Raspberry Pi now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.