From e009c5c6c61da7dcf2683a75e7b17ea4fb3c6e2d Mon Sep 17 00:00:00 2001 From: "David A. Mellis" Date: Tue, 1 Mar 2011 19:52:13 -0500 Subject: Renamed WProgram.h to Arduino.h. --- cores/arduino/Arduino.h | 63 +++++++++++++++++++++++++++++++++++++++++++++++ cores/arduino/WProgram.h | 63 ----------------------------------------------- cores/arduino/WString.cpp | 2 +- cores/arduino/WString.h | 2 +- cores/arduino/main.cpp | 2 +- 5 files changed, 66 insertions(+), 66 deletions(-) create mode 100755 cores/arduino/Arduino.h delete mode 100755 cores/arduino/WProgram.h (limited to 'cores/arduino') diff --git a/cores/arduino/Arduino.h b/cores/arduino/Arduino.h new file mode 100755 index 0000000..ceaa560 --- /dev/null +++ b/cores/arduino/Arduino.h @@ -0,0 +1,63 @@ +#ifndef Arduino_h +#define Arduino_h + +#include +#include +#include + +#include + +#include "wiring.h" + +#ifdef __cplusplus +#include "WCharacter.h" +#include "WString.h" +#include "HardwareSerial.h" + +uint16_t makeWord(uint16_t w); +uint16_t makeWord(byte h, byte l); + +#define word(...) makeWord(__VA_ARGS__) + +unsigned long pulseIn(uint8_t pin, uint8_t state, unsigned long timeout = 1000000L); + +void tone(uint8_t _pin, unsigned int frequency, unsigned long duration = 0); +void noTone(uint8_t _pin); + +// WMath prototypes +long random(long); +long random(long, long); +void randomSeed(unsigned int); +long map(long, long, long, long, long); + +#if defined(__AVR_ATmega1280__) || defined(__AVR_ATmega2560__) +const static uint8_t A0 = 54; +const static uint8_t A1 = 55; +const static uint8_t A2 = 56; +const static uint8_t A3 = 57; +const static uint8_t A4 = 58; +const static uint8_t A5 = 59; +const static uint8_t A6 = 60; +const static uint8_t A7 = 61; +const static uint8_t A8 = 62; +const static uint8_t A9 = 63; +const static uint8_t A10 = 64; +const static uint8_t A11 = 65; +const static uint8_t A12 = 66; +const static uint8_t A13 = 67; +const static uint8_t A14 = 68; +const static uint8_t A15 = 69; +#else +const static uint8_t A0 = 14; +const static uint8_t A1 = 15; +const static uint8_t A2 = 16; +const static uint8_t A3 = 17; +const static uint8_t A4 = 18; +const static uint8_t A5 = 19; +const static uint8_t A6 = 20; +const static uint8_t A7 = 21; +#endif + +#endif + +#endif \ No newline at end of file diff --git a/cores/arduino/WProgram.h b/cores/arduino/WProgram.h deleted file mode 100755 index f73e760..0000000 --- a/cores/arduino/WProgram.h +++ /dev/null @@ -1,63 +0,0 @@ -#ifndef WProgram_h -#define WProgram_h - -#include -#include -#include - -#include - -#include "wiring.h" - -#ifdef __cplusplus -#include "WCharacter.h" -#include "WString.h" -#include "HardwareSerial.h" - -uint16_t makeWord(uint16_t w); -uint16_t makeWord(byte h, byte l); - -#define word(...) makeWord(__VA_ARGS__) - -unsigned long pulseIn(uint8_t pin, uint8_t state, unsigned long timeout = 1000000L); - -void tone(uint8_t _pin, unsigned int frequency, unsigned long duration = 0); -void noTone(uint8_t _pin); - -// WMath prototypes -long random(long); -long random(long, long); -void randomSeed(unsigned int); -long map(long, long, long, long, long); - -#if defined(__AVR_ATmega1280__) || defined(__AVR_ATmega2560__) -const static uint8_t A0 = 54; -const static uint8_t A1 = 55; -const static uint8_t A2 = 56; -const static uint8_t A3 = 57; -const static uint8_t A4 = 58; -const static uint8_t A5 = 59; -const static uint8_t A6 = 60; -const static uint8_t A7 = 61; -const static uint8_t A8 = 62; -const static uint8_t A9 = 63; -const static uint8_t A10 = 64; -const static uint8_t A11 = 65; -const static uint8_t A12 = 66; -const static uint8_t A13 = 67; -const static uint8_t A14 = 68; -const static uint8_t A15 = 69; -#else -const static uint8_t A0 = 14; -const static uint8_t A1 = 15; -const static uint8_t A2 = 16; -const static uint8_t A3 = 17; -const static uint8_t A4 = 18; -const static uint8_t A5 = 19; -const static uint8_t A6 = 20; -const static uint8_t A7 = 21; -#endif - -#endif - -#endif \ No newline at end of file diff --git a/cores/arduino/WString.cpp b/cores/arduino/WString.cpp index db5a441..5899798 100644 --- a/cores/arduino/WString.cpp +++ b/cores/arduino/WString.cpp @@ -18,7 +18,7 @@ */ #include -#include "WProgram.h" +#include "Arduino.h" #include "WString.h" diff --git a/cores/arduino/WString.h b/cores/arduino/WString.h index cadddb9..ff671d8 100644 --- a/cores/arduino/WString.h +++ b/cores/arduino/WString.h @@ -20,7 +20,7 @@ #ifndef String_h #define String_h -//#include "WProgram.h" +//#include "Arduino.h" #include #include #include diff --git a/cores/arduino/main.cpp b/cores/arduino/main.cpp index cc6e81d..a806ebc 100755 --- a/cores/arduino/main.cpp +++ b/cores/arduino/main.cpp @@ -1,4 +1,4 @@ -#include +#include int main(void) { -- cgit v1.2.3-18-g5258