failure to connect with raspberry pi 4 with 'raspi'
41 visualizaciones (últimos 30 días)
Mostrar comentarios más antiguos
Ran Zeimer
el 7 de Dic. de 2025 a las 1:27
Respondida: Ran Zeimer
hace alrededor de 17 horas
when using raspi for a new connection i get an error that gpiod.h is not found.
i have followed all the suggections of copilot at no avail.
0 comentarios
Respuestas (4)
Taylor
el 8 de Dic. de 2025 a las 16:43
1 comentario
Ran Zeimer
el 8 de Dic. de 2025 a las 21:58
Movida: Walter Roberson
el 9 de Dic. de 2025 a las 16:20
Ran Zeimer
el 9 de Dic. de 2025 a las 0:42
2 comentarios
Taylor
el 9 de Dic. de 2025 a las 16:10
Try
% Run this on your Raspberry Pi, NOT MATLAB
sudo apt-get update
sudo apt-get install gpiod libgpiod-dev
This will install command line tools and install header files and libraries. Then try connecting to the Raspberry Pi again.
Walter Roberson
el 9 de Dic. de 2025 a las 16:29
According to https://www.mathworks.com/help/matlab/supportpkg/install-support-for-raspberry-pi-hardware.html there is currently compatibility with
- 32-bit Buster OS
- 32-bit and 64-bit Bullseye OS
- 32-bit and 64-bit Bookworm OS
The support for Stretch was roughly R2021b. Jessie support started from R2016a (but ended before R2021b.)
Ran Zeimer
el 10 de Dic. de 2025 a las 1:19
1 comentario
Taylor
hace alrededor de 4 horas
Sounds like an libgpiod API mismatch. Start by confirming what version you have on the Raspberry Pi. Again, run the following code in SSH/terminal not MATLAB
# Shows the version provided by pkg-config (if installed)
pkg-config --modversion libgpiod || echo "pkg-config not found"
# Shows installed and candidate versions
apt-cache policy libgpiod-dev libgpiod2
# Peek at the header to see which API it exposes
grep -n "gpiod_line_request_output" /usr/include/gpiod.h || echo "v1 symbol not found"
grep -n "gpiod_line_settings_new" /usr/include/gpiod.h || echo "v2-only symbol not found"
If you see 2.x in apt-cache policy and the header lacks gpiod_line_request_output, you’re on libgpiod v2 headers. MATLAB’s server expects v1 symbols; v2 is not source-compatible with those calls. To install the v1 headers:
sudo apt-get update
# Install (or reinstall) the v1 dev and runtime packages from the current repo
# On Raspberry Pi OS Bookworm these resolve to 1.6.3
sudo apt-get install --yes --allow-downgrades libgpiod-dev libgpiod2
# (Optional) prevent an unintended upgrade to v2 later
sudo apt-mark hold libgpiod-dev libgpiod2
Then reconnect to your board with the raspi command in MATLAB.
Ver también
Categorías
Más información sobre Introduction to Installation and Licensing en Help Center y File Exchange.
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!