Main.ArduinoBTInitializationSketch History

Hide minor edits - Show changes to markup

June 01, 2008, at 11:20 AM by Camille Moussette - fix typo for printString
Changed line 29 from:
  printString("SET CONTROL BAUD 115200,8n1");      //first release 19200
to:
  Serial.println("SET CONTROL BAUD 115200,8n1");      //first release 19200
January 27, 2007, at 02:46 PM by David A. Mellis -
Changed lines 3-4 from:

This sketch is run once on each Arduino BT to initialize the bluetooth module. For details on the commands sent to the module, see the iWrap data sheet.

to:

This sketch is run once on each Arduino BT to initialize the bluetooth module before the board is shipped (you shouldn't need to run this code; it's just here for reference). For details on the commands sent to the module, see the iWrap data sheet.

January 27, 2007, at 02:45 PM by David A. Mellis -
Added lines 1-39:

Arduino BT Initialization Sketch

This sketch is run once on each Arduino BT to initialize the bluetooth module. For details on the commands sent to the module, see the iWrap data sheet.

 
/* BT test 01
* ------------------
* Massimo Banzi
*
*/

int LED = 13;   // select the pin for the LED
int RESET = 7;

void setup() {
  pinMode(LED,OUTPUT);   // declare the LED's pin as output
  pinMode(RESET,OUTPUT);   // declare the LED's pin as output
  Serial.begin(115200);        // connect to the serial port
  digitalWrite(RESET, HIGH);
  delay(10);
  digitalWrite(RESET, LOW);
  delay(2000);
  Serial.println("SET BT PAGEMODE 3 2000 1");
  Serial.println("SET BT NAME ARDUINOBT");
  Serial.println("SET BT ROLE 0 f 7d00");
  Serial.println("SET CONTROL ECHO 0");
  Serial.println("SET BT AUTH * 12345");
  Serial.println("SET CONTROL ESCAPE - 00 1");
  printString("SET CONTROL BAUD 115200,8n1");      //first release 19200
}

void loop () {
  digitalWrite(LED, HIGH);
  delay(100);
  digitalWrite(LED, LOW);
  Serial.println("ciao");
  delay(1000);
}

Share