Raspberry Pi Cookbook for Python Programmers


Raspberry Pi Cookbook for Python Programmers
eBook: $26.99
Formats: PDF, PacktLib, ePub and Mobi formats
$22.94
save 15%!
Print + free eBook + free PacktLib access to the book: $71.98    Print cover: $44.99
$44.99
save 37%!
Free Shipping!
UK, US, Europe and selected countries in Asia.
Also available on:
Overview
Table of Contents
Author
Support
Sample Chapters
  • Install your first operating system, share files over the network, and run programs remotely
  • Unleash the hidden potential of the Raspberry Pi’s powerful Video Core IV graphics processor with your own hardware accelerated 3D graphics
  • Discover how to create your own electronic circuits to interact with the Raspberry Pi
  • Interface with purpose-built add-ons and adapt off-the-shelf household devices

Book Details

Language : English
Paperback : 402 pages [ 235mm x 191mm ]
Release Date : April 2014
ISBN : 1849696624
ISBN 13 : 9781849696623
Author(s) : Tim Cox
Topics and Technologies : All Books, Cookbooks


Table of Contents

Preface
Chapter 1: Getting Started with a Raspberry Pi Computer
Chapter 2: Starting with Python Strings, Files, and Menus
Chapter 3: Using Python for Automation and Productivity
Chapter 4: Creating Games and Graphics
Chapter 5: Creating 3D Graphics
Chapter 6: Using Python to Drive Hardware
Chapter 7: Sense and Display Real-world Data
Chapter 8: Creating Projects with the Raspberry Pi Camera Module
Chapter 9: Building Robots
Chapter 10: Interfacing with Technology
Appendix: Hardware and Software List
Index
  • Chapter 1: Getting Started with a Raspberry Pi Computer
    • Introduction
    • Connecting the Raspberry Pi
    • Using NOOBS to set up your Raspberry Pi SD card
    • Networking and connecting your Raspberry Pi to the Internet via the LAN connector
    • Configuring your network manually
    • Networking directly to a laptop or computer
    • Networking and connecting your Raspberry Pi to the Internet via a USB Wi-Fi dongle
    • Connecting to the Internet through a proxy server
    • Connecting remotely to the Raspberry Pi over the network using VNC
    • Connecting remotely to the Raspberry Pi over the network using SSH (and X11 Forwarding)
    • Sharing the home folder of the Raspberry Pi with SMB
    • Keeping the Raspberry Pi up to date
  • Chapter 4: Creating Games and Graphics
    • Introduction
    • Using IDLE3 to debug your programs
    • Drawing lines using a mouse on Tkinter Canvas
    • Creating a bat and ball game
    • Creating an overhead scrolling game
  • Chapter 5: Creating 3D Graphics
    • Introduction
    • Starting with 3D coordinates and vertices
    • Creating and importing 3D models
    • Creating a 3D world to roam in
    • Building 3D maps and mazes
  • Chapter 7: Sense and Display Real-world Data
    • Introduction
    • Using devices with the I2C bus
    • Reading analog data using an analog-to-digital converter
    • Logging and plotting data
    • Extending the Raspberry Pi GPIO with an I/O expander
    • Sensing and sending data to online services
  • Chapter 9: Building Robots
    • Introduction
    • Building a Rover-Pi robot with forward driving motors
    • Using advanced motor control
    • Building a six-legged Pi-Bug robot
    • Avoiding objects and obstacles
    • Getting a sense of direction
  • Chapter 10: Interfacing with Technology
    • Introduction
    • Automating your home with remote sockets
    • Using SPI to control an LED matrix
    • Communicating using a serial interface
    • Controlling the Raspberry Pi over Bluetooth
    • Controlling USB devices

Tim Cox

Tim Cox lives in England with his wife and two young daughters and works as a software engineer. His passion for programming can be traced back to one Christmas in the mid 1980s when he received a Sinclair Spectrum 48k+ home computer (a joint present with his two elder brothers). By typing out and modifying BASIC programs, while dreaming about building robots, an interest in computers and electronics was sparked, which has never faded. This interest saw him through university, where he earned a BEng in Electronics and Electrical Engineering, and into a career in developing embedded software for a wide range of applications, for automotive, aerospace, and the oil industry, among others.

Keen to support the vision behind the Raspberry Pi, reignite engineering in schools, and encourage a new generation of engineers, Tim co-founded the MagPi magazine. Thanks to the dedication and time of the volunteers who contribute to it every month, it continues to have monthly issues and attract an ever-increasing number of readers (and writers) worldwide. Through his site PiHardware.com, Tim produces electronic kits and helps people learn about the Raspberry Pi and hardware interfacing; each of them is supported with detailed instructions and tutorials to help novices build the knowledge and skills for their projects.

This is Tim's first ever book; it mirrors his own experience of discovering the Raspberry Pi and showcasing its fantastic abilities.

Sorry, we don't have any reviews for this title yet.

Code Downloads

Download the code and support files for this book.


Submit Errata

Please let us know if you have found any errors not listed on this list by completing our errata submission form. Our editors will check them and add them to this list. Thank you.


Errata

- 1 submitted: last submission 07 Jul 2014

Errata Type: Code | Page Number: 232

raspistill > less
raspivid > less

should be

raspistill | less

raspivid | less

Sample chapters

You can view our sample chapters and prefaces of this title on PacktLib or download sample chapters in PDF format.

Frequently bought together

Raspberry Pi Cookbook for Python Programmers +    Mastering Object-oriented Python =
50% Off
the second eBook
Price for both: ₨463.20

Buy both these recommended eBooks together and get 50% off the cheapest eBook.

What you will learn from this book

  • Set up and run Raspberry Pi for the first time
  • Develop desktop applications, and handle images and process files with ease
  • Make use of graphics and user control to develop your own exciting games
  • Create 3D worlds by using the Raspberry Pi's powerful GPU
  • Discover how to create your own electronic circuits to interact with the Raspberry Pi
  • Use the Raspberry Pi Camera to create animations and timelapses
  • Design and build your own Raspberry Pi controlled robots
  • Take control of the real world and interface with physical hardware, combining hardware and software for your own needs

In Detail

The Raspberry Pi foundation has been selling their computers since 2012 with the aim of inspiring programmers and engineers.

Raspberry Pi Cookbook for Python Programmers is a practical guide for getting the most out of this little computer. It will guide you through the many uses of the Raspberry Pi and allow you to showcase the best it has to offer. Discover what the Raspberry Pi has to offer using detailed Python 3 examples that you can adapt and extend; see where your creativity takes you!

"Raspberry Pi Cookbook for Python Programmers" begins by guiding you through setting up the Raspberry Pi, performing tasks using Python 3 and introduces the first steps to interface with electronics. As you work through each chapter you will build up your skills and knowledge and apply them as you progress throughout the book, delving further and further into the unique abilities and features of the Raspberry Pi.

Later, you will learn how to automate tasks by accessing files, build applications using the popular Tkinter library and create games by controlling graphics on screen. You will harness the power of the built-in graphics processor by using Pi3D to generate your own high quality 3D graphics and environments. Connect directly to the Raspberry Pi’s hardware pins to control electronics from switching on LEDs and responding to push buttons right through to driving motors and servos. Learn how to monitor sensors to gather real-life data and use it to control other devices, and view the results over the Internet. Apply what you have learnt by creating your own Pi-Rover or Pi-Hexipod robots. Finally, we will explore using many of the purpose-built add-ons available for the Raspberry Pi, as well as interfacing with common household devices in new ways.

The "Raspberry Pi Cookbook for Python Programmers" will allow you to discover the vast range of abilities this micro-computer has. By following the clear examples you can pick up many new skills and arm yourself with the tools to create your own exciting and interesting projects.

Approach

"Raspberry Pi Cookbook for Python Programmers" is written in a Cookbook format, presenting examples in the style of recipes.This allows you to go directly to your topic of interest, or follow topics throughout a chapter to gain a thorough in-depth knowledge.

Who this book is for

The aim of this book is to bring you a broad range of Python 3 examples and practical ideas which you can develop to suit your own requirements. By modifying and combining the examples to create your own projects you learn far more effectively with a much greater understanding. Each chapter is designed to become a foundation for further experimentation and discovery of the topic, providing you with the tools and information to jump right in.

Readers are expected to be familiar with programming concepts and Python (where possible Python 3 is used), although beginners should manage with the help of a good Python reference book and background reading. No prior knowledge of the Raspberry Pi or electronics is required; however for the hardware sections you will need some basic electronic components/household tools to build some of the projects.

Code Download and Errata
Packt Anytime, Anywhere
Register Books
Print Upgrades
eBook Downloads
Video Support
Contact Us
Awards Voting Nominations Previous Winners
Judges Open Source CMS Hall Of Fame CMS Most Promising Open Source Project Open Source E-Commerce Applications Open Source JavaScript Library Open Source Graphics Software
Resources
Open Source CMS Hall Of Fame CMS Most Promising Open Source Project Open Source E-Commerce Applications Open Source JavaScript Library Open Source Graphics Software