Ceci est une ancienne révision du document !
Welcome fellow pythoners. As the kids here in the central parts of the U.S. say, “What’s Shakin’ Bacon?” I’m not exactly sure what that’s supposed to mean, but I assume it’s a good thing.
You might notice the new header. I decided that I’ve taught you all the basics of Python that I can for “general” programming, so now we are going to delve into using Python to talk to other types of computers and controllers, like the Raspberry Pi and the Arduino micro controller. We’ll look at things like temperature sensors, controlling motors, flashing LEDs and more.
This issue we will be focusing on what we’ll need to do this and focus on a few of the projects we will be looking at in the future. Next issue, we will start the first project.
One of the things we will talk about next time will be the Raspberry Pi. The Pi is a credit-card sized computer that natively runs Linux on an SD card. Its output goes to your TV set via HDMI. It also has an Ethernet connection for Internet access.
You can find out more at the official site https://www.raspberrypi.org. If you want to follow along with the projects, you will need a Pi, SD card, Keyboard, Mouse, a 5volt DC power supply like the ones on modern cell phones, and access to an HDMI monitor or TV. Eventually, you should also consider getting a breadboard and some connecting wires for when we start to interface to the outside world. You can find any number of places that sell the Pi on the Internet. Here in the U.S., we can get them for around $35.
One other thing about the Pi is that it provides access to a series of pins that support GPIO (General Purpose Input/Output). Basically, this means that you can write programs that will send signals to the output pins and read the signals from the input pins. This can be used to interface to things like LEDs, sensors, push buttons, etc. Many people have made home automation systems, multiple processor systems (by linking 40 or so Pi computers together to emulate a supercomputer), weather stations, even drones. So you can imagine that the possibilities are endless. That’s why I decided to start with it for this series of articles.
After a while, we will begin to work with the Arduino, which according to the official website (https://www.arduino.cc): “Arduino is an open-source electronics platform based on easy-to-use hardware and software. It's intended for anyone making interactive projects”.
Once again, this is an exciting device to work with. In this part of the series, we will look at talking to the Arduino, first in its native scripting language, and then in Python and eventually interfacing the Pi with the Arduino.
I know this month’s article is fairly short, but I’ve been doing poorly health-wise, so I’m saving my strength for the next article. Until then, grab some electronics and get ready for fun!