Building on Raspberry Pi - alex-konshin/f007th-rpi GitHub Wiki
If you want to enable MQTT support (this is not usual) then please read this special instruction.
- You need to install libcurl and microhttpd libraries.
sudo apt-get update sudo apt-get install libcurl4-openssl-dev libmicrohttpd-dev
- If you want to use pigpio library then you need to install it.
Note: It is recommended do not use pigpio but use gpio-ts driver. The driver works better and creates less load to Raspberry Pi CPU.
sudo apt-get install pigpio
- Clone sources from GitHub. The following command will create new sub-directory f007th-rpi in the current directory and download sources
git clone https://github.com/alex-konshin/f007th-rpi.git
- Build
/bin/bash f007th-rpi/build.sh
- Executables are created in directory
f007th-rpi/bin
.
Re-building or updating the utility
If you later will need to update/upgrade the utility with newest changes then you just have to do the following:
-
Make sure that the utility is not running. Use command
pkill f007th-send
(orpkill f007th-rpi_send
if you run this executable) to stop the utility. You can check that the utility is running by commandpgrep f007th-send
(orpkill f007th-rpi_send
if you use this executable). -
Update your Git repository (we assuming that utility sources are located in
~/f007th-rpi
):cd ~/f007th-rpi git pull
-
Re-build binaries
/bin/bash ~/f007th-rpi/build.sh
Executables will be copied in folder
~/f007th-rpi/bin
-
If something went wrong then it is better to build the utility from scratch:
- Don't forget to copy your configuration files to some other directory if they are located in
~/f007th-rpi
. - Go to your home directory (actually to any directory except the directory with utility sources)
cd ~
- Delete sources directory with command
rm -R ~/f007th-rpi
- Re-clone sources with command
git clone https://github.com/alex-konshin/f007th-rpi.git
- Re-build binaries with command
/bin/bash ~/f007th-rpi/build.sh
- Restore your configuration file.
- Don't forget to copy your configuration files to some other directory if they are located in