Table of Contents

[hemmerling] FORTH 7/7 - H2oForth

Related pages:

Other possible Names for my FORTH

  1. Chameleon FORTH.
  2. Dolly FORTH ( from EN.Wikipedia "Dolly (sheep)".
  3. Clone FORTH.

Features

Architectural Decisions

  1. Supported Architectures: Support for both the common “Von Neumann architecture” EN.Wikipedia "Von Neumann architecture" and the rare “Harvard architecture” ( EN.Wikipedia "Harvard architecture" ).
    • With “Harvard architecture”, read-only data, e.g. struct tables and strings, is stored in ( Flash ) ROM. For the ARDUINO AVR C/C++ compiler, this is achieved by adding the keyword “PROGMEM” to such read-only data. To access the data, special code is necessary, e.g. “pgm_read_ptr()”.
  2. Planned support for a large number of wordsets of historical FORTH implementations, if possible ( Note that not yet all wordsets are implemented, i.e. all FORTH wordsets after FORTH83 & VolksForth are not yet implemented ).
    1. #define AIM65_FORTH 1
    2. #define ATARICOINUP_FORTH 2
    3. #define BBCMICRO_FORTH 3
    4. #define BIG_FORTH 4
    5. #define CAMEL_FORTH 5
    6. #define COLOR_FORTH 6
    7. #define E_FORTH 7
    8. #define FIG_FORTH 8
    9. #define FORTH79 9
    10. #define FORTH79_REQ_DBL_ASM_EXP_REF 10
    11. #define FORTH79_NUC_INTERP_COMP 11
    12. #define FPC_FORTH 12
    13. #define GNU_FORTH 13
    14. #define HECTOR_FORTH 14
    15. #define JUPITER_FORTH 15
    16. #define KNAGGSBENNET_FORTH 16
    17. #define LAXONPERRY_FORTH 17
    18. #define LAXONPERRY_PC_FORTH 18
    19. #define LAXONPERRY_CPM_FORTH 19
    20. #define LAXONPERRY_CPM68K_FORTH 20
    21. #define LMI_FORTH 21
    22. #define LMI_MSDOS_FORTH 22
    23. #define LMI_WIN_FORTH 23
    24. #define MECRISP_FORTH 24
    25. #define MVP_FORTH 25
    26. #define NELSON_FORTH 26
    27. #define NELSON_ESP_FORTH 27
    28. #define NELSON_UE_FORTH 28
    29. #define PATEL_FORTH 29
    30. #define Q_FORTH 30
    31. #define RCAMICRO_FORTH 31
    32. #define RSC_FORTH 32
    33. #define SECTOR_FORTH 33
    34. #define TERSE_FORTH 34
    35. #define VOLK_FORTH 35
    36. #define VOLK_C64_FORTH 36
    37. #define VOLK_ST_FORTH 37
    38. #define VOLK_CPM_FORTH 38
    39. #define VOLK_PC_FORTH 39
    40. #define WIN32_FORTH 40
  3. Providing of the original error messages of historical FORTH implementations ( if available as list, e.g. printed in a manual ).
  4. Option for “DoublePrecision Integer” ( just if sizeof(LONG_LONG)>sizeof(int). Not available with Arduino AVR C/C++ and Borland C++ 5.5.1 ).
  5. Option for “Float” ( So far, Brad Nelson's “ESP32Forth v.7.05” and “Jupiter Ace” the only FORTH implementation with built-in Float words, for which I implemented a FORTH wordlist )
  6. Planned support of several C architectures ( XXYYZZBit = Int=XX, PTR=YY, Long(Long)=ZZ ):
    1. #define SYSTEM_ARCHITECTURE_HOST 0
    2. #define SYSTEM_ARCHITECTURE_081616BIT 1
    3. #define SYSTEM_ARCHITECTURE_161632BIT 2
    4. #define SYSTEM_ARCHITECTURE_323232BIT 3
    5. #define SYSTEM_ARCHITECTURE_326464BIT 4
    6. #define SYSTEM_ARCHITECTURE_646464BIT 5
    7. #define SYSTEM_ARCHITECTURE_6464128BIT 6

Step 1: Setting up the Development System

Install a MinGW C Development System on Windows & Visual Studio Code IDE

Software Installation

*MinGW - Minimalist GNU for Windows”, version 6.3 - My choice, as this is the development system for Lua 6.3. *Sourceforge "MinGW - Minimalist GNU for Windows".

Software Configuration

Step 2: Software Development by Waterfall Model

FORTH Interpreter

Step 2.1: Component #2a - Parser: Basic Parser

Step 2.2: Component #1 - Command Line Interface

Step 2.3: Component #2b - Parser: Process Input according to given Command Line Interface Options

Step 2.4: Component #2c - Parser: Detect Integer, Double Integer, Float

Step 2.5: Component #3a - Vocabularies: Collect and implement Wordlists

Step 2.6: Component #2d - Parser & Interpreter: Add Interpreter Mode

Step 2.7: Component #3b - Vocabularies: Interpret Mode Words

Step 2.8: Component #4 - Message System and Error Handling System

Step 2.9: Moving read-only data into Flash ROM

Step 2.10: Component #2e - Parser & Interpreter & Compiler: Add Compile Mode

FORTH Compiler

Step 2.11: Component #3c - Vocabularies: Statically defined FORTH Words

Step 2.11: Component #2f - Parser & Interpreter: Separate Parser from Interpreter

Step 2.12: Component #3d - Vocabularies: Compile Mode Words

Resources


When this document changes ! Site Navigation ( My Business ! My Topics ! Imprint / Contact ! Privacy Policy ! Keyword Index ! ! Google+ Publisher "hemmerling" )