Raspberry pi
An Introduction
What is Raspberry pi
 Credit card sized computer with incredible features
SOC HDMI ETHERNET
GPIO
USP?
 Model A = $25
 Model B = $35
 Uses low power SOC (System on Chip) Broadcom
BCM2835
 BCM2835 supports applications from word
processing, web-browsing to 3D gaming
 Linux OS
 Industry standard for prototyping IOT applications
We’re excited to announce that we are expanding our Windows
Developer Program for IoT by delivering a version of Windows 10
that supports Raspberry Pi 2 -Microsoft
Brains of PI
 ARM1176JZF is the central nervous system of PI
 This means any language that can compile on
ARMv6 can be used with raspberry pi
Features of PI
 SOC powerful enough to easily render
opengl 3D graphics, games and other
multimedia applications
 512 MB of ram
 Low power consumption (micro USB few
watts)
 Built in support for Camera module
 40 GPIOs
 4 USB ports
 Audio output
 SD card (primary storage device)
GPIO general purpose IO
 Raspberry pi model B+ has a set of
about 40 GPIOs
What is a GPIO?
 A GPIO is a terminal for electronic
signals which can act as source or
sink of signals.
 Signals may be both control as well as
data signals
 Plays an important role in automation
applications
 Python package required to use GPIO
from raspberry pi
sudo apt-get install python-RPi.GPIO
BCM vs Board-mode
 Board mode means to refer to the pin-
number via it’s position on the board
starting from 1-40
 In BCM mode we refer to the pin
names rather than by numbers. It is
based on Broadcom SOC channel
number
Words of Caution !!
 While working with GPIO it is
important to keep in mind that they are
directly connected to the micro-
processor
 Means NO overhead protection
 If a high current/voltage signal is
applied to the pin, It may burn the PI
Booting up the Raspberry
 Step-1 “Choice of OS”
Where to get??
 http://www.raspberrypi.org/downloads/
For windows and linux users
 Download the zip file and extract the OS image
 Insert sd card in the sd card reader
 Use Win32DiskImager to write to the sd card
 Detailed instructions can be found on the raspberry pi
website:
 http://www.raspberrypi.org/documentation/installati
on/installing-images/windows.md
 For Linux Users:
 http://www.raspberrypi.org/documentation/installati
on/installing-images/linux.md
 Caution: Linux users should be very careful with
the use of DD command.
NOOBS Project
 “New Out Of The Box Software” for beginners
 It gives you the options to choose from different
operating systems
 Download NOOBS zip file and extract it
 Format SD card and “drag/drop files into it”
 On first boot we see a screen like this
For Lazy Coders
 Perhaps the most easy way to get
started with Raspberry PI
 Buy an SD card with NOOBS pre-
installed and plug it into the pi
 Saves you a lot of time if you are more
concerned about app development
Monitor, mouse and keyboard
 Raspberry pi supports High Definition
video output through HDMI port
 We can use our HD TV as a monitor
for raspberry pi
 Raspberry pi has 4 usb ports and any
2 can be used to connect a mouse
and a keyboard
I can’t take LED with me all the
time
 Relax we have a solution !!
 Now edit the IPv4 settings in windows
also So they are both in same local
network
Edit: /etc/network/interfaces
SSH into your pi
 Use an ssh client e.g. PUTTY
 ssh pi@192.168.137.10
 Enter the password of your raspberry
pi
 Start Exploring
Why Pi is choice of IOT
industry
 Raspberry Pi is a good starting point for home and
industry automation prototypes
 Because >>
 Ease of Use
 Cost Effective
 Can be programmed easily to do
powerful things
Pi Onboard Camera Module
 Enables pi to see things around
About the camera
 Sensor type: OmniVision OV5647
 Sensor size: 3.67 x 2.74 mm
 Pixel Count: 2592 x 1944
(5megapixel)
 Pixel Size: 1.4 x 1.4 um
 Video: 1080p at 30 fps with codec
H.264
 Connects to Raspberry via CSI
interface
Using camera to capture
images
 raspistill [options]
 -?, --help : This help information
 -o, --output : Output filename
<filename>
 -v, --verbose : Output verbose
information during run
 -d, --demo : Run a demo mode (cycle
through range of camera options, no
capture)
 -sh, --sharpness : Set image sharpness
(-100 to 100)
More options
 -ex, --exposure : Set exposure mode
 Exposure mode options :
auto,night,nightpreview,backlight,spotli
ght,sports,snow,beach,verylong,fixedf
ps,antishake,fireworks
Video options
 raspivid [options]
 -o, --output : Output filename
<filename>
 -t, --timeout : Time (in ms) to capture
for. If not specified, set to 5s
 Example USAGE: raspivid –o
sample.mp4
Pi Relay Module
 Lets control the world of Alternating
Current AC
Mapping from PI to Relay
 5V output from Pi to VCC pin of Relay
 Ground to Ground of relay
 {
GPIO => Relay
}
We can use any GPIO as long as it is
not meant for other purposes

Raspberry pi

  • 1.
  • 3.
    What is Raspberrypi  Credit card sized computer with incredible features SOC HDMI ETHERNET GPIO
  • 4.
    USP?  Model A= $25  Model B = $35  Uses low power SOC (System on Chip) Broadcom BCM2835  BCM2835 supports applications from word processing, web-browsing to 3D gaming  Linux OS  Industry standard for prototyping IOT applications We’re excited to announce that we are expanding our Windows Developer Program for IoT by delivering a version of Windows 10 that supports Raspberry Pi 2 -Microsoft
  • 5.
    Brains of PI ARM1176JZF is the central nervous system of PI  This means any language that can compile on ARMv6 can be used with raspberry pi
  • 6.
    Features of PI SOC powerful enough to easily render opengl 3D graphics, games and other multimedia applications  512 MB of ram  Low power consumption (micro USB few watts)  Built in support for Camera module  40 GPIOs  4 USB ports  Audio output  SD card (primary storage device)
  • 7.
    GPIO general purposeIO  Raspberry pi model B+ has a set of about 40 GPIOs
  • 8.
    What is aGPIO?  A GPIO is a terminal for electronic signals which can act as source or sink of signals.  Signals may be both control as well as data signals  Plays an important role in automation applications  Python package required to use GPIO from raspberry pi sudo apt-get install python-RPi.GPIO
  • 9.
    BCM vs Board-mode Board mode means to refer to the pin- number via it’s position on the board starting from 1-40  In BCM mode we refer to the pin names rather than by numbers. It is based on Broadcom SOC channel number
  • 10.
    Words of Caution!!  While working with GPIO it is important to keep in mind that they are directly connected to the micro- processor  Means NO overhead protection  If a high current/voltage signal is applied to the pin, It may burn the PI
  • 11.
    Booting up theRaspberry  Step-1 “Choice of OS”
  • 12.
    Where to get?? http://www.raspberrypi.org/downloads/
  • 13.
    For windows andlinux users  Download the zip file and extract the OS image  Insert sd card in the sd card reader  Use Win32DiskImager to write to the sd card  Detailed instructions can be found on the raspberry pi website:  http://www.raspberrypi.org/documentation/installati on/installing-images/windows.md  For Linux Users:  http://www.raspberrypi.org/documentation/installati on/installing-images/linux.md  Caution: Linux users should be very careful with the use of DD command.
  • 14.
    NOOBS Project  “NewOut Of The Box Software” for beginners  It gives you the options to choose from different operating systems  Download NOOBS zip file and extract it  Format SD card and “drag/drop files into it”  On first boot we see a screen like this
  • 15.
    For Lazy Coders Perhaps the most easy way to get started with Raspberry PI  Buy an SD card with NOOBS pre- installed and plug it into the pi  Saves you a lot of time if you are more concerned about app development
  • 16.
    Monitor, mouse andkeyboard  Raspberry pi supports High Definition video output through HDMI port  We can use our HD TV as a monitor for raspberry pi  Raspberry pi has 4 usb ports and any 2 can be used to connect a mouse and a keyboard
  • 17.
    I can’t takeLED with me all the time  Relax we have a solution !!  Now edit the IPv4 settings in windows also So they are both in same local network Edit: /etc/network/interfaces
  • 18.
    SSH into yourpi  Use an ssh client e.g. PUTTY  ssh pi@192.168.137.10  Enter the password of your raspberry pi  Start Exploring
  • 19.
    Why Pi ischoice of IOT industry  Raspberry Pi is a good starting point for home and industry automation prototypes  Because >>  Ease of Use  Cost Effective  Can be programmed easily to do powerful things
  • 20.
    Pi Onboard CameraModule  Enables pi to see things around
  • 21.
    About the camera Sensor type: OmniVision OV5647  Sensor size: 3.67 x 2.74 mm  Pixel Count: 2592 x 1944 (5megapixel)  Pixel Size: 1.4 x 1.4 um  Video: 1080p at 30 fps with codec H.264  Connects to Raspberry via CSI interface
  • 22.
    Using camera tocapture images  raspistill [options]  -?, --help : This help information  -o, --output : Output filename <filename>  -v, --verbose : Output verbose information during run  -d, --demo : Run a demo mode (cycle through range of camera options, no capture)  -sh, --sharpness : Set image sharpness (-100 to 100)
  • 23.
    More options  -ex,--exposure : Set exposure mode  Exposure mode options : auto,night,nightpreview,backlight,spotli ght,sports,snow,beach,verylong,fixedf ps,antishake,fireworks
  • 24.
    Video options  raspivid[options]  -o, --output : Output filename <filename>  -t, --timeout : Time (in ms) to capture for. If not specified, set to 5s  Example USAGE: raspivid –o sample.mp4
  • 25.
    Pi Relay Module Lets control the world of Alternating Current AC
  • 26.
    Mapping from PIto Relay  5V output from Pi to VCC pin of Relay  Ground to Ground of relay  { GPIO => Relay } We can use any GPIO as long as it is not meant for other purposes