IMFS demos ( examples ) ???

Joel Sherrill joel.sherrill at OARcorp.com
Mon Jan 3 13:09:36 UTC 2000


Rosimildo DaSilva wrote:
> 
> Hi,
> 
> I am wondering if there are some examples of how to use the
> IMFS now available on RTEMS. Something similar to the
> Network demos. A document is nice, but some examples make things a lot
> easier.

The POSIX tests actually exercise the filesystem code.
 
> It would be nice if they have:
> 
> 1. Example on how to "get" files from ROM to the FS, like ".zip" and
> ".tar.gz"

The GoAhead httpd demo includes the code to do this.  Basically it
tars the initial filesystem image up, converts it to binary using 
objcopy, and links it into the executable.

Jake Janovetz wrote the untar support so he could use the tftp
filesystem
client to load the tar image across the network but the principle is
the same.

> 2. file2rom.exe utility to read a file and generate "C" module to be
> linked with application( rom code ).

This fragment from the http test Makefile makes a "tarfile" image of the
initial filesystem, converts it to a binary (temp.o), merges it with
init.o
and them produces an executable.  This does what you are looking for.

${PGM}: $(OBJS) $(LINK_FILES)
        tar cf $(ARCH)/tarfile index.html
        $(LD) -r -o $(ARCH)/temp.o  $(ARCH)/init.o -b binary
$(ARCH)/tarfile
        $(MV) $(ARCH)/temp.o  $(ARCH)/init.o
        $(RM) $(ARCH)/temp.o
        $(make-exe)


> 3. Example on how to "mount" things.

The psxmount test has plenty of examples of this. 

> 4. Usage of the IMFS with TFTP/FTP and HTTP server.

See a recent netdemos.

> 5.   Example of updating files to remote locations through FTP/TFTP.

Hmm... I don't think this one exists yet.

I think most of the pieces are there but scattered.  What needs to be
put where so you would have found it? :)

 
> Regards, Rosimildo.
> 
> +---------------------------------------------------------------------
> | ConnectTel, Inc. - Austin, Texas.
> | Phone : 512-338-1111 - Fax : 512-918-0449
> | Email : devl at connecttel.com  or mkting at connecttel.com
> | Site  : http://www.connecttel.com
> +---------------------------------------------------------------------

-- 
Joel Sherrill, Ph.D.             Director of Research & Development
joel at OARcorp.com                 On-Line Applications Research
Ask me about RTEMS: a free RTOS  Huntsville AL 35805
   Support Available             (256) 722-9985



More information about the users mailing list