I really need help getting started. I want to make a basic program (in C) that can read a bluetooth socket and print whatever it is sent. I tried to get Bluez (followed this:http://hackgnar.com/article/installing-the-latest-bluez-software-in-ubuntu-12/ it went great until the "make" at the end and then no luck, would not make and example program could not find bluetooth/bluetooth.h).
我真的需要帮助。我想做一个基本的程序(用C语言),可以读取蓝牙套接字并打印发送的任何内容。我尝试获得Bluez(如下:http://hackgnar.com/article/installing-the latest- Bluez -in-ubuntu-12/),直到“make”(make)结束,没有运气,无法制作,示例程序无法找到蓝牙/bluetooth.h)。
I guess my hopeful options are:
我想我希望的选择是:
- some one can tell me what I'm missing with Bluez's install and possibly how to get started with it (compiling etc)
- 有人可以告诉我Bluez的安装缺少什么,以及如何开始(编译等)
- Alternative to bluez? Laptop could do bluetooth file transfers before I installed bluez so do I even need it for this application?
- bluez替代品吗?在我安装bluez之前,笔记本电脑可以做蓝牙文件传输,所以我在这个应用程序中需要它吗?
- Any sort of comprehensive hello world (download, install, example, compile and run)
- 任何一种全面的hello world(下载、安装、示例、编译和运行)
I have a strong programming background, just not in Linux (you can gloss over the C stuff but please not the Linux/Ubuntu stuff).
我有很强的编程背景,只是在Linux上没有(你可以掩盖C的东西,但请不要掩盖Linux/Ubuntu的东西)。
Thanks!
谢谢!
1 个解决方案
#1
2
I can only guess that you have an old version of the kernel, or one of the required libraries. Try updating your linux installation (e.g. to a 3.5.x kernel or thereabouts).
我只能猜测您有一个旧版本的内核,或者一个必需的库。尝试更新您的linux安装(例如:3.5。x内核左右)。
I had no problem completing the steps you took.
完成你采取的步骤我没有问题。
If you are looking for example programs, you can always look at the simpler tools.
如果您正在寻找示例程序,您总是可以查看更简单的工具。
On my ubuntu box I'd do e.g.
在我的ubuntu框里,我用例。
sudo apt-get build-dep bluez-tools
apt-get source --compile bluez-tools
which gets all build dependencies, sources and builds the bluez-tools
package on your system.
获取所有构建依赖项、源代码并在系统上构建bluez-tools包。
#1
2
I can only guess that you have an old version of the kernel, or one of the required libraries. Try updating your linux installation (e.g. to a 3.5.x kernel or thereabouts).
我只能猜测您有一个旧版本的内核,或者一个必需的库。尝试更新您的linux安装(例如:3.5。x内核左右)。
I had no problem completing the steps you took.
完成你采取的步骤我没有问题。
If you are looking for example programs, you can always look at the simpler tools.
如果您正在寻找示例程序,您总是可以查看更简单的工具。
On my ubuntu box I'd do e.g.
在我的ubuntu框里,我用例。
sudo apt-get build-dep bluez-tools
apt-get source --compile bluez-tools
which gets all build dependencies, sources and builds the bluez-tools
package on your system.
获取所有构建依赖项、源代码并在系统上构建bluez-tools包。