-
-
Save neosarchizo/3f0b3bce65853f81339f to your computer and use it in GitHub Desktop.
[앱 인벤터] 아두이노로 블루투스 사용하기
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include <SoftwareSerial.h> | |
SoftwareSerial btSerial(2, 3); | |
void setup() { | |
Serial.begin(9600); | |
btSerial.begin(9600); | |
} | |
void loop() { | |
if(Serial.available()) | |
btSerial.write(Serial.read()); | |
if(btSerial.available()) | |
Serial.write(btSerial.read()); | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment