Libraries Installation for RPi

From Waveshare Wiki
Revision as of 09:24, 7 June 2017 by Wiki Editorial Team (Talk | contribs)

(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to: navigation, search

Libraries Installation for RPi

Open the terminal of Raspberry Pi and install libraries as guides below

Install WiringPi Library

cd
sudo apt-get install wiringpi
wget https://project-downloads.drogon.net/wiringpi-latest.deb
sudo dpkg -i wiringpi-latest.deb
gpio -v

Install C Library bcm2835

cd
wget http://www.airspayce.com/mikem/bcm2835/bcm2835-1.60.tar.gz
tar zxvf bcm2835-1.60.tar.gz 
cd bcm2835-1.60/
sudo ./configure
sudo make && sudo make check && sudo make install

For more information and the newest libraries please refer to website:http://www.airspayce.com/mikem/bcm2835/

Install Python Library

sudo pip3 install pillow
sudo pip3 install numpy
sudo apt-get install libopenjp2-7
sudo apt install libtiff
sudo apt install libtiff5
sudo apt-get install libatlas-base-dev
For python2
cd
sudo apt-get update
sudo apt-get install python-pip
sudo pip install RPi.GPIO
For python3
cd
sudo apt-get update
sudo apt-get install python3-pip
sudo pip3 install RPi.GPIO