Refining FORTH to enable more productive development

This commit is contained in:
Jeremiah Orians 2017-06-17 00:02:33 -04:00
parent 1e28eadc7a
commit b3eedb60de
No known key found for this signature in database
GPG Key ID: 7457821534D2ACCD
6 changed files with 10 additions and 5 deletions

3
.gitignore vendored
View File

@ -22,7 +22,8 @@ roms/
prototypes/
# Generated files that don't need to be version controlled
libvm.so
*.so
*.o
tape_*
rom
*.qst

View File

@ -29,6 +29,7 @@ Extended VPATH in makefile to shorten dependency names
Updated checksum for stage2 forth
Reversed the order of operands in stage2 forth arithmetic
Modified webIDE to leverage new enhanced disassembler output
Altered stage2 forth KEY to echo keypress so that S" and similiar functions behave like gforth
** Fixed
Stack offset bug in stage2 forth was found and fixed by reepca in record time

View File

@ -174,7 +174,7 @@ Then we use our M0 Line macro assembler to convert our assembly into hex2 format
Then we need to assemble that hex into our desired program:
./bin/vm --rom roms/stage1_assembler-2 --tape_01 temp2 --tape_02 roms/forth --memory 48K
roms/forth should with the sha256sum of 8b31c02b98d85bcc8049d3a56395abb8a1494d153be5536c528dbfd553889477
roms/forth should with the sha256sum of 9b84fb95fd00d83f27a2d9b96472a78baa40f10f4b1868624e299bfb16cda399
Our forth will first attempt to evaluate any code in tape_01 and then evaluate any code that the user types in
(Otherwise there is no way for a forth fan to have a chance against the lisp in terms of being able to bootstrap something cool)

View File

@ -817,6 +817,8 @@
:Key_Code
COPY R1 R7 ; Using designated IO
FGETC ; Get a byte
CMPSKIPI.NE R1 0 ; If not TTY
FPUTC ; Skip Echoing
PUSHR R0 R14 ; And push it onto the stack
JSR_COROUTINE R11 ; NEXT

View File

@ -17,9 +17,10 @@
\ Simply cat this file to the top of any forth program that leverages its functionality
\ then execute the resulting out put as so:
\ ./bin/vm-production --rom roms/forth --memory 1M --tape_01 The_combined_file
\ ./bin/vm --rom roms/forth --memory 1M --tape_01 The_combined_file
\ All writes via WRITE8 will be written to tape_02 or whatever name you prefer via the --tape_02 option
\ However should you wish to leverage readline for interacting with forth use vm-production but be warned
\ WILL see duplicate lines being printed when you hit enter as both readline and the forth are echoing your key strokes
\ Define our CELL size as 4 bytes
: CELL 4 ;

View File

@ -1,6 +1,6 @@
8f465d3ec1cba00a7d024a1964e74bb6d241f86a73c77d95d8ceb10d09c8f7b9 roms/CAT
59f0502748af32e3096e026a95e77216179cccfe803a05803317414643e2fcec roms/DEHEX
8b31c02b98d85bcc8049d3a56395abb8a1494d153be5536c528dbfd553889477 roms/forth
9b84fb95fd00d83f27a2d9b96472a78baa40f10f4b1868624e299bfb16cda399 roms/forth
4c146297da8c672955698a82207295b28feb389c9856a2c6ea6a60ce7e84260a roms/lisp
2b9727381aec15a504c0898189fbc2344209d8e04451e3fa5d743e08e38f64cf roms/M0
24a4d74eb2eb7a82e68335643855658b27b5a6c3b13db473539f3e08d6f26ceb roms/SET