Fatal error initialising file system

I appear to have somehow corrupted the FLASH file system in a number of Digi ConnectCore9P 9215 modules. When the system starts it fails to boot and the on-board LEDs Flash.

I have tracked this in the debugger to the lines in bsproot.c
if (filesystem_init ()) /*initialize file system for C lib functions and ftp, email, http modules */
netosFatalError (“Unable to initialize file system”, 1, 1);
and it is hanging up with the netosFatalError. I have tried reloading both rom.bin, and image.bin using JTAG with a simple sample project. This sample works OK but other code that has worked properly will not run in these units due to this error.

Any help on resolving this or reinitialising the FLASH to get it to work agian would be much appreciated.

This application that now fails, did it used to run correctly on the Digi CC9215? If yes, then any idea what changed?

Now to directly answer your question, in the src\examples directory of your distribution tree, there is an application entitled naflash. There is (I believe) a similar application under ESP (NET+OS sample applications/projects). It can/will go through and completely wipe FLASH clean. You’d then have to reload rom.bin and image.bin using an ftp example application (available through gnu cli or ESP), using a debugger (the jlink for example).

Hi dakotas_dad,

Many thanks, that worked like a dream, and I now have things working, again.

The origional application had a modified bootlader, and a large application that used updated ‘bootldr.dat’ files to change size of bootlader. The same app runs onthe 9P EM and ME modules, and it appears that the ME version got downloaded to some modules and seemed to cause the problem.

Running the naflash app from the debugger, and then using the ftpserver app under the debugger to load the original app got it all working. Many thanks!!