Bluetooth Genuino 101

Hello,

I am trying to connect my smartphone with my board Genuino 101 but I can't. I have done an application with app inventor and I have proved it with another board and it's all ok, but with Genuino 101 I can't connect. I don't know what code and libraries I have to put to get it. Ould anyone help me?

Thanks a lot

Daniel

dmeq6:
I have proved it with another board and it’s all ok, but with Genuino 101 I can’t connect.

Did you make sure it knows what board you’re using? When you have the Genuino 101 connected, go to tools>board and make sure it has that board. If it doesn’t, select the board you want

Hello,

Yes, I have selected the correct board. In the code I put this code:

https://www.arduino.cc/en/Reference/BLECharacteristicConstructor

but my phone can't connect with board.

Thanks a lot

Daniel

dmeq6: but my phone can't connect with board.

Will the phone pair with Arduino?

Will the phone connect when using a standard terminal programme?

Yes, my phone is pair with the board. I put this code:

#include <Servo.h>

#include <CurieBLE.h>

#include<BLEPeripheral.h>
#include<BLEService.h>

BLEPeripheral blePeripheral;

Servo servos[13];

// creació del objecte servo per controlar els servos

void waitForInput(){

while(Serial.available()==0){
delay(500);
}

while(Serial.available()>0){
char incomingChar= Serial.read();
manageChar (incomingChar);
}
}
void manageChar (char c){

switch(c){

}
}

void setup() {
servos[3].attach(3);
servos[4].attach(4);
Serial.begin(19200);

blePeripheral.setLocalName (“LEDCB”);

blePeripheral.begin();

}

void loop() {
waitForInput();

}

Thaks a lot

Daniel