Move the kernel version tuple calculation out of gpio.py into
the utils package so its available for any module that requires
it. In addition, report the kernel version string with the distribution
info and log the platform in the rollover header.
Signed-off-by: Eric Callahan <arksine.code@gmail.com>
The python-periphery library XORs the initial value based on
whether or not its inverted. This requires consumers to set
the direction to "high" for inverted pins that are off, and
"low" otherwise.
Signed-off-by: Eric Callahan <arksine.code@gmail.com>
Use a traditional debouncing method, waiting for a specified
debounce period before triggering events. Consumers may
choose to futher ignore events based on the the duration
between events.
Signed-off-by: Eric Callahan <arksine.code@gmail.com>
The libgpiod library has breaks API compatibility with version 2.
Given that not all distributions ship gpiod and its unique nature
as a system package, replace it with a wrapper that directly
accesses the GPIO character device.
Signed-off-by: Eric Callahan <arksine.code@gmail.com>