I'm a new user of intel edison, so i've a question: Does anyone know with intruction/library to use for checking the bluetooth status in Arduino IDE?
What exactly do you mean by the Bluetooth status? What exactly do you want to see in the Arduino IDE? Could you explain us what you are trying to achieve?
Thanks for your reply. In my application I want to use Bluetooth, Wifi or Ethernet network to sent a text file to my phone (bluetooth by default). But as I've said, I'm just a beginner with Intel Edison and the language that I'm conformtable is Arduino language or C/C++. So, I want first, to start the Edison BT and check if it's really connected before choose another network connexion (wifi or ethernet) : that's what I mean by bluetooth status. I've seen many linux command to it in this pdf http://download.intel.com/support/edison/sb/edisonbluetooth_331704004.pdf http://download.intel.com/support/edison/sb/edisonbluetooth_331704004.pdf but I don't know how to include them in my arduino program.
Thank you for your help
I understand, doing this from the Arduino IDE is not the best approach (at least that's my opinion, I personally like working from Linux) but it can be done. Are you trying to connect to a device that has not been paired (in that case, it would be better to do manually or it'd get complex) or are you trying to set up Linux and connect to an already paired device?
Setting up Edison's Bluetooth interface from the Arduino IDE is actually easy you can do it with the command:
system("rfkill unblock bluetooth");
Under the setup section. To scan for Bluetooth devices and send the output to the IDE's serial monitoryou can use the command:
system("hcitool scan > /dev/ttyGS0");
However since the sketch has to know the MAC address of the device before connecting to it, it's better to pair the device before.
There are a few documents about Bluetooth that might interest you, why don't you take a look at:
They might be of your interest.
the problem is I want to make an Embeed system controled by the Edison card. So, doing the configuration manually in linux terminal will be not possible. That's why I was trying to do it in my arduino code. If you have another way to to do it, please let me know.
Furthermore, I'm facing to another problem: I also want to make my devices see BT edison in slave mode in order to connect any phone with Edison. I don't know if I'm clear enough
Thank you for your help
The commands I posted above are for the Arduino IDE, they use the Arduino IDE's system call to use Linux commands from the Arduino interface. Anyway, I would still suggest you to try to achieve the goal of your project first from Linux and when you manage to achieve this do it from the Arduino IDE. I mean, you will probably rely on system calls so starting from Linux is probably the best option for your project.