Page 118 - Programming the Raspberry Pi Getting Started with Python
P. 118
will inspire you to do great things with your Pi.
For more information about the hardware side of using the Raspberry Pi, the following links are
useful:
• http://elinux.org/RPi_VerifiedPeripherals A list of peripherals verified as working with the
Raspberry Pi.
• http://elinux.org/RPi_Low-level_peripherals A list of peripherals for interfacing with the
GPIO connector.
• www.element14.com/community/docs/DOC-43016/ A datasheet for the Broadcom chip at the
heart of the Raspberry Pi. (This is not for the faint of heart!)
If you are interested in buying hardware add-ons and components for your Raspberry Pi, Adafruit
has a whole section devoted to the Raspberry Pi. SparkFun also sells Raspberry Pi add-on boards and
modules.
Other Programming Languages
In this book, we have looked exclusively at programming the Raspberry Pi in Python, and with some
justification: Python is a popular language that provides a good compromise between ease of use and
power. However, Python is by no means the only choice when it comes to programming the Raspberry
Pi. The Raspbian Wheezy distribution includes several other languages.
Scratch
Scratch is a visual programming language developed by MIT. It has become popular in education
circles as a way of encouraging youngsters to learn programming. Scratch includes its own
development environment, like IDLE for Python, but programming is carried out by dragging and
dropping programming structures rather than simply typing text.
Figure 12-1 shows a section of one of the sample programs provided with Scratch for the game
Pong, where a ball is bounced on a paddle.
Figure 12-1 Editing a program in Scratch
C
The C programming language is the language used to implement Linux, and the GNU C compiler is
included as part of the Raspbian Wheezy distribution. To try out a little “Hello World”’ type of