PIC Forth

Programming a PIC can be tackled in a number of ways, Assembler, Basic, C and Forth. It is this later method that I employ, usually with a little assembler. The program F2P will convert Forth source into Assembler source suitable for use as an input file to the Microchip PIC Assembler. The resultant output being loadable PIC code. F2P was written by Michael Josefsseon and the version included in the file download is dated August 1997, my thanks to him for providing the application as shareware. It includes a description and with my project files a good idea of how to produce PIC code should be obtained.



Note that F2P does not function as a Forth system in the conventional way, you cannot run the Forth code in its native form, F2P is not an interpreter nor a compiler, it converts Forth to PIC assembler. Even with this limitation it has proved to be a quick method of producing working PIC code. As the intermediate stage produces assembler it is an easy matter to extract the PIC machine code and include it in the Forth source directly. You would do this to produce faster execution as well as a more compact code module.

To download the files required follow the first link below.

Last modified at :