User`s manual
UC-7408 User’s Manual Getting Started
2-14
Checking the Flash Memory Space
If the flash memory is full, you will not be able to save data to the Flash ROM. Use the following
command to calculate the amount of “Available” flash memory:
/>df –h
If there isn’t enough “Available” space for your application, you will need to delete some existing
files. To do this, connect your PC to the UC-7408 with the console cable, and then use the console
utility to delete the files from UC-7408’s flash memory.
NOTE If the flash memory is full, you will need to free up some memory space before saving files to
the Flash ROM.
Compiling Hello.c
The UC-7408 CD contains several example programs. Here we use Hello.c as an example to show
you how to compile and run your applications. Type the following commands from your PC to
copy the files used for this example from the CD to your computer’s hard drive:
# cd /tmp/
# mkdir example
# cp –r /mnt/cdrom/example/* /tmp/example
To compile the program, go to the Hello subdirectory and issue the following commands:
#cd example/hello
#make
You should receive the following response:
[root@localhost hello]# make
/usr/local/mxscaleb/bin/mxscaleb-gcc –o hello-release hello.c
/usr/local/mxscaleb/bin/mxscaleb-strip –s hello-release
/usr/local/mxscaleb/bin/mxscaleb-gcc –ggdb -o hello-debug hello.c
[root@localhost hello]# _
Next, execute the hello.exe to generate hello-release and hello-debug, which are described below:
hello-release—an IXP platform execution file (created specifically to run on UC-7408)
hello-debug—an IXP platform GDB debug server execution file (see Chapter 5 for details about
the GDB debug tool).