Maker Faire - September 20, 2014
#include <SoftwareSerial.h>
#define RxD 6
#define TxD 7
SoftwareSerial bluetooth(RxD,TxD);
void setup() {
Serial.begin(9600);
bluetooth.begin(9600);
}
void loop() {
temperature = readTempSensor();
bluetooth.println(temperature);
delay(2000);
}
void loop() {
if (bluetooth.available()) {
if (bluetooth.read() == 65) {
digitalWrite(LED, HIGH);
} else {
digitalWrite(LED, LOW);
}
}
}
void loop() {
if (bluetooth.find("c")) {
red = bluetooth.parseInt();
green = bluetooth.parseInt();
blue = bluetooth.parseInt();
showColor(red, green, blue);
}
}
#include <SPI.h>
#include "Adafruit_BLE_UART.h"
Adafruit_BLE_UART uart = ...
void setup() {
uart.begin();
}
MAKE: PROJECTS Bluetooth Low Energy Lock
Supports nRF8001 and nRF51822 based boards
https://github.com/sandeepmistry/arduino-BLEPeripheralDon Coleman
Add Bluetooth to your Project by Don Coleman
is licensed under a Creative Commons Attribution-ShareAlike 3.0 Unported License.
Based on a work at https://github.com/don/.../2014-09-20-makerfaire-bluetooth.