Skip to content

Instantly share code, notes, and snippets.

@bastisk
Last active August 29, 2015 10:52
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save bastisk/f7a1c57e7c989be783a8 to your computer and use it in GitHub Desktop.
Save bastisk/f7a1c57e7c989be783a8 to your computer and use it in GitHub Desktop.
#include <SoftwareSerial.h>
SoftwareSerial esp8266(5, 6);
int ready, connected = 0;
void setup() {
Serial.begin(115200);
esp8266.begin(115200);
}
void loop() {
if(esp8266.available())
while(esp8266.available())
{
char c = esp8266.read();
Serial.write(c);
}
if (Serial.available())
{
while(Serial.available()){
char command =Serial.read();
esp8266.write(command);
}
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment