commit de8b1d46f07afaf87b853ab52f35ecc8c0076def Author: Red Forks Date: Fri Jan 12 10:53:57 2018 +0800 First commit, serial test diff --git a/com-test/com-test.ino b/com-test/com-test.ino new file mode 100644 index 0000000..3c95a32 --- /dev/null +++ b/com-test/com-test.ino @@ -0,0 +1,20 @@ +void setup() { + // initialize serial communication at 9600 bits per second: + Serial.begin(9600); +} + +void loop() { + // send data only when you receive data: + while (Serial.available() > 0) { + // read the incoming byte: + int incomingByte = Serial.read(); + + Serial.write(incomingByte); + } + + static int no = 0; + + Serial.print("serial port test "); + Serial.println(no++); + delay(2000); +} diff --git a/libraries/readme.txt b/libraries/readme.txt new file mode 100644 index 0000000..96ce674 --- /dev/null +++ b/libraries/readme.txt @@ -0,0 +1 @@ +For information on installing libraries, see: http://www.arduino.cc/en/Guide/Libraries