Created
June 18, 2012 17:38
-
-
Save jonmarkgo/2949602 to your computer and use it in GitHub Desktop.
WiFly Loop
This file contains hidden or 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
void loop() | |
{ | |
//turn on the LED if the TCP socket is open | |
if (client.connected()) { | |
digitalWrite(ledPin, HIGH); | |
} | |
else { | |
digitalWrite(ledPin, LOW); | |
} | |
//check for incoming data over TCP | |
if (client.available()) { | |
char c = client.read(); | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment