https://www.jianshu.com/p/56929416b4a1
0 Raspberry Pi is set in the root directory of the SD card to expand to the entire
Command line interface to enter commands into the Raspberry Pi configuration interface. Using the arrow keys and left and right cursor key switch position.
In other source
sudo nano /etc/apt/sources.list
In the beginning of the first line plus one #
after the next copy the contents of the last row, as shown in the results:
deb http://mirrors.tuna.tsinghua.edu.cn/raspbian/raspbian/ stretch main contrib non-free rpi
deb-src http://mirrors.tuna.tsinghua.edu.cn/raspbian/raspbian/ stretch main contrib non-free rpi
Press on the keyboard ctrl
+ o
, press Enter to save, press ctrl
+ x
to exit nano editor back to the command line interface. Then enter the following command to update to the latest software mirroring Tsinghua list.
sudo apt-get update
To pip change source
sudo mkdir ~/.pip
ls .pip
sudo nano pip.conf
Enter the following in the open file:
[global]
timeout = 10
index-url = http://mirrors.aliyun.com/pypi/simple/
extra-index-url= http://pypi.douban.com/simple/
[install]
trusted-host=
mirrors.aliyun.com
pypi.douban.com
Press on the keyboard ctrl
+ o
, press Enter to save, press ctrl
+ x
to exit nano editor back to the command line interface.
2 opening function ssh pin serial port spi etc.
Raspberry Pi internal settings
Command line interface to enter commands into the Raspberry Pi configuration interface. Using the arrow keys and left and right cursor key switch position.
sudo raspi-config
Interfacing Options
Open the Camera, SSH, VNC, Serial, Remote GPIO
Advanced Options
- Select Expand Filesystem, will be extended to the root directory of the SD card, make full use of the SD memory card. Without this step, subsequent commands will be stuck. Exit setup interface, restart the raspberry pie.
3 Chinese Typing hair
Install Chinese fonts
sudo apt-get install fonts-wqy-zenhei
Fcitx installed Chinese input method and Google Pinyin input method (takes about five minutes)
sudo apt-get install Fcitx Fcitx googlepinyin Fcitx-module-Cloudpinyin Fcitx Sunpinyin
After installation, you can restart. ctrl + Chinese input method is switched to the space
4 to replace python2.7 3.7
Raspberry Pi comes python2 and 3 versions, to use the words of 3, had to specifically knock python3, pip3 so a series of instructions
But python2 we basically have not learned
So delete python2.7, enter:
sudo apt-get autoremove python2.7
After unloading, we found python3 want to use the time, I had to knock python3
Want to knock out directly python3 python, then the first link python deleted:
sudo rm /usr/bin/python
Upload a new link:
sudo ln -s /usr/bin/python3.7 /usr/bin/python
View Version:
python
It is shown below:
Python 3.7.3 (default, Apr 3 2019, 05:39:12) [GCC 8.2.0] on linux Type "help", "copyright", "credits" or "license" for more information.