Problem Description
Raspberry Pi information:
#4B#
#64位#
#aarch#
- cmmand not foung is displayed when using the
gpio -v
or commandgpio readall
- After installing RPi.GPIO (installation command:
pip install RPi.GPIO
), you still cannot use the above command. - After installing wiringpi, an error is reported
wiringpi:armhf
Cause Analysis:
The 64-bit Raspberry Pi cannot directly use
pip install wiringpi
the command to install wiringpi, otherwise the installation will be incompatible with the armhf architecture.
solution:
- Completely uninstall the incorrectly installed wiringpi
sudo apt-get remove wiringpi
sudo apt-get purge wiringpi
hash -r
- Install the wiringpi version suitable for 64-bit ARM architecture
sudo apt-get update
sudo apt-get install git-core
git clone https://github.com/WiringPi/WiringPi.git
cd WiringPi
./build
不必担心连不上github,因为安装了git-core包可以直接克隆代码库