Merge remote-tracking branch 'upstream/master'

This commit is contained in:
David A. Mellis 2012-05-21 09:31:54 -07:00
commit 2cbde219c1
7 changed files with 148 additions and 2576 deletions

View File

@ -86,7 +86,6 @@ public class Preferences {
"Català" + " (" + _("Catalan") + ")",
"简体中文" + " (" + _("Chinese Simplified") + ")",
"繁體中文" + " (" + _("Chinese Traditional") + ")",
"Hrvatski Jezik" + " (" + _("Croatian") + ")",
"Dansk" + " (" + _("Danish") + ")",
"Nederlands" + " (" + _("Dutch") + ")",
"English" + " (" + _("English") + ")",
@ -121,7 +120,6 @@ public class Preferences {
"ca",
"zh_cn",
"zh_tw",
"hr",
"da",
"nl",
"en",

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

View File

@ -11,7 +11,8 @@
* Serial monitor open on Serial port 0:
created 30 Dec. 2008
by Tom Igoe
modified 20 May 2012
by Tom Igoe & Jed Roach
This example code is in the public domain.
@ -30,4 +31,10 @@ void loop() {
int inByte = Serial1.read();
Serial.write(inByte);
}
// read from port 0, send to port 1:
if (Serial.available()) {
int inByte = Serial.read();
Serial1.write(inByte);
}
}

View File

@ -1,3 +1,117 @@
ARDUINO 1.0.1
[environment]
* The IDE has been internationalized and translated into multiple languages.
Thanks to Shigeru Kanemoto for the internationalization and Japanese
translation and many others for the other translations. For more
information, see: http://arduino.cc/playground/Main/LanguagesIDE
* Added preference for selecting the language in which to display the
Arduino software. Defaults to the operating system locale.
* The editor font size preference now applies to the serial monitor and
error / message console as well as the editor. (Paul Stoffregen)
http://code.google.com/p/arduino/issues/detail?id=550
* Compilation has been speeded up by only compiling changed files. (All
files are recompiled when a new board is selected.) (Paul Stoffregen)
http://code.google.com/p/arduino/issues/detail?id=638
* Console log files (stdout.txt and stderr.txt) are now removed when the
Arduino software exits. (Paul Stoffregen)
* The minimum size for the Arduino software window has been reduced.
http://code.google.com/p/arduino/issues/detail?id=52
* Improvements to the Find / Replace dialog. (Peter Lewis)
http://code.google.com/p/arduino/issues/detail?id=825
* Support for selecting words (on double-click) and lines (triple-click)
in the Arduino software. (Peter Lewis)
http://code.google.com/p/arduino/issues/detail?id=824
* Don't insert newline when using serial monitor keyboard
shortcut. (Lars J. Nielsen)
http://code.google.com/p/arduino/issues/detail?id=279
* Added a preference for disabling verification on upload (for increased
speed). (Nathan Seidle)
http://code.google.com/p/arduino/issues/detail?id=842
* Added the gcc toolchain to the Linux distribution. (To use the
toolchain already installed on your system, simply delete the one
that comes with the Arduino software.) (Paul Stoffregen)
http://code.google.com/p/arduino/issues/detail?id=300
* Updating Arduino Mini upload protocol to 'arduino' from 'stk500' (should
fix problems with auto-reset not working).
[core / libraries]
* Adding overloads to Wire.write() (for Wire.write(0)). (Paul Stoffregen)
http://code.google.com/p/arduino/issues/detail?id=527
* Fixing delayMicroseconds() for 20 MHz clocks (Erdem U. Altinyurt)
http://code.google.com/p/arduino/issues/detail?id=306
* Support third external interrupt on ATmega1284P. (maniacbug)
http://code.google.com/p/arduino/issues/detail?id=728
* Update reference voltage constants for ATmega1284P. (maniacbug)
http://code.google.com/p/arduino/issues/detail?id=728
* Adding --relax linker flag for ATmega2560. (arducopter)
http://code.google.com/p/arduino/issues/detail?id=729
* Fixing Ethernet library bug on avr-gcc 4.5.1 (SurferTim)
http://code.google.com/p/arduino/issues/detail?id=605
* Fixed DHCP hostname generation. (peter)
* Simplifying microseconds to clock cycles conversions (Rob Tillaart)
http://code.google.com/p/arduino/issues/detail?id=675
* Fixed various warnings. (maniacbug)
http://code.google.com/p/arduino/issues/detail?id=688
* Fixed bug w/ repeated initial characters in findUntil(). (Jeffery.zksun)
http://code.google.com/p/arduino/issues/detail?id=768
* Added INPUT_PULLUP option for pinMode(). The INPUT mode now explicitly
disables the pullup resistors. (Paul Stoffregen)
http://code.google.com/p/arduino/issues/detail?id=246
* Fixing bug in the receiving of multiple UDP packets. (dylan and peter)
http://code.google.com/p/arduino/issues/detail?id=669
* Added ability to generate repeated starts in the Wire library (in
master mode). Extra boolean parameters to endTransmission() and
requestFrom() control whether or not to send a stop (or a repeated
start instead). (Todd Krein)
http://code.google.com/p/arduino/issues/detail?id=663
* Added Ethernet.maintain() to renew DHCP leases. (Peter Magnusson)
http://code.google.com/p/arduino/issues/detail?id=716
* Fix for CLOSE_WAIT bug that could cause Ethernet sketches to crash
over time. (mr-russ and Johann Richard)
* Fix to servo pulse timing calculation. (jwatte)
http://code.google.com/p/arduino/issues/detail?id=908
* Added readString() and readStringUntil() functions. (Adrian McEwen)
http://code.google.com/p/arduino/issues/detail?id=454
[examples]
* Updated to latest ArduinoISP sketch. (rsbohn)
http://code.google.com/p/arduino/issues/detail?id=378
* Fixed ArduinoISP sketch by lowering delay() in heartbeat.
* Other updates.
ARDUINO 1.0 - 2011.11.30
[environment]

View File

@ -244,3 +244,27 @@ size_t Stream::readBytesUntil(char terminator, char *buffer, size_t length)
return index; // return number of characters, not including null terminator
}
String Stream::readString()
{
String ret;
int c = timedRead();
while (c >= 0)
{
ret += (char)c;
c = timedRead();
}
return ret;
}
String Stream::readStringUntil(char terminator)
{
String ret;
int c = timedRead();
while (c >= 0 && c != terminator)
{
ret += (char)c;
c = timedRead();
}
return ret;
}

View File

@ -82,6 +82,8 @@ class Stream : public Print
// returns the number of characters placed in the buffer (0 means no valid data found)
// Arduino String functions to be added here
String readString();
String readStringUntil(char terminator);
protected:
long parseInt(char skipChar); // as above but the given skipChar is ignored