Programming with Python Turtle graphics


© Lead Image © Baurzhan Moldabekov,

© Lead Image © Baurzhan Moldabekov,

Article from Issue 231/2020
Author(s): , Author(s):

Create a bulb and tube analog thermometer with a Raspberry Pi and Python Turtle graphics.

Turtle graphics are a great way to get kids started programming. The Python turtle library offers simple step-by-step graphical methods that allow young programmers to create graphics with only a few lines of code.

I found that once my kids understood Turtle basics, we were able to do more advanced Raspberry Pi projects that used sensors, push buttons, and outputs. In this article, I share a Rasp Pi Turtle project that creates a graphic of an "old style" mercury thermometer animated with a Pi temperature sensor.

Getting Started

The Python turtle library is probably already loaded on your Raspberry Pi system, but if it is not, enter:


Use Express-Checkout link below to read the full article (PDF).

Buy this article as PDF

Express-Checkout as PDF
Price $2.95
(incl. VAT)

Buy Linux Magazine

Get it on Google Play

US / Canada

Get it on Google Play

UK / Australia

Related content

  • Workspace: Markdown Tools

    From note-taking applications to wikis – there are plenty of handy tools for working with Markdown-formatted content. Here are a few worth adding to your toolbox.

  • Perl – Memes

    It started off harmlessly enough with a few funny pictures of cats, but eventually it became the Internet phenomenon par excellence. It's no joke: Perl gives you some great tools for building and customizing memes yourself.

  • Gran Canaria Desktop Summit: Saints, Gentlemen and Schoolchildren

    At the start of the Gran Canaria Desktop Summit on the Canary Islands, Richard Stallman, Robert Lefkowitz and Walter Bender rallied open source developers in their common tasks.

  • Hidden Meaning: Working with Microformats

    Programs aren’t as smart as humans when it comes to interpreting the meaning of web information. If you want to maximize your search rank, you might want to dress up your HTML documents with microformats and microdata.

  • curses

    When you need some quick graphical output, the old school curses library can save you some time and effort.

comments powered by Disqus

Direct Download

Read full article as PDF:

Price $2.95