RPi-1.54inch-LCD
構築済イメージ
ストレージ容量
イメージは8GBなのでSDカードの容量に合わせて拡張しておく。
$ sudo raspi-config --expand-rootfs
Key
code:key.c
char KEY[]={4,9,15,16,21,22,23,24,25,26,27,28,29};
unsigned char i;
int main(){
if (wiringPiSetup() < 0)return 1 ;
for(i=0;i<13;i++)
{
pinMode (KEYi,INPUT) ;//pinMode (LED, OUTPUT) ; pullUpDnControl(KEYi, PUD_UP); }
while(1)
{
if (digitalRead (KEY0) == 0) {
printf ("tl \n") ;
ドライバインストール
ドライバのインストールに失敗した後起動しなくなった。
-> 構築済イメージを使った。
code:err
$ sudo ./LCD154-show
Reading package lists... Done
Building dependency tree
Reading state information... Done
The following NEW packages will be installed:
xserver-xorg-input-evdev
0 upgraded, 1 newly installed, 0 to remove and 22 not upgraded.
Need to get 117 kB of archives.
After this operation, 170 kB of additional disk space will be used.
Fetched 117 kB in 1s (102 kB/s)
Selecting previously unselected package xserver-xorg-input-evdev.
(Reading database ... 105030 files and directories currently installed.)
Preparing to unpack .../xserver-xorg-input-evdev_1%3a2.10.6-1+b1_armhf.deb ...
Unpacking xserver-xorg-input-evdev (1:2.10.6-1+b1) ...
Setting up xserver-xorg-input-evdev (1:2.10.6-1+b1) ...
Processing triggers for man-db (2.8.5-2) ...
Selecting previously unselected package xinput-calibrator.
(Reading database ... 105040 files and directories currently installed.)
Preparing to unpack .../xinput-calibrator_0.7.5-1_armhf.deb ...
Unpacking xinput-calibrator (0.7.5-1) ...
Setting up xinput-calibrator (0.7.5-1) ...
Processing triggers for gnome-menus (3.31.4-3) ...
Processing triggers for desktop-file-utils (0.23-4) ...
Processing triggers for mime-support (3.62) ...
Processing triggers for man-db (2.8.5-2) ...
Reading package lists... Done
Building dependency tree
Reading state information... Done
The following additional packages will be installed:
cmake-data libjsoncpp1 librhash0 libuv1
Suggested packages:
cmake-doc ninja-build
The following NEW packages will be installed:
cmake cmake-data libjsoncpp1 librhash0 libuv1
0 upgraded, 5 newly installed, 0 to remove and 23 not upgraded.
Need to get 4,330 kB of archives.
After this operation, 21.8 MB of additional disk space will be used.
Fetched 4,330 kB in 5s (845 kB/s)
Selecting previously unselected package cmake-data.
(Reading database ... 105049 files and directories currently installed.)
Preparing to unpack .../cmake-data_3.13.4-1_all.deb ...
Unpacking cmake-data (3.13.4-1) ...
Selecting previously unselected package libjsoncpp1:armhf.
Preparing to unpack .../libjsoncpp1_1.7.4-3_armhf.deb ...
Unpacking libjsoncpp1:armhf (1.7.4-3) ...
Selecting previously unselected package librhash0:armhf.
Preparing to unpack .../librhash0_1.3.8-1_armhf.deb ...
Unpacking librhash0:armhf (1.3.8-1) ...
Selecting previously unselected package libuv1:armhf.
Preparing to unpack .../libuv1_1.24.1-1_armhf.deb ...
Unpacking libuv1:armhf (1.24.1-1) ...
Selecting previously unselected package cmake.
Preparing to unpack .../cmake_3.13.4-1_armhf.deb ...
Unpacking cmake (3.13.4-1) ...
Setting up libuv1:armhf (1.24.1-1) ...
Setting up librhash0:armhf (1.3.8-1) ...
Setting up cmake-data (3.13.4-1) ...
Setting up libjsoncpp1:armhf (1.7.4-3) ...
Setting up cmake (3.13.4-1) ...
Processing triggers for man-db (2.8.5-2) ...
Processing triggers for libc-bin (2.28-10+rpi1) ...
CMake Error: The current CMakeCache.txt directory /home/pi/camera-test/LCD-show/rpi-fbcp/build/CMakeCache.txt is different than the directory /home/pi/LCD-show/rpi-fbcp/build where CMakeCache.txt was created. This may result in binaries being created in the wrong place. If you are not sure, reedit the CMakeCache.txt
CMake Error: The source "/home/pi/camera-test/LCD-show/rpi-fbcp/CMakeLists.txt" does not match the source "/home/pi/LCD-show/rpi-fbcp/CMakeLists.txt" used to generate cache. Re-run cmake with a different source directory.
CMake Error: The source directory "/home/pi/LCD-show/rpi-fbcp" does not exist.
Specify --help for usage, or press the help button on the CMake GUI.
LCD configrue 0
reboot now