From af4e19a6d24c822087ebc17785da0eb51039da93 Mon Sep 17 00:00:00 2001 From: Joshua Zenn Date: Thu, 20 Aug 2015 13:55:05 +0000 Subject: [PATCH] Final documentation update --- docs/html/annotated.html | 2 +- docs/html/classCore-members.html | 2 +- docs/html/classCore.html | 2 +- docs/html/classCrash-members.html | 2 +- docs/html/classCrash.html | 4 +- docs/html/classOutput-members.html | 2 +- docs/html/classOutput.html | 4 +- docs/html/classParse-members.html | 2 +- docs/html/classParse.html | 2 +- docs/html/classParse_1_1Opcode.html | 2 +- .../classParse_1_1Opcode_1_1IO-members.html | 2 +- docs/html/classParse_1_1Opcode_1_1IO.html | 6 +- ...arse_1_1Opcode_1_1IO_1_1Files-members.html | 2 +- .../classParse_1_1Opcode_1_1IO_1_1Files.html | 10 +- ...arse_1_1Opcode_1_1IO_1_1Ports-members.html | 2 +- .../classParse_1_1Opcode_1_1IO_1_1Ports.html | 2 +- ...classParse_1_1Opcode_1_1Logic-members.html | 2 +- docs/html/classParse_1_1Opcode_1_1Logic.html | 10 +- ...lassParse_1_1Opcode_1_1System-members.html | 2 +- docs/html/classParse_1_1Opcode_1_1System.html | 2 +- ...e_1_1Opcode_1_1System_1_1SWAP-members.html | 2 +- ...lassParse_1_1Opcode_1_1System_1_1SWAP.html | 10 +- docs/html/classParse_1_1Opcode_1_1Var.html | 2 +- ...e_1_1Opcode_1_1Var_1_1Strings-members.html | 2 +- ...lassParse_1_1Opcode_1_1Var_1_1Strings.html | 10 +- docs/html/classStack-members.html | 2 +- docs/html/classStack.html | 18 +- docs/html/classSwap-members.html | 2 +- docs/html/classSwap.html | 476 +++++++++--------- docs/html/classTokenizer-members.html | 2 +- docs/html/classTokenizer.html | 6 +- docs/html/classch__Serial-members.html | 2 +- docs/html/classch__Serial.html | 4 +- docs/html/classes.html | 2 +- docs/html/core_8cpp.html | 2 +- docs/html/core_8cpp_source.html | 6 +- docs/html/core_8h.html | 2 +- docs/html/core_8h_source.html | 6 +- docs/html/crash_8cpp.html | 2 +- docs/html/crash_8cpp_source.html | 6 +- docs/html/crash_8h.html | 2 +- docs/html/crash_8h_source.html | 6 +- .../dir_68267d1309a1af8e8297ef4c3efbcdba.html | 2 +- docs/html/files.html | 2 +- docs/html/functions.html | 2 +- docs/html/functions_func.html | 2 +- docs/html/globals.html | 5 +- docs/html/globals_defs.html | 5 +- docs/html/globals_func.html | 2 +- docs/html/index.html | 2 +- docs/html/main_8ino.html | 4 +- docs/html/main_8ino_source.html | 8 +- docs/html/output_8cpp.html | 2 +- docs/html/output_8cpp_source.html | 6 +- docs/html/output_8h.html | 25 +- docs/html/output_8h_source.html | 82 +-- docs/html/pbparse_8cpp.html | 2 +- docs/html/pbparse_8cpp_source.html | 12 +- docs/html/pbparse_8h.html | 2 +- docs/html/pbparse_8h_source.html | 6 +- docs/html/search/all_10.js | 5 +- docs/html/search/all_11.js | 2 +- docs/html/search/all_12.js | 3 +- docs/html/search/all_13.html | 26 + docs/html/search/all_13.js | 5 + docs/html/search/all_7.js | 6 +- docs/html/search/all_8.js | 7 +- docs/html/search/all_9.js | 3 +- docs/html/search/all_a.js | 3 +- docs/html/search/all_b.js | 6 +- docs/html/search/all_c.js | 12 +- docs/html/search/all_d.js | 11 +- docs/html/search/all_e.js | 16 +- docs/html/search/all_f.js | 17 +- docs/html/search/defines_1.html | 26 + docs/html/search/defines_1.js | 4 + docs/html/search/search.js | 4 +- docs/html/stack_8cpp.html | 2 +- docs/html/stack_8cpp_source.html | 10 +- docs/html/stack_8h.html | 2 +- docs/html/stack_8h_source.html | 6 +- docs/html/swap_8cpp.html | 2 +- docs/html/swap_8cpp_source.html | 458 +++++++++-------- docs/html/swap_8h.html | 2 +- docs/html/swap_8h_source.html | 14 +- docs/html/tokenizer_8cpp.html | 2 +- docs/html/tokenizer_8cpp_source.html | 8 +- docs/html/tokenizer_8h.html | 2 +- docs/html/tokenizer_8h_source.html | 6 +- 89 files changed, 802 insertions(+), 675 deletions(-) create mode 100644 docs/html/search/all_13.html create mode 100644 docs/html/search/all_13.js create mode 100644 docs/html/search/defines_1.html create mode 100644 docs/html/search/defines_1.js diff --git a/docs/html/annotated.html b/docs/html/annotated.html index ae6574e..db2a83e 100644 --- a/docs/html/annotated.html +++ b/docs/html/annotated.html @@ -109,7 +109,7 @@ diff --git a/docs/html/classCore-members.html b/docs/html/classCore-members.html index 4d97764..be4e8e4 100644 --- a/docs/html/classCore-members.html +++ b/docs/html/classCore-members.html @@ -92,7 +92,7 @@ diff --git a/docs/html/classCore.html b/docs/html/classCore.html index cb83d6a..a29b95c 100644 --- a/docs/html/classCore.html +++ b/docs/html/classCore.html @@ -150,7 +150,7 @@ diff --git a/docs/html/classCrash-members.html b/docs/html/classCrash-members.html index ae9fb58..bfa4712 100644 --- a/docs/html/classCrash-members.html +++ b/docs/html/classCrash-members.html @@ -92,7 +92,7 @@ diff --git a/docs/html/classCrash.html b/docs/html/classCrash.html index 913271e..613c17f 100644 --- a/docs/html/classCrash.html +++ b/docs/html/classCrash.html @@ -125,7 +125,7 @@

Definition at line 15 of file crash.cpp.

-

Referenced by Swap::create(), Parse::Opcode::System::END(), Parse::Opcode::IO::Files::FILEREAD(), Parse::Opcode::IO::Files::FILEWRITE(), Output::init(), Swap::init(), Swap::read(), Swap::ready(), Parse::run(), Swap::sdelete(), Parse::start(), and Output::write().

+

Referenced by Swap::create(), Parse::Opcode::System::END(), Parse::Opcode::IO::Files::FILEREAD(), Parse::Opcode::IO::Files::FILEWRITE(), Swap::init(), Output::init(), Swap::read(), Swap::ready(), Parse::run(), Swap::sdelete(), Parse::start(), and Output::write().

16  {
17  // Bad idea, may cause crash loop
18  // Output::write(msg);
@@ -158,7 +158,7 @@
diff --git a/docs/html/classOutput-members.html b/docs/html/classOutput-members.html index 202541d..91ab2f7 100644 --- a/docs/html/classOutput-members.html +++ b/docs/html/classOutput-members.html @@ -93,7 +93,7 @@ diff --git a/docs/html/classOutput.html b/docs/html/classOutput.html index 7a0ecb5..08e9c1e 100644 --- a/docs/html/classOutput.html +++ b/docs/html/classOutput.html @@ -100,7 +100,7 @@

Detailed Description

-

Definition at line 11 of file output.h.

+

Definition at line 15 of file output.h.

Member Function Documentation

@@ -238,7 +238,7 @@
diff --git a/docs/html/classParse-members.html b/docs/html/classParse-members.html index 3d6c0fa..7e84a08 100644 --- a/docs/html/classParse-members.html +++ b/docs/html/classParse-members.html @@ -93,7 +93,7 @@ diff --git a/docs/html/classParse.html b/docs/html/classParse.html index efd30fc..d20b93b 100644 --- a/docs/html/classParse.html +++ b/docs/html/classParse.html @@ -261,7 +261,7 @@ diff --git a/docs/html/classParse_1_1Opcode.html b/docs/html/classParse_1_1Opcode.html index eebf862..98d648e 100644 --- a/docs/html/classParse_1_1Opcode.html +++ b/docs/html/classParse_1_1Opcode.html @@ -114,7 +114,7 @@ diff --git a/docs/html/classParse_1_1Opcode_1_1IO-members.html b/docs/html/classParse_1_1Opcode_1_1IO-members.html index b7629ab..18bda3f 100644 --- a/docs/html/classParse_1_1Opcode_1_1IO-members.html +++ b/docs/html/classParse_1_1Opcode_1_1IO-members.html @@ -98,7 +98,7 @@ diff --git a/docs/html/classParse_1_1Opcode_1_1IO.html b/docs/html/classParse_1_1Opcode_1_1IO.html index 6ca720b..6174219 100644 --- a/docs/html/classParse_1_1Opcode_1_1IO.html +++ b/docs/html/classParse_1_1Opcode_1_1IO.html @@ -210,13 +210,13 @@

Definition at line 98 of file pbparse.cpp.

-

References Swap::read(), and Output::write().

+

References Swap::read(), and Output::write().

Referenced by Parse::run().

99  {
100  Output::write(Swap::read(_var));
101  }
-
static String read(String name)
Definition: swap.cpp:120
+
static String read(String name)
Definition: swap.cpp:129
static void write(String msg)
Definition: output.cpp:57
@@ -228,7 +228,7 @@ diff --git a/docs/html/classParse_1_1Opcode_1_1IO_1_1Files-members.html b/docs/html/classParse_1_1Opcode_1_1IO_1_1Files-members.html index 3a668d7..75280bf 100644 --- a/docs/html/classParse_1_1Opcode_1_1IO_1_1Files-members.html +++ b/docs/html/classParse_1_1Opcode_1_1IO_1_1Files-members.html @@ -97,7 +97,7 @@ diff --git a/docs/html/classParse_1_1Opcode_1_1IO_1_1Files.html b/docs/html/classParse_1_1Opcode_1_1IO_1_1Files.html index 7a22b8f..dd90a38 100644 --- a/docs/html/classParse_1_1Opcode_1_1IO_1_1Files.html +++ b/docs/html/classParse_1_1Opcode_1_1IO_1_1Files.html @@ -141,7 +141,7 @@

Definition at line 152 of file pbparse.cpp.

-

References Crash::forceHalt(), and Swap::update().

+

References Crash::forceHalt(), and Swap::update().

Referenced by Parse::run().

153  {
@@ -170,7 +170,7 @@
176  Swap::update(_var, _readbuf);
177  _file.close();
178  }
-
static void update(String name, String value)
Definition: swap.cpp:263
+
static void update(String name, String value)
Definition: swap.cpp:281
static void forceHalt(String msg)
Definition: crash.cpp:15
@@ -210,7 +210,7 @@

Definition at line 131 of file pbparse.cpp.

-

References Crash::forceHalt(), and Swap::read().

+

References Crash::forceHalt(), and Swap::read().

Referenced by Parse::run().

132  {
@@ -230,7 +230,7 @@
146  _file.flush();
147  _file.close();
148  }
-
static String read(String name)
Definition: swap.cpp:120
+
static String read(String name)
Definition: swap.cpp:129
static void forceHalt(String msg)
Definition: crash.cpp:15
@@ -242,7 +242,7 @@ diff --git a/docs/html/classParse_1_1Opcode_1_1IO_1_1Ports-members.html b/docs/html/classParse_1_1Opcode_1_1IO_1_1Ports-members.html index 655a1d0..91357ba 100644 --- a/docs/html/classParse_1_1Opcode_1_1IO_1_1Ports-members.html +++ b/docs/html/classParse_1_1Opcode_1_1IO_1_1Ports-members.html @@ -96,7 +96,7 @@ diff --git a/docs/html/classParse_1_1Opcode_1_1IO_1_1Ports.html b/docs/html/classParse_1_1Opcode_1_1IO_1_1Ports.html index 02bc158..62eed84 100644 --- a/docs/html/classParse_1_1Opcode_1_1IO_1_1Ports.html +++ b/docs/html/classParse_1_1Opcode_1_1IO_1_1Ports.html @@ -163,7 +163,7 @@ diff --git a/docs/html/classParse_1_1Opcode_1_1Logic-members.html b/docs/html/classParse_1_1Opcode_1_1Logic-members.html index 9c34301..a651b24 100644 --- a/docs/html/classParse_1_1Opcode_1_1Logic-members.html +++ b/docs/html/classParse_1_1Opcode_1_1Logic-members.html @@ -97,7 +97,7 @@ diff --git a/docs/html/classParse_1_1Opcode_1_1Logic.html b/docs/html/classParse_1_1Opcode_1_1Logic.html index acbb173..03008f8 100644 --- a/docs/html/classParse_1_1Opcode_1_1Logic.html +++ b/docs/html/classParse_1_1Opcode_1_1Logic.html @@ -147,7 +147,7 @@

Definition at line 257 of file pbparse.cpp.

-

References Swap::read(), and Parse::start().

+

References Swap::read(), and Parse::start().

Referenced by Parse::run().

258  {
@@ -157,7 +157,7 @@
262  }
263  }
static void start(String filename)
Definition: pbparse.cpp:21
-
static String read(String name)
Definition: swap.cpp:120
+
static String read(String name)
Definition: swap.cpp:129
@@ -202,7 +202,7 @@

Definition at line 269 of file pbparse.cpp.

-

References Swap::read(), and Parse::start().

+

References Swap::read(), and Parse::start().

Referenced by Parse::run().

270  {
@@ -212,7 +212,7 @@
274  }
275  }
static void start(String filename)
Definition: pbparse.cpp:21
-
static String read(String name)
Definition: swap.cpp:120
+
static String read(String name)
Definition: swap.cpp:129
@@ -223,7 +223,7 @@ diff --git a/docs/html/classParse_1_1Opcode_1_1System-members.html b/docs/html/classParse_1_1Opcode_1_1System-members.html index efc2722..5372395 100644 --- a/docs/html/classParse_1_1Opcode_1_1System-members.html +++ b/docs/html/classParse_1_1Opcode_1_1System-members.html @@ -98,7 +98,7 @@ diff --git a/docs/html/classParse_1_1Opcode_1_1System.html b/docs/html/classParse_1_1Opcode_1_1System.html index a2569f4..58043d8 100644 --- a/docs/html/classParse_1_1Opcode_1_1System.html +++ b/docs/html/classParse_1_1Opcode_1_1System.html @@ -226,7 +226,7 @@ diff --git a/docs/html/classParse_1_1Opcode_1_1System_1_1SWAP-members.html b/docs/html/classParse_1_1Opcode_1_1System_1_1SWAP-members.html index b6fa772..b6453e2 100644 --- a/docs/html/classParse_1_1Opcode_1_1System_1_1SWAP-members.html +++ b/docs/html/classParse_1_1Opcode_1_1System_1_1SWAP-members.html @@ -99,7 +99,7 @@ diff --git a/docs/html/classParse_1_1Opcode_1_1System_1_1SWAP.html b/docs/html/classParse_1_1Opcode_1_1System_1_1SWAP.html index a9097ca..8d8c638 100644 --- a/docs/html/classParse_1_1Opcode_1_1System_1_1SWAP.html +++ b/docs/html/classParse_1_1Opcode_1_1System_1_1SWAP.html @@ -167,13 +167,13 @@

Definition at line 240 of file pbparse.cpp.

-

References Swap::sdelete().

+

References Swap::sdelete().

Referenced by Parse::run().

241  {
242  Swap::sdelete(_name);
243  }
-
static void sdelete(String name)
Definition: swap.cpp:275
+
static void sdelete(String name)
Definition: swap.cpp:293
@@ -257,13 +257,13 @@

Definition at line 247 of file pbparse.cpp.

-

References Swap::update().

+

References Swap::update().

Referenced by Parse::run().

248  {
249  Swap::update(_name, _value);
250  }
-
static void update(String name, String value)
Definition: swap.cpp:263
+
static void update(String name, String value)
Definition: swap.cpp:281
@@ -274,7 +274,7 @@ diff --git a/docs/html/classParse_1_1Opcode_1_1Var.html b/docs/html/classParse_1_1Opcode_1_1Var.html index d3b584c..aff6911 100644 --- a/docs/html/classParse_1_1Opcode_1_1Var.html +++ b/docs/html/classParse_1_1Opcode_1_1Var.html @@ -108,7 +108,7 @@ diff --git a/docs/html/classParse_1_1Opcode_1_1Var_1_1Strings-members.html b/docs/html/classParse_1_1Opcode_1_1Var_1_1Strings-members.html index 2565f15..75c6bd9 100644 --- a/docs/html/classParse_1_1Opcode_1_1Var_1_1Strings-members.html +++ b/docs/html/classParse_1_1Opcode_1_1Var_1_1Strings-members.html @@ -97,7 +97,7 @@ diff --git a/docs/html/classParse_1_1Opcode_1_1Var_1_1Strings.html b/docs/html/classParse_1_1Opcode_1_1Var_1_1Strings.html index 203461c..15dfaef 100644 --- a/docs/html/classParse_1_1Opcode_1_1Var_1_1Strings.html +++ b/docs/html/classParse_1_1Opcode_1_1Var_1_1Strings.html @@ -147,13 +147,13 @@

Definition at line 183 of file pbparse.cpp.

-

References Swap::update().

+

References Swap::update().

Referenced by Parse::run().

184  {
185  Swap::update(_store, _s1 + _s2);
186  }
-
static void update(String name, String value)
Definition: swap.cpp:263
+
static void update(String name, String value)
Definition: swap.cpp:281
@@ -198,14 +198,14 @@

Definition at line 190 of file pbparse.cpp.

-

References Swap::update().

+

References Swap::update().

Referenced by Parse::run().

191  {
192  int _cindex = _rchar.toInt();
193  Swap::update(_store, String(_srg.charAt(_cindex)));
194  }
-
static void update(String name, String value)
Definition: swap.cpp:263
+
static void update(String name, String value)
Definition: swap.cpp:281
@@ -216,7 +216,7 @@ diff --git a/docs/html/classStack-members.html b/docs/html/classStack-members.html index 10dc659..47d54a6 100644 --- a/docs/html/classStack-members.html +++ b/docs/html/classStack-members.html @@ -95,7 +95,7 @@ diff --git a/docs/html/classStack.html b/docs/html/classStack.html index 0b183af..345ed1d 100644 --- a/docs/html/classStack.html +++ b/docs/html/classStack.html @@ -130,7 +130,7 @@

Definition at line 48 of file stack.cpp.

-

References Swap::read().

+

References Swap::read().

49  {
50  String dump = "";
51  #ifdef CORE_STACK
@@ -139,7 +139,7 @@
54  return dump;
55  }
static String dump()
Definition: stack.cpp:48
-
static String read(String name)
Definition: swap.cpp:120
+
static String read(String name)
Definition: swap.cpp:129
@@ -202,7 +202,7 @@

Definition at line 37 of file stack.cpp.

-

References Swap::read(), and Swap::update().

+

References Swap::read(), and Swap::update().

Referenced by Parse::start().

38  {
@@ -212,8 +212,8 @@
42  Swap::update("OCTSTACK", stackvar);
43  #endif
44  }
-
static void update(String name, String value)
Definition: swap.cpp:263
-
static String read(String name)
Definition: swap.cpp:120
+
static void update(String name, String value)
Definition: swap.cpp:281
+
static String read(String name)
Definition: swap.cpp:129
@@ -242,7 +242,7 @@

Definition at line 26 of file stack.cpp.

-

References Swap::read(), and Swap::update().

+

References Swap::read(), and Swap::update().

Referenced by Parse::start().

27  {
@@ -252,8 +252,8 @@
31  Swap::update("OCTSTACK", result);
32  #endif
33  }
-
static void update(String name, String value)
Definition: swap.cpp:263
-
static String read(String name)
Definition: swap.cpp:120
+
static void update(String name, String value)
Definition: swap.cpp:281
+
static String read(String name)
Definition: swap.cpp:129
@@ -264,7 +264,7 @@ diff --git a/docs/html/classSwap-members.html b/docs/html/classSwap-members.html index c3e1146..45a29ed 100644 --- a/docs/html/classSwap-members.html +++ b/docs/html/classSwap-members.html @@ -99,7 +99,7 @@ diff --git a/docs/html/classSwap.html b/docs/html/classSwap.html index 237b08d..48f3e59 100644 --- a/docs/html/classSwap.html +++ b/docs/html/classSwap.html @@ -199,45 +199,54 @@

Definition at line 83 of file swap.cpp.

-

References Crash::forceHalt(), GetPath(), and ready().

+

References Crash::forceHalt(), GetPath(), and ready().

-

Referenced by Stack::init(), Parse::Opcode::System::SWAP::NEW(), and update().

+

Referenced by Stack::init(), Parse::Opcode::System::SWAP::NEW(), and update().

84  {
-
85  // Make sure that swap is ready
-
86  Swap::ready();
-
87  // Check to see if variable already exists
-
88  if(SD.exists(Swap::GetPath(name)))
-
89  {
-
90  // It does, so crash system
-
91  #ifdef CRASH_MSG_DETAIL
-
92  Crash::forceHalt("Tried to create a variable that already exists in swap.");
-
93  #else
-
94  Crash::forceHalt("Ex012");
-
95  #endif
-
96  }
-
97  // Create new file handle for new swap file
-
98  File newSwap = SD.open(Swap::GetPath(name), FILE_WRITE);
-
99  // Check to see if we could open the file
-
100  if (newSwap)
-
101  {
-
102  // Write value of item and close the handle
-
103  newSwap.println(value);
-
104  newSwap.close();
-
105  }
-
106  else
-
107  {
-
108  // IO error, crash the system
-
109  #ifdef CRASH_MSG_DETAIL
-
110  Crash::forceHalt("Error writing new swap variable to SD card.");
-
111  #else
-
112  Crash::forceHalt("Ex013");
-
113  #endif
-
114  }
-
115 
-
116  }
+
85  // Make sure that the var name is 8.3 compliant
+
86  if(name.length() > 8)
+
87  {
+
88  #ifdef CRASH_MSG_DETAIL
+
89  Crash::forceHalt("Variable is not 8.0 compliant.");
+
90  #else
+
91  Crash::forceHalt("Ex017");
+
92  #endif
+
93  }
+
94  // Make sure that swap is ready
+
95  Swap::ready();
+
96  // Check to see if variable already exists
+
97  if(SD.exists(Swap::GetPath(name)))
+
98  {
+
99  // It does, so crash system
+
100  #ifdef CRASH_MSG_DETAIL
+
101  Crash::forceHalt("Tried to create a variable that already exists in swap.");
+
102  #else
+
103  Crash::forceHalt("Ex012");
+
104  #endif
+
105  }
+
106  // Create new file handle for new swap file
+
107  File newSwap = SD.open(Swap::GetPath(name), FILE_WRITE);
+
108  // Check to see if we could open the file
+
109  if (newSwap)
+
110  {
+
111  // Write value of item and close the handle
+
112  newSwap.println(value);
+
113  newSwap.close();
+
114  }
+
115  else
+
116  {
+
117  // IO error, crash the system
+
118  #ifdef CRASH_MSG_DETAIL
+
119  Crash::forceHalt("Error writing new swap variable to SD card.");
+
120  #else
+
121  Crash::forceHalt("Ex013");
+
122  #endif
+
123  }
+
124 
+
125  }
static String GetPath(String name)
Definition: swap.cpp:71
static void forceHalt(String msg)
Definition: crash.cpp:15
-
static void ready()
Definition: swap.cpp:296
+
static void ready()
Definition: swap.cpp:314
@@ -266,7 +275,7 @@

Definition at line 71 of file swap.cpp.

-

Referenced by create(), read(), and sdelete().

+

Referenced by create(), read(), and sdelete().

72  {
73  // Add parts together
74  String swp = "/swap/";
@@ -302,7 +311,7 @@

Definition at line 18 of file swap.cpp.

-

References clearFolder(), Crash::forceHalt(), and ready().

+

References clearFolder(), Crash::forceHalt(), and ready().

Referenced by Core::init().

19  {
@@ -332,7 +341,7 @@
43  }
static void clearFolder(File fldr)
Definition: swap.cpp:47
static void forceHalt(String msg)
Definition: crash.cpp:15
-
static void ready()
Definition: swap.cpp:296
+
static void ready()
Definition: swap.cpp:314
@@ -359,153 +368,162 @@

Returns the value of the requested SWAP object.

-

Definition at line 120 of file swap.cpp.

+

Definition at line 129 of file swap.cpp.

-

References Crash::forceHalt(), GetPath(), and ready().

+

References Crash::forceHalt(), GetPath(), and ready().

Referenced by Stack::dump(), Parse::Opcode::IO::Files::FILEWRITE(), Parse::Opcode::Logic::IFE(), Parse::Opcode::Logic::IFNE(), Stack::pop(), Parse::Opcode::IO::PRINTV(), Stack::push(), and Tokenizer::TKgetToken().

-
121  {
-
122  // Make sure that swap is ready
-
123  Swap::ready();
-
124  // Check for special compile-time variables
-
125  if(name == "$bootver")
-
126  {
-
127  return "v0.2.0a";
-
128  }
-
129  #ifdef SWAP_CONST_BOOL
-
130  else if(name == "$CONST_true")
-
131  {
-
132  return "true";
-
133  }
-
134  else if(name == "$CONST_false")
-
135  {
-
136  return "false";
-
137  }
-
138  #endif
-
139  #ifdef SWAP_CONST_NUM
-
140  else if(name == "$CONST_1")
-
141  {
-
142  return "1";
-
143  }
-
144  else if(name == "$CONST_2")
-
145  {
-
146  return "2";
-
147  }
-
148  else if(name == "$CONST_3")
-
149  {
-
150  return "3";
-
151  }
-
152  else if(name == "$CONST_4")
-
153  {
-
154  return "4";
-
155  }
-
156  else if(name == "$CONST_5")
-
157  {
-
158  return "5";
-
159  }
-
160  else if(name == "$CONST_6")
-
161  {
-
162  return "6";
-
163  }
-
164  else if(name == "$CONST_7")
-
165  {
-
166  return "7";
-
167  }
-
168  else if(name == "$CONST_8")
-
169  {
-
170  return "8";
-
171  }
-
172  else if(name == "$CONST_9")
-
173  {
-
174  return "9";
-
175  }
-
176  else if(name == "$CONST_0")
-
177  {
-
178  return "0";
-
179  }
-
180  #endif
-
181  else if(name == "$FEAT_SWAP_CONST")
-
182  {
-
183  #ifdef SWAP_CONST_BOOL
-
184  #ifdef SWAP_CONST_NUM
-
185  return "true";
-
186  #endif
-
187  #endif
-
188  return "false";
-
189  }
-
190  else if(name == "$FEAT_IO_Serial")
-
191  {
-
192  #ifdef IO_LOG_SERIAL
-
193  return "true";
-
194  #endif
-
195  return "false";
-
196  }
-
197  else if(name == "$FEAT_IO_SD")
-
198  {
-
199  #ifdef IO_LOG_SD
-
200  return "true";
-
201  #endif
-
202  return "false";
-
203  }
-
204  else if(name == "$FEAT_IO_LCD")
-
205  {
-
206  #ifdef IO_LOG_LCD
-
207  return "true";
-
208  #endif
-
209  return "false";
-
210  }
-
211  else if(name == "$FEAT_CORE_STACK")
-
212  {
-
213  #ifdef CORE_STACK
-
214  return "true";
-
215  #endif
-
216  return "false";
-
217  }
-
218  else if(name.startsWith("$PIN"))
-
219  {
-
220  int nPin = 0;
-
221  sscanf(name.c_str(), "$PIN%02d", &nPin);
-
222  pinMode(nPin, INPUT);
-
223  String result = String(digitalRead(nPin));
-
224  return result;
-
225  }
-
226  // Check to see if variable exists
-
227  if(!SD.exists(Swap::GetPath(name)))
-
228  {
-
229  // It doesn't, so crash the system
-
230  #ifdef CRASH_MSG_DETAIL
-
231  Crash::forceHalt("Swap variable already exists in swap space.");
-
232  #else
-
233  Crash::forceHalt("Ex014");
-
234  #endif
-
235  }
-
236  // Create IO handle
-
237  File readSwap = SD.open(Swap::GetPath(name));
-
238  // Check to see if IO handle was created
-
239  if(readSwap)
-
240  {
-
241  // Create buffer
-
242  String result = "";
-
243  while (readSwap.available())
-
244  {
-
245  // Read characters from IO stream
-
246  result += readSwap.read();
-
247  }
-
248  // Close handle
-
249  readSwap.close();
-
250  // Return swap variable value
-
251  return result;
-
252  }
-
253  // IO error, crash system
-
254  #ifdef CRASH_MSG_DETAIL
-
255  Crash::forceHalt("Error opening swapfile on SD card.");
-
256  #else
-
257  Crash::forceHalt("Ex015");
-
258  #endif
-
259  }
+
130  {
+
131  // Make sure that swap is ready
+
132  Swap::ready();
+
133  // Check for special compile-time variables
+
134  if(name == "$bootver")
+
135  {
+
136  return "v0.2.0a";
+
137  }
+
138  #ifdef SWAP_CONST_BOOL
+
139  else if(name == "$CONST_true")
+
140  {
+
141  return "true";
+
142  }
+
143  else if(name == "$CONST_false")
+
144  {
+
145  return "false";
+
146  }
+
147  #endif
+
148  #ifdef SWAP_CONST_NUM
+
149  else if(name == "$CONST_1")
+
150  {
+
151  return "1";
+
152  }
+
153  else if(name == "$CONST_2")
+
154  {
+
155  return "2";
+
156  }
+
157  else if(name == "$CONST_3")
+
158  {
+
159  return "3";
+
160  }
+
161  else if(name == "$CONST_4")
+
162  {
+
163  return "4";
+
164  }
+
165  else if(name == "$CONST_5")
+
166  {
+
167  return "5";
+
168  }
+
169  else if(name == "$CONST_6")
+
170  {
+
171  return "6";
+
172  }
+
173  else if(name == "$CONST_7")
+
174  {
+
175  return "7";
+
176  }
+
177  else if(name == "$CONST_8")
+
178  {
+
179  return "8";
+
180  }
+
181  else if(name == "$CONST_9")
+
182  {
+
183  return "9";
+
184  }
+
185  else if(name == "$CONST_0")
+
186  {
+
187  return "0";
+
188  }
+
189  #endif
+
190  #ifdef SWAP_CONST_CHAR
+
191  else if(name.startsWith("$CONST_CHAR_"))
+
192  {
+
193  char cnst;
+
194  sscanf(name.c_str(), "$CONST_CHAR_%c", &cnst);
+
195  String result = String(cnst);
+
196  return result;
+
197  }
+
198  #endif
+
199  else if(name == "$FEAT_SWAP_CONST")
+
200  {
+
201  #ifdef SWAP_CONST_BOOL
+
202  #ifdef SWAP_CONST_NUM
+
203  return "true";
+
204  #endif
+
205  #endif
+
206  return "false";
+
207  }
+
208  else if(name == "$FEAT_IO_Serial")
+
209  {
+
210  #ifdef IO_LOG_SERIAL
+
211  return "true";
+
212  #endif
+
213  return "false";
+
214  }
+
215  else if(name == "$FEAT_IO_SD")
+
216  {
+
217  #ifdef IO_LOG_SD
+
218  return "true";
+
219  #endif
+
220  return "false";
+
221  }
+
222  else if(name == "$FEAT_IO_LCD")
+
223  {
+
224  #ifdef IO_LOG_LCD
+
225  return "true";
+
226  #endif
+
227  return "false";
+
228  }
+
229  else if(name == "$FEAT_CORE_STACK")
+
230  {
+
231  #ifdef CORE_STACK
+
232  return "true";
+
233  #endif
+
234  return "false";
+
235  }
+
236  else if(name.startsWith("$PIN"))
+
237  {
+
238  int nPin = 0;
+
239  sscanf(name.c_str(), "$PIN%02d", &nPin);
+
240  pinMode(nPin, INPUT);
+
241  String result = String(digitalRead(nPin));
+
242  return result;
+
243  }
+
244  // Check to see if variable exists
+
245  if(!SD.exists(Swap::GetPath(name)))
+
246  {
+
247  // It doesn't, so crash the system
+
248  #ifdef CRASH_MSG_DETAIL
+
249  Crash::forceHalt("Swap variable already exists in swap space.");
+
250  #else
+
251  Crash::forceHalt("Ex014");
+
252  #endif
+
253  }
+
254  // Create IO handle
+
255  File readSwap = SD.open(Swap::GetPath(name));
+
256  // Check to see if IO handle was created
+
257  if(readSwap)
+
258  {
+
259  // Create buffer
+
260  String result = "";
+
261  while (readSwap.available())
+
262  {
+
263  // Read characters from IO stream
+
264  result += readSwap.read();
+
265  }
+
266  // Close handle
+
267  readSwap.close();
+
268  // Return swap variable value
+
269  return result;
+
270  }
+
271  // IO error, crash system
+
272  #ifdef CRASH_MSG_DETAIL
+
273  Crash::forceHalt("Error opening swapfile on SD card.");
+
274  #else
+
275  Crash::forceHalt("Ex015");
+
276  #endif
+
277  }
static String GetPath(String name)
Definition: swap.cpp:71
static void forceHalt(String msg)
Definition: crash.cpp:15
-
static void ready()
Definition: swap.cpp:296
+
static void ready()
Definition: swap.cpp:314
@@ -531,24 +549,24 @@

Checks to see if the SWAP has been initialized. If not, it forces a system crash with swapcrash().

-

Definition at line 296 of file swap.cpp.

+

Definition at line 314 of file swap.cpp.

References Crash::forceHalt().

-

Referenced by create(), init(), read(), sdelete(), and update().

-
297  {
-
298  // Check if swap was initialized
-
299  if(SD.exists("/swap"))
-
300  {
-
301  return;
-
302  }
-
303  // Swap not found, crash system
-
304  #ifdef CRASH_MSG_DETAIL
-
305  Crash::forceHalt("Swap directory not found.");
-
306  #else
-
307  Crash::forceHalt("Ex017");
-
308  #endif
-
309  }
+

Referenced by create(), init(), read(), sdelete(), and update().

+
315  {
+
316  // Check if swap was initialized
+
317  if(SD.exists("/swap"))
+
318  {
+
319  return;
+
320  }
+
321  // Swap not found, crash system
+
322  #ifdef CRASH_MSG_DETAIL
+
323  Crash::forceHalt("Swap directory not found.");
+
324  #else
+
325  Crash::forceHalt("Ex017");
+
326  #endif
+
327  }
static void forceHalt(String msg)
Definition: crash.cpp:15
@@ -576,31 +594,31 @@

Removes the requested SWAP object from the SWAP space.

-

Definition at line 275 of file swap.cpp.

+

Definition at line 293 of file swap.cpp.

-

References Crash::forceHalt(), GetPath(), and ready().

+

References Crash::forceHalt(), GetPath(), and ready().

-

Referenced by Parse::Opcode::System::SWAP::DELETE(), and update().

-
276  {
-
277  // Make sure swap is ready
-
278  Swap::ready();
-
279  // Check to see if file exists
-
280  if(SD.exists(Swap::GetPath(name)))
-
281  {
-
282  // Remove file
-
283  SD.remove(Swap::GetPath(name));
-
284  return;
-
285  }
-
286  // IO error, crash the system
-
287  #ifdef CRASH_MSG_DETAIL
-
288  Crash::forceHalt("Error deleting swap file on SD card.");
-
289  #else
-
290  Crash::forceHalt("Ex016");
-
291  #endif
-
292  }
+

Referenced by Parse::Opcode::System::SWAP::DELETE(), and update().

+
294  {
+
295  // Make sure swap is ready
+
296  Swap::ready();
+
297  // Check to see if file exists
+
298  if(SD.exists(Swap::GetPath(name)))
+
299  {
+
300  // Remove file
+
301  SD.remove(Swap::GetPath(name));
+
302  return;
+
303  }
+
304  // IO error, crash the system
+
305  #ifdef CRASH_MSG_DETAIL
+
306  Crash::forceHalt("Error deleting swap file on SD card.");
+
307  #else
+
308  Crash::forceHalt("Ex016");
+
309  #endif
+
310  }
static String GetPath(String name)
Definition: swap.cpp:71
static void forceHalt(String msg)
Definition: crash.cpp:15
-
static void ready()
Definition: swap.cpp:296
+
static void ready()
Definition: swap.cpp:314
@@ -637,22 +655,22 @@

Replaces the requested SWAP object with the given value.

-

Definition at line 263 of file swap.cpp.

+

Definition at line 281 of file swap.cpp.

-

References create(), ready(), and sdelete().

+

References create(), ready(), and sdelete().

Referenced by Parse::Opcode::Var::Strings::ADDS(), Parse::Opcode::IO::Files::FILEREAD(), Parse::Opcode::Var::Strings::GETC(), Stack::pop(), Stack::push(), and Parse::Opcode::System::SWAP::SET().

-
264  {
-
265  // Make sure swap is ready
-
266  Swap::ready();
-
267  // Delete old value
-
268  Swap::sdelete(name);
-
269  // Create new value
-
270  Swap::create(name, value);
-
271  }
-
static void sdelete(String name)
Definition: swap.cpp:275
+
282  {
+
283  // Make sure swap is ready
+
284  Swap::ready();
+
285  // Delete old value
+
286  Swap::sdelete(name);
+
287  // Create new value
+
288  Swap::create(name, value);
+
289  }
+
static void sdelete(String name)
Definition: swap.cpp:293
static void create(String name, String value)
Definition: swap.cpp:83
-
static void ready()
Definition: swap.cpp:296
+
static void ready()
Definition: swap.cpp:314
@@ -663,7 +681,7 @@ diff --git a/docs/html/classTokenizer-members.html b/docs/html/classTokenizer-members.html index f4434ba..f3d5e63 100644 --- a/docs/html/classTokenizer-members.html +++ b/docs/html/classTokenizer-members.html @@ -92,7 +92,7 @@ diff --git a/docs/html/classTokenizer.html b/docs/html/classTokenizer.html index 3fd6d77..e732f0b 100644 --- a/docs/html/classTokenizer.html +++ b/docs/html/classTokenizer.html @@ -135,7 +135,7 @@

Definition at line 18 of file tokenizer.cpp.

-

References Swap::read(), and Output::write().

+

References Swap::read(), and Output::write().

Referenced by Parse::run().

19  {
@@ -230,7 +230,7 @@
108  resultToken = "TKERROR";
109  return resultToken;
110  }
-
static String read(String name)
Definition: swap.cpp:120
+
static String read(String name)
Definition: swap.cpp:129
static void write(String msg)
Definition: output.cpp:57
@@ -242,7 +242,7 @@ diff --git a/docs/html/classch__Serial-members.html b/docs/html/classch__Serial-members.html index 141fd1e..b860860 100644 --- a/docs/html/classch__Serial-members.html +++ b/docs/html/classch__Serial-members.html @@ -93,7 +93,7 @@ diff --git a/docs/html/classch__Serial.html b/docs/html/classch__Serial.html index baf8889..e98884f 100644 --- a/docs/html/classch__Serial.html +++ b/docs/html/classch__Serial.html @@ -100,7 +100,7 @@

Detailed Description

-

Definition at line 17 of file output.h.

+

Definition at line 21 of file output.h.

Member Function Documentation

@@ -192,7 +192,7 @@
diff --git a/docs/html/classes.html b/docs/html/classes.html index e347c0c..c09dc6f 100644 --- a/docs/html/classes.html +++ b/docs/html/classes.html @@ -112,7 +112,7 @@ diff --git a/docs/html/core_8cpp.html b/docs/html/core_8cpp.html index dd207b5..412d337 100644 --- a/docs/html/core_8cpp.html +++ b/docs/html/core_8cpp.html @@ -100,7 +100,7 @@ diff --git a/docs/html/core_8cpp_source.html b/docs/html/core_8cpp_source.html index 75c2bb1..7f3b4b8 100644 --- a/docs/html/core_8cpp_source.html +++ b/docs/html/core_8cpp_source.html @@ -90,8 +90,8 @@
Go to the documentation of this file.
1 // This software is provided "as is" with //
3 // no warranty of any kind. Use this software //
-
4 // at your own risk. Distributed under the //
-
5 // MIT license. Copyright 2015 Joshua Zenn. //
+
4 // at your own risk. Protected under the GPL //
+
5 // v2.0 license. Copyright 2015 NETponents. //
7 
8 #include <Arduino.h>
9 #include <SD.h>
@@ -125,7 +125,7 @@
diff --git a/docs/html/core_8h.html b/docs/html/core_8h.html index 360ecb4..4dd269a 100644 --- a/docs/html/core_8h.html +++ b/docs/html/core_8h.html @@ -101,7 +101,7 @@ diff --git a/docs/html/core_8h_source.html b/docs/html/core_8h_source.html index 2a03604..0d4ddc3 100644 --- a/docs/html/core_8h_source.html +++ b/docs/html/core_8h_source.html @@ -90,8 +90,8 @@
Go to the documentation of this file.
1 // This software is provided "as is" with //
3 // no warranty of any kind. Use this software //
-
4 // at your own risk. Distributed under the //
-
5 // MIT license. Copyright 2015 Joshua Zenn. //
+
4 // at your own risk. Protected under the GPL //
+
5 // v2.0 license. Copyright 2015 NETponents. //
7 
8 #ifndef HEADER_CORE
9  #define HEADER_CORE
@@ -108,7 +108,7 @@
diff --git a/docs/html/crash_8cpp.html b/docs/html/crash_8cpp.html index 7a37cec..a0178cc 100644 --- a/docs/html/crash_8cpp.html +++ b/docs/html/crash_8cpp.html @@ -96,7 +96,7 @@ diff --git a/docs/html/crash_8cpp_source.html b/docs/html/crash_8cpp_source.html index 20c0ea9..359e6aa 100644 --- a/docs/html/crash_8cpp_source.html +++ b/docs/html/crash_8cpp_source.html @@ -90,8 +90,8 @@
Go to the documentation of this file.
1 // This software is provided "as is" with //
3 // no warranty of any kind. Use this software //
-
4 // at your own risk. Distributed under the //
-
5 // MIT license. Copyright 2015 Joshua Zenn. //
+
4 // at your own risk. Protected under the GPL //
+
5 // v2.0 license. Copyright 2015 NETponents. //
7 
8 #include <Arduino.h>
9 #include "stack.h"
@@ -126,7 +126,7 @@
diff --git a/docs/html/crash_8h.html b/docs/html/crash_8h.html index 735a2ac..fde561c 100644 --- a/docs/html/crash_8h.html +++ b/docs/html/crash_8h.html @@ -101,7 +101,7 @@ diff --git a/docs/html/crash_8h_source.html b/docs/html/crash_8h_source.html index 81c3749..fc3ad9d 100644 --- a/docs/html/crash_8h_source.html +++ b/docs/html/crash_8h_source.html @@ -90,8 +90,8 @@
Go to the documentation of this file.
1 // This software is provided "as is" with //
3 // no warranty of any kind. Use this software //
-
4 // at your own risk. Distributed under the //
-
5 // MIT license. Copyright 2015 Joshua Zenn. //
+
4 // at your own risk. Protected under the GPL //
+
5 // v2.0 license. Copyright 2015 NETponents. //
7 
8 #ifndef HEADER_CRASH
9  #define HEADER_CRASH
@@ -108,7 +108,7 @@
diff --git a/docs/html/dir_68267d1309a1af8e8297ef4c3efbcdba.html b/docs/html/dir_68267d1309a1af8e8297ef4c3efbcdba.html index 0c8aab4..a71a2c8 100644 --- a/docs/html/dir_68267d1309a1af8e8297ef4c3efbcdba.html +++ b/docs/html/dir_68267d1309a1af8e8297ef4c3efbcdba.html @@ -119,7 +119,7 @@ diff --git a/docs/html/files.html b/docs/html/files.html index ff03dbe..84d1e5f 100644 --- a/docs/html/files.html +++ b/docs/html/files.html @@ -107,7 +107,7 @@ diff --git a/docs/html/functions.html b/docs/html/functions.html index 0120811..80c6e2e 100644 --- a/docs/html/functions.html +++ b/docs/html/functions.html @@ -268,7 +268,7 @@

- w -