linux Bluetooth programming in c

后端 未结 4 1233
死守一世寂寞
死守一世寂寞 2021-02-04 10:31

I am trying to run a basic code of c in linux[ubuntu] to search bluetooth device, but i am facing some problem.

By using command sudo apt-get install bluez,

4条回答
  •  不要未来只要你来
    2021-02-04 11:05

    As for i know there no packages for these headers. You have to download the following header files from internet.

    1. bluetooth.h
    2. hci.h
    3. hci_lib.h

    and create a directory called "bluetooth" under /usr/lib/ in your host machine and copy the above headers to /usr/lib/bluetooth/. Then compile your program, it should work.

    Note: while compiling link with -lbluetooth

提交回复
热议问题