Close

Bluetooth Central

A project log for Arduino Glasses a HMD for Multimeter

Building an HMD with no special parts, to make work easier and safer

alain-mauerAlain Mauer 07/23/2016 at 09:020 Comments

I've worked a little bit on the software. I configured the Hm11 as central and I let the module search for BT4.0 devices. After a few try's I made it work. I used a simple written Arduino program to send the serial, Bluetooth data to the USB and vice versa. Now I receive the data from my external device.

This program can be found on my Github (serialtest3.ino)

void setup() {

Serial.begin(9600); // opens serial port, sets data rate to 9600 bps

Serial1.begin(9600); // opens serial port 1, sets data rate to 9600 bps

}

void loop() {

if (Serial1.available())

Serial.write(Serial1.read()); //read data from Bluetooth and send it to USB

if (Serial.available())

Serial1.write(Serial.read()); //read data from USB and send it to Bluetooth

}

Discussions