The Raspberry Pi is a credit-card-sized single-board computer developed in the UK by the Raspberry Pi Foundation with the intention of promoting the teaching of basic computer science in schools
A good place to start is the Raspberry PI quick start guideÂ This will describe the different components on the board and what they can be used for.
Downloading, installing and perparingÂ the Raspberry PI OS
The Raspberry PI will run several different specialty prepared versions of Linux that have been compiled specifically for the Raspberry PI. The Raspberry PI team have created a image of several different compatible Raspberry PI Operating systems that can fit on a 4gb SD card. They called this imageÂ New Out of Box Software (NOOBS) and it can be downloaded from theÂ Raspberry PI main site. The NOOBS Image makes this whole process a lot easier.
- Format your SD card using the SD Card Associationâ€™s formatting tool.Â https://www.sdcard.org/downloads/formatter_4/Â
- Download the NOOBS image file
- Unpack the NOOBS zip file onto the SD card (in to the root not a sub directory)
- Insert the SD card in to the Raspberry PI, Connect the monitor, keyboard and power.
For this tutorial we will be using theÂ Raspbian OS. Raspbian is an unofficial port of Debian Wheezy and has been specifically modified to work with the Raspberry PI. Its also part of the NOOBS image provided by the Raspberry PI team.
- On start up you will be asked what OS you want to boot to, Select theÂ Raspbian OS
- After the RaspbianÂ has been installed, Your Raspberry PI should restart and display the Rasppi-Configuration screen. Select “advanced options” from the menu and change the Host name to something unique. The new hostname will not come in to effect until you restart your device.
- Before restarting your Raspberry PI, write down its MAC address (HWaddr) and IP address (inet addr)
- Restart your Raspberry PI
Connecting to your Raspberry PI with SSH (running headless)Â
By default theÂ Raspbian OS comes with SSH enabled. This allows us to run the Raspberry PI without a monitor or keyboard (headless) and connect to it from another computer (our laptops) remotely.
If you are on windows you can use Putty (Â http://www.putty.orgÂ )Â as your SSH client. MAC and Linux both have built in SSH clients.
The default username is pi and the password is raspberry
Installing the AdaFruit WebIDE
The instructions on AdaFruit’s website are straight forward with plenty of pictures.
Raspberry PI and the GPIO pins
You can also make your own.Â Hardware lesson with Gert: make your own ribbon cable connector.
Since I am usingÂ bitbucketÂ all my source code is public. I created a few learning scripts to understand how the GPIO pins work on the Raspberry PI. The first script I made was a simpleÂ blinking LED, just like theÂ arduino blinking LED script. Next was to read theÂ current state of a switchÂ and print the results to the screen.
# Blinkly Script
# This script will blink a LED ON and OFF again.
# Created on Feb 2, 2013 by Steven Smethurst
# Version: 1.00
# Connect a LED between Pin 6 ( Ground) and pin 12 (GPIO18)
from time import sleep
import RPi.GPIO as GPIO
# print about info
print "Blinky script, v1.0"
GPIO.setup(12, GPIO.OUT )
GPIO.output(12, GPIO.HIGH )
GPIO.output(12, GPIO.LOW )