Blog

Introducing libgpiod

Wednesday, 15 Sep 2021  |  Nathan Drude

Variscite is introducing support for libgpiod, the new and recommended way for accessing GPIO from userspace. libgpiod was introduced in Linux 4.8 and provides both command line utilities and library bindings for C/C++ and Python. Variscite has added libgpiod support to all software releases starting from Yocto Dunfell, Boot2Qt Dunfell, and Debian Bullseye.

Previously, the recommended way of accessing GPIOs from Linux userspace was using the GPIO sysfs interface, which is limited and requires custom userspace libraries for higher level programming languages like C, C++, Python, etc.

Moving forward, the sysfs interface is being deprecated. For now, it will continue to be maintained, but no new features will be added. Please monitor the kernel documentation for the latest information.

Instead, it is now recommended to use libgpiod.
libgpiod has several significant improvements over the GPIO sysfs interface:

  • Userspace libraries for C/C++ and Python provide a standardized API
  • Each GPIO controller is registered as a character device in /dev so GPIO allocation is tied to the process that is using it
  • Multiple GPIO pins can be read at once
  • GPIO controllers and pins can be found by name
  • GPIO pin settings can be configured at runtime (pull-up, pull-down, etc.)
  • Interrupt driven event monitoring (rising, falling, etc.)
DART-MX8M-PLUS
DART-MX8M-PLUS System on Module

 

For more information about using libgpiod, check out the DART-MX8M-PLUS GPIO sample guide or visit the ‘how to’ section on the chosen SoM and Yocto release page within Variscite’s wiki website.

Latest Posts
Software releases
November 2026 Software Releases for Variscite SoMs
Stay current with software updates – Keep your Variscite SoMs performing at their best with our latest software releases.
 
Newsroom
Variscite VAR-SMARC-MX952 module shown at an angle, with its gold edge connector visible.
Variscite has announced two new SoMs built around NXP’s i.MX 952 applications processor: the DART-MX952 and the VAR-SMARC-MX952. Both bring AI/ML acceleration, vision processing, 4K display output, and hardware-level security. They come in two form factors, each with its own memory technology: DART with LPDDR4 and VAR-SMARC with LPDDR5, allowing embedded engineers to pick the combination that best suits their project.
Embedded products keep taking on more demanding features, and each one adds load to the main processor. A single design may need to handle real-time control, process images, render advanced graphics, run a touchscreen interface, and keep the system secure, often all at once and within a fixed power and cost envelope.
Blog
DART-MX8M-PLUS System on Module (SoM)
Pierluigi Passaro, Variscite’s R&D engineer, introduces the VAR-SMARC-MX8M-PLUS and DART-MX8M-PLUS, two Systems on Module based on the NXP i.MX 8M Plus. Both modules use the same processor and BSP, giving developers a common software base and a choice of form factors and interfaces.