[gnoduino] arduino: remove trailing whitespace for libraries



commit ee8c9f1931f851235775ea9474d3ba3fe2c69b40
Author: Pascal de Bruijn <pmjdebruijn pcode nl>
Date:   Thu Jul 17 18:51:26 2014 +0200

    arduino: remove trailing whitespace for libraries

 libraries/Ethernet/Dns.cpp                |    4 +-
 libraries/Ethernet/Ethernet.cpp           |    4 +-
 libraries/Ethernet/EthernetClient.cpp     |    2 +-
 libraries/Ethernet/EthernetClient.h       |    4 +-
 libraries/Ethernet/EthernetServer.cpp     |   14 +++---
 libraries/Ethernet/EthernetServer.h       |    2 +-
 libraries/Ethernet/EthernetUdp.cpp        |   10 ++--
 libraries/Ethernet/EthernetUdp.h          |   12 +++---
 libraries/Firmata/Boards.h                |    4 +-
 libraries/Firmata/Firmata.cpp             |   26 ++++++------
 libraries/Firmata/Firmata.h               |    2 +-
 libraries/Firmata/LICENSE.txt             |   18 ++++----
 libraries/LiquidCrystal/LiquidCrystal.cpp |   66 ++++++++++++++--------------
 libraries/LiquidCrystal/LiquidCrystal.h   |    6 +-
 libraries/SD/File.cpp                     |   16 ++++----
 libraries/SD/SD.cpp                       |   66 ++++++++++++++--------------
 libraries/SD/SD.h                         |   16 ++++----
 libraries/SD/keywords.txt                 |    2 +-
 libraries/SPI/SPI.cpp                     |    2 +-
 libraries/Servo/Servo.h                   |   54 ++++++++++++------------
 libraries/Stepper/Stepper.cpp             |   46 ++++++++++----------
 libraries/Stepper/Stepper.h               |   14 +++---
 libraries/Wire/Wire.cpp                   |   14 +++---
 libraries/Wire/Wire.h                     |    2 +-
 24 files changed, 203 insertions(+), 203 deletions(-)
---
diff --git a/libraries/Ethernet/Dns.cpp b/libraries/Ethernet/Dns.cpp
index b3c1a9d..fb52fea 100644
--- a/libraries/Ethernet/Dns.cpp
+++ b/libraries/Ethernet/Dns.cpp
@@ -131,7 +131,7 @@ int DNSClient::getHostByName(const char* aHostname, IPAddress& aResult)
     {
         return INVALID_SERVER;
     }
-       
+
     // Find a socket to use
     if (iUdp.begin(1024+(millis() & 0xF)) == 1)
     {
@@ -268,7 +268,7 @@ uint16_t DNSClient::ProcessResponse(uint16_t aTimeout, IPAddress& aAddress)
     // Read the UDP header
     uint8_t header[DNS_HEADER_SIZE]; // Enough space to reuse for the DNS header
     // Check that it's a response from the right server and the right port
-    if ( (iDNSServer != iUdp.remoteIP()) || 
+    if ( (iDNSServer != iUdp.remoteIP()) ||
         (iUdp.remotePort() != DNS_PORT) )
     {
         // It's not from who we expected
diff --git a/libraries/Ethernet/Ethernet.cpp b/libraries/Ethernet/Ethernet.cpp
index c31a85f..00602ae 100644
--- a/libraries/Ethernet/Ethernet.cpp
+++ b/libraries/Ethernet/Ethernet.cpp
@@ -3,9 +3,9 @@
 #include "Dhcp.h"
 
 // XXX: don't make assumptions about the value of MAX_SOCK_NUM.
-uint8_t EthernetClass::_state[MAX_SOCK_NUM] = { 
+uint8_t EthernetClass::_state[MAX_SOCK_NUM] = {
   0, 0, 0, 0 };
-uint16_t EthernetClass::_server_port[MAX_SOCK_NUM] = { 
+uint16_t EthernetClass::_server_port[MAX_SOCK_NUM] = {
   0, 0, 0, 0 };
 
 int EthernetClass::begin(uint8_t *mac_address)
diff --git a/libraries/Ethernet/EthernetClient.cpp b/libraries/Ethernet/EthernetClient.cpp
index ef3d19b..a7f999b 100644
--- a/libraries/Ethernet/EthernetClient.cpp
+++ b/libraries/Ethernet/EthernetClient.cpp
@@ -146,7 +146,7 @@ void EthernetClient::stop() {
 
 uint8_t EthernetClient::connected() {
   if (_sock == MAX_SOCK_NUM) return 0;
-  
+
   uint8_t s = status();
   return !(s == SnSR::LISTEN || s == SnSR::CLOSED || s == SnSR::FIN_WAIT ||
     (s == SnSR::CLOSE_WAIT && !available()));
diff --git a/libraries/Ethernet/EthernetClient.h b/libraries/Ethernet/EthernetClient.h
index 1992db0..b887f3c 100644
--- a/libraries/Ethernet/EthernetClient.h
+++ b/libraries/Ethernet/EthernetClient.h
@@ -1,6 +1,6 @@
 #ifndef ethernetclient_h
 #define ethernetclient_h
-#include "Arduino.h"   
+#include "Arduino.h"
 #include "Print.h"
 #include "Client.h"
 #include "IPAddress.h"
@@ -28,7 +28,7 @@ public:
   virtual bool operator!=(const EthernetClient& rhs) { return !this->operator==(rhs); };
 
   friend class EthernetServer;
-  
+
   using Print::write;
 
 private:
diff --git a/libraries/Ethernet/EthernetServer.cpp b/libraries/Ethernet/EthernetServer.cpp
index 0308b92..74f02ee 100644
--- a/libraries/Ethernet/EthernetServer.cpp
+++ b/libraries/Ethernet/EthernetServer.cpp
@@ -23,7 +23,7 @@ void EthernetServer::begin()
       EthernetClass::_server_port[sock] = _port;
       break;
     }
-  }  
+  }
 }
 
 void EthernetServer::accept()
@@ -36,11 +36,11 @@ void EthernetServer::accept()
     if (EthernetClass::_server_port[sock] == _port) {
       if (client.status() == SnSR::LISTEN) {
         listening = 1;
-      } 
+      }
       else if (client.status() == SnSR::CLOSE_WAIT && !client.available()) {
         client.stop();
       }
-    } 
+    }
   }
 
   if (!listening) {
@@ -67,15 +67,15 @@ EthernetClient EthernetServer::available()
   return EthernetClient(MAX_SOCK_NUM);
 }
 
-size_t EthernetServer::write(uint8_t b) 
+size_t EthernetServer::write(uint8_t b)
 {
   return write(&b, 1);
 }
 
-size_t EthernetServer::write(const uint8_t *buffer, size_t size) 
+size_t EthernetServer::write(const uint8_t *buffer, size_t size)
 {
   size_t n = 0;
-  
+
   accept();
 
   for (int sock = 0; sock < MAX_SOCK_NUM; sock++) {
@@ -86,6 +86,6 @@ size_t EthernetServer::write(const uint8_t *buffer, size_t size)
       n += client.write(buffer, size);
     }
   }
-  
+
   return n;
 }
diff --git a/libraries/Ethernet/EthernetServer.h b/libraries/Ethernet/EthernetServer.h
index 86ccafe..1ad2d35 100644
--- a/libraries/Ethernet/EthernetServer.h
+++ b/libraries/Ethernet/EthernetServer.h
@@ -5,7 +5,7 @@
 
 class EthernetClient;
 
-class EthernetServer : 
+class EthernetServer :
 public Server {
 private:
   uint16_t _port;
diff --git a/libraries/Ethernet/EthernetUdp.cpp b/libraries/Ethernet/EthernetUdp.cpp
index 3760052..2421b87 100644
--- a/libraries/Ethernet/EthernetUdp.cpp
+++ b/libraries/Ethernet/EthernetUdp.cpp
@@ -1,7 +1,7 @@
 /*
  *  Udp.cpp: Library to send/receive UDP packets with the Arduino ethernet shield.
  *  This version only offers minimal wrapping of socket.c/socket.h
- *  Drop Udp.h/.cpp into the Ethernet library directory at hardware/libraries/Ethernet/ 
+ *  Drop Udp.h/.cpp into the Ethernet library directory at hardware/libraries/Ethernet/
  *
  * MIT License:
  * Copyright (c) 2008 Bjoern Hartmann
@@ -11,10 +11,10 @@
  * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
  * copies of the Software, and to permit persons to whom the Software is
  * furnished to do so, subject to the following conditions:
- * 
+ *
  * The above copyright notice and this permission notice shall be included in
  * all copies or substantial portions of the Software.
- * 
+ *
  * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
  * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
  * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
@@ -124,7 +124,7 @@ int EthernetUDP::parsePacket()
   {
     //HACK - hand-parse the UDP packet using TCP recv method
     uint8_t tmpBuf[8];
-    int ret =0; 
+    int ret =0;
     //read 8 header bytes and get IP and port from it
     ret = recv(_sock,tmpBuf,8);
     if (ret > 0)
@@ -174,7 +174,7 @@ int EthernetUDP::read(unsigned char* buffer, size_t len)
     }
     else
     {
-      // too much data for the buffer, 
+      // too much data for the buffer,
       // grab as much as will fit
       got = recv(_sock, buffer, len);
     }
diff --git a/libraries/Ethernet/EthernetUdp.h b/libraries/Ethernet/EthernetUdp.h
index 8a6b7ab..cd2e730 100644
--- a/libraries/Ethernet/EthernetUdp.h
+++ b/libraries/Ethernet/EthernetUdp.h
@@ -1,12 +1,12 @@
 /*
  *  Udp.cpp: Library to send/receive UDP packets with the Arduino ethernet shield.
  *  This version only offers minimal wrapping of socket.c/socket.h
- *  Drop Udp.h/.cpp into the Ethernet library directory at hardware/libraries/Ethernet/ 
+ *  Drop Udp.h/.cpp into the Ethernet library directory at hardware/libraries/Ethernet/
  *
  * NOTE: UDP is fast, but has some important limitations (thanks to Warren Gray for mentioning these)
  * 1) UDP does not guarantee the order in which assembled UDP packets are received. This
  * might not happen often in practice, but in larger network topologies, a UDP
- * packet can be received out of sequence. 
+ * packet can be received out of sequence.
  * 2) UDP does not guard against lost packets - so packets *can* disappear without the sender being
  * aware of it. Again, this may not be a concern in practice on small local networks.
  * For more information, see http://www.cafeaulait.org/course/week12/35.html
@@ -19,10 +19,10 @@
  * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
  * copies of the Software, and to permit persons to whom the Software is
  * furnished to do so, subject to the following conditions:
- * 
+ *
  * The above copyright notice and this permission notice shall be included in
  * all copies or substantial portions of the Software.
- * 
+ *
  * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
  * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
  * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
@@ -56,7 +56,7 @@ public:
   virtual void stop();  // Finish with the UDP socket
 
   // Sending UDP packets
-  
+
   // Start building up a packet to send to the remote host specific in ip and port
   // Returns 1 if successful, 0 if there was a problem with the supplied IP address or port
   virtual int beginPacket(IPAddress ip, uint16_t port);
@@ -70,7 +70,7 @@ public:
   virtual size_t write(uint8_t);
   // Write size bytes from buffer into the packet
   virtual size_t write(const uint8_t *buffer, size_t size);
-  
+
   using Print::write;
 
   // Start processing the next available incoming packet
diff --git a/libraries/Firmata/Boards.h b/libraries/Firmata/Boards.h
index 06f69c6..5477e03 100644
--- a/libraries/Firmata/Boards.h
+++ b/libraries/Firmata/Boards.h
@@ -23,7 +23,7 @@
     Firmata Hardware Abstraction Layer
 
 Firmata is built on top of the hardware abstraction functions of Arduino,
-specifically digitalWrite, digitalRead, analogWrite, analogRead, and 
+specifically digitalWrite, digitalRead, analogWrite, analogRead, and
 pinMode.  While these functions offer simple integer pin numbers, Firmata
 needs more information than is provided by Arduino.  This file provides
 all other hardware specific details.  To make Firmata support a new board,
@@ -161,7 +161,7 @@ writePort(port, value, bitmask):  Write an 8 bit port.
 #define PIN_TO_DIGITAL(p)       (p)
 #define PIN_TO_ANALOG(p)        ((p) - FIRST_ANALOG_PIN)
 #define PIN_TO_PWM(p)           PIN_TO_DIGITAL(p)
-#define PIN_TO_SERVO(p)         (p) 
+#define PIN_TO_SERVO(p)         (p)
 
 
 // old Arduinos
diff --git a/libraries/Firmata/Firmata.cpp b/libraries/Firmata/Firmata.cpp
index e81c10b..a5afaf5 100644
--- a/libraries/Firmata/Firmata.cpp
+++ b/libraries/Firmata/Firmata.cpp
@@ -1,7 +1,7 @@
 /*
   Firmata.cpp - Firmata library
   Copyright (C) 2006-2008 Hans-Christoph Steiner.  All rights reserved.
- 
+
   This library is free software; you can redistribute it and/or
   modify it under the terms of the GNU Lesser General Public
   License as published by the Free Software Foundation; either
@@ -134,7 +134,7 @@ void FirmataClass::setFirmwareNameAndVersion(const char *name, byte major, byte
   firmwareVersionVector[1] = minor;
   strncpy((char*)firmwareVersionVector + 2, filename, firmwareVersionCount - 2);
   // alas, no snprintf on Arduino
-  //    snprintf(firmwareVersionVector, MAX_DATA_BYTES, "%c%c%s", 
+  //    snprintf(firmwareVersionVector, MAX_DATA_BYTES, "%c%c%s",
   //             (char)major, (char)minor, firmwareVersionVector);
 }
 
@@ -179,12 +179,12 @@ void FirmataClass::processInput(void)
 {
   int inputData = FirmataSerial.read(); // this is 'int' to handle -1 when no data
   int command;
-    
+
   // TODO make sure it handles -1 properly
 
   if (parsingSysex) {
     if(inputData == END_SYSEX) {
-      //stop sysex byte      
+      //stop sysex byte
       parsingSysex = false;
       //fire off handler function
       processSysexMessage();
@@ -193,7 +193,7 @@ void FirmataClass::processInput(void)
       storedInputData[sysexBytesRead] = inputData;
       sysexBytesRead++;
     }
-  } else if( (waitForData > 0) && (inputData < 128) ) {  
+  } else if( (waitForData > 0) && (inputData < 128) ) {
     waitForData--;
     storedInputData[waitForData] = inputData;
     if( (waitForData==0) && executeMultiByteCommand ) { // got the whole message
@@ -226,7 +226,7 @@ void FirmataClass::processInput(void)
         break;
       }
       executeMultiByteCommand = 0;
-    }  
+    }
   } else {
     // remove channel info from command byte if less than 0xF0
     if(inputData < 0xF0) {
@@ -266,7 +266,7 @@ void FirmataClass::processInput(void)
 // Serial Send Handling
 
 // send an analog message
-void FirmataClass::sendAnalog(byte pin, int value) 
+void FirmataClass::sendAnalog(byte pin, int value)
 {
   // pin can only be 0-15, so chop higher bits
   FirmataSerial.write(ANALOG_MESSAGE | (pin & 0xF));
@@ -274,7 +274,7 @@ void FirmataClass::sendAnalog(byte pin, int value)
 }
 
 // send a single digital pin in a digital message
-void FirmataClass::sendDigital(byte pin, int value) 
+void FirmataClass::sendDigital(byte pin, int value)
 {
   /* TODO add single pin digital messages to the protocol, this needs to
    * track the last digital data sent so that it can be sure to change just
@@ -306,25 +306,25 @@ void FirmataClass::sendDigitalPort(byte portNumber, int portData)
 }
 
 
-void FirmataClass::sendSysex(byte command, byte bytec, byte* bytev) 
+void FirmataClass::sendSysex(byte command, byte bytec, byte* bytev)
 {
   byte i;
   startSysex();
   FirmataSerial.write(command);
   for(i=0; i<bytec; i++) {
-    sendValueAsTwo7bitBytes(bytev[i]);        
+    sendValueAsTwo7bitBytes(bytev[i]);
   }
   endSysex();
 }
 
-void FirmataClass::sendString(byte command, const char* string) 
+void FirmataClass::sendString(byte command, const char* string)
 {
   sendSysex(command, strlen(string), (byte *)string);
 }
 
 
 // send a string as the protocol string type
-void FirmataClass::sendString(const char* string) 
+void FirmataClass::sendString(const char* string)
 {
   sendString(STRING_DATA, string);
 }
@@ -425,7 +425,7 @@ void FirmataClass::systemReset(void)
 
 // =============================================================================
 // used for flashing the pin for the version number
-void FirmataClass::pin13strobe(int count, int onInterval, int offInterval) 
+void FirmataClass::pin13strobe(int count, int onInterval, int offInterval)
 {
   byte i;
   pinMode(VERSION_BLINK_PIN, OUTPUT);
diff --git a/libraries/Firmata/Firmata.h b/libraries/Firmata/Firmata.h
index 74f1ccc..823deef 100644
--- a/libraries/Firmata/Firmata.h
+++ b/libraries/Firmata/Firmata.h
@@ -1,7 +1,7 @@
 /*
   Firmata.h - Firmata library
   Copyright (C) 2006-2008 Hans-Christoph Steiner.  All rights reserved.
- 
+
   This library is free software; you can redistribute it and/or
   modify it under the terms of the GNU Lesser General Public
   License as published by the Free Software Foundation; either
diff --git a/libraries/Firmata/LICENSE.txt b/libraries/Firmata/LICENSE.txt
index 77cec6d..68095d5 100644
--- a/libraries/Firmata/LICENSE.txt
+++ b/libraries/Firmata/LICENSE.txt
@@ -56,7 +56,7 @@ modified by someone else and passed on, the recipients should know
 that what they have is not the original version, so that the original
 author's reputation will not be affected by problems that might be
 introduced by others.
-
+
   Finally, software patents pose a constant threat to the existence of
 any free program.  We wish to make sure that a company cannot
 effectively restrict the users of a free program by obtaining a
@@ -112,7 +112,7 @@ modification follow.  Pay close attention to the difference between a
 "work based on the library" and a "work that uses the library".  The
 former contains code derived from the library, whereas the latter must
 be combined with the library in order to run.
-
+
                  GNU LESSER GENERAL PUBLIC LICENSE
    TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION
 
@@ -147,7 +147,7 @@ such a program is covered only if its contents constitute a work based
 on the Library (independent of the use of the Library in a tool for
 writing it).  Whether that is true depends on what the Library does
 and what the program that uses the Library does.
-  
+
   1. You may copy and distribute verbatim copies of the Library's
 complete source code as you receive it, in any medium, provided that
 you conspicuously and appropriately publish on each copy an
@@ -159,7 +159,7 @@ Library.
   You may charge a fee for the physical act of transferring a copy,
 and you may at your option offer warranty protection in exchange for a
 fee.
-
+
   2. You may modify your copy or copies of the Library or any portion
 of it, thus forming a work based on the Library, and copy and
 distribute such modifications or work under the terms of Section 1
@@ -217,7 +217,7 @@ instead of to this License.  (If a newer version than version 2 of the
 ordinary GNU General Public License has appeared, then you can specify
 that version instead if you wish.)  Do not make any other change in
 these notices.
-
+
   Once this change is made in a given copy, it is irreversible for
 that copy, so the ordinary GNU General Public License applies to all
 subsequent copies and derivative works made from that copy.
@@ -268,7 +268,7 @@ Library will still fall under Section 6.)
 distribute the object code for the work under the terms of Section 6.
 Any executables containing that work also fall under Section 6,
 whether or not they are linked directly with the Library itself.
-
+
   6. As an exception to the Sections above, you may also combine or
 link a "work that uses the Library" with the Library to produce a
 work containing portions of the Library, and distribute that work
@@ -330,7 +330,7 @@ restrictions of other proprietary libraries that do not normally
 accompany the operating system.  Such a contradiction means you cannot
 use both them and the Library together in an executable that you
 distribute.
-
+
   7. You may place library facilities that are a work based on the
 Library side-by-side in a single library together with other library
 facilities not covered by this License, and distribute such a combined
@@ -371,7 +371,7 @@ subject to these terms and conditions.  You may not impose any further
 restrictions on the recipients' exercise of the rights granted herein.
 You are not responsible for enforcing compliance by third parties with
 this License.
-
+
   11. If, as a consequence of a court judgment or allegation of patent
 infringement or for any other reason (not limited to patent issues),
 conditions are imposed on you (whether by court order, agreement or
@@ -423,7 +423,7 @@ conditions either of that version or of any later version published by
 the Free Software Foundation.  If the Library does not specify a
 license version number, you may choose any version ever published by
 the Free Software Foundation.
-
+
   14. If you wish to incorporate parts of the Library into other free
 programs whose distribution conditions are incompatible with these,
 write to the author to ask for permission.  For software which is
diff --git a/libraries/LiquidCrystal/LiquidCrystal.cpp b/libraries/LiquidCrystal/LiquidCrystal.cpp
index 0653487..ad518a8 100644
--- a/libraries/LiquidCrystal/LiquidCrystal.cpp
+++ b/libraries/LiquidCrystal/LiquidCrystal.cpp
@@ -8,17 +8,17 @@
 // When the display powers up, it is configured as follows:
 //
 // 1. Display clear
-// 2. Function set: 
-//    DL = 1; 8-bit interface data 
-//    N = 0; 1-line display 
-//    F = 0; 5x8 dot character font 
-// 3. Display on/off control: 
-//    D = 0; Display off 
-//    C = 0; Cursor off 
-//    B = 0; Blinking off 
-// 4. Entry mode set: 
-//    I/D = 1; Increment by 1 
-//    S = 0; No shift 
+// 2. Function set:
+//    DL = 1; 8-bit interface data
+//    N = 0; 1-line display
+//    F = 0; 5x8 dot character font
+// 3. Display on/off control:
+//    D = 0; Display off
+//    C = 0; Cursor off
+//    B = 0; Blinking off
+// 4. Entry mode set:
+//    I/D = 1; Increment by 1
+//    S = 0; No shift
 //
 // Note, however, that resetting the Arduino doesn't reset the LCD, so we
 // can't assume that its in that state when a sketch starts (and the
@@ -57,29 +57,29 @@ void LiquidCrystal::init(uint8_t fourbitmode, uint8_t rs, uint8_t rw, uint8_t en
   _rs_pin = rs;
   _rw_pin = rw;
   _enable_pin = enable;
-  
+
   _data_pins[0] = d0;
   _data_pins[1] = d1;
   _data_pins[2] = d2;
-  _data_pins[3] = d3; 
+  _data_pins[3] = d3;
   _data_pins[4] = d4;
   _data_pins[5] = d5;
   _data_pins[6] = d6;
-  _data_pins[7] = d7; 
+  _data_pins[7] = d7;
 
   pinMode(_rs_pin, OUTPUT);
   // we can save 1 pin by not using RW. Indicate by passing 255 instead of pin#
-  if (_rw_pin != 255) { 
+  if (_rw_pin != 255) {
     pinMode(_rw_pin, OUTPUT);
   }
   pinMode(_enable_pin, OUTPUT);
-  
+
   if (fourbitmode)
     _displayfunction = LCD_4BITMODE | LCD_1LINE | LCD_5x8DOTS;
-  else 
+  else
     _displayfunction = LCD_8BITMODE | LCD_1LINE | LCD_5x8DOTS;
-  
-  begin(16, 1);  
+
+  begin(16, 1);
 }
 
 void LiquidCrystal::begin(uint8_t cols, uint8_t lines, uint8_t dotsize) {
@@ -97,14 +97,14 @@ void LiquidCrystal::begin(uint8_t cols, uint8_t lines, uint8_t dotsize) {
   // SEE PAGE 45/46 FOR INITIALIZATION SPECIFICATION!
   // according to datasheet, we need at least 40ms after power rises above 2.7V
   // before sending commands. Arduino can turn on way befer 4.5V so we'll wait 50
-  delayMicroseconds(50000); 
+  delayMicroseconds(50000);
   // Now we pull both RS and R/W low to begin commands
   digitalWrite(_rs_pin, LOW);
   digitalWrite(_enable_pin, LOW);
-  if (_rw_pin != 255) { 
+  if (_rw_pin != 255) {
     digitalWrite(_rw_pin, LOW);
   }
-  
+
   //put the LCD into 4 bit or 8 bit mode
   if (! (_displayfunction & LCD_8BITMODE)) {
     // this is according to the hitachi HD44780 datasheet
@@ -117,13 +117,13 @@ void LiquidCrystal::begin(uint8_t cols, uint8_t lines, uint8_t dotsize) {
     // second try
     write4bits(0x03);
     delayMicroseconds(4500); // wait min 4.1ms
-    
+
     // third go!
-    write4bits(0x03); 
+    write4bits(0x03);
     delayMicroseconds(150);
 
     // finally, set to 4-bit interface
-    write4bits(0x02); 
+    write4bits(0x02);
   } else {
     // this is according to the hitachi HD44780 datasheet
     // page 45 figure 23
@@ -141,10 +141,10 @@ void LiquidCrystal::begin(uint8_t cols, uint8_t lines, uint8_t dotsize) {
   }
 
   // finally, set # lines, font size, etc.
-  command(LCD_FUNCTIONSET | _displayfunction);  
+  command(LCD_FUNCTIONSET | _displayfunction);
 
   // turn the display on with no cursor or blinking default
-  _displaycontrol = LCD_DISPLAYON | LCD_CURSOROFF | LCD_BLINKOFF;  
+  _displaycontrol = LCD_DISPLAYON | LCD_CURSOROFF | LCD_BLINKOFF;
   display();
 
   // clear it off
@@ -176,7 +176,7 @@ void LiquidCrystal::setCursor(uint8_t col, uint8_t row)
   if ( row >= _numlines ) {
     row = _numlines-1;    // we count rows starting w/0
   }
-  
+
   command(LCD_SETDDRAMADDR | (col + row_offsets[row]));
 }
 
@@ -270,12 +270,12 @@ void LiquidCrystal::send(uint8_t value, uint8_t mode) {
   digitalWrite(_rs_pin, mode);
 
   // if there is a RW pin indicated, set it low to Write
-  if (_rw_pin != 255) { 
+  if (_rw_pin != 255) {
     digitalWrite(_rw_pin, LOW);
   }
-  
+
   if (_displayfunction & LCD_8BITMODE) {
-    write8bits(value); 
+    write8bits(value);
   } else {
     write4bits(value>>4);
     write4bits(value);
@@ -284,7 +284,7 @@ void LiquidCrystal::send(uint8_t value, uint8_t mode) {
 
 void LiquidCrystal::pulseEnable(void) {
   digitalWrite(_enable_pin, LOW);
-  delayMicroseconds(1);    
+  delayMicroseconds(1);
   digitalWrite(_enable_pin, HIGH);
   delayMicroseconds(1);    // enable pulse must be >450ns
   digitalWrite(_enable_pin, LOW);
@@ -305,6 +305,6 @@ void LiquidCrystal::write8bits(uint8_t value) {
     pinMode(_data_pins[i], OUTPUT);
     digitalWrite(_data_pins[i], (value >> i) & 0x01);
   }
-  
+
   pulseEnable();
 }
diff --git a/libraries/LiquidCrystal/LiquidCrystal.h b/libraries/LiquidCrystal/LiquidCrystal.h
index 24ec5af..8197e6a 100644
--- a/libraries/LiquidCrystal/LiquidCrystal.h
+++ b/libraries/LiquidCrystal/LiquidCrystal.h
@@ -58,7 +58,7 @@ public:
   void init(uint8_t fourbitmode, uint8_t rs, uint8_t rw, uint8_t enable,
            uint8_t d0, uint8_t d1, uint8_t d2, uint8_t d3,
            uint8_t d4, uint8_t d5, uint8_t d6, uint8_t d7);
-    
+
   void begin(uint8_t cols, uint8_t rows, uint8_t charsize = LCD_5x8DOTS);
 
   void clear();
@@ -78,10 +78,10 @@ public:
   void noAutoscroll();
 
   void createChar(uint8_t, uint8_t[]);
-  void setCursor(uint8_t, uint8_t); 
+  void setCursor(uint8_t, uint8_t);
   virtual size_t write(uint8_t);
   void command(uint8_t);
-  
+
   using Print::write;
 private:
   void send(uint8_t, uint8_t);
diff --git a/libraries/SD/File.cpp b/libraries/SD/File.cpp
index 6eee39a..9cc4e0f 100644
--- a/libraries/SD/File.cpp
+++ b/libraries/SD/File.cpp
@@ -20,13 +20,13 @@
 
 File::File(SdFile f, const char *n) {
   // oh man you are kidding me, new() doesnt exist? Ok we do it by hand!
-  _file = (SdFile *)malloc(sizeof(SdFile)); 
+  _file = (SdFile *)malloc(sizeof(SdFile));
   if (_file) {
     memcpy(_file, &f, sizeof(SdFile));
-    
+
     strncpy(_name, n, 12);
     _name[12] = 0;
-    
+
     /* for debugging file open/close leaks
        nfilecount++;
        Serial.print("Created \"");
@@ -74,7 +74,7 @@ size_t File::write(const uint8_t *buf, size_t size) {
 }
 
 int File::peek() {
-  if (! _file) 
+  if (! _file)
     return 0;
 
   int c = _file->read();
@@ -83,14 +83,14 @@ int File::peek() {
 }
 
 int File::read() {
-  if (_file) 
+  if (_file)
     return _file->read();
   return -1;
 }
 
 // buffered read for more efficient, high speed reading
 int File::read(void *buf, uint16_t nbyte) {
-  if (_file) 
+  if (_file)
     return _file->read(buf, nbyte);
   return 0;
 }
@@ -127,7 +127,7 @@ uint32_t File::size() {
 void File::close() {
   if (_file) {
     _file->close();
-    free(_file); 
+    free(_file);
     _file = 0;
 
     /* for debugging file open/close leaks
@@ -139,7 +139,7 @@ void File::close() {
 }
 
 File::operator bool() {
-  if (_file) 
+  if (_file)
     return  _file->isOpen();
   return false;
 }
diff --git a/libraries/SD/SD.cpp b/libraries/SD/SD.cpp
index c746809..a40f865 100644
--- a/libraries/SD/SD.cpp
+++ b/libraries/SD/SD.cpp
@@ -17,11 +17,11 @@
      `SD` object which can be interacted with in a similar
      manner to other standard global objects like `Serial` and `Ethernet`.
 
-   * Boilerplate initialisation code is contained in one method named 
+   * Boilerplate initialisation code is contained in one method named
      `begin` and no further objects need to be created in order to access
      the SD card.
 
-   * Calls to `open` can supply a full path name including parent 
+   * Calls to `open` can supply a full path name including parent
      directories which simplifies interacting with files in subdirectories.
 
    * Utility methods are provided to determine whether a file exists
@@ -37,7 +37,7 @@
 
   Implementation Notes
 
-  In order to handle multi-directory path traversal, functionality that 
+  In order to handle multi-directory path traversal, functionality that
   requires this ability is implemented as callback functions.
 
   Individual methods call the `walkPath` function which performs the actual
@@ -92,7 +92,7 @@ bool getNextPathComponent(char *path, unsigned int *p_offset,
   if (path[offset] == '/') {
     offset++;
   }
-  
+
   // Copy the next next path segment
   while (bufferOffset < MAX_COMPONENT_LEN
         && (path[offset] != '/')
@@ -122,7 +122,7 @@ boolean walkPath(char *filepath, SdFile& parentDir,
                                     void *object),
                 void *object = NULL) {
   /*
-     
+
      When given a file path (and parent directory--normally root),
      this function traverses the directories in the path and at each
      level calls the supplied callback function while also providing
@@ -153,17 +153,17 @@ boolean walkPath(char *filepath, SdFile& parentDir,
   SdFile subfile1;
   SdFile subfile2;
 
-  char buffer[PATH_COMPONENT_BUFFER_LEN]; 
+  char buffer[PATH_COMPONENT_BUFFER_LEN];
 
   unsigned int offset = 0;
 
   SdFile *p_parent;
   SdFile *p_child;
 
-  SdFile *p_tmp_sdfile;  
-  
+  SdFile *p_tmp_sdfile;
+
   p_child = &subfile1;
-  
+
   p_parent = &parentDir;
 
   while (true) {
@@ -181,11 +181,11 @@ boolean walkPath(char *filepath, SdFile& parentDir,
       }
       return false;
     }
-    
+
     if (!moreComponents) {
       break;
     }
-    
+
     boolean exists = (*p_child).open(*p_parent, buffer, O_RDONLY);
 
     // If it's one we've created then we
@@ -193,7 +193,7 @@ boolean walkPath(char *filepath, SdFile& parentDir,
     if (p_parent != &parentDir) {
       (*p_parent).close();
     }
-    
+
     // Handle case when it doesn't exist and we can't continue...
     if (exists) {
       // We alternate between two file handles as we go down
@@ -209,7 +209,7 @@ boolean walkPath(char *filepath, SdFile& parentDir,
       return false;
     }
   }
-  
+
   if (p_parent != &parentDir) {
     (*p_parent).close(); // TODO: Return/ handle different?
   }
@@ -230,7 +230,7 @@ boolean walkPath(char *filepath, SdFile& parentDir,
 
  */
 
-boolean callback_pathExists(SdFile& parentDir, char *filePathComponent, 
+boolean callback_pathExists(SdFile& parentDir, char *filePathComponent,
                            boolean isLastComponent, void *object) {
   /*
 
@@ -243,17 +243,17 @@ boolean callback_pathExists(SdFile& parentDir, char *filePathComponent,
   SdFile child;
 
   boolean exists = child.open(parentDir, filePathComponent, O_RDONLY);
-  
+
   if (exists) {
-     child.close(); 
+     child.close();
   }
-  
+
   return exists;
 }
 
 
 
-boolean callback_makeDirPath(SdFile& parentDir, char *filePathComponent, 
+boolean callback_makeDirPath(SdFile& parentDir, char *filePathComponent,
                             boolean isLastComponent, void *object) {
   /*
 
@@ -265,19 +265,19 @@ boolean callback_makeDirPath(SdFile& parentDir, char *filePathComponent,
   */
   boolean result = false;
   SdFile child;
-  
+
   result = callback_pathExists(parentDir, filePathComponent, isLastComponent, object);
   if (!result) {
     result = child.makeDir(parentDir, filePathComponent);
-  } 
-  
+  }
+
   return result;
 }
 
 
   /*
 
-boolean callback_openPath(SdFile& parentDir, char *filePathComponent, 
+boolean callback_openPath(SdFile& parentDir, char *filePathComponent,
                          boolean isLastComponent, void *object) {
 
     Callback used to open a file specified by a filepath that may
@@ -308,7 +308,7 @@ boolean callback_openPath(SdFile& parentDir, char *filePathComponent,
 
 
 
-boolean callback_remove(SdFile& parentDir, char *filePathComponent, 
+boolean callback_remove(SdFile& parentDir, char *filePathComponent,
                        boolean isLastComponent, void *object) {
   if (isLastComponent) {
     return SdFile::remove(parentDir, filePathComponent);
@@ -316,7 +316,7 @@ boolean callback_remove(SdFile& parentDir, char *filePathComponent,
   return true;
 }
 
-boolean callback_rmdir(SdFile& parentDir, char *filePathComponent, 
+boolean callback_rmdir(SdFile& parentDir, char *filePathComponent,
                        boolean isLastComponent, void *object) {
   if (isLastComponent) {
     SdFile f;
@@ -356,7 +356,7 @@ SdFile SDClass::getParentDir(const char *filepath, int *index) {
   // we'll use the pointers to swap between the two objects
   SdFile *parent = &d1;
   SdFile *subdir = &d2;
-  
+
   const char *origpath = filepath;
 
   while (strchr(filepath, '/')) {
@@ -366,7 +366,7 @@ SdFile SDClass::getParentDir(const char *filepath, int *index) {
       filepath++;
       continue;
     }
-    
+
     if (! strchr(filepath, '/')) {
       // it was in the root directory, so leave now
       break;
@@ -463,7 +463,7 @@ File SDClass::open(const char *filepath, uint8_t mode) {
     parentdir.close();
   }
 
-  if (mode & (O_APPEND | O_WRITE)) 
+  if (mode & (O_APPEND | O_WRITE))
     file.seekSet(file.fileSize());
   return File(file, filepath);
 }
@@ -538,22 +538,22 @@ boolean SDClass::exists(char *filepath) {
 
 boolean SDClass::mkdir(char *filepath) {
   /*
-  
+
     Makes a single directory or a heirarchy of directories.
 
     A rough equivalent to `mkdir -p`.
-  
+
    */
   return walkPath(filepath, root, callback_makeDirPath);
 }
 
 boolean SDClass::rmdir(char *filepath) {
   /*
-  
+
     Makes a single directory or a heirarchy of directories.
 
     A rough equivalent to `mkdir -p`.
-  
+
    */
   return walkPath(filepath, root, callback_rmdir);
 }
@@ -597,7 +597,7 @@ File File::openNextFile(uint8_t mode) {
 
     if (f.open(_file, name, mode)) {
       //Serial.println("OK!");
-      return File(f, name);    
+      return File(f, name);
     } else {
       //Serial.println("ugh");
       return File();
@@ -608,7 +608,7 @@ File File::openNextFile(uint8_t mode) {
   return File();
 }
 
-void File::rewindDirectory(void) {  
+void File::rewindDirectory(void) {
   if (isDirectory())
     _file->rewind();
 }
diff --git a/libraries/SD/SD.h b/libraries/SD/SD.h
index 7435cf5..7d4f419 100644
--- a/libraries/SD/SD.h
+++ b/libraries/SD/SD.h
@@ -48,7 +48,7 @@ public:
   boolean isDirectory(void);
   File openNextFile(uint8_t mode = O_RDONLY);
   void rewindDirectory(void);
-  
+
   using Print::write;
 };
 
@@ -59,14 +59,14 @@ private:
   Sd2Card card;
   SdVolume volume;
   SdFile root;
-  
+
   // my quick&dirty iterator, should be replaced
   SdFile getParentDir(const char *filepath, int *indx);
 public:
   // This needs to be called to set up the connection to the SD card
   // before other methods are used.
   boolean begin(uint8_t csPin = SD_CHIP_SELECT_PIN);
-  
+
   // Open the specified file/directory with the supplied mode (e.g. read or
   // write, etc). Returns a File object for interacting with the file.
   // Note that currently only one file can be open at a time.
@@ -78,23 +78,23 @@ public:
   // Create the requested directory heirarchy--if intermediate directories
   // do not exist they will be created.
   boolean mkdir(char *filepath);
-  
+
   // Delete the file.
   boolean remove(char *filepath);
-  
+
   boolean rmdir(char *filepath);
 
 private:
 
   // This is used to determine the mode used to open a file
-  // it's here because it's the easiest place to pass the 
+  // it's here because it's the easiest place to pass the
   // information through the directory walking function. But
   // it's probably not the best place for it.
   // It shouldn't be set directly--it is set via the parameters to `open`.
   int fileOpenMode;
-  
+
   friend class File;
-  friend boolean callback_openPath(SdFile&, char *, boolean, void *); 
+  friend boolean callback_openPath(SdFile&, char *, boolean, void *);
 };
 
 extern SDClass SD;
diff --git a/libraries/SD/keywords.txt b/libraries/SD/keywords.txt
index 419fe04..b031e3f 100644
--- a/libraries/SD/keywords.txt
+++ b/libraries/SD/keywords.txt
@@ -21,7 +21,7 @@ open  KEYWORD2
 close  KEYWORD2
 seek   KEYWORD2
 position       KEYWORD2
-size   KEYWORD2        
+size   KEYWORD2
 
 #######################################
 # Constants (LITERAL1)
diff --git a/libraries/SPI/SPI.cpp b/libraries/SPI/SPI.cpp
index 5e48073..60dad32 100644
--- a/libraries/SPI/SPI.cpp
+++ b/libraries/SPI/SPI.cpp
@@ -33,7 +33,7 @@ void SPIClass::begin() {
   // MISO pin automatically overrides to INPUT.
   // By doing this AFTER enabling SPI, we avoid accidentally
   // clocking in a single bit since the lines go directly
-  // from "input" to SPI control.  
+  // from "input" to SPI control.
   // http://code.google.com/p/arduino/issues/detail?id=888
   pinMode(SCK, OUTPUT);
   pinMode(MOSI, OUTPUT);
diff --git a/libraries/Servo/Servo.h b/libraries/Servo/Servo.h
index 8168494..a76954a 100644
--- a/libraries/Servo/Servo.h
+++ b/libraries/Servo/Servo.h
@@ -17,8 +17,8 @@
   Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA  02110-1301  USA
 */
 
-/* 
-  
+/*
+
   A servo is activated by creating an instance of the Servo class passing the desired pin to the attach() 
method.
   The servos are pulsed in the background using the value most recently written using the write() method
 
@@ -32,14 +32,14 @@
 
    attach(pin )  - Attaches a servo motor to an i/o pin.
    attach(pin, min, max  ) - Attaches to a pin setting min and max values in microseconds
-   default min is 544, max is 2400  
- 
+   default min is 544, max is 2400
+
    write()     - Sets the servo angle in degrees.  (invalid angle that is valid as pulse in microseconds is 
treated as microseconds)
-   writeMicroseconds() - Sets the servo pulse width in microseconds 
-   read()      - Gets the last written servo pulse width as an angle between 0 and 180. 
+   writeMicroseconds() - Sets the servo pulse width in microseconds
+   read()      - Gets the last written servo pulse width as an angle between 0 and 180.
    readMicroseconds()   - Gets the last written servo pulse width in microseconds. (was read_us() in first 
release)
-   attached()  - Returns true if there is a servo attached. 
-   detach()    - Stops an attached servos from pulsing its i/o pin. 
+   attached()  - Returns true if there is a servo attached.
+   detach()    - Stops an attached servos from pulsing its i/o pin.
  */
 
 #ifndef Servo_h
@@ -47,8 +47,8 @@
 
 #include <inttypes.h>
 
-/* 
- * Defines for 16 bit timers used with  Servo library 
+/*
+ * Defines for 16 bit timers used with  Servo library
  *
  * If _useTimerX is defined then TimerX is a 16 bit timer on the curent board
  * timer16_Sequence_t enumerates the sequence that the timers should be allocated
@@ -59,13 +59,13 @@
 // Say which 16 bit timers can be used and in what order
 #if defined(__AVR_ATmega1280__) || defined(__AVR_ATmega2560__)
 #define _useTimer5
-#define _useTimer1 
+#define _useTimer1
 #define _useTimer3
-#define _useTimer4 
+#define _useTimer4
 typedef enum { _timer5, _timer1, _timer3, _timer4, _Nbr_16timers } timer16_Sequence_t ;
 
-#elif defined(__AVR_ATmega32U4__)  
-#define _useTimer1 
+#elif defined(__AVR_ATmega32U4__)
+#define _useTimer1
 typedef enum { _timer1, _Nbr_16timers } timer16_Sequence_t ;
 
 #elif defined(__AVR_AT90USB646__) || defined(__AVR_AT90USB1286__)
@@ -80,25 +80,25 @@ typedef enum { _timer3, _timer1, _Nbr_16timers } timer16_Sequence_t ;
 
 #else  // everything else
 #define _useTimer1
-typedef enum { _timer1, _Nbr_16timers } timer16_Sequence_t ;                  
+typedef enum { _timer1, _Nbr_16timers } timer16_Sequence_t ;
 #endif
 
 #define Servo_VERSION           2      // software version of this library
 
-#define MIN_PULSE_WIDTH       544     // the shortest pulse sent to a servo  
-#define MAX_PULSE_WIDTH      2400     // the longest pulse sent to a servo 
+#define MIN_PULSE_WIDTH       544     // the shortest pulse sent to a servo
+#define MAX_PULSE_WIDTH      2400     // the longest pulse sent to a servo
 #define DEFAULT_PULSE_WIDTH  1500     // default pulse width when servo is attached
-#define REFRESH_INTERVAL    20000     // minumim time to refresh servos in microseconds 
+#define REFRESH_INTERVAL    20000     // minumim time to refresh servos in microseconds
 
-#define SERVOS_PER_TIMER       12     // the maximum number of servos controlled by one timer 
+#define SERVOS_PER_TIMER       12     // the maximum number of servos controlled by one timer
 #define MAX_SERVOS   (_Nbr_16timers  * SERVOS_PER_TIMER)
 
 #define INVALID_SERVO         255     // flag indicating an invalid servo index
 
 typedef struct  {
   uint8_t nbr        :6 ;             // a pin number from 0 to 63
-  uint8_t isActive   :1 ;             // true if this channel is enabled, pin not pulsed if false 
-} ServoPin_t   ;  
+  uint8_t isActive   :1 ;             // true if this channel is enabled, pin not pulsed if false
+} ServoPin_t   ;
 
 typedef struct {
   ServoPin_t Pin;
@@ -110,17 +110,17 @@ class Servo
 public:
   Servo();
   uint8_t attach(int pin);           // attach the given pin to the next free channel, sets pinMode, returns 
channel number or 0 if failure
-  uint8_t attach(int pin, int min, int max); // as above but also sets min and max values for writes. 
+  uint8_t attach(int pin, int min, int max); // as above but also sets min and max values for writes.
   void detach();
-  void write(int value);             // if value is < 200 its treated as an angle, otherwise as pulse width 
in microseconds 
-  void writeMicroseconds(int value); // Write pulse width in microseconds 
+  void write(int value);             // if value is < 200 its treated as an angle, otherwise as pulse width 
in microseconds
+  void writeMicroseconds(int value); // Write pulse width in microseconds
   int read();                        // returns current pulse width as an angle between 0 and 180 degrees
   int readMicroseconds();            // returns current pulse width in microseconds for this servo (was 
read_us() in first release)
-  bool attached();                   // return true if this servo is attached, otherwise false 
+  bool attached();                   // return true if this servo is attached, otherwise false
 private:
    uint8_t servoIndex;               // index into the channel data for this servo
-   int8_t min;                       // minimum is this value times 4 added to MIN_PULSE_WIDTH    
-   int8_t max;                       // maximum is this value times 4 added to MAX_PULSE_WIDTH   
+   int8_t min;                       // minimum is this value times 4 added to MIN_PULSE_WIDTH
+   int8_t max;                       // maximum is this value times 4 added to MAX_PULSE_WIDTH
 };
 
 #endif
diff --git a/libraries/Stepper/Stepper.cpp b/libraries/Stepper/Stepper.cpp
index 5d6b5e5..24a75b9 100644
--- a/libraries/Stepper/Stepper.cpp
+++ b/libraries/Stepper/Stepper.cpp
@@ -1,19 +1,19 @@
 /*
   Stepper.cpp - - Stepper library for Wiring/Arduino - Version 0.4
-  
+
   Original library     (0.1) by Tom Igoe.
   Two-wire modifications   (0.2) by Sebastian Gassner
   Combination version   (0.3) by Tom Igoe and David Mellis
-  Bug fix for four-wire   (0.4) by Tom Igoe, bug fix from Noah Shibley  
+  Bug fix for four-wire   (0.4) by Tom Igoe, bug fix from Noah Shibley
 
   Drives a unipolar or bipolar stepper motor using  2 wires or 4 wires
 
   When wiring multiple stepper motors to a microcontroller,
-  you quickly run out of output pins, with each motor requiring 4 connections. 
+  you quickly run out of output pins, with each motor requiring 4 connections.
 
   By making use of the fact that at any time two of the four motor
   coils are the inverse  of the other two, the number of
-  control connections can be reduced from 4 to 2. 
+  control connections can be reduced from 4 to 2.
 
   A slightly modified circuit around a Darlington transistor array or an L293 H-bridge
   connects to only 2 microcontroler pins, inverts the signals received,
@@ -37,11 +37,11 @@
      3  1  0
      4  0  0
 
-  The circuits can be found at 
- 
+  The circuits can be found at
+
 http://www.arduino.cc/en/Tutorial/Stepper
- 
- 
+
+
  */
 
 
@@ -59,7 +59,7 @@ Stepper::Stepper(int number_of_steps, int motor_pin_1, int motor_pin_2)
   this->direction = 0;      // motor direction
   this->last_step_time = 0;    // time stamp in ms of the last step taken
   this->number_of_steps = number_of_steps;    // total number of steps for this motor
-  
+
   // Arduino pins for the motor control connection:
   this->motor_pin_1 = motor_pin_1;
   this->motor_pin_2 = motor_pin_2;
@@ -67,11 +67,11 @@ Stepper::Stepper(int number_of_steps, int motor_pin_1, int motor_pin_2)
   // setup the pins on the microcontroller:
   pinMode(this->motor_pin_1, OUTPUT);
   pinMode(this->motor_pin_2, OUTPUT);
-  
+
   // When there are only 2 pins, set the other two to 0:
   this->motor_pin_3 = 0;
   this->motor_pin_4 = 0;
-  
+
   // pin_count is used by the stepMotor() method:
   this->pin_count = 2;
 }
@@ -89,7 +89,7 @@ Stepper::Stepper(int number_of_steps, int motor_pin_1, int motor_pin_2, int moto
   this->direction = 0;      // motor direction
   this->last_step_time = 0;    // time stamp in ms of the last step taken
   this->number_of_steps = number_of_steps;    // total number of steps for this motor
-  
+
   // Arduino pins for the motor control connection:
   this->motor_pin_1 = motor_pin_1;
   this->motor_pin_2 = motor_pin_2;
@@ -102,8 +102,8 @@ Stepper::Stepper(int number_of_steps, int motor_pin_1, int motor_pin_2, int moto
   pinMode(this->motor_pin_3, OUTPUT);
   pinMode(this->motor_pin_4, OUTPUT);
 
-  // pin_count is used by the stepMotor() method:  
-  this->pin_count = 4;  
+  // pin_count is used by the stepMotor() method:
+  this->pin_count = 4;
 }
 
 /*
@@ -116,18 +116,18 @@ void Stepper::setSpeed(long whatSpeed)
 }
 
 /*
-  Moves the motor steps_to_move steps.  If the number is negative, 
+  Moves the motor steps_to_move steps.  If the number is negative,
    the motor moves in the reverse direction.
  */
 void Stepper::step(int steps_to_move)
-{  
+{
   int steps_left = abs(steps_to_move);  // how many steps to take
-  
+
   // determine direction based on whether steps_to_mode is + or -:
   if (steps_to_move > 0) {this->direction = 1;}
   if (steps_to_move < 0) {this->direction = 0;}
-    
-    
+
+
   // decrement the number of steps, moving one step each time:
   while(steps_left > 0) {
   // move only if the appropriate delay has passed:
@@ -141,8 +141,8 @@ void Stepper::step(int steps_to_move)
         if (this->step_number == this->number_of_steps) {
           this->step_number = 0;
         }
-      } 
-      else { 
+      }
+      else {
         if (this->step_number == 0) {
           this->step_number = this->number_of_steps;
         }
@@ -179,7 +179,7 @@ void Stepper::stepMotor(int thisStep)
       digitalWrite(motor_pin_1, LOW);
       digitalWrite(motor_pin_2, LOW);
       break;
-    } 
+    }
   }
   if (this->pin_count == 4) {
     switch (thisStep) {
@@ -207,7 +207,7 @@ void Stepper::stepMotor(int thisStep)
       digitalWrite(motor_pin_3, LOW);
       digitalWrite(motor_pin_4, HIGH);
       break;
-    } 
+    }
   }
 }
 
diff --git a/libraries/Stepper/Stepper.h b/libraries/Stepper/Stepper.h
index 4094aee..ecff924 100644
--- a/libraries/Stepper/Stepper.h
+++ b/libraries/Stepper/Stepper.h
@@ -1,6 +1,6 @@
 /*
   Stepper.h - - Stepper library for Wiring/Arduino - Version 0.4
-  
+
   Original library     (0.1) by Tom Igoe.
   Two-wire modifications   (0.2) by Sebastian Gassner
   Combination version   (0.3) by Tom Igoe and David Mellis
@@ -9,11 +9,11 @@
   Drives a unipolar or bipolar stepper motor using  2 wires or 4 wires
 
   When wiring multiple stepper motors to a microcontroller,
-  you quickly run out of output pins, with each motor requiring 4 connections. 
+  you quickly run out of output pins, with each motor requiring 4 connections.
 
   By making use of the fact that at any time two of the four motor
   coils are the inverse  of the other two, the number of
-  control connections can be reduced from 4 to 2. 
+  control connections can be reduced from 4 to 2.
 
   A slightly modified circuit around a Darlington transistor array or an L293 H-bridge
   connects to only 2 microcontroler pins, inverts the signals received,
@@ -37,7 +37,7 @@
      3  1  0
      4  0  0
 
-  The circuits can be found at 
+  The circuits can be found at
   http://www.arduino.cc/en/Tutorial/Stepper
 */
 
@@ -62,20 +62,20 @@ class Stepper {
 
   private:
     void stepMotor(int this_step);
-    
+
     int direction;        // Direction of rotation
     int speed;          // Speed in RPMs
     unsigned long step_delay;    // delay between steps, in ms, based on speed
     int number_of_steps;      // total number of steps this motor can take
     int pin_count;        // whether you're driving the motor with 2 or 4 pins
     int step_number;        // which step the motor is on
-    
+
     // motor pin numbers:
     int motor_pin_1;
     int motor_pin_2;
     int motor_pin_3;
     int motor_pin_4;
-    
+
     long last_step_time;      // time stamp in ms of when the last step was taken
 };
 
diff --git a/libraries/Wire/Wire.cpp b/libraries/Wire/Wire.cpp
index 4e7a17c..64bf25c 100644
--- a/libraries/Wire/Wire.cpp
+++ b/libraries/Wire/Wire.cpp
@@ -15,7 +15,7 @@
   You should have received a copy of the GNU Lesser General Public
   License along with this library; if not, write to the Free Software
   Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA  02110-1301  USA
- 
+
   Modified 2012 by Todd Krein (todd krein org) to implement repeated starts
 */
 
@@ -125,8 +125,8 @@ void TwoWire::beginTransmission(int address)
 //     Originally, 'endTransmission' was an f(void) function.
 //     It has been modified to take one parameter indicating
 //     whether or not a STOP should be performed on the bus.
-//     Calling endTransmission(false) allows a sketch to 
-//     perform a repeated start. 
+//     Calling endTransmission(false) allows a sketch to
+//     perform a repeated start.
 //
 //     WARNING: Nothing in the library keeps track of whether
 //     the bus tenure has been properly ended with a STOP. It
@@ -169,7 +169,7 @@ size_t TwoWire::write(uint8_t data)
     // put byte in tx buffer
     txBuffer[txBufferIndex] = data;
     ++txBufferIndex;
-    // update amount in buffer   
+    // update amount in buffer
     txBufferLength = txBufferIndex;
   }else{
   // in slave send mode
@@ -211,7 +211,7 @@ int TwoWire::available(void)
 int TwoWire::read(void)
 {
   int value = -1;
-  
+
   // get each successive byte on each call
   if(rxBufferIndex < rxBufferLength){
     value = rxBuffer[rxBufferIndex];
@@ -227,7 +227,7 @@ int TwoWire::read(void)
 int TwoWire::peek(void)
 {
   int value = -1;
-  
+
   if(rxBufferIndex < rxBufferLength){
     value = rxBuffer[rxBufferIndex];
   }
@@ -256,7 +256,7 @@ void TwoWire::onReceiveService(uint8_t* inBytes, int numBytes)
   // copy twi rx buffer into local read buffer
   // this enables new reads to happen in parallel
   for(uint8_t i = 0; i < numBytes; ++i){
-    rxBuffer[i] = inBytes[i];    
+    rxBuffer[i] = inBytes[i];
   }
   // set rx iterator vars
   rxBufferIndex = 0;
diff --git a/libraries/Wire/Wire.h b/libraries/Wire/Wire.h
index a93d0f5..4b47808 100644
--- a/libraries/Wire/Wire.h
+++ b/libraries/Wire/Wire.h
@@ -65,7 +65,7 @@ class TwoWire : public Stream
        virtual void flush(void);
     void onReceive( void (*)(int) );
     void onRequest( void (*)(void) );
-  
+
     inline size_t write(unsigned long n) { return write((uint8_t)n); }
     inline size_t write(long n) { return write((uint8_t)n); }
     inline size_t write(unsigned int n) { return write((uint8_t)n); }


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]