Added BTSerial Code

This commit is contained in:
BM Devs 2017-04-07 03:03:18 -04:00 committed by GitHub
parent 247cafd30d
commit 375187200f
1 changed files with 19 additions and 0 deletions

19
BTSerial/BTSerial.ino Normal file
View File

@ -0,0 +1,19 @@
#include <SoftwareSerial.h>
SoftwareSerial BTSerial(10, 11); // RX | TX
void setup()
{
Serial.begin(38400);
Serial.println("Enter AT commands:");
BTSerial.begin(38400);
}
void loop()
{
if (BTSerial.available())
Serial.write(BTSerial.read());
if (Serial.available())
BTSerial.write(Serial.read());
}