Programming on Raspberry Pi with Python: Raspberry Pi Setup
Anurag Rana
Posted on July 16, 2019
This article was originally published on pythoncircle.com
We are going to start a series of articles 'Programming on Raspberry Pi with Python'. In this series, we will write weekly articles about mini-projects you can build using Python programming on Raspberry Pi.
This is the first article in the series where we will walk you through the initial setup of Raspberry pi. After the initial setup, we will be ready to write the first Python program on Raspberry Pi.
We are using the Raspberry Pi 3 B+ model.
What is Raspberry Pi:
Raspberry Pi is a low-cost fully-functional single-board computer with a Broadcom processor and with programmable I/O pins where you can attach physical devices and sensors. On Raspberry Pi, you can run an operating system like Linux, FreeBSD, and even Windows 10 from a micro SD card. Plug it into a monitor, keyboard, and a mouse, you have a full graphical user-interface of an OS of your choice.
What can we build using Raspberry Pi:
What can be achieved using Raspberry Pi and Python Programming is limited by our imagination only. The Internet is full of articles on building different projects using Raspberry Pi. Few of them are:
- Motion detection and notification
- Home Automation
- Build your Amazon echo
- FM transmitter
- Twitter bot
- Remote-controlled car
- And n more such projects
Where to start:
To start experimenting we need below equipment.
- Raspberry Pi
- MicroSD card
- LAN Cable
- Power Adaptor
- HDMI Cable to connect to Monitor
- USB Keyboard and Mouse
There are few items which are optional as of now but will be required at the later stage.
- Raspberry Pi case
- Breadboard
- Jumper wires
- LED
- Resistors
Purchasing items in the first list separately will be costly. You can purchase the starter kit provided by CanaKit from Amazon.com or from Amazon.in.
Setting up:
Step 1: Formatting SD card.
If you purchased the CanaKit from Amazon.com then you can skip this step as they deliver the preloaded SD card. If not then proceed.
- Insert the SD card in your system and format it.
- Download the Noobs zip file from raspberrypi.org and extract its content in a folder.
- Copy the content of the folder (not the folder itself) to SD card.
- Remove the SD card.
Step 2: Installing Raspbian
- Insert the SD card in Raspberry Pi. Attach the USB keyboard and mouse. Attach the monitor using HDMI cable.
- Plug-in ethernet wire in ethernet port.
- Plug-in the power source.
- As soon as the power source is plugged in, Raspberry Pi will boot. On the screen, a list of operating systems to install will appear. Select the Raspbian.
- Just wait while OS is being installed.
- After Installation, login into it using default username
pi
and default passwordraspberry
.
Step 3: Update:
- Open terminal.
- Update your system package list using the command
sudo apt-get update
. - Upgrade all installed packages to the latest version using the command
sudo apt-get upgrade
.
That's it for now. You can play with it. Make yourself familiar with it.
Raspberry pi is a small computer. If we need to attach a large monitor to it all the time to work on it, then we are not using it efficiently.
In the next part of this article we will see:
- How to configure wifi settings
- How to enable SSH
- How to connect to a wifi network on reboot
- How Raspberry pi will tell us its IP address after each reboot so that we can SSH into it.
- And few more configurations.
These configurations will help us controlling the Raspberry Pi from our laptop. We can place the Raspberry Pi anywhere and SSH into it from our system and build projects without the requirement of monitor and ethernet cable.
Next Article: Configuring WIFI and enabling SSH on Raspberry Pi
Purchase Raspberry Pi Starter Kit Here.
This article was originally published on pythoncircle.com
Posted on July 16, 2019
Join Our Newsletter. No Spam, Only the good stuff.
Sign up to receive the latest update from our blog.
Related
October 6, 2024