Mad Apple Forth v1.0 1 March 1989 Origins ------- Mad Apple Forth originated under DOS 3.3 from the 6502 Fig-Forth for the Apple. It was then modified by Ted St. John and Bill O'Ryan to more closely resemble the Forth-79 standard. Mad Apple Forth went through many changes during this time, at times changing so fast you couldn't keep up with the current version! Then Bill O'Ryan moved away, and Ted St. John stopped working with it to any degree. I started supporting and enhancing it about that time. Up until that time modifications to Mad Apple Forth had been done using a version of the target compiler for fig Forth modified by Mr. O'Ryan. He also tended to be the only one who could get it to work. I disassembled Mad Apple Forth into Merlin Assembler source, and then modified it to work with Prodos through the use of Forth words tacked on top of the DOS 3.3 originals. Mad Apple Forth was then converted to work with Prodos intrinsically. I also added many utilities and enhanced old ones. I converted many old utilities from DOS 3.3 to Prodos. I added a lot of Forth words, including a new DUMP and DECOMPILE. Many more words were vectored to allow fancier programming. A new "on the fly" decompiler was created. Support for 3.5" drives was added along with the ability to change the block/drive allocations on the fly. After converting Mad Apple Forth to Prodos, I then added support to the basic kernal for the Super Serial Card using interrupts and machine code for speed. Work currently continues on this version and is not yet complete. Words are included to allow complete control of Mad Apple Forth over the modem. The Future ---------- Currently Mad Apple Forth remains in 6502 code. One future improvement is therefore to convert MAF to 65802 code and full 16-bit capability. Specifically, I hope to convert MAF to 65802 code capable of running on any Apple II+ with a 65802 installed. After a 65802 conversion multitasking is high on the list. The multitasking scheme will be cooperative, and a simple priority scheme will be implemented. Semaphores will control access to various devices. The Super Serial Card support will also be converted to support multiple ports with multiple tasks. With the 65802 version may come full support as a shareware product, inluding upgrades and detailed documentation. File-oriented Forth blocks are also in the works. Up to four files will be available at one time. Using a file will supplant the entire physical drive system, prevent access to physical drives. Memory Map ---------- $95FF LIMIT - top of Forth disk buffers $91FF - (for versions containing Forth File access words) $85EF FIRST - bottom of Forth disk buffers $81EF - (for versions containing Forth File access words) $2Fxx PAD - varies... at fixed location relative to HERE $2Fxx HERE - varies... $903 Forth WARM start $900 Forth COLD start $900 Start of Forth Kernal $800 User Area $3C7 Data stack - grows downward, location fixed $300 Standard Apple vectors - Reset and control-Y are connected $200 TIB - terminal input buffer $100 Stack - the return stack $000 DP - used for W, UP, and other misc Note that FIRST is defined as a function of LIMIT and #BUFS - so to move the buffers it is only necessary to specify the number of buffers (#BUFS) and the location of the last valid buffer address (LIMIT). Revision History ---------------- Original: Mad Apple Forth begin as figForth. It was modified heavily by Bill O'Ryan, with help from Ted St. John, Marty Isaacs, and many others. Mad Apple Forth had been modified to approximate the Forth-79 standard. Dates were used to identify the most recent version of Mad Apple Forth. v1.0: Mad Apple Forth was disassembled and Merlin assembler source was created. MAF was converted to Prodos, and Prodos MLI call support was implemented. Version numbers replaced version dates. v1.1: A kernal with Super Serial Card support was released for the first time. The text comparison word -TEXT was added. A user definable bell was added. One bug - EXPECT will back the cursor past the left margin after it has beeped once - this is inherent in the original figForth source. v2.0: Planned. Create a ROMable Forth kernal. Fix EXPECT. Continue expanding Super Serial Card support. Upgrade source further to include macros and meaningful labels instead of disassembler- created data names. Note that the planned ROMable Forth kernal will by its nature have a different memory map than the current release. Word Breakdown -------------- Stats of Mad Apple Forth: 166 words, 9853 bytes; average, 27 bytes/word Breakdown (slightly dated): 20 5.46% constants 161 43.98% colon definitions 5 1.36% variables 19 5.19% user area vectors (US@X) 45 12.29% user variables 113 30.60% code definitions 1 0.27% vocabulary 1 0.27% tickles