|
Arduino-FVM
Byte Token Threaded Forth Virtual Machine (FVM) for Arduino
|
#include "FVM.h"
Go to the source code of this file.
Macros | |
| #define | PREFIX "WORD" |
| #define | THEN_CODE FORWARD_RESOLVE_CODE |
| #define | BEGIN_CODE BACKWARD_MARK_CODE |
| #define | WHILE_CODE IF_CODE |
Functions | |
| FVM_OP (HERE) | |
| FVM_OP (ZERO) | |
| FVM_OP (C_COMMA) | |
| FVM_OP (OVER) | |
| FVM_OP (MINUS) | |
| FVM_OP (SWAP) | |
| FVM_OP (C_STORE) | |
| FVM_OP (COMPILE) | |
| FVM_OP (ZERO_BRANCH) | |
| FVM_CALL (FORWARD_MARK) | |
| FVM_OP (BRANCH) | |
| FVM_CALL (FORWARD_RESOLVE) | |
| FVM_CALL (BACKWARD_RESOLVE) | |
| FVM_CALL (AGAIN) | |
| FVM_OP (DO) | |
| FVM_CALL (BACKWARD_MARK) | |
| FVM_OP (LOOP) | |
| FVM_OP (PLUS_LOOP) | |
| FVM_SYMBOL (15, LEFT_BRACKET,"[") | |
| FVM_SYMBOL (16, COMMENT,"(") | |
| FVM_SYMBOL (17, DOT_QUOTE,".\"") | |
| FVM_SYMBOL (18, LITERAL,"literal") | |
| FVM_SYMBOL (19, SEMICOLON,";") | |
| FVM_SYMBOL (20, RIGHT_BRACKET,"]") | |
| FVM_SYMBOL (21, COLON,":") | |
| FVM_SYMBOL (22, VARIABLE,"variable") | |
| FVM_SYMBOL (23, CONSTANT,"constant") | |
| FVM_SYMBOL (24, COMPILED_WORDS,"compiled-words") | |
| FVM_SYMBOL (25, GENERATE_CODE,"generate-code") | |
| void | setup () |
| void | loop () |
| void | compiled_words (Stream &ios) |
| void | generate_code (Stream &ios) |
Variables | |
| const int | THEN = 5 |
| const char | THEN_PSTR [] = "then" |
| const int | BEGIN = 7 |
| const char | BEGIN_PSTR [] = "begin" |
| const int | WHILE = 10 |
| const char | WHILE_PSTR [] = "while" |
| const int | DATA_MAX = 32 * 1024 |
| const int | WORD_MAX = 128 |
| uint8_t | data [DATA_MAX] |
| FVM | fvm (data, DATA_MAX, WORD_MAX) |
| FVM::Task< 64, 32 > | task (Serial) |
| bool | compiling = false |
| #define BEGIN_CODE BACKWARD_MARK_CODE |
Definition at line 137 of file Compiler.ino.
| #define PREFIX "WORD" |
Definition at line 67 of file Compiler.ino.
| #define THEN_CODE FORWARD_RESOLVE_CODE |
Definition at line 124 of file Compiler.ino.
| #define WHILE_CODE IF_CODE |
Definition at line 155 of file Compiler.ino.
| void compiled_words | ( | Stream & | ios | ) |
Definition at line 376 of file Compiler.ino.
| FVM_CALL | ( | FORWARD_MARK | ) |
| FVM_CALL | ( | FORWARD_RESOLVE | ) |
| FVM_CALL | ( | BACKWARD_RESOLVE | ) |
| FVM_CALL | ( | AGAIN | ) |
| FVM_CALL | ( | BACKWARD_MARK | ) |
| FVM_OP | ( | HERE | ) |
| FVM_OP | ( | ZERO | ) |
| FVM_OP | ( | C_COMMA | ) |
| FVM_OP | ( | OVER | ) |
| FVM_OP | ( | MINUS | ) |
| FVM_OP | ( | SWAP | ) |
| FVM_OP | ( | C_STORE | ) |
| FVM_OP | ( | COMPILE | ) |
| FVM_OP | ( | ZERO_BRANCH | ) |
| FVM_OP | ( | BRANCH | ) |
| FVM_OP | ( | DO | ) |
| FVM_OP | ( | LOOP | ) |
| FVM_OP | ( | PLUS_LOOP | ) |
| FVM_SYMBOL | ( | 15 | , |
| LEFT_BRACKET | , | ||
| "[" | |||
| ) |
| FVM_SYMBOL | ( | 16 | , |
| COMMENT | |||
| ) |
| FVM_SYMBOL | ( | 17 | , |
| DOT_QUOTE | , | ||
| ".\"" | |||
| ) |
| FVM_SYMBOL | ( | 18 | , |
| LITERAL | , | ||
| "literal" | |||
| ) |
| FVM_SYMBOL | ( | 19 | , |
| SEMICOLON | , | ||
| ";" | |||
| ) |
| FVM_SYMBOL | ( | 20 | , |
| RIGHT_BRACKET | , | ||
| "]" | |||
| ) |
| FVM_SYMBOL | ( | 21 | , |
| COLON | , | ||
| ":" | |||
| ) |
| FVM_SYMBOL | ( | 22 | , |
| VARIABLE | , | ||
| "variable" | |||
| ) |
| FVM_SYMBOL | ( | 23 | , |
| CONSTANT | , | ||
| "constant" | |||
| ) |
| FVM_SYMBOL | ( | 24 | , |
| COMPILED_WORDS | , | ||
| "compiled-words" | |||
| ) |
| FVM_SYMBOL | ( | 25 | , |
| GENERATE_CODE | , | ||
| "generate-code" | |||
| ) |
| void generate_code | ( | Stream & | ios | ) |
Definition at line 391 of file Compiler.ino.
| void loop | ( | ) |
Definition at line 270 of file Compiler.ino.
| void setup | ( | ) |
Definition at line 263 of file Compiler.ino.
| const int BEGIN = 7 |
Definition at line 135 of file Compiler.ino.
| const char BEGIN_PSTR[] = "begin" |
Definition at line 136 of file Compiler.ino.
| bool compiling = false |
Definition at line 261 of file Compiler.ino.
| uint8_t data[DATA_MAX] |
Definition at line 256 of file Compiler.ino.
| const int DATA_MAX = 32 * 1024 |
Definition at line 253 of file Compiler.ino.
| FVM::Task<64,32> task(Serial) |
| const int THEN = 5 |
Definition at line 122 of file Compiler.ino.
| const char THEN_PSTR[] = "then" |
Definition at line 123 of file Compiler.ino.
| const int WHILE = 10 |
Definition at line 153 of file Compiler.ino.
| const char WHILE_PSTR[] = "while" |
Definition at line 154 of file Compiler.ino.
| const int WORD_MAX = 128 |
Definition at line 254 of file Compiler.ino.