★ APPLICATIONS ★ PROGRAMMATION ★ Follow the Forth protocol|Computing with the Amstrad) ★ |
Hisoft Forth | Applications Programmation |
Stephen Devine evaluates Hisoft's language implementation customised for the CPC6128 THIS HiSoft version of Forth is a full implementation for use under CP/M Plus. It is also available for the PCW and the review copy contained both versions on the same disc. It conforms to the popular FIG (Forth Interest Group) standard with no extras in the basic system. Forth, however, is an extensible language and, in the true spirit of this, HiSoft has provided many extra features in the form of support libraries. This means that you don't need to clutter up precious memory with all the features at once, but can select only those required by a particular application. Four such libraries are provided. The first is a utility library which extends the system to include such features as strings and arrays as well as a full CASE statement familiar to Pascal and C users. The second, CPM.LIB, allows you to access the BDOS to perform your own disc filing operations. Then there's ASSEMBLE.LIB which, as its name suggests, is a Z80 assembler. As well as having the usual Z80 mnemonics, it supports loops and conditional statements. Perhaps the most interesting library is GSX.LIB. This opens up the full range of the CPC's high-resolution graphics and allows you to output some very impressive results. As with most Forths, programs can be entered directly from the command line and tested right away. But in order to make development easier, use the proper Forth method of entering text into 'screens'. These allow you to develop very large programs using the disc as extra memory. HiSoft Forth contains a full screen editor which makes the use of screens very easy. Each screen consists of up to 16 lines of 64 characters and using the arrow keys you can move around and enter text wherever you wish in either overwrite or insert mode. You can also move freely from one screen to another without leaving the editor-not all implementations allow this. When you've finished editing a screen it is automatically saved and you can continue on a new blank screen. Unfortunately, the editor does not have a find or search/replace facility but it is possible to step through screens fairly rapidly to find a particular item. A blank file of 50 screens is provided to develop your own programs and this can be extended. A manual is supplied in the form of an 84-page A5 booklet in three parts. Part one contains a brief description of Forth on the CPC6128, a list of editor commands, and details of all the support libraries supplied. This is followed by a section of over 20 pages which, although not claiming to be a full tutorial, provides a very clear and thorough introduction to The final section consists of three appendices containing a list of error messages, a full glossary of the words provided in the basic implementation, and a useful list of books on Forth. There's no index but this shouldn't . be a drawback given the very clear layout of the manual. There are other files on the disc, the most important of which is READ.ME, containing essential information missing from the manual. Among the topics covered are the use of the printer, various extensions to the library files, and some important changes to the editor commands. It also has details of three utility programs provided: WD.COM - for deleting files - similar to ERASE.COM but easier to use, WP.COM - for copying files - like PIP.COM but more user friendly, and SD.COM - for listing disc directories - much better than DIR.COM and far smaller at less than 1k. These are not public domain utilities but have been specially written by HiSoft to provide similar facilities. If you think Forth might be the language for you and you want to use it in a CP/M environment, I can certainly recommend this version. With its various support libraries and the extra disc utilities provided you have a complete package that is hard to beat.
|