1
0
mirror of https://github.com/esp8266/Arduino.git synced 2025-07-30 16:24:09 +03:00

Changed all .pde examples to .ino

All examples in /build/shared/examples/ and /libraries/ have had their
extensions changed to .ino
This commit is contained in:
Tom Igoe
2011-08-30 15:33:32 -04:00
parent 4553cee443
commit 35777612c0
124 changed files with 2850 additions and 57 deletions

View File

@ -0,0 +1,33 @@
/*
Mega multple serial test
Receives from the main serial port, sends to the others.
Receives from serial port 1, sends to the main serial (Serial 0).
This example works only on the Arduino Mega
The circuit:
* Any serial device attached to Serial port 1
* Serial monitor open on Serial port 0:
created 30 Dec. 2008
by Tom Igoe
This example code is in the public domain.
*/
void setup() {
// initialize both serial ports:
Serial.begin(9600);
Serial1.begin(9600);
}
void loop() {
// read from port 1, send to port 0:
if (Serial1.available()) {
int inByte = Serial1.read();
Serial.write(inByte);
}
}