node-serialport-bindings-cpp/examples/socketio/ledWrite.ino
Jessica Quynh Tran b8b77e725f Add socketio example (#1081)
* Add socketio example
* fix json in .eslintrc file
2017-02-19 19:39:54 -05:00

14 lines
No EOL
306 B
C++

void setup() {
// put your setup code here, to run once:
pinMode(LED_BUILTIN, OUTPUT);
Serial.begin(9600);
}
void loop() {
// put your main code here, to run repeatedly:
while (Serial.available()) {
int byte = Serial.read();
digitalWrite(LED_BUILTIN, byte);
Serial.print(byte);
}
}