-
You Reply: I will try all your advices tonight.
My last questions :
So in my case (Arduino (connected to pc with usb) + Xbee Shield + Xbee Bluetooth) :
- I choose "Prog" switch (regardless the USB and Xbee Switch ) to upload the sketch ?
and
- I choose "RUN" and "XBEE" to run all ?
-
You Reply: I will try all your advices tonight.
My last questions :
So in my case (Arduino (connected to pc with usb) + Xbee Shield + Xbee Bluetooth) :
- I choose "Prog" switch (regardless the USB and Xbee Switch ) to upload the sketch ?
and
- I choose "RUN" and "XBEE" to run all ?
-
You Reply: [quote="Lauren"]
1. I've updated the wiki page for the xbee shield for Arduino...
[/quote]
Thank Lauren for the update.
For programming the xbee, the switches must be :
- Connection Switch = PROG
- Interface Switch = USB
Is it correct ?
[quote="Lauren"]
2. About the name of them module, do you mean to config the bluetooth device name displayed on your Android phone?
[/quote]
With this command : sendBlueToothCommand("\r\n+STNA=hexapod\r\n");
I should have this name on my bluetoohth network on my android phone but I have this default name "Bluetooth_Bee_V2" (I suppose).
Perharps a switch problem, I look at this this tonight.
Thx !
-
You Reply: [quote="Lauren"]
1. I've updated the wiki page for the xbee shield for Arduino...
[/quote]
Thank Lauren for the update.
For programming the xbee, the switches must be :
- Connection Switch = PROG
- Interface Switch = USB
Is it correct ?
[quote="Lauren"]
2. About the name of them module, do you mean to config the bluetooth device name displayed on your Android phone?
[/quote]
With this command : sendBlueToothCommand("\r\n+STNA=hexapod\r\n");
I should have this name on my bluetoohth network on my android phone but I have this default name "Bluetooth_Bee_V2" (I suppose).
Perharps a switch problem, I look at this this tonight.
Thx !
-
You Reply: Hi,
I use this code to connect my android phone to the xbee bluetooth :
[code]
#include <SoftwareSerial.h> //Software Serial Port
#define RxD 0 // Pin Arduino Uno
#define TxD 1 // Pin Arduino Uno
SoftwareSerial blueToothSerial(RxD,TxD);
void setup()
{
Serial.begin(9600); //Serial port for debugging, Comment this line if not required
pinMode(RxD, INPUT);
pinMode(TxD, OUTPUT);
setupBlueToothConnection();
}
void loop()
{
if(blueToothSerial.read() == 'a')
{
blueToothSerial.println("You are connected to Bluetooth Bee");
//You can write you BT communication logic here
}
}
void setupBlueToothConnection()
{
Serial.print("Setting up Bluetooth link"); //For debugging, Comment this line if not required
blueToothSerial.begin(38400); //Set BluetoothBee BaudRate to default baud rate 38400
delay(1000);
sendBlueToothCommand("\r\n+STWMOD=0\r\n");
sendBlueToothCommand("\r\n+STNA=hexapod\r\n");
sendBlueToothCommand("\r\n+STAUTO=0\r\n");
sendBlueToothCommand("\r\n+STOAUT=1\r\n");
sendBlueToothCommand("\r\n+STPIN=0000\r\n");
delay(2000); // This delay is required.
blueToothSerial.print("\r\n+INQ=1\r\n");
delay(2000); // This delay is required.
Serial.print("Setup complete");
}
void sendBlueToothCommand(char command[])
{
char a;
blueToothSerial.print(command);
Serial.print(command); //For debugging, Comment this line if not required
delay(3000);
while(blueToothSerial.available()) //For debugging, Comment this line if not required
{ //For debugging, Comment this line if not required
Serial.print(char(blueToothSerial.read())); //For debugging, Comment this line if not required
} //For debugging, Comment this line if not required
}
[/code]
In Serial Monitor, the at command display correctly.
I use the EF_BluetoothBeeV1.1.zip application ([url=http://www.elecfreaks.com/829.html]http://www.elecfreaks.com/829.html[/url]). The connection to xbee bluetooth is okay because the same at command display my phone.
But I would like to know send a command to display the "You are connected to Bluetooth Bee" message ?
Thx.
Ps :
- There is something very strange : the name of the bluetooth is unchanged always "Bluetooth_Bee_V2" instead "hexapod"
- There is "AT mode", XBEE/USB" and "RUN/PROG" what do they means ?
-
You Reply: Hi,
I use this code to connect my android phone to the xbee bluetooth :
[code]
#include <SoftwareSerial.h> //Software Serial Port
#define RxD 0 // Pin Arduino Uno
#define TxD 1 // Pin Arduino Uno
SoftwareSerial blueToothSerial(RxD,TxD);
void setup()
{
Serial.begin(9600); //Serial port for debugging, Comment this line if not required
pinMode(RxD, INPUT);
pinMode(TxD, OUTPUT);
setupBlueToothConnection();
}
void loop()
{
if(blueToothSerial.read() == 'a')
{
blueToothSerial.println("You are connected to Bluetooth Bee");
//You can write you BT communication logic here
}
}
void setupBlueToothConnection()
{
Serial.print("Setting up Bluetooth link"); //For debugging, Comment this line if not required
blueToothSerial.begin(38400); //Set BluetoothBee BaudRate to default baud rate 38400
delay(1000);
sendBlueToothCommand("\r\n+STWMOD=0\r\n");
sendBlueToothCommand("\r\n+STNA=hexapod\r\n");
sendBlueToothCommand("\r\n+STAUTO=0\r\n");
sendBlueToothCommand("\r\n+STOAUT=1\r\n");
sendBlueToothCommand("\r\n+STPIN=0000\r\n");
delay(2000); // This delay is required.
blueToothSerial.print("\r\n+INQ=1\r\n");
delay(2000); // This delay is required.
Serial.print("Setup complete");
}
void sendBlueToothCommand(char command[])
{
char a;
blueToothSerial.print(command);
Serial.print(command); //For debugging, Comment this line if not required
delay(3000);
while(blueToothSerial.available()) //For debugging, Comment this line if not required
{ //For debugging, Comment this line if not required
Serial.print(char(blueToothSerial.read())); //For debugging, Comment this line if not required
} //For debugging, Comment this line if not required
}
[/code]
In Serial Monitor, the at command display correctly.
I use the EF_BluetoothBeeV1.1.zip application ([url=http://www.elecfreaks.com/829.html]http://www.elecfreaks.com/829.html[/url]). The connection to xbee bluetooth is okay because the same at command display my phone.
But I would like to know send a command to display the "You are connected to Bluetooth Bee" message ?
Thx.
Ps :
- There is something very strange : the name of the bluetooth is unchanged always "Bluetooth_Bee_V2" instead "hexapod"
- There is "AT mode", XBEE/USB" and "RUN/PROG" what do they means ?
-
You Reply: [quote="Lauren"]
Are you going to extend them to your hexapod? [/quote]
Yes !! :D
Thanks you for your help ! ;-)
-
You Reply: [quote="Lauren"]
Are you going to extend them to your hexapod? [/quote]
Yes !! :D
Thanks you for your help ! ;-)
-
You Reply: Hi,
I would like to connect an Arduino 1280 controller with a bluetooth or wifi shield, what is the good method to connect them ?
Thank you ! :D
-
You Reply: Hello,
It's run !!
You can see my test here : [url=http://www.youtube.com/watch?v=aSei7TQPt20]http://www.youtube.com/watch?v=aSei7TQPt20[/url]
-
You Reply: Hi,
I tried with the included IR library and with another ir remote, that's run perflectly.
The ir transmitter has the specific NEC standard ?
-
You Reply: I would like to have the exact code of the line tracking and the good manner to execute this project ?
Thanks you !
-
You Reply: I would like to have the exact code of the line tracking and the good manner to execute this project ?
Thanks you !
-
You Reply: Another code : to avoid obstacles
-
You Reply: Another code : to avoid obstacles
-
You Reply: For the song, see my attachment too.
Dont' forget to rename the file from .txt to .ino
-
You Reply: For the song, see my attachment too.
Dont' forget to rename the file from .txt to .ino
-
You Reply: Hello,
For the remote control code, see my attachment.
-
You Reply: Hello,
For the remote control code, see my attachment.