This is work based on work done by Matthew Robinson (https://github.com/mttrb)
Enable spi interface with raspi-config before building. Also define version to build in the Makefile before building as of below
- WIRINGPI - using the wiringpi library
- PIGPIO - using the pigpio library (must be root)
- PIGPIOIF2 - using the pigpio library and the pigpiod daemon (user space available)
The pigpio library is described here
On Debian systems install with
sudo apt install pigpio pigpiod
The pigpiod daemon must be running to run this codde. To have it started on boot
sudo systemctl enable pigpiod
Manually start service with
sudo systemctl start pigpiod
and stop with
sudo systemctl start pigpiod
Copyright -2018 Matthew Robinson - https://github.com/mttrb Copyright 2018-2022 Changes and VSCP demo adoption Ake Hedman, Grodans Paradis AB