AMC 68VZ328 software manual Creating a ROM image, Customizing the filesystem

Page 35

Creating a ROM image

Before using the development hardware a file system will need to be created for use on it. The ‘/ opt/fs’ directory contains the tools necessary to create a filesystem image. From this directory run the Makefile. The first time you run this it will compile all the tools that will be used on the dimmPCI platform itself, subsequently it will create an image for download.

make imagez.bin

An explanation of some of the more important files and sub-directories in the ‘/opt/fs’ directory:

imagez.bin

- this contains both the µClinux kernel and the filesystem,

 

ready to be programmed to the dimmPCI platform.

linux

- a link to where the µClinux kernel source and binaries reside.

romdisk

- the set of files that will make up the root file system on the

 

dimmPCI module.

src

- source code for each of the tools available on the dimmPCI module.

Any time after the files have been modified in the romdisk directory, typing the following will create a new image file:

make imagez.bin

This will compress the filesystem and the ‘linux.bin’ kernel file into a single image file, ‘imagez.bin’. The one file is all that is necessary to program onto the dimmPCI CPU module in order for it to operate properly.

Customizing the filesystem

Before programming the dimmPCI module for the first time, the filesystem should be configured so that it does what is wanted from it the first time. These are the files, which control the startup and initialization process in the filesystem. They are stored in the ‘/opt/fs/romdisk/etc’ directory. The files are:

www.amctechcorp.com

35

Image 35
Contents DimmPCITM 68VZ328 Hardware / Software Manual DimmPCITM Software Development Kit Copyright noticeContact Information NETdimm Developers Kit Quick Start Guide Etc/issue Page This page left intentionally blank Launching Linux at the embedded IntroductionPage System Requirements What’s on the CD?This page left intentionally blank Backplane FeaturesUC68VZ328 Embedded Microcontroller CPU ModuleCPU Module Description General DescriptionBackplane Description CPU Architecture ArchitectureMemory Map MCU CoreSystem Memory Memory Map MemoryLayout of the Flash and Flash Schematic Layout of the Flash Sdram Viewing the Ethernet MAC ID Ethernet ControllerNETdimm Ethernet Schematic IOdimm Digital I/ODigital Output Schematic Analog Output Schematic Analog Input Schematic Digital to Analog Converter Schematic Highlights RS-232Watchdog Usage LCD Interface LCD SchematicDimmPCITM signals for System Slot DimmPCITM Signal DescriptionsPCI Maximum Ratings Electrical Characteristics This page left intentionally blank Before beginning Installing the dimmPCI TM SystemInstallation Builder KitConfiguring and compiling the µClinux kernel Customizing the filesystem Creating a ROM imageAccessing your dimmPCI development board via the serial port Dynamic IP Accessing the NetworkStatic IP Compiling your own source code Accessing your dimmPCI development board via telnetUsing NFS to streamline the development cycle Home directory/dimmpci/source Method Updating Applications on your dimmPCI moduleThis page left intentionally blank Loader Programming the uC68VZ328Oops Cd /opt/boottools/oops Oops -p /dev/ttyS0 -k kernel.bin Page Page This page left intentionally blank Sample Code AppendixClose the file afterwards fclose filehandle Page Longwatchdogid #include unistd.h #include stdio.h int main void This page left intentionally blank Journalling Flash File System Umount /usr Sbin/mkjffs /dev/flash0 Page This page left intentionally blank Development Tool Chains Normal Usage of the PIC-COFFTool Chain Page This page left intentionally blank Introduction D1 Application NoteKernel and Filesystem Configuration YES Kernel and Filesystem Configuration Flow ChartAvailable Digital I/O Pins List of all available digital I/O pins Dimmio structure description Programming StructureDigital I/O Functions Page In0 In1 In2 In3 In4 In5 In6 In7 Out0 Even Parity Sample ProgramsMknod io1 c 123 Page This page left intentionally blank Abstract D2 Application NoteRequirements Kernel ConfigurationAgain, from the main menu under Network device support Kernel Configuration Flow Chart AtCommandPrompt Filesystem Configuration Cd /opt/filesystem name make clean Make Modifications to ‘rc’ file Filesystem Configuration Flow ChartTesting Host machine ConfigurationPage This page left intentionally blank Application Note Using Multiple NETdimm ModulesInetd based Server & Client Simple Server & ClientPage This page left intentionally blank IOdimm Using Analog and Digital I/O withCd /opt Cp -Rpdx newfs iodimmmfs ADC MAX1203 Category Channel Backplane System Backplane Header Slot Pin Available I/O PinsDigital Inputs and Outputs Functions+ Κ Iodimm/dio Samples/cardspecific/iodimm/dio Page This page left intentionally blank Purpose & basic format of files for oops Using OopsUpload & Flash Download Upload & RunCommon oops program arguments Appendix This page left intentionally blank 104 Preamble Licensing, Copyrights & LiabilityDimmPCITM Software Development Kit Distribution 106 107 108 109 Appendix How to Apply These Terms to Your New Programs No Warranty111 112 113 This page left intentionally blank 114 References/ Suggested Reading