Kalet的技术文档 Kalet的技术文档,涉及.NET、Andriod、Arduino、Python的软件开发,所有资料均从网络复制,版权归原著者所有。

[原创]树莓派安装软件

在  SD卡 中建一个ssh空文件,打开默认SSH


$ sudo nano /etc/apt/sources.list

 

deb http://mirrordirector.raspbian.org/raspbian/ stretch main contrib non-free rpi
# Uncomment line below then 'apt-get update' to enable 'apt-get source'
#deb-src http://archive.raspbian.org/raspbian/ stretch main contrib non-free rpi


 修改内容为清华大学源

deb http://mirrors.tuna.tsinghua.edu.cn/raspbian/raspbian/ stretch main contrib non-free
deb-src http://mirrors.tuna.tsinghua.edu.cn/raspbian/raspbian/ stretch main contrib non-free

Ctrl+O保存,回车,Ctrl+X退出


sources.list


deb http://mirrors.ustc.edu.cn/raspbian/raspbian/ stretch main contrib non-free rpi 

deb-src http://mirrors.ustc.edu.cn/raspbian/raspbian/ stretch main contrib non-free rpi


/etc/apt/sources.list.d/raspi.list


deb http://mirrors.ustc.edu.cn/archive.raspberrypi.org/ stretch main ui


非该版本请自行打开(/etc/apt/sources.list 和 /etc/apt/sources.list.d/raspi.list)替换网址即可


2.其它源:( 并未测试!)
中山大学 Raspbian http://mirror.sysu.edu.cn/raspbian/raspbian/

清华大学 Raspbian http://mirrors.tuna.tsinghua.edu.cn/raspbian/raspbian/

华中科技大学 Raspbian http://mirrors.hustunique.com/raspbian/raspbian/ Arch

Linux ARM http://mirrors.hustunique.com/archlinuxarm/

大连东软信息学院源(北方用户) Raspbian
http://mirrors.neusoft.edu.cn/raspbian/raspbian/

重庆大学源(中西部用户) Raspbian http://mirrors.cqu.edu.cn/Raspbian/raspbian/


ubuntu源

 

deb http://ports.ubuntu.com/ xenial main restricted universe multiverse
deb-src http://ports.ubuntu.com/ xenial main restricted universe multiverse

deb http://ports.ubuntu.com/ xenial-updates main restricted universe multiverse
deb-src http://ports.ubuntu.com/ xenial-updates main restricted universe multiverse

deb http://ports.ubuntu.com/ xenial-security main restricted universe multiverse
deb-src http://ports.ubuntu.com/ xenial-security main restricted universe multiverse

deb http://ports.ubuntu.com/ xenial-backports main restricted universe multiverse
deb-src http://ports.ubuntu.com/ xenial-backports main restricted universe multiverse

 

修改为清华大学源

 


deb http://mirrors.ustc.edu.cn/ubuntu-ports/ xenial main restricted universe multiverse

deb-src http://mirrors.ustc.edu.cn/ubuntu-ports/ xenial main restricted universe multiverse

 

deb http://mirrors.ustc.edu.cn/ubuntu-ports/ xenial-updates main restricted universe multiverse

deb-src http://mirrors.ustc.edu.cn/ubuntu-ports/ xenial-updates main restricted universe multiverse


deb http://mirrors.ustc.edu.cn/ubuntu-ports/ xenial-security main restricted universe multiverse

deb-src http://mirrors.ustc.edu.cn/ubuntu-ports/ xenial-security main restricted universe multiverse


deb http://mirrors.ustc.edu.cn/ubuntu-ports/ xenial-backports main restricted universe multiverse

deb-src http://mirrors.ustc.edu.cn/ubuntu-ports/ xenial-backports main restricted universe multiverse

 

升级更新

 

sudo apt-get update

sudo apt-get dist-upgrade

 

 

安装FTP


sudo apt-get install vsftpd


修改配置文件,并增加以下内容
sudo vim /etc/vsftpd.conf

 

local_enable=YES
write_enable=YES
local_umask=022

chroot_local_user=YES
allow_writeable_chroot=YES
local_root=/var/www/html


ESC->:wq回车


设置目录权限
sudo chown pi:ftp /var/www/html
sudo chmod o+w /var/www/html


重启服务
sudo service vsftpd restart

 

安装nginx

sudo apt-get -y install nginx

 

安装php及附加组件

sudo apt-get install apache2 php7.0

sudo apt-get install php7.0-curl php7.0-gd php7.0-imap php7.0-json php7.0-mcrypt php7.0-mysql php7.0-opcache php7.0-xmlrpc libapache2-mod-php7.0

sudo apt-get install php7.0-sqlite3

sudo apt-get install php7.0-xml


 安装mysql

sudo apt-get install -y mysql-client mysql-server

 

安装screenfetch

$ sudo apt-get install screenfetch

 

安装ST7735驱动

 

git clone https://github.com/cskau/Python_ST7735.git

 

sudo apt-get update

sudo apt-get install build-essential python-dev python-smbus python-pip python-imaging python-numpy


sudo pip install RPi.GPIO

sudo pip install Adafruit_GPIO

sudo pip install Adafruit_BBIO


sudo python setup.py install

 


安装SSD1306驱动

 

sudo apt-get update

sudo apt-get install build-essential python-dev python-pip

sudo pip install RPi.GPIO

sudo apt-get install python-imaging python-smbus

sudo apt-get install git


#clone 下国外友人提供的python库

git clone https://github.com/adafruit/Adafruit_Python_SSD1306.git

cd Adafruit_Python_SSD1306

sudo python setup.py install

 

7ZIP解压软件

 

p7zip

 

Eric代码编辑器

 

eric

Tags:

发布: Kalet 分类: Linux系统、树莓派 评论: 0 浏览: 103
留言列表