Rabbit Minimal gForth Loader

(Keep It Simple, Stupid!)

 

The Rabbit Semiconductor Technical Notes on large sector flash devices suggest that there may be some configurations of their core modules that will not support FS2 on the first flash. (See TN226, TN216, TN218)

 

This version uses Rabbit Serial Port A (the same one used for programming).

LOADER_GF.C

gforth.bin

 

Normal operation

#define DEBUG_PRINT FALSE

Uncheck [Include debug code/RST 28 instructions]

[Compile to Target]

Success if message: "Program successfully compiled to flash. Disconnect target and toggle reset line to run."

Power off.

Connect the "DIAG" cable.

Power on.

 

Diagnostic operation

#define DEBUG_PRINT TRUE

Check [Include debug code/RST 28 instructions]

[Compile to Target]

[Run]

 

Success if Stdio Window opens (actual numbers may vary):

 

Then after a second or two…

Error Window. "While Debugging: Timeout while waiting for response from target."

This is normal. gForth starts and the BIOS stops interacting with Dynamic-C.

Clicking on OK in the Error Window will close the Stdio Window.

 

This version has no built in mechanism for extending the gForth image. If you want to build a gForth image with your new definitions, you’ll have to add them to the source for the gForth cross compiler, or implement a mechanism to capture the image as a new binary file and then re-run LOADER_GF.C with the new gForth image.

 

http://home.mho.net/jswaby/fb.html Binary File Utility

http://srecord.sourceforge.net/ S-Record Utility

 

One promising way to do this is to compile the LOADER_GF.C to a .bin file with the #ximport commented out.

Use gforthimage.c compiled to a .bin to place the image into flash.

Step 1: RFU gforthimage.bin

Step 2: RFU loader_gf.bin

 

TODO: implement gforth binary utilities…this runs on your desktop system.

 

| © 2005 Ken Staton