WiringPi for Linux
Compatible with: Unosquare.Raspberry.IO 0.17.2
-
Open with nano or through GUI file: /boot/firmware/cmdline.txt
-
Add following string at the end: iomem=relaxed
-
Final result should look like that:
-
console=tty0 console=ttyS1,115200 root=/dev/mmcblk0p2 rw fsck.repair=yes net.ifnames=0 cma=64M rootwait iomem=relaxed
-
Reboot to take effect (this steps are valid also for PiGPIO)
https://github.com/WiringPi/WiringPi/tree/final_official_2.50 https://github.com/sakaki-/genpi64-overlay/tree/master/dev-embedded/wiringpi/files
-
Clone 2.50 repo
-
#depth 1 in order to avoid downloading commits history git clone --depth 1 --branch final_official_2.50 https://github.com/WiringPi/WiringPi.git
-
Download also 2.44-pseudo-cpuinfo.patch from second link (name is not important)
-
Paste downloaded .patch file into cloned directory
-
patch -u < 2.44-pseudo-cpuinfo.patch
-
./build
-
Test all works (you should see a table if all ok):
-
gpio readall
-
Already patched GPIO version will be packed in Parko/Distrib/Utilities_Software/RaspberryPi
-
#if wiringpi tells you have nothing in /etc/wiringpi/cpuinfo sudo mkdir /etc/wiringpi sudo cp /proc/cpuinfo /etc/wiringpi/cpuinfo
-
Making compiled WiringPi usable by C# actual unosquare.wiringPi
-
sudo ln -s /usr/local/lib/libwiringPi.so.2.50 /usr/lib/liblibwiringPi.so.2.50