Jump to content
  • 0

Installation error daqhats driver package for MCC HAT modules


PapaJoe

Question

Hello,

during installation process of the daqhats driver package I got an error while building the gpio.o binary. The bcm_host.h package is obviously missing, and this terminates the build process. Thus my MCC172 HAT can't be detected by my software. I used the latest driver version (1.4.0.8) and even tried an older one (1.4.0.6) with the same result. Could you help me?

Building and installing library

make: Entering directory '/home/pi/newversion/daqhats/lib'
gcc -I../include -I/opt/vc/include -I/usr/include -fPIC -Wall -Wextra -g -O2 -DENABLE_LOCALES=Off -MMD -c util.c -o build/util.o
gcc -I../include -I/opt/vc/include -I/usr/include -fPIC -Wall -Wextra -g -O2 -DENABLE_LOCALES=Off -MMD -c mcc118.c -o build/mcc118.o
gcc -I../include -I/opt/vc/include -I/usr/include -fPIC -Wall -Wextra -g -O2 -DENABLE_LOCALES=Off -MMD -c mcc152.c -o build/mcc152.o
gcc -I../include -I/opt/vc/include -I/usr/include -fPIC -Wall -Wextra -g -O2 -DENABLE_LOCALES=Off -MMD -c mcc152_dac.c -o build/mcc152_dac.o
gcc -I../include -I/opt/vc/include -I/usr/include -fPIC -Wall -Wextra -g -O2 -DENABLE_LOCALES=Off -MMD -c mcc152_dio.c -o build/mcc152_dio.o
gcc -I../include -I/opt/vc/include -I/usr/include -fPIC -Wall -Wextra -g -O2 -DENABLE_LOCALES=Off -MMD -c gpio.c -o build/gpio.o
gpio.c:18:10: fatal error: bcm_host.h: No such file or directory
   18 | #include "bcm_host.h"
      |          ^~~~~~~~~~~~
compilation terminated.
make: *** [makefile:32: build/gpio.o] Error 1
make: Leaving directory '/home/pi/newversion/daqhats/lib'
make: Entering directory '/home/pi/newversion/daqhats/lib'
make[1]: Entering directory '/home/pi/newversion/daqhats/include'
make[1]: Leaving directory '/home/pi/newversion/daqhats/include'
install: cannot stat './build/libdaqhats.so.1.4.0.8': No such file or directory
make: *** [makefile:38: install] Error 1
make: Leaving directory '/home/pi/newversion/daqhats/lib'
make: Entering directory '/home/pi/newversion/daqhats/lib'
make: Leaving directory '/home/pi/newversion/daqhats/lib'

Building and installing tools

By the way (in case this might be important): In the moment I am using an installation of RaspiOS-light (terminal version, Debian 12 bookworm, kernel 6.1.0-rpi8-rpi-v8, aarch64), that comes without GUI. A former installation of the driver packages on a RaspiOS that comes with GUI was successful.

Thanks a lot in advance!

PapaJoe

Edited by PapaJoe
Link to comment
Share on other sites

4 answers to this question

Recommended Posts

  • 0

Hello @PapaJoe.

Please run the command cat /proc/cpuinfo | grep Model  from your OS Terminal.  If you are using a Raspberry 5 model, then uninstall the MCC DAQHATS library and install the branch (beta version) for RPi 5 modules.  https://github.com/mccdaq/daqhats/tree/pi5

1.  Uninstall your existing daqhats library.
2.  Update your library with “git pull”.
3.  Switch to the dev library with “git checkout pi5”.
4.  Install the new library.

Note that the new library does not install Python support by default.  The latest versions of Python do not allow you to install local or pip packages when the system manages packages like in Raspberry Pi OS.  You can get around it with a command line option.  Python also encourages using virtual environments to keep packages separate for different things.  

You can switch back to the released library by uninstalling the pi5 library, running “git checkout master”, and then installing the master library.

 

Regards,

Fausto

Link to comment
Share on other sites

  • 0
On 2/12/2024 at 9:21 AM, PapaJoe said:

Hello Fausto,

many thanks for the response. I am using a Raspberry Pi model 4B from the year 2020.

Best regards

PapaJoe 

Hello Fausto,

here comes the output of the command

cat /proc/cpuinfo | grep model 

model        : 112
model name    : AMD A6-9220 RADEON R4, 5 COMPUTE CORES 2C+3G
model        : 112
model name    : AMD A6-9220 RADEON R4, 5 COMPUTE CORES 2C+3G

Best regards

PapaJoe

Edited by PapaJoe
Link to comment
Share on other sites

  • 0

I got the same issue and it was solved by installing libraspberrypi-dev package per instruction on the link: https://raspberrypi.stackexchange.com/questions/36121/fatal-error-bcm-host-h-no-such-file-or-directory-compilation-terminated

 

I just run in the terminal: "apt-get install libraspberrypi-dev" and after that the MCC module installation went through without any errors. However I'm not sure if the solution is the right one but for me it worked.

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...