DeviceMaster Software Development Kit - Single File Version

Introduction

The DeviceMaster Software Developer Kit includes the basic tools required to develop eCos applications for the following Pepperl+Fuchs Comtrol, Inc. DeviceMaster platforms:

  • DeviceMaster PRO

  • DeviceMaster RTS

  • DeviceMaster UP

It is assumed that the reader has some experience with embedded software development and is familiar with software development tools under the host environment (Windows/ Cygwin or Linux).

If you are unfamiliar with the tools mentioned in the SDK documentation, you may want to locate information about Cygwin, bash, make, and tar.

You can browse the CD (left) to locate software and documentation to install and configure the SDK or use this version. The single file version (this page) and the pages in the navigational bar contain the same content.

A table of Contents has been provided for your convenience.

Kit Contents

The DeviceMaster SDK distribution contains the following:

[Note]
Note

If you ordered the Software Development Kit or purchased the DeviceMaster PRO, you will have the JTAG interface that uses RDI protocol over UDP/IP.

Hints and Tips

  • line-endings

    Do not convert source or configuration files to MS-DOS line endings. Cygwin users: use a text editor that preserves UNIX line endings (jed, vim, PFE, textpad, VisualStudio, Wordpad, etc.). Do not use Notepad to edit source files or configuration files.

  • printf()

    The stdio printf() function is not currently supported by the DeviceMaster HAL package. Use diag_printf() instead.

  • Disabling Auto-Load

    If you want to prevent the bootloader on the DeviceMaster from loading and running the default application on start-up, follow the steps in Disabling Auto-Load.

  • WinZip

    When unpacking .tar.gz files, disable smart or automatic handling of line endings for text files. Otherwise, WinZip will cause breakage by adding carriage returns to line endings.

Installation Overview

The complete SDK requires about 800Mb of disk space. The original development of the DeviceMaster and the samples in the SDK was done under RedHat Linux 8.0.

In order to develop eCos applications for the DeviceMaster, you must install at least the arm-elf tools and the pre-compiled eCos libraries. The Windows arm-elf tools require that Cygwin be installed. If you would like to modify the eCos configuration, then the eCos sources must be installed. Changes in eCos configuration require that the eCos libraries and include files be rebuilt from the eCos source tree.

Building at least one of the included sample applications is also suggested as a way to insure that the tools and libraries are operational. See Verifying the Installation for information about how to install, build, and run the serecho program that is included in the Sample_Apps directory.

GNU cross development tools (compiler, linker, assembler, debugger) are included for IA32 hosts running either Cygwin/Win32 or Linux. A complete Cygwin distribution is also included.

The following illustrates the steps to using this SDK effectively.

  1. If you are working on a Windows system, install Cygwin.

  2. Install the arm-elf tool for your operating system (Linux or Windows):

    [Note]
    Note

    Windows developers will need to install Cygwin before installing the arm-elf tools.

  3. Install the eCos library (pre-compiled eCos object libraries or eCos source libraries)

  4. Build a program (discussed in Sample Programs)

  5. Download the application to the DeviceMaster.

Installing Cygwin

[Note]
Note

If you are working on a Windows system and you have Cygwin installed, go to Installing arm-elf Tools.

If you have not previously installed Cygwin, you will need to do so before installing the arm-elf tools. The SDK provides all the files that you need for installation, which includes:

  • Installation files for the Cygwin UNIX environment for Windows DLL and associated programs

  • Compressed tar file that contains the executable binaries for the arm-elf cross platform GNU tools GCC, GDB, AS and LD.

Use the following procedure if you need to install Cygwin.

  1. Double-click on the setup.exe file in the Windows_Tools\cygwin directory, which will launch a series of dialog boxes.

  2. Select Next in the Cygwin Net Release Setup Program dialog box.

  3. Select the Install from Local Directory radio button in the Cygwin Setup dialog box and click Next.

  4. Verify that the \Windows_Tools\Cygwin directory is listed in the Local Package Directory dialog box or enter it into the text entry box and click Next.

  5. In the Select install root directory dialog box accept the default installation directory C:\Cygwin or enter the path name of an alternate directory in the Select install root directory text field..

  6. Allow Default Text File Type to default to UNIX and Install For to default unless you must restrict access to yourself and click Next.

  7. Make no changes in the Select packages to install dialog box and click Next.

    The setup.exe will begin copying files.

    [Note]
    Note

    This may take awhile depending on your system. One machine took 10 - 12 minutes.

  8. When file copying is complete you will be prompted to select a Cygwin icon on your desktop and/or in your Start Menu. Select your preference and click Next.

  9. Select OK when the Installation Complete dialog box appears.

    You now have the full power of the bash shell available on your Windows computer. For more information, see the Cygwin User’s Guide.

  10. You are ready to install the eCos library (pre-compiled or source eCos library).

Installing arm-elf Tools

The complete SDK requires about 800Mb of disk space. The original development of the DeviceMaster and the samples in the SDK was done under RedHat Linux 8.0.

Use the appropriate procedure for your system:

Linux: Installing arm-elf Tools

The Linux binaries for the Gnu ARM-elf toolchain are provided in a compressed tar archive. When un-tarred, a directory called gnutools will be created and the directory gnutools/bin will need to be added to the PATH variable. You can place the gnutools directory anywhere you like. In this example, we will install the tools under /usr/local, so /usr/local/gnutools/bin will need to be added to the user's PATH environment variable.

  1. Change to the usr/local directory.

    # cd /usr/local

  2. Unpackage the arm-elf-3.4.3-linux.tar.gz file in Linux_Tools directory.

    # tar xf arm-elf-3.4.3-linux.tar.gz

  3. Verify that the arm-elf tools installed on your system.

     # tree gnutools

    gnutools
    |-- arm-elf
    |   |-- bin
    |   |   |-- ar
    |   |   |-- as
    |   |   |-- c++
    |   |   |-- g++
    |   |   |-- gcc
    |   |   |-- ld
    |   |   |-- nm
    |   |   |-- objcopy
    |   |   |-- objdump
    |   |   |-- ranlib
    |   |   `-- strip
    |   |-- include
    |   |   |-- _ansi.h
    |   |   |-- _syslist.h
    |   |  ...  ...
    |   |   |-- wchar.h
    |   |   `-- wctype.h
    |   `-- lib
    |       |-- be
    |       |   |-- crt0.o
    |      ... ...
    |       |   `-- redboot.specs
    |       |-- crt0.o
    |       |-- iq80310.specs
    |      ...  ...
    |       |-- redboot.specs
    |       `-- thumb
    |   `- ...
    |-- bin
    |   |-- arm-elf-addr2line
    |   |-- arm-elf-ar
    |   |-- arm-elf-as
    |   |-- arm-elf-c++
    |   |-- arm-elf-c++filt
    |   |-- arm-elf-cpp
    |   |-- arm-elf-g++
    |   |-- arm-elf-gcc
    |   |-- arm-elf-gcc-3.4.3
    |   |-- arm-elf-gccbug
    |   |-- arm-elf-gcov
    |   |-- arm-elf-gdb
    |   |-- arm-elf-gdbtui
    |   |-- arm-elf-gprof
    |   |-- arm-elf-insight
    |   |-- arm-elf-ld
    |   |-- arm-elf-nm
    |   |-- arm-elf-objcopy
    |   |-- arm-elf-objdump
    |   |-- arm-elf-ranlib
    |   |-- arm-elf-readelf
    |   |-- arm-elf-run
    |   |-- arm-elf-size
    |   |-- arm-elf-strings
    |   |-- arm-elf-strip
    |   |-- tclsh8.4
    |   `-- wish8.4
    |-- include
    |   |-- itcl.h
    |   |-- itclDecls.h
    |   |-- itclInt.h
    |   |-- itclIntDecls.h
    |   |-- itk.h
    |   |-- itkDecls.h
    |   |-- tcl.h
    |   |-- tclDecls.h
    |   |-- tclPlatDecls.h
    |   |-- tk.h
    |   |-- tkDecls.h
    |   `-- tkPlatDecls.h
    |-- info
    |   |-- annotate.info
    |   |-- as.info
    |   |-- bfd.info
    |   |-- binutils.info
    |   |-- configure.info
    |   |-- cpp.info
    |   |-- cppinternals.info
    |   |-- dir
    |   |-- gcc.info
    |   |-- gccinstall.info
    |   |-- gccint.info
    |   |-- gdb.info
    |   |-- gdb.info-1
    |   |-- gdb.info-2
    |   |-- gdb.info-3
    |   |-- gdb.info-4
    |   |-- gdbint.info
    |   |-- gdbint.info-1
    |   |-- gdbint.info-2
    |   |-- gprof.info
    |   |-- ld.info
    |   |-- stabs.info
    |   `-- standards.info
    |-- lib
    |   |-- gcc
    |   |   `-- arm-elf
    |   |       `-- 3.4.3
    |   |   |-- be
    |   |  ...
    |   |-- insight1.0
    |   |   `-- plugins.tcl
    |   |-- itcl3.2
    |   |   `-- pkgIndex.tcl
    |   |-- itk3.2
    |   |   `-- pkgIndex.tcl
    |   |-- libarm-elf-sim.a
    |   |-- libiberty.a
    |   |-- libitcl3.2.a
    |   |-- libitclstub3.2.a
    |   |-- libitk3.2.a
    |   |-- libitkstub3.2.a
    |   |-- libtcl8.4.a
    |   |-- libtclstub8.4.a
    |   |-- libtk8.4.a
    |   |-- libtkstub8.4.a
    |   |-- tclConfig.sh
    |   |-- tk8.4
    |   `-- tkConfig.sh
    |-- libexec
    |   `-- gcc
    |       `-- arm-elf
    |           `-- 3.4.3
    |               |-- cc1
    |               |-- cc1plus
    |               |-- collect2
    |               `-- install-tools
    |                   |-- fixinc.sh
    |                   |-- fixincl
    |                   `-- mkheaders
    |-- man
    |   |-- man1
    |   |   |-- arm-elf-addr2line.1
    |   |   |-- arm-elf-ar.1
    |   |  ...  ...
    |   |   |-- tclsh.1
    |   |   `-- wish.1
    |   |-- man3
    |   |   |-- 3DBorder.3
    |   |   |-- Access.3
    |   |  ...  ...
    |   |   `-- panicVA.3
    |   |-- man7
    |   |   |-- fsf-funding.7
    |   |   |-- gfdl.7
    |   |   `-- gpl.7
    |   `-- mann
    |       |-- Archetype.n
    |      ...  ...
    |       |-- winfo.n
    |       `-- wm.n
            `-- share
    |-- insight1.0
    |   |-- about.tcl
    |  ...  ...
    |   `-- watch.tcl
    |-- itcl3.2
    |   `-- itcl.tcl
    |-- itk3.2
    |   |-- Archetype.itk
    |  ...  ...
    |   `-- tclIndex
    |-- iwidgets4.0.1
    |   |-- demos
    |   |    ...
    |   |-- iwidgets.tcl
    |   |-- license.terms
    |   |-- pkgIndex.tcl
    |   `-- scripts
    |       ...
    |       `-- watch.itk
    |-- locale
    |   |-- be
    |  ...  ...
    |   `-- zh_TW
    |       `- ...
    |
    |-- redhat
    |   `- ...
    |-- tcl8.4
    |   |-- auto.tcl
    |  ... ...
    |   `-- word.tcl
        `-- tk8.4
    |-- bgerror.tcl
    ...  ...
    |-- button.tcl
    `-- xmfbox.tcl
    
    121 directories, 2520 files

Windows: arm-elf Tools

If you did a default installation of Cygwin from the snapshot in the cygwin directory (Installing Cygwin), then you already have the arm-elf toolchain installed in /usr/local and you do not need to install the files in arm-elf-3.4.3-cygwin.tar.gz, and you do not need to modify your PATH variable.

[Note]
Note

The files in arm-elf-3.4.3-cygwin.tar.gz, which are used in the following procedures are provided for users who already have a Cygwin installation and are not installing Cygwin from this SDK.

While Pepperl+Fuchs Comtrol, Inc. is happy to provide such users with a copy of the toolchain binaries, Pepperl+Fuchs Comtrol, Inc. will be unable to provide technical support for toolchain-related problems that occur on Cygwin systems that were not installed from the SDK Cygwin snapshot.

To perform the following procedure, you must have installed Cygwin, which provides the Cygwin UNIX environment for Windows DLL and associated programs; including the arm-elf toolchain required for use with eCos for the DeviceMaster.

You can use the one of the following procedures to install the arm-elf tools using Cygwin.

  • Experienced Users:

    All you need to do is untar arm-elf-3.4.3-cygwin.tar.gz somewhere. That will create a directory called gnutools. Add the location of gnutools/bin to your PATH.

  • Detailed procedures are provided in the following subsections.

Installing arm-elf Tools with Cygwin

Use the following procedure to install the arm-elf toolchain for Windows with Cygwin.

  1. Move the arm-elf-3.4.3-cygwin.tar.gz file $/Windows_Tools/arm-elf-tools/tools.tar.gz to the Cygwin root directory.

    '$' designates the root directory of the Pepperl+Fuchs Comtrol, Inc. DeviceMaster Developer Kit distribution disk. The Cygwin root directory is C:\Cygwin unless you chose to override the default Cygwin installation directory during Cygwin installation.

  2. Open a Cygwin window by clicking the Cygwin icon on the desktop or selecting Start\Programs\Cygnus Solutions\Cygwin Bash Shell from the Start menu

  3. Change the directory to the location of the arm-elf-3.4.3-cygwin.tar.gz file. In this example, the file is located in the root directory of a CD ROM that is drive D.

    cd /cygwin/d

  4. Unpack the file, instructing tar to do so in the root "/" directory.

    tar -xzvf arm-elf-3.4.3-cygwin.tar.gz -C / &> /tar.out

  5. Open the file tar.out with vi or emacs in a Cygwin window or with Wordpad.

    cd /
    emacs tar.out

    [Note]
    Note

    Do not use Notepad. Files created in the Cygwin environment have UNIX line endings, Notepad does not display files legibly.

  6. Scan the file for error messages. If there are no error messages the installation was successful and you may delete tar.out.

  7. Update the PATH environmental variable for the tools to function properly.

  8. You can test your Cygwin and arm-elf tool installations by building the Sample Programs.

Windows Installation Method

This procedure requires WinZip. Verify that the WinZip version you have supports tar.gz file expansion.

  1. Open WinZip.

  2. Under the Options menu, select Configuration. On the Miscellaneous tab, make sure that TAR file smart CR/LF handling is not checked.

    Click OK to save the configuration.

  3. Double-click arm-elf-3.4.3-cygwin.tar.gz file to use the file on the SDK CD (or the location to which it was downloaded).

    WinZip will present a dialog box reading:

    Archive contains one file:
    arm-elf-3.4.3-cygwin.tar
    Should WinZip decompress it to a temporary folder and open it?     
  4. Click Yes.

  5. In the WinZip Actions drop down menu select Extract.

  6. WinZip will present an Extract dialog box. Enter C:\Cygwin or your Cygwin root directory path in the Extract to: text entry field.

  7. Click the Extract button.

    WinZip will create the C:\Cygwin\gnutools directory and populate it with the contents of tool.tar.gz.

  8. Go to Updating PATH to continue the installation.

Updating PATH

After the tool executables are installed you must add their location to the PATH environmental variable. This allows the system to find them. Use one of the following methods.

  • The simple method is to add the fully qualified path name of the tool executables to the existing PATH statement. Assuming that you allowed tar to place the tools in their default path, type the following at the Cygwin prompt:

    PATH=$PATH":/gnutools/bin"

    Unfortunately using the simple method means that additions to the PATH variable are lost at log off.

  • Optionally, you can edit the .bash_profile file to add the GNU tools to the PATH variable every time you login.

    [Note]
    Note

    The .bash_profile file resides in you home directory, i.e. /home/yourusername. If it does not exist in your installation create it with your favorite text editor and add the above PATH= statement to it. If it does exist open it with your favorite text editor and add the above PATH= statement. When you are done, logout and login to invoke the PATH= command.

    DO NOT USE NOTEPAD. Notepad ends lines with the DOS CALF instead of the UNIX new-line.

    Bash supports both vi and emacs, but emacs is the default. However, all text editing of bash text files can be done with Wordpad if you prefer a GUI editor. WordPad seems to have a problem with creating a new file with a leading period in it's name. WordPad also wants to append a suffix on a new file when it creates it. Consequently you may have to store your new file as bash_profile.txt or something similar. You can rename the file using the bash mv (move) command. The following syntax should work: mv -i bash_profile.txt .bash_profile

    If you use vi or emacs you won't have this problem.

You are ready to install the eCos library (pre-compiled or source eCos library).

[Note]
Note

You can refer to the GNU Documentation for more information.

Installing eCos

You can install one of the following eCos libraries for the SDK:

  • Pre-compiled version of eCos configured for the DeviceMaster. You may use this library to develop eCos applications without having to build eCos from its sources.

  • Optionally, you can install eCos sources and build the complete eCos libraries from the sources. The complete sources used to build the pre-compiled eCos binaries and the configuration file that was used to build the pre-compiled eCos binaries are in the eCos\Source directory. The eCos/Source/ecos.tar.gz file contains eCos source tree including Pepperl+Fuchs Comtrol, Inc. serial and Ethernet drivers. The eCos/Source/ecos.ecc file is the eCos configuration used to build binaries included in the SDK distribution.

Installing the Pre-Compiled (Binary) eCos Libraries

The install.tar.gz file contains the pre-built eCos files needed to build applications for the DeviceMaster.

To install the pre-built eCos libraries and include files, un-tar them to a desired location. The following example represents the procedure if the install.tar.gz file is in the user's home directory and they are to be installed in /home/my-proj/ecos.

$ mkdir -p /home/my-proj/ecos 
$ cd /home/my-proj/ecos
$ tar xzf ~/install.tar.gz

This will create an install directory that contains lib and include directories that contain the eCos library and included files, respectively.

You can go to Sample Programs to build one of the provided sample applications.

Installing eCos Sources

Install the eCos sources on your system. This example uses /opt and assumes that the eCos sources are in the user's home directory, which will create a directory tree under /opt/ecos:

$ cd /opt
$ tar xzf ~/ecos.tar.gz

If you are planning on building eCos from source you will need to install an eCos configuration tool.

Installing the eCos Configuration Tool

Use one of the following sections to install an eCos configuration tool for your system, which is required if building eCos source.

Linux

To install the tool (ecosconfig), a Linux/i386 binary executable of eCos configuration utility, copy the ecosconfig file to a directory present in your PATH.

Before attempting to build eCos, you should read the eCos User's Guide (A4 version available). To install the eCos source files and build a new eCos configuration, see Installing eCos Sources and Building eCos.

Cygwin Configuration GUI Utility

Due to the rapid rate at which the Cygwin Configuration GUI is being developed, the GUI eCos configtool is no longer included in the Pepperl+Fuchs Comtrol, Inc. DeviceMaster SDK. If you wish to use the GUI configtool, please download it from eCosCentric.

Before attempting to build eCos using Configtool you should read the eCos User's Guide (A4 version). To install the eCos source files and build a new eCos configuration, see Installing eCos Sources and Building eCos.

Cygwin Command Line Configuration Utility

The eCos_Config_Tool\Cygwin\cmd_line directory contains the ecosconfig.exe file, a Cygwin binary executable of eCos configuration utility, which provides a command line user interface.

In the following procedure all paths are from the Cygwin root.

  1. Delete the ecosconfig file from \opt\ecos\tools\bin, which is the Linux ecosconfig tool that is replaced in this example.

  2. Execute the ecosconfig.exe file and set the target directory to \opt\ecos\tools\bin/.

  3. Add the configuration tool directory to your path by executing the following command at the Cygwin command line.

    PATH=$PATH":/opt/ecos/tools/bin"

  4. Add the above command to your .bash_profile to enable it's execution each time you start Cygwin. If you need more information on how to do that see Updating PATH.

Before attempting to build eCos using ecosconfig you should refer to the eCos User Guide (A4 version).

Building eCos

The following steps provide an example of how to build eCos.

  1. Verify that the previously installed eCos configuration tool is somewhere in your path. The following command shows the current PATH.

    $ echo $PATH

  2. Install the eCos sources somewhere. In this example, the source tar file is in the user's home directory and it installs the eCos sources in the users home directory as well.

    $ cd ~
    $ tar xzf ecos2src-sdk.tar.gz

    This creates a directory tree under ecos2src-sdk.

  3. Install the eCos configuration utility ecosconfig somewhere in your path.

  4. Create an empty directory for the build tree (ecos-build and in the user's home directory).

    $ cd ~
    $ mkdir ecos-build
    $ cd ecos-build

  5. If you need to add an eCos configuration tool to your path, you can do so with the following command, which shows a what path would look like using the Linux configuration tool.

    $ export ECOS_REPOSITORY=~/ecos2src-sdk

  6. Create a new eCos configuration for the DeviceMaster target platform using the newTree-2.0 script. If desired, you can add the line from Step 5) to the top of the newTree-2.0 script.

     $ ../newTree-2.0

    U CYGBLD_ISO_DIRENT_HEADER, new inferred value <cyg/fileio/dirent.h>
    U CYGBLD_ISO_OPEN_MAX_HEADER, new inferred value <cyg/fileio/limits.h>
    U CYGBLD_ISO_NAME_MAX_HEADER, new inferred value <cyg/fileio/limits.h>
    U CYGBLD_ISO_BSDTYPES_HEADER, new inferred value <sys/bsdtypes.h>
    U CYGBLD_ISO_NETDB_PROTO_HEADER, new inferred value <net/netdb.h>
    U CYGBLD_ISO_NETDB_SERV_HEADER, new inferred value <net/netdb.h>
    Settings: 
    cdl_option CYGPKG_IO_NFILE {user_value 256}
    cdl_option CYGNUM_FILEIO_NFILE {user_value 256}
    cdl_option CYGNUM_FILEIO_NFD {user_value 256}
    cdl_option CYGPKG_NET_MAXSOCKETS {user_value 256}
    cdl_component CYGSEM_KERNEL_SCHED_TIMESLICE {user_value 0}
    cdl_option CYGNUM_MEMALLOC_FALLBACK_MALLOC_POOL_SIZE {user_value 0x20}
    cdl_option CYGPKG_NET_MEM_USAGE {user_value 0x260000}
    cdl_option CYGPKG_NET_NUM_WAKEUP_EVENTS {user_value 40}
    cdl_option CYGPKG_DEVS_ETH_ARM_DMRTS_PHY_ADDR {user_value 1}
    cdl_option CYGPKG_NET_BUILD_HW_TESTS {user_value 1}
    cdl_option CYGSEM_HAL_DIAG_MANGLER {user_value None}
    cdl_option CYGPKG_NET_FREEBSD_INET6 {user_value 0}
    cdl_option CYGPKG_NET_FREEBSD_SYSCTL {user_value 1}
    cdl_component CYGPKG_DEVS_ETH_ARM_DMRTS_SWTXCRC {user_value 1}
            
    # set IP configuration for test/devel purposes.  These settings
    # are ignored by socketServer and devmast apps
    cdl_component CYGHWR_NET_DRIVER_ETH0_BOOTP        {user_value 0}
    cdl_component CYGHWR_NET_DRIVER_ETH0_DHCP         {user_value 0}
    cdl_component CYGHWR_NET_DRIVER_ETH0_ADDRS        {user_value 1}
    cdl_option CYGHWR_NET_DRIVER_ETH0_ADDRS_IP        {user_value "10.0.0.101"}
    cdl_option CYGHWR_NET_DRIVER_ETH0_ADDRS_NETMASK   {user_value "255.0.0.0"}
    cdl_option CYGHWR_NET_DRIVER_ETH0_ADDRS_BROADCAST {user_value "10.255.255.255"}
    cdl_option CYGHWR_NET_DRIVER_ETH0_ADDRS_GATEWAY   {user_value "10.0.0.1"}
    cdl_option CYGHWR_NET_DRIVER_ETH0_ADDRS_SERVER    {user_value "10.0.0.1"}
    
    $

    This creates a directory tree and makefiles. The top level of the build directory now looks like this.

  7. Enter the following command.

    $ ls -l

    total 564
    drwxr-xr-x 4 grante users   4096 Jan  1 14:35 devs
    -rw-r--r-- 1 grante users 518641 Jan  1 14:35 ecos.ecc
    drwxr-xr-x 3 grante users   4096 Jan  1 14:35 error
    drwxr-xr-x 4 grante users   4096 Jan  1 14:35 hal
    drwxr-xr-x 3 grante users   4096 Jan  1 14:35 infra
    drwxr-xr-x 4 grante users   4096 Jan  1 14:35 install
    drwxr-xr-x 8 grante users   4096 Jan  1 14:35 io
    drwxr-xr-x 3 grante users   4096 Jan  1 14:35 isoinfra
    drwxr-xr-x 3 grante users   4096 Jan  1 14:35 kernel
    drwxr-xr-x 3 grante users   4096 Jan  1 14:35 language
    -rw-r--r-- 1 grante users   6282 Jan  1 14:35 makefile
    drwxr-xr-x 5 grante users   4096 Jan  1 14:35 net
    drwxr-xr-x 3 grante users   4096 Jan  1 14:35 services
  8. Perform the build.

    $ make

     make -r -C hal/arm/arch/current headers
     make[1]: Entering directory `/home/grante/ecos-build/hal/arm
     /arch/current'
     make[1]: Leaving directory `/home/grante/ecos-build/hal/arm
     /arch/current'
     make -r -C hal/arm/dmrts/current headers
     [...]
     headers finished
     make -r -C hal/arm/arch/current arm.inc
     make[1]: Entering directory `/home/grante/ecos-build/hal/arm
     /arch/current'
     arm-elf-gcc -finline-limit=7000 -mcpu=arm7tdmi -mbig-endian 
     -Wall -Wpointer-arith 
     -Wstrict-prototypes -Winline -Wundef -Woverloaded-virtual 
     -g -O2 -ffunction-sections
     -fdata-sections -fno-rtti -fno-exceptions    
     -I/home/grante/ecos-build/install/include
     -I/home/grante/ecos2src-sdk/hal/arm/arch/current -I/home/grante
     /ecos2src-sdk/hal
     /arm/arch/current/src -I/home/grante/ecos2src-sdk/hal/arm/arch/
     current/tests -I. -Wp,
     -MD,arm.tmp -o hal_mk_defs.tmp -S /home/grante/ecos2src-sdk
     /hal/arm/arch/current/src/hal_mk_defs.c
     fgrep .equ hal_mk_defs.tmp | sed s/#// > arm.inc
     make[1]: Leaving directory `/home/grante/ecos-build/hal/arm/
     arch/current'
     make -r -C services/memalloc/common/current 
     heapgeninc.tcl
     make[1]: Entering directory `/home/grante/ecos-build/
     services/memalloc/common/current'
     arm-elf-gcc -finline-limit=7000 -mcpu=arm7tdmi -mbig-endian
     -Wall -Wpointer-arith 
     -Wstrict-prototypes -Winline -Wundef -Woverloaded-virtual 
     -g -O2 -ffunction-sections 
     -fdata-sections -fno-rtti -fno-exceptions    -I/home/grante/
     ecos-build/install/include 
     -I/home/grante/ecos2src-sdk/services/memalloc/common/
     current -I/home/grante
     /ecos2src-sdk/services/memalloc/common/current/src 
     -I/home/grante/ecos2src-sdk
     /services/memalloc/common/current/tests -I. -Wp,
     -MD,heapgen.tmp -E /home/grante
     /ecos2src-sdk/services/memalloc/common/current/src/
     heapgen.cpp -o heapgeninc.tcl
     make[1]: Leaving directory `/home/grante/ecos-build/
     services/memalloc/common/current'
     make -r -C services/memalloc/common/current 
     heaps.cxx
     make[1]: Entering directory `/home/grante/ecos-build/
     services/memalloc/common/current'
     XPWD=`pwd` ; cd /home/grante/ecos2src-sdk/services/
     memalloc/common/current/src ; 
     sh heapgen.tcl "/home/grante/ecos-build/install" "$XPWD"
     make[1]: Leaving directory `/home/grante/ecos-build/
     services/memalloc/common/current'
     make -r -C hal/arm/arch/current build
     make[1]: Entering directory `/home/grante/ecos-build/
     hal/arm/arch/current'
     arm-elf-gcc -c  -I/home/grante/ecos-build/install/include 
     -I/home/grante/ecos2src-sdk
     /hal/arm/arch/current -I/home/grante/ecos2src-sdk/hal/
     arm/arch/current/src 
     -I/home/grante/ecos2src-sdk/hal/arm/arch/current/tests -I. 
     -I/home/grante/ecos2src-sdk
     /hal/arm/arch/current/src/ -finline-limit=7000 -mcpu=arm7tdmi 
     -mbig-endian -Wall 
     -Wpointer-arith -Wstrict-prototypes -Winline -Wundef  -g -O2 
     -ffunction-sections -fdata-sections  
     -fno-exceptions   -Wp,-MD,src/hal_misc.tmp -o src/hal_arm
     _arch_hal_misc.o /home/grante
     /ecos2src-sdk/hal/arm/arch/current/src/hal_misc.c
     arm-elf-gcc -c  -I/home/grante/ecos-build/install/include 
     -I/home/grante/ecos2src-sdk/hal
     /arm/arch/current -I/home/grante/ecos2src-sdk/hal/arm
     /arch/current/src -I/home/grante
     /ecos2src-sdk/hal/arm/arch/current/tests -I. -I/home/grante/
     ecos2src-sdk/hal/arm
     /arch/current/src/ -finline-limit=7000 -mcpu=arm7tdmi 
     -mbig-endian -Wall -Wpointer-arith 
     -Wstrict-prototypes -Winline -Wundef  -g -O2 
     -ffunction-sections -fdata-sections  -fno-exceptions   
     -Wp,-MD,src/context.tmp -o src/hal_arm_arch_context.o 
     /home/grante/ecos2src-sdk/hal
     /arm/arch/current/src/context.S
     [...]
     arm-elf-gcc -c  -I/home/grante/ecos-build/install
     include -I/home/grante/ecos2src-sdk/net
     /snmp/agent/current -I/home/grante/ecos2src-sdk/
     net/snmp/agent/current/src -I/home/grante
     /ecos2src-sdk/net/snmp/agent/current/tests -I. 
     -I/home/grante/ecos2src-sdk/net/snmp/agent/
     current/src/mibgroup/mibII/ -finline-limit=7000 
     -mcpu=arm7tdmi -mbig-endian -Wall 
     -Wpointer-arith -Wstrict-prototypes -Winline 
     -Wundef  -g -O2 -ffunction-sections -fdata-sections  
     -fno-exceptions   -D_KERNEL -D__ECOS
     -DIN_UCD_SNMP_SOURCE=1 -I/home/grante
     /ecos-build/install/include/ucd-snmp -Wp,
     -MD,src/mibgroup/mibII/vacm_vars.tmp -o src
     /mibgroup/mibII/net_snmp_agent_vacm_vars.o 
     /home/grante/ecos2src-sdk/net/snmp
     /agent/current/src/mibgroup/mibII/vacm_vars.c
     arm-elf-ar rcs /home/grante/ecos-build/install/
     lib/libtarget.a src/net_snmp_agent_agent
     _read_config.o src/net_snmp_agent_agent_
     registry.o src/net_snmp_agent_agent_trap.o 
     src/net_snmp_agent_kernel.o src/net_snmp_
     agent_mib_modules.o src/net_snmp_agent_
     snmp_agent.o src/net_snmp_agent_snmp_vars.o
     src/net_snmp_agent_snmpd.o src/net_
     snmp_agent_snmptask.o src/mibgroup/mibII/
     net_snmp_agent_helpers.o src/mibgroup
     /mibII/net_snmp_agent_system_mib.o src/
     mibgroup/mibII/net_snmp_agent
     _sysORTable.o src/mibgroup/mibII/net_snmp_
     agent_snmp_mib.o src/mibgroup
     /mibII/net_snmp_agent_icmp.o src/mibgroup/
     mibII/net_snmp_agent_interfaces.o src/mibgroup/
     mibII/net_snmp_agent_ip.o src/mibgroup/mibII/net_
     snmp_agent_tcp.o src/mibgroup/mibII/net_snmp_
     agent_udp.o src/mibgroup/net_snmp_agent_util_funcs.o 
     src/mibgroup/mibII/net_snmp_agent_dot3.o src/mibgroup/
     snmpv3/net_snmp_agent_usmStats.o src/mibgroup/
     snmpv3/net_snmp_agent_usmUser.o src/mibgroup/
     snmpv3/net_snmp_agent_snmpEngine.o src/mibgroup
     /mibII/net_snmp_agent_vacm_vars.o
     make[1]: Leaving directory `/home/grante/ecos-build
     /net/snmp/agent/current'
     make -r -C hal/common/current /home/grante/
     ecos-build/install/lib/extras.o
     make[1]: Entering directory `/home/grante/
     ecos-build/hal/common/current'
     arm-elf-gcc -finline-limit=7000 -mcpu=arm7tdmi 
     -mbig-endian -Wall -Wpointer-arith -Wstrict-prototypes 
     -Winline -Wundef -Woverloaded-virtual -g -O2 
     -ffunction-sections -fdata-sections -fno-rtti 
     -fno-exceptions   -nostdlib -Wl,-r -Wl,--whole-archive -o 
     /home/grante/ecos-build/install/lib/extras.o /home
     /grante/ecos-build/install/lib/libextras.a
     make[1]: Leaving directory `/home/grante/ecos-build/hal/common/current'
     make -r -C hal/arm/arch/current /home/grante/ecos-build/install/lib/vectors.o
     make[1]: Entering directory `/home/grante/ecos-build/hal/arm/arch/current'
     arm-elf-gcc -Wp,-MD,vectors.tmp  -I/home/grante/ecos-build/
     install/include -I/home/grante/ecos2src-sdk/hal/arm/arch/
     current -I/home/grante/ecos2src-sdk/hal/arm/arch/current/src 
     -I/home/grante/ecos2src-sdk/hal/arm/arch/current/tests -I. 
     -finline-limit=7000 -mcpu=arm7tdmi -mbig-endian 
     -Wall -Wpointer-arith -Wstrict-prototypes -Winline 
     -Wundef -Woverloaded-virtual -g -O2 -ffunction-sections 
     -fdata-sections -fno-rtti -fno-exceptions   -c -o /home/
     grante/ecos-build/install/lib/vectors.o /home/grante/
     ecos2src-sdk/hal/arm/arch/current/src/vectors.S
     make[1]: Leaving directory `/home/grante/ecos-build/hal/arm/arch/current'
     make -r -C hal/arm/arch/current /home/grante/ecos-build/install/lib/target.ld
     make[1]: Entering directory `/home/grante/ecos-build/hal/arm/arch/current'
     arm-elf-gcc -E -P -Wp,-MD,target.tmp -xc  -I/home/grante/ecos-build/
     install/include -I/home/grante/ecos2src-sdk/hal/arm/arch/current 
     -I/home/grante/ecos2src-sdk/hal/arm/arch/current/src -I/home/
     grante/ecos2src-sdk/hal/arm/arch/current/tests -I. -finline
     -limit=7000 -mcpu=arm7tdmi -mbig-endian -Wall -Wpointer-
     arith -Wstrict-prototypes -Winline -Wundef -Woverloaded-virtual 
     -g -O2 -ffunction-sections -fdata-sections -fno-rtti -fno-exceptions   
     -o /home/grante/ecos-build/install/lib/target.ld /home/grante/
     ecos2src-sdk/hal/arm/arch/current/src/arm.ld
     make[1]: Leaving directory `/home/grante/ecos-build/hal/arm/arch/current'
     build finished
     

You should now have an install directory containing include and library files. This directory is all that is needed to compile and build eCos applications.

The install directory tree should contain a large include directory tree and a lib directory containing a handful of files:

$ tree install

 install
 |-- include
 |    |-- arpa
 |    |   ....
 |    |   `-- tftp.h
 |    |-- assert.h
 |   ...
 |    |-- dhcp.h
 |    |-- dirent.h
 |    |-- dlfcn.h
 |    |-- errno.h
 |   ...
 |    |-- string.h
 |    |-- sys
 |   ...
 |    `-- unistd.h
 `-- lib
      |-- extras.o
      |-- libextras.a
      |-- libtarget.a
      |-- target.ld
      `-- vectors.o
 
 32 directories, 364 files

Verifying Installation

This discussion is an overview of how to build all three samples included in the SDK. Detailed instructions are provided for each of the examples in Sample Programs.

  1. Copy the sample program files to your hard disk. In this example, they were copied to the user’s home directory

  2. Create a work directory. In this example, ecos-demo is the name of the work directory.

    $ mkdir ecos-demo
    $ cd ecos-demo

  3. If you have not done so, unpack and install the pre-compiled eCos libraries.

  4. Modify the Makefile to point to the location of the eCos install directory.

  5. Unpack the demo sources

    $ tar xzf ~/demo.tar.gz

  6. Go to the demo subdirectory where you unpacked the source files.

    $ cd demo

  7. Remove all previously complied components and object files.

    $ make clean
    $ rm -f netecho.elf serecho.elf netecho.bin serecho.bin netech . .
    $ touch srcdeps

  8. Compile source dependencies.

    $ make depend 

  9. Compile the Sample Program.

    $ make

Sample Programs

The SDK contains several sample application sources. The sample programs are intended to illustrate how you can write programs to use the DeviceMaster. In some cases, you may be able to take portions of the sample source and implement in your application..

Two of the sample applications include web servers.

  • The demoSocketServer.tar.gz: file is the source tree for SocketServer, a simplified version of the default DeviceMaster application (including the GoAhead web server). See Building the SocketServer Sample Application for instructions on how to build the sample SocketServer server.

  • The goahead.tar.gz file is the source distribution for the GoAhead web server version 2.1. The source files have been modified in order to fix bugs, add features, and build/run on the DeviceMaster. See Building the GoAhead Webserver for instructions on how to build the webserver sample application.

The third sample application program, demo.tar.gz, contains two example eCos applications that demonstrate the use of the DeviceMaster serial driver and the DeviceMaster Ethernet driver. You can review documentation for the Pepperl+Fuchs Comtrol, Inc. serial and Ethernet drivers, and information on the two small sample applications netecho and serecho. See Building the eCos Sample Applications (Serial and Ethernet) for the build procedures.

Building the SocketServer Sample Application

The demoSocketServer.tar.gz file contains the source tree for SocketServer, which is a simplified version of the default DeviceMaster application (including the GoAhead web server).

Use the following procedure to build the sample SocketServer application.

  1. If you have not done so, unpack and install the pre-compiled eCos libraries. See Installing the Pre-Compiled (Binary) eCos Libraries.

    [Note]
    Note

    If you already have the eCos libraries installed, or if you built them from sources, you can skip this step, but you must modify the Makefile to point to the location of the eCos install directory.

  2. Copy the gzipped tar files containing the SocketServer source files to your hard disk. In the following example, they were copied to the user's home directory.

  3. Create a work directory. This example uses the ss-demo directory.

    $ mkdir ss-demo
    $ cd ss-demo

  4. Unpack the SocketServer sources.

    $ tar xzf ~/demoSocketServer.tar.gz

  5. Modify the Makefile so that the ECOS variable points to the install directory containing the eCos object libraries. In this example you should use ECOS = ../install.

  6. Build SocketServer.

    $ cd demoSocketServer
    $ make clean

    rm -f  socket.srec socket.bin socket.elf  *.o *~ *.lst *.map 
    \#*\# *.bin *.elf10 core *.bak .*~ for d in snmp socketServer webserv 
    webpages admin ; do make -C $d clean; done
    make[1]: Entering directory `/WORK/demoSocketServer/snmp'
    rm -f  *.o *~ *.lst *.map \#*\# *.bin *.elf10 core *.bak .*~
    make[1]: Leaving directory `/WORK/demoSocketServer/snmp'
    make[1]: Entering directory `/WORK/demoSocketServer/socketServer'
    rm -f  *.o *~ *.lst *.map \#*\# *.bin *.elf10 core *.bak .*~
    make[1]: Leaving directory `/WORK/demoSocketServer/socketServer'
    make[1]: Entering directory `/WORK/demoSocketServer/webserv'
    rm -f  *.o *~ *.lst *.map \#*\# *.bin *.elf10 core *.bak .*~
    make[1]: Leaving directory `/WORK/demoSocketServer/webserv'
    make[1]: Entering directory `/WORK/demoSocketServer/webpages'
    rm -f  *.o *~ *.lst *.map \#*\# *.bin *.elf10 core *.bak .*~
    make[1]: Leaving directory `/WORK/demoSocketServer/webpages'
    make[1]: Entering directory `/WORK/demoSocketServer/admin'
    rm -f  *.o *~ *.lst *.map \#*\# *.bin *.elf10 core *.bak .*~
    make[1]: Leaving directory `/WORK/demoSocketServer/admin'
    make -C goahead/ECOS clean
    make[1]: Entering directory `/WORK/demoSocketServer/goahead/ECOS'
    rm -f webs libwebs.a ../asp.d ../balloc.d ../base64.d ../default.d 
    ../ejlex.d ../ejparse.d ../form.d ../h.d ../handler.d ../mime.d ../misc.d 
    ../page.d ../ringq.d ../rom.d ../sock.d ../sockGen.d ../security.d
    ../sym.d ../uemf.d ../url.d ../value.d ../webs.d ../websuemf.d 
    ../websda.d ../md5c.d main.d webserv.d websupp.d 
    ../asp.o ../balloc.o ../base64.o ../default.o ../ejlex.o 
    ../ejparse.o ../form.o ../h.o ../handler.o ../mime.o ../misc.o 
    ../page.o ../ringq.o ../rom.o ../sock.o ../sockGen.o 
    ../security.o ../sym.o ../uemf.o ../url.o ../value.o
    ../webs.o ../websuemf.o ../websda.o ../md5c.o ../*.lst 
    rm -f main.o webrom.c webcomp web_files .depend *.lst
    make[1]: Leaving directory `/WORK/demoSocketServer/goahead/ECOS'
  7. Compile the source dependencies.

    $ make depend

    arm-elf-gcc -g -mcpu=arm7tdmi -mbig-endian  -M -I/WORK/
    demoSocketServer/../ecos-build/install/include -D__ECOS  
    main.c watchdog.cxx commands.c portmon.c >.srcdeps
    for d in snmp socketServer webserv webpages admin ; 
    do touch $d/.srcdeps; make -C $d depend; done
    make[1]: Entering directory `/WORK/demoSocketServer/snmp'
    gcc -M -I/WORK/demoSocketServer/../ecos-build/install
    /include -D__ECOS  snmp.c >.srcdeps
    make[1]: Leaving directory `/WORK/demoSocketServer/snmp'
    make[1]: Entering directory `/WORK/demoSocketServer/socketServer'
    gcc -M -I/WORK/demoSocketServer/../ecos-build/install/
    include -D__ECOS  server.c flash.c >.srcdeps
    make[1]: Leaving directory `/WORK/demoSocketServer/socketServer'
    make[1]: Entering directory `/WORK/demoSocketServer/webserv'
    gcc -M -I/WORK/demoSocketServer/../ecos-build/install
    /include -I/WORK/demoSocketServer/goahead -D__ECOS  
    -DWEBS -DUEMF -DWEBS_PAGE_ROM -DOS="eCos" 
    -DECOS -D__NO_FCNTL=1 -DDIGEST_ACCESS_SUPPORT 
    websupp.c webserv.c  telnetserv.c >.srcdeps
    make[1]: Leaving directory `/WORK/demoSocketServer/webserv'
    make[1]: Entering directory `/WORK/demoSocketServer/webpages'
    gcc -M -I/WORK/demoSocketServer/../ecos-build/install/include 
    -I/WORK/demoSocketServer/goahead -D__ECOS  -DWEBS 
    -DUEMF -DWEBS_PAGE_ROM -DOS="eCos" -DECOS 
    -D__NO_FCNTL=1 -DDIGEST_ACCESS_SUPPORT 
    webcomp.c >.srcdeps
    make[1]: Leaving directory `/WORK/demoSocketServer/webpages'
    make[1]: Entering directory `/WORK/demoSocketServer/admin'
    gcc -M -I/WORK/demoSocketServer/../ecos-build/install
    /include -D__ECOS  tadmin.c madmin.c >.srcdeps
    make[1]: Leaving directory `/WORK/demoSocketServer/admin'
  8. Perform a make to build the demo applications.

    $ make

    make -C snmp
    make[1]: Entering directory `/home/grante/comtrol/sdk/
    DeviceMaster_Apps/SocketServer/Source/demoSocketServer/snmp'
    arm-elf-gcc -g -mcpu=arm7tdmi -mbig-endian  -c -o snmp.o 
    -fverbose-asm -Wall -O2 -I/home/grante/comtrol/sdk
    /DeviceMaster_Apps/SocketServer/Source/demoSocketServer/
    ../ecos-build/install/include -D__ECOS  snmp.c
    cp snmp.o app.o
    make[1]: Leaving directory `/home/grante/comtrol/sdk/
    DeviceMaster_Apps/SocketServer/Source/demoSocketServer/snmp'
    make -C socketServer
    make[1]: Entering directory `/home/grante/comtrol/sdk/
    DeviceMaster_Apps/SocketServer/Source/demoSocketServer/socketServer'
    arm-elf-gcc -g -mcpu=arm7tdmi -mbig-endian  -c -o server.o 
    -fverbose-asm -Wall -O2 -I/home/grante/comtrol/sdk
    /DeviceMaster_Apps/SocketServer/Source/demoSocketServer/
    ../ecos-build/install/include -D__ECOS  server.c
    arm-elf-gcc -g -mcpu=arm7tdmi -mbig-endian  -c -o flash.o 
    -fverbose-asm -Wall -O2 -I/home/grante/comtrol/sdk/
    DeviceMaster_Apps/SocketServer/Source/demoSocketServer/
    ../ecos-build/install/include -D__ECOS  flash.c
    arm-elf-ld -EB -i -o app.o server.o flash.o
    make[1]: Leaving directory `/home/grante/comtrol/sdk/
    DeviceMaster_Apps/SocketServer/Source/demoSocketServer/socketServer'
    make -C webserv
    make[1]: Entering directory `/home/grante/comtrol/sdk/
    DeviceMaster_Apps/SocketServer/Source/demoSocketServer/webserv'
    arm-elf-gcc -g -mcpu=arm7tdmi -mbig-endian  -c -o webserv.o 
    -fverbose-asm -Wall -O2 -I/home/grante/comtrol/sdk/
    DeviceMaster_Apps/SocketServer/Source/demoSocketServer/
    ../ecos-build/install/include -I/home/grante/comtrol/sdk/
    DeviceMaster_Apps/SocketServer/Source/demoSocketServer
    /goahead -D__ECOS  -DWEBS -DUEMF -DWEBS_PAGE_ROM -DOS="eCos" 
    -DECOS -D__NO_FCNTL=1 -DDIGEST_ACCESS_SUPPORT webserv.c
    arm-elf-gcc -g -mcpu=arm7tdmi -mbig-endian  -c -o websupp.o 
    -fverbose-asm -Wall -O2 -I/home/grante/comtrol/sdk/
    DeviceMaster_Apps/SocketServer/Source/demoSocketServer/
    ../ecos-build/install/include -I/home/grante/comtrol/sdk/
    DeviceMaster_Apps/SocketServer/Source/demoSocketServer
    /goahead -D__ECOS  -DWEBS -DUEMF -DWEBS_PAGE_ROM 
    -DOS="eCos" -DECOS -D__NO_FCNTL=1 -DDIGEST_ACCESS
    _SUPPORT websupp.c
    arm-elf-gcc -g -mcpu=arm7tdmi -mbig-endian  -c -o telnetserv.o 
    -fverbose-asm -Wall -O2 -I/home/grante/comtrol/sdk/
    DeviceMaster_Apps/SocketServer/Source/demoSocketServer/
    ../ecos-build/install/include -I/home/grante/comtrol/sdk/
    DeviceMaster_Apps/SocketServer/Source/demoSocketServer
    /goahead -D__ECOS  -DWEBS -DUEMF -DWEBS_PAGE_ROM 
    -DOS="eCos" -DECOS -D__NO_FCNTL=1 -DDIGEST_ACCESS
    _SUPPORT telnetserv.c
    arm-elf-ld -EB -i -o app.o webserv.o websupp.o telnetserv.o
    make[1]: Leaving directory `/home/grante/comtrol/sdk/
    DeviceMaster_Apps/SocketServer/Source/demoSocketServer/webserv'
    make -C webpages
    make[1]: Entering directory `/home/grante/comtrol/sdk/
    DeviceMaster_Apps/SocketServer/Source/demoSocketServer/webpages'
    gcc -o webcomp -O2 -I ../goahead -DWEBS -DUEMF  -DUNIX  webcomp.c
    webcomp.c: In function 'compile':
    webcomp.c:121: warning: comparison of distinct pointer types lacks a 
    cast echo root/images/blackbanner.gif root/images/DMLogo.jpg root/images
    /ecos-logo.gif root/images/goahead-logo.gif root/images/DMAirLogo.jpg 
    root/editPort.asp root/home.asp root/netCfg.asp root/netSaved.asp 
    root/portSaved.asp root/resetUnit.asp root/style.css | tr ' ' '\n' 
    > web_files
    ./webcomp root web_files >webrom.c
    arm-elf-gcc -g -mcpu=arm7tdmi -mbig-endian  -c -o webrom.o 
    -fverbose-asm -Wall -O2 -I/home/grante/comtrol/sdk/DeviceMaster_Apps
    /SocketServer/Source/demoSocketServer/../ecos-build/install/include 
    -I/home/grante/comtrol/sdk/DeviceMaster_Apps/SocketServer/Source
    /demoSocketServer/goahead -D__ECOS  -DWEBS -DUEMF 
    -DWEBS_PAGE_ROM -DOS="eCos" -DECOS -D__NO_FCNTL=1 
    -DDIGEST_ACCESS_SUPPORT webrom.c
    cp webrom.o app.o
    make[1]: Leaving directory `/home/grante/comtrol/sdk/DeviceMaster_Apps/
    SocketServer/Source/demoSocketServer/webpages'
    make -C admin
    make[1]: Entering directory `/home/grante/comtrol/sdk/DeviceMaster_Apps/
    SocketServer/Source/demoSocketServer/admin'
    arm-elf-gcc -g -mcpu=arm7tdmi -mbig-endian  -c -o tadmin.o 
    -fverbose-asm -Wall -O2 -I/home/grante/comtrol/sdk/DeviceMaster_Apps
    /SocketServer/Source/demoSocketServer/../ecos-build/install/include 
    -D__ECOS  tadmin.c arm-elf-gcc -g -mcpu=arm7tdmi -mbig-endian  -c -o madmin.o 
    -fverbose-asm -Wall -O2 -I/home/grante/comtrol/sdk/DeviceMaster_Apps
    /SocketServer/Source/demoSocketServer/../ecos-build/install
    /include -D__ECOS  madmin.c
    arm-elf-ld -EB -r -o app.o tadmin.o madmin.o
    make[1]: Leaving directory `/home/grante/comtrol/sdk/DeviceMaster_Apps/
    SocketServer/Source/demoSocketServer/admin'
    make -C goahead/ECOS
    make[1]: Entering directory `/home/grante/comtrol/sdk/DeviceMaster_Apps/
    SocketServer/Source/demoSocketServer/goahead/ECOS'
    arm-elf-gcc -g -mcpu=arm7tdmi -mbig-endian -c -o ../asp.o 
    -fverbose-asm -Wa,-ahlsn=../asp.lst -I -O2 -D__ECOS -DWEBS 
    -DUEMF -DWEBS_PAGE_ROM -DDIGEST_ACCESS_SUPPORT 
    -DOS="eCos" -DECOS -D__ECOS -D__NO_FCNTL=1 -I.. 
    -Wall -I/home/grante/comtrol/sdk/DeviceMaster_Apps/SocketServer/
    Source/demoSocketServer/../ecos-build/install/include -ffunction-sections 
    -fdata-sections -Wp,-MD,../asp.d ../asp.c
    arm-elf-gcc -g -mcpu=arm7tdmi -mbig-endian -c -o ../balloc.o 
    -fverbose-asm -Wa,-ahlsn=../balloc.lst -I -O2 -D__ECOS 
    -DWEBS -DUEMF -DWEBS_PAGE_ROM -DDIGEST_
    ACCESS_SUPPORT -DOS="eCos" -DECOS -D__
    ECOS -D__NO_FCNTL=1 -I.. -Wall -I/home/grante/comtrol/
    sdk/DeviceMaster_Apps/SocketServer/Source/demoSocketServer/
    ../ecos-build/install/include -ffunction-sections -fdata-sections 
    -Wp,-MD,../balloc.d ../balloc.c
    arm-elf-gcc -g -mcpu=arm7tdmi -mbig-endian -c -o ../base64.o 
    -fverbose-asm -Wa,-ahlsn=../base64.lst -I -O2 -D__ECOS 
    -DWEBS -DUEMF -DWEBS_PAGE_ROM -DDIGEST_ACCESS
    _SUPPORT -DOS="eCos" -DECOS -D__ECOS -D__NO_
    FCNTL=1 -I.. -Wall -I/home/grante/comtrol/sdk/DeviceMaster_Apps
    /SocketServer/Source/demoSocketServer/../ecos-build/install/
    include -ffunction-sections -fdata-sections -Wp,-MD,
    ../base64.d ../base64.c
    arm-elf-gcc -g -mcpu=arm7tdmi -mbig-endian -c -o ../default.o 
    -fverbose-asm -Wa,-ahlsn=../default.lst -I -O2 -D__ECOS 
    -DWEBS -DUEMF -DWEBS_PAGE_ROM -DDIGEST_ACCESS_
    SUPPORT -DOS="eCos" -DECOS -D__ECOS -D__NO_FCNTL=1 
    -I.. -Wall -I/home/grante/comtrol/sdk/DeviceMaster_Apps/
    SocketServer/Source/demoSocketServer/../ecos-build
    /install/include -ffunction-sections -fdata-sections -Wp,-MD,
    ../default.d ../default.c
    arm-elf-gcc -g -mcpu=arm7tdmi -mbig-endian -c -o ../ejlex.o 
    -fverbose-asm -Wa,-ahlsn=../ejlex.lst -I -O2 -D__ECOS 
    -DWEBS -DUEMF -DWEBS_PAGE_ROM -DDIGEST_ACCESS_
    SUPPORT -DOS="eCos" -DECOS -D__ECOS -D__NO_FCNTL=1
    -I.. -Wall -I/home/grante/comtrol/sdk/DeviceMaster_Apps/
    SocketServer/Source/demoSocketServer/../ecos-build/install
    /include -ffunction-sections -fdata-sections -Wp,-MD,../ejlex.d ../ejlex.c
    arm-elf-gcc -g -mcpu=arm7tdmi -mbig-endian -c -o ../ejparse.o 
    -fverbose-asm -Wa,-ahlsn=../ejparse.lst -I -O2 -D__ECOS 
    -DWEBS -DUEMF -DWEBS_PAGE_ROM -DDIGEST_ACCESS
    _SUPPORT -DOS="eCos" -DECOS -D__ECOS -D__NO_FCNTL=1
    -I.. -Wall -I/home/grante/comtrol/sdk/DeviceMaster_Apps/
    SocketServer/Source/demoSocketServer/../ecos-build/install/
    include -ffunction-sections -fdata-sections -Wp,-MD,../ejparse.d ../ejparse.c
    arm-elf-gcc -g -mcpu=arm7tdmi -mbig-endian -c -o ../form.o 
    -fverbose-asm -Wa,-ahlsn=../form.lst -I -O2 -D__ECOS 
    -DWEBS -DUEMF -DWEBS_PAGE_ROM -DDIGEST_
    ACCESS_SUPPORT -DOS="eCos" -DECOS -D__ECOS 
    -D__NO_FCNTL=1 -I.. -Wall -I/home/grante/comtrol/sdk/
    DeviceMaster_Apps/SocketServer/Source/demoSocketServer/
    ../ecos-build/install/include -ffunction-sections -fdata-sections 
    -Wp,-MD,../form.d ../form.c
    arm-elf-gcc -g -mcpu=arm7tdmi -mbig-endian -c -o ../h.o 
    -fverbose-asm -Wa,-ahlsn=../h.lst -I -O2 -D__ECOS -DWEBS 
    -DUEMF -DWEBS_PAGE_ROM -DDIGEST_ACCESS_
    SUPPORT -DOS="eCos" -DECOS -D__ECOS -D__NO_FCNTL=1 
    -I.. -Wall -I/home/grante/comtrol/sdk/DeviceMaster_Apps/
    SocketServer/Source/demoSocketServer/../ecos-build/install
    /include -ffunction-sections -fdata-sections -Wp,-MD,../h.d ../h.c
    arm-elf-gcc -g -mcpu=arm7tdmi -mbig-endian -c -o ../handler.o 
    -fverbose-asm -Wa,-ahlsn=../handler.lst -I -O2 -D__ECOS 
    -DWEBS -DUEMF -DWEBS_PAGE_ROM -DDIGEST_ACCESS
    _SUPPORT -DOS="eCos" -DECOS -D__ECOS -D__NO_FCNTL=1 
    -I.. -Wall -I/home/grante/comtrol/sdk/DeviceMaster_Apps/
    SocketServer/Source/demoSocketServer/../ecos-build/install/
    include -ffunction-sections -fdata-sections -Wp,-MD
    ,../handler.d ../handler.c
    arm-elf-gcc -g -mcpu=arm7tdmi -mbig-endian -c -o ../mime.o 
    -fverbose-asm -Wa,-ahlsn=../mime.lst -I -O2 -D__ECOS -DWEBS 
    -DUEMF -DWEBS_PAGE_ROM -DDIGEST_ACCESS_SUPPORT 
    -DOS="eCos" -DECOS -D__ECOS -D__NO_FCNTL=1
    -I.. -Wall -I/home/grante/comtrol/sdk/DeviceMaster_Apps/
    SocketServer/Source/demoSocketServer/../ecos-build/install
    /include -ffunction-sections -fdata-sections -Wp,-MD,../mime.d ../mime.c
    arm-elf-gcc -g -mcpu=arm7tdmi -mbig-endian -c -o ../misc.o 
    -fverbose-asm -Wa,-ahlsn=../misc.lst -I -O2 -D__ECOS 
    -DWEBS -DUEMF -DWEBS_PAGE_ROM -DDIGEST_ACCESS
    _SUPPORT -DOS="eCos" -DECOS -D__ECOS -D__NO_FCNTL=1 
    -I.. -Wall -I/home/grante/comtrol/sdk/DeviceMaster_Apps/
    SocketServer/Source/demoSocketServer/../ecos-build/install/
    include -ffunction-sections -fdata-sections -Wp,-MD,../misc.d ../misc.c
    ../misc.c: In function `gstrtoi':
    ../misc.c:662: warning: implicit declaration of function `atoi'
    arm-elf-gcc -g -mcpu=arm7tdmi -mbig-endian -c -o ../page.o 
    -fverbose-asm -Wa,-ahlsn=../page.lst -I -O2 -D__ECOS -DWEBS 
    -DUEMF -DWEBS_PAGE_ROM -DDIGEST_ACCESS_SUPPORT 
    -DOS="eCos" -DECOS -D__ECOS -D__NO_FCNTL=1 -I.. 
    -Wall -I/home/grante/comtrol/sdk/DeviceMaster_Apps/
    SocketServer/Source/demoSocketServer/../ecos-build/install
    /include -ffunction-sections -fdata-sections -Wp,-MD,../page.d ../page.c
    arm-elf-gcc -g -mcpu=arm7tdmi -mbig-endian -c -o ../ringq.o 
    -fverbose-asm -Wa,-ahlsn=../ringq.lst -I -O2 -D__ECOS -DWEBS
    -DUEMF -DWEBS_PAGE_ROM -DDIGEST_ACCESS_SUPPORT
    -DOS="eCos" -DECOS -D__ECOS -D__NO_FCNTL=1 -I.. -Wall 
    -I/home/grante/comtrol/sdk/DeviceMaster_Apps/SocketServer/
    Source/demoSocketServer/../ecos-build/install/include 
    -ffunction-sections -fdata-sections -Wp,-MD,../ringq.d ../ringq.c
    arm-elf-gcc -g -mcpu=arm7tdmi -mbig-endian -c -o ../rom.o 
    -fverbose-asm -Wa,-ahlsn=../rom.lst -I -O2 -D__ECOS 
    -DWEBS -DUEMF -DWEBS_PAGE_ROM -DDIGEST_
    ACCESS_SUPPORT -DOS="eCos" -DECOS -D__ECOS 
    -D__NO_FCNTL=1 -I.. -Wall -I/home/grante/comtrol/sdk/
    DeviceMaster_Apps/SocketServer/Source/demoSocketServer
    /../ecos-build/install/include -ffunction-sections -fdata-sections 
    -Wp,-MD,../rom.d ../rom.c
    arm-elf-gcc -g -mcpu=arm7tdmi -mbig-endian -c -o ../sock.o 
    -fverbose-asm -Wa,-ahlsn=../sock.lst -I -O2 -D__ECOS 
    -DWEBS -DUEMF -DWEBS_PAGE_ROM -DDIGEST_
    ACCESS_SUPPORT -DOS="eCos" -DECOS -D__ECOS 
    -D__NO_FCNTL=1 -I.. -Wall -I/home/grante/comtrol/sdk/
    DeviceMaster_Apps/SocketServer/Source/demoSocketServer
    /../ecos-build/install/include -ffunction-sections -fdata-sections 
    -Wp,-MD,../sock.d ../sock.c
    ../sock.c: In function `socketDoOutput':
    ../sock.c:506: warning: implicit declaration of function `inet_addr'
    arm-elf-gcc -g -mcpu=arm7tdmi -mbig-endian -c -o ../sockGen.o 
    -fverbose-asm -Wa,-ahlsn=../sockGen.lst -I -O2 -D__ECOS -DWEBS 
    -DUEMF -DWEBS_PAGE_ROM -DDIGEST_ACCESS_SUPPORT 
    -DOS="eCos" -DECOS -D__ECOS -D__NO_FCNTL=1 -I.. -Wall 
    -I/home/grante/comtrol/sdk/DeviceMaster_Apps/SocketServer
    /Source/demoSocketServer/../ecos-build/install/include 
    -ffunction-sections -fdata-sections -Wp,-MD,../sockGen.d ../sockGen.c
    ../sockGen.c: In function `socketOpenConnection':
    ../sockGen.c:134: warning: implicit declaration of function `inet_addr'
    ../sockGen.c: In function `socketAccept':
    ../sockGen.c:359: warning: passing arg 3 of `accept' 
    from incompatible pointer type
    ../sockGen.c: In function `socketSelect':
    ../sockGen.c:704: warning: unused variable `len'
    ../sockGen.c:704: warning: unused variable `nwords'
    arm-elf-gcc -g -mcpu=arm7tdmi -mbig-endian -c -o ../security.o 
    -fverbose-asm -Wa,-ahlsn=../security.lst -I -O2 -D__ECOS 
    -DWEBS -DUEMF -DWEBS_PAGE_ROM -DDIGEST_ACCESS
    _SUPPORT -DOS="eCos" -DECOS -D__ECOS -D__NO_FCNTL=1 
    -I.. -Wall -I/home/grante/comtrol/sdk/DeviceMaster_Apps/
    SocketServer/Source/demoSocketServer/../ecos-build/install/include
    -ffunction-sections -fdata-sections -Wp,-MD,../security.d ../security.c
    arm-elf-gcc -g -mcpu=arm7tdmi -mbig-endian -c -o ../sym.o 
    -fverbose-asm -Wa,-ahlsn=../sym.lst -I -O2 -D__ECOS -DWEBS 
    -DUEMF -DWEBS_PAGE_ROM -DDIGEST_ACCESS_SUPPORT 
    -DOS="eCos" -DECOS -D__ECOS -D__NO_FCNTL=1 -I.. -Wall
     -I/home/grante/comtrol/sdk/DeviceMaster_Apps/SocketServer
    /Source/demoSocketServer/../ecos-build/install/include 
    -ffunction-sections -fdata-sections -Wp,-MD,../sym.d ../sym.c
    arm-elf-gcc -g -mcpu=arm7tdmi -mbig-endian -c -o ../uemf.o 
    -fverbose-asm -Wa,-ahlsn=../uemf.lst -I -O2 -D__ECOS -DWEBS 
    -DUEMF -DWEBS_PAGE_ROM -DDIGEST_ACCESS_SUPPORT 
    -DOS="eCos" -DECOS -D__ECOS -D__NO_FCNTL=1 -I.. -Wall
    -I/home/grante/comtrol/sdk/DeviceMaster_Apps/SocketServer/
    Source/demoSocketServer/../ecos-build/install/include 
    -ffunction-sections -fdata-sections -Wp,-MD,../uemf.d ../uemf.c
    arm-elf-gcc -g -mcpu=arm7tdmi -mbig-endian -c -o ../url.o 
    -fverbose-asm -Wa,-ahlsn=../url.lst -I -O2 -D__ECOS -DWEBS 
    -DUEMF -DWEBS_PAGE_ROM -DDIGEST_ACCESS_SUPPORT 
    -DOS="eCos" -DECOS -D__ECOS -D__NO_FCNTL=1 -I.. -Wall 
    -I/home/grante/comtrol/sdk/DeviceMaster_Apps/SocketServer/
    Source/demoSocketServer/../ecos-build/install/include 
    -ffunction-sections -fdata-sections -Wp,-MD,../url.d ../url.c
    arm-elf-gcc -g -mcpu=arm7tdmi -mbig-endian -c -o ../value.o 
    -fverbose-asm -Wa,-ahlsn=../value.lst -I -O2 -D__ECOS -DWEBS 
    -DUEMF -DWEBS_PAGE_ROM -DDIGEST_ACCESS_SUPPORT 
    -DOS="eCos" -DECOS -D__ECOS -D__NO_FCNTL=1 -I.. -Wall 
    -I/home/grante/comtrol/sdk/DeviceMaster_Apps/SocketServer/
    Source/demoSocketServer/../ecos-build/install/include 
    -ffunction-sections -fdata-sections -Wp,-MD,../value.d ../value.c
    arm-elf-gcc -g -mcpu=arm7tdmi -mbig-endian -c -o ../webs.o 
    -fverbose-asm -Wa,-ahlsn=../webs.lst -I -O2 -D__ECOS -DWEBS 
    -DUEMF -DWEBS_PAGE_ROM -DDIGEST_ACCESS_SUPPORT 
    -DOS="eCos" -DECOS -D__ECOS -D__NO_FCNTL=1 -I.. -Wall 
    -I/home/grante/comtrol/sdk/DeviceMaster_Apps/SocketServer/
    Source/demoSocketServer/../ecos-build/install/include 
    -ffunction-sections -fdata-sections -Wp,-MD,../webs.d ../webs.c
    arm-elf-gcc -g -mcpu=arm7tdmi -mbig-endian -c -o ../websuemf.o 
    -fverbose-asm -Wa,-ahlsn=../websuemf.lst -I -O2 -D__ECOS -DWEBS 
    -DUEMF -DWEBS_PAGE_ROM -DDIGEST_ACCESS_SUPPORT 
    -DOS="eCos" -DECOS -D__ECOS -D__NO_FCNTL=1 -I.. -Wall 
    -I/home/grante/comtrol/sdk/DeviceMaster_Apps/SocketServer/
    Source/demoSocketServer/../ecos-build/install/include 
    -ffunction-sections -fdata-sections -Wp,-MD,../websuemf.d ../websuemf.c
    arm-elf-gcc -g -mcpu=arm7tdmi -mbig-endian -c -o ../websda.o 
    -fverbose-asm -Wa,-ahlsn=../websda.lst -I -O2 -D__ECOS -DWEBS
    -DUEMF -DWEBS_PAGE_ROM -DDIGEST_ACCESS_SUPPORT 
    -DOS="eCos" -DECOS -D__ECOS -D__NO_FCNTL=1 -I.. -Wall 
    -I/home/grante/comtrol/sdk/DeviceMaster_Apps/SocketServer/
    Source/demoSocketServer/../ecos-build/install/include 
    -ffunction-sections -fdata-sections -Wp,-MD,../websda.d ../websda.c
    In file included from ../websda.c:24:
    ./md5.h:48:20: warning: no newline at end of file
    arm-elf-gcc -g -mcpu=arm7tdmi -mbig-endian -c -o ../md5c.o 
    -fverbose-asm -Wa,-ahlsn=../md5c.lst -I -O2 -D__ECOS -DWEBS 
    -DUEMF -DWEBS_PAGE_ROM -DDIGEST_ACCESS_SUPPORT 
    -DOS="eCos" -DECOS -D__ECOS -D__NO_FCNTL=1 -I.. -Wall 
    -I/home/grante/comtrol/sdk/DeviceMaster_Apps/SocketServer/
    Source/demoSocketServer/../ecos-build/install/include 
    -ffunction-sections -fdata-sections -Wp,-MD,../md5c.d ../md5c.c
    In file included from ../md5c.c:26:
    ./md5.h:48:20: warning: no newline at end of file
    arm-elf-ar rv libwebs.a ../asp.o ../balloc.o ../base64.o 
    ../default.o ../ejlex.o ../ejparse.o ../form.o ../h.o ../handler.o 
    ../mime.o ../misc.o ../page.o ../ringq.o ../rom.o ../sock.o
    ../sockGen.o ../security.o ../sym.o ../uemf.o ../url.o ../value.o
    ../webs.o ../websuemf.o ../websda.o ../md5c.o
    a - ../asp.o
    a - ../balloc.o
    a - ../base64.o
    a - ../default.o
    a - ../ejlex.o
    a - ../ejparse.o
    a - ../form.o
    a - ../h.o
    a - ../handler.o
    a - ../mime.o
    a - ../misc.o
    a - ../page.o
    a - ../ringq.o
    a - ../rom.o
    a - ../sock.o
    a - ../sockGen.o
    a - ../security.o
    a - ../sym.o
    a - ../uemf.o
    a - ../url.o
    a - ../value.o
    a - ../webs.o
    a - ../websuemf.o
    a - ../websda.o
    a - ../md5c.o
    make[1]: Leaving directory `/home/grante/comtrol/
    sdk/DeviceMaster_Apps/SocketServer/Source/
    demoSocketServer/goahead/ECOS'
    make binaries
    make[1]: Entering directory `/home/grante/comtrol/
    sdk/DeviceMaster_Apps/SocketServer/Source/
    demoSocketServer'
    arm-elf-gcc -g -mcpu=arm7tdmi -mbig-endian  -c -o main.o
    -fverbose-asm -Wall -O2 -D__ECOS  -I/home/grante/comtrol
    /sdk/DeviceMaster_Apps/SocketServer/Source/
    demoSocketServer/../ecos-build/install/include main.c
    arm-elf-as --gstabs -EB -m arm7tdmi -amhlsnd=boot.lst 
    -o boot.o boot.s
    arm-elf-gcc -g -mcpu=arm7tdmi -mbig-endian 
    -c -o watchdog.o 
    -fverbose-asm -Wall -O2 -D__ECOS  -I/home
    grante/comtrol/sdk/DeviceMaster_Apps/
    SocketServer/Source/demoSocketServer/../
    ecos-build/install/include watchdog.cxx
    arm-elf-gcc -g -mcpu=arm7tdmi -mbig-endian 
    -c -o commands.o 
    -fverbose-asm -Wall -O2 -D__ECOS  -I/home
    /grante/comtrol/sdk/DeviceMaster_Apps/
    SocketServer/Source/demoSocketServer/
    ../ecos-build/install/include commands.c
    arm-elf-gcc -g -mcpu=arm7tdmi -mbig-endian  
    -c -o portmon.o 
    -fverbose-asm -Wall -O2 -D__ECOS  -I/home/
    grante/comtrol/sdk/DeviceMaster_Apps/
    SocketServer/Source/demoSocketServer
    /../ecos-build/install/include portmon.c
    echo "char linkTimeStamp[] = \"`date`\";" 
    >linkTimeStamp.c
    arm-elf-gcc -g -mcpu=arm7tdmi -mbig-endian  -c linkTimeStamp.c
    arm-elf-gcc -g -mcpu=arm7tdmi -mbig-endian 
    -Wl,-Map,socket.elf.map -nostartfiles -L/home/grante/
    comtrol/sdk/DeviceMaster_Apps/SocketServer/Source
    demoSocketServer/../ecos-build/install/lib -Wl,--gc-sections 
    -o socket.elf main.o boot.o watchdog.o commands.o 
    portmon.o snmp/app.o webserv/app.o webpages/app.o
     goahead/ECOS/libwebs.a socketServer/app.o  admin
    /app.o linkTimeStamp.o -Ttarget.ld -nostdlib
    arm-elf-objcopy -O srec socket.elf socket.srec
    arm-elf-objcopy -O binary socket.elf socket.bin
    make[1]: Leaving directory `/home/grante/comtrol/
    sdk/DeviceMaster_Apps/SocketServer/Source/
    demoSocketServer'
  9. Verify that the installation files copied.

    $ ls -l

    total 9324
    -rwxr-xr-x 1 grante users    2428 Jan  1 11:07 Makefile
    drwxr-xr-x 2 grante users    4096 Jan  1 11:10 admin
    -rwxr-xr-x 1 grante users     843 Jun  3  2004 assert.h
    -rw-r--r-- 1 grante users     323 Jan  1 11:10 boot.lst
    -rw-r--r-- 1 grante users     828 Jan  1 11:10 boot.o
    -rwxr-xr-x 1 grante users     138 Jun  3  2004 boot.s
    -rwxr-xr-x 1 grante users   16555 Jun  3  2004 commands.c
    -rwxr-xr-x 1 grante users     768 Jun  3  2004 commands.h
    -rw-r--r-- 1 grante users   37292 Jan  1 11:10 commands.o
    -rwxr-xr-x 1 grante users    4030 Apr  7  2004 dbgthreads.cxx
    -rwxr-xr-x 1 grante users    2089 Apr  7  2004 dm.README
    -rwxr-xr-x 1 grante users    2153 Jun 29  2004 dm.h
    drwxr-xr-x 9 grante users    4096 Jan  1 11:10 goahead
    -rwxr-xr-x 1 grante users     562 Jun  3  2004 ident.h
    -rw-r--r-- 1 grante users      55 Jan  1 11:10 linkTimeStamp.c
    -rw-r--r-- 1 grante users    1704 Jan  1 11:10 linkTimeStamp.o
    -rw-r--r-- 1 grante users       0 Jan  1 11:11 ls.out
    -rwxr-xr-x 1 grante users   14505 Jun 29  2004 main.c
    -rw-r--r-- 1 grante users   50952 Jan  1 11:10 main.o
    -rw-r--r-- 1 grante users   18060 Jan  1 11:10 make.out
    -rwxr-xr-x 1 grante users     198 Apr  7  2004 memconfig.ld
    -rwxr-xr-x 1 grante users     997 Apr  7  2004 memconfigDRAM0_Flash100.s
    drwxr-xr-x 2 grante users    4096 Jul  2  2004 myextension
    -rwxr-xr-x 1 grante users    4130 Jun  3  2004 portmon.c
    -rw-r--r-- 1 grante users   35084 Jan  1 11:10 portmon.o
    drwxr-xr-x 2 grante users    4096 Jan  1 11:10 snmp
    -rwxr-xr-x 1 grante users  639076 Jan  1 11:10 socket.bin
    -rwxr-xr-x 1 grante users 5627800 Jan  1 11:10 socket.elf
    -rw-r--r-- 1 grante users 1133670 Jan  1 11:10 socket.elf.map
    -rwxr-xr-x 1 grante users 1835046 Jan  1 11:10 socket.srec
    drwxr-xr-x 2 grante users    4096 Jan  1 11:10 socketServer
    -rwxr-xr-x 1 grante users    3247 Jun  3  2004 state.h
    -rwxr-xr-x 1 grante users     447 Jun  3  2004 watchdog.cxx
    -rwxr-xr-x 1 grante users     112 Jun  3  2004 watchdog.h
    -rw-r--r-- 1 grante users    5392 Jan  1 11:10 watchdog.o
    drwxr-xr-x 3 grante users    4096 Jan  1 11:10 webpages
    drwxr-xr-x 2 grante users    4096 Jan  1 11:10 webserv

You may download the resulting ELF binary (the file named socket.elf) using GDB, or use RedBoot to load the binary (socket.bin) or S-Record (socket.srec) versions of the file. See Downloading a Program to locate procedures for downloading files into the DeviceMaster.

Building the GoAhead WebServer

The goahead.tar.gz file contains the source distribution for the GoAhead web server version 2.1. The source files have been modified to:

  • Fix bugs

  • Add features

  • Build/run on DeviceMaster

Use the following procedure to build the sample demo server.

[Note]
Note

Before you perform this procedure, you should closely review the GoAhead WebServer License.

  1. If you have not done so, unpack and install the pre-compiled eCos libraries. See Installing the Pre-Compiled (Binary) eCos Libraries.

    [Note]
    Note

    If you already have the eCos libraries installed, or if you built them from sources, you can skip this step, but you must edit the Makefile and change the value of PKG_INSTALL_DIR so that it contains the path of the eCos install directory.

  2. Copy the GoAhead source files to your hard disk. In this example, they were copied to the user's home directory.

  3. Create a work directory, in this example, we-demo.

    $ mkdir ws-demo
    $ cd ws-demo

  4. Unpack the GoAhead sources.

    $ tar xzf ~/goahead.tar.gz

  5. Build the demonstration web server.

    $ cd goahead/ECOS

  6. Compile the sample program.

    $ make

    arm-elf-as --gstabs -EB -m arm7tdmi   -o boot.o boot.s
    arm-elf-gcc -g -mcpu=arm7tdmi -mbig-endian -c 
    -o ../asp.o -fverbose-asm -I -O2 -D__ECOS -DWEBS -DUEMF 
    -DWEBS_PAGE_ROM -DDIGEST_ACCESS_SUPPORT 
    -DOS="eCos" -DECOS -D__ECOS -D__NO_FCNTL=1 
    -I.. -Wall -I../../install/include -ffunction-sections 
    -fdata-sections -Wp,-MD,../asp.d ../asp.c
    arm-elf-gcc -g -mcpu=arm7tdmi -mbig-endian -c 
    -o ../balloc.o -fverbose-asm -I -O2 -D__ECOS -DWEBS -DUEMF 
    -DWEBS_PAGE_ROM -DDIGEST_ACCESS_SUPPORT 
    -DOS="eCos" -DECOS -D__ECOS -D__NO_FCNTL=1
    -I.. -Wall -I../../install/include -ffunction-sections 
    -fdata-sections -Wp,-MD,../balloc.d ../balloc.c
    arm-elf-gcc -g -mcpu=arm7tdmi -mbig-endian -c 
    -o ../base64.o -fverbose-asm -I -O2 -D__ECOS -DWEBS -DUEMF 
    -DWEBS_PAGE_ROM -DDIGEST_ACCESS_SUPPORT 
    -DOS="eCos" -DECOS -D__ECOS -D__NO_FCNTL=1 
    -I.. -Wall -I../../install/include -ffunction-sections 
    -fdata-sections -Wp,-MD,../base64.d ../base64.c
    arm-elf-gcc -g -mcpu=arm7tdmi -mbig-endian -c 
    -o ../default.o -fverbose-asm -I -O2 -D__ECOS -DWEBS -DUEMF 
    -DWEBS_PAGE_ROM -DDIGEST_ACCESS_SUPPORT 
    -DOS="eCos" -DECOS -D__ECOS -D__NO_FCNTL=1 
    -I.. -Wall -I../../install/include -ffunction-sections 
    -fdata-sections -Wp,-MD,../default.d ../default.c
    arm-elf-gcc -g -mcpu=arm7tdmi -mbig-endian -c 
    -o ../ejlex.o -fverbose-asm -I -O2 -D__ECOS -DWEBS -DUEMF 
    -DWEBS_PAGE_ROM -DDIGEST_ACCESS_SUPPORT
    -DOS="eCos" -DECOS -D__ECOS -D__NO_FCNTL=1 
    -I.. -Wall -I../../install/include -ffunction-sections 
    -fdata-sections -Wp,-MD,../ejlex.d ../ejlex.c
    arm-elf-gcc -g -mcpu=arm7tdmi -mbig-endian -c 
    -o ../ejparse.o -fverbose-asm -I -O2 -D__ECOS 
    -DWEBS -DUEMF 
    -DWEBS_PAGE_ROM -DDIGEST_ACCESS_SUPPORT 
    -DOS="eCos" -DECOS -D__ECOS -D__NO_FCNTL=1 
    -I.. -Wall -I../../install/include -ffunction-sections 
    -fdata-sections -Wp,-MD,../ejparse.d ../ejparse.c
    arm-elf-gcc -g -mcpu=arm7tdmi -mbig-endian -c 
     -o ../form.o -fverbose-asm -I -O2 -D__ECOS -DWEBS -DUEMF 
    -DWEBS_PAGE_ROM -DDIGEST_ACCESS_SUPPORT 
    -DOS="eCos" -DECOS -D__ECOS -D__NO_FCNTL=1
    -I.. -Wall -I../../install/include -ffunction-sections 
    -fdata-sections -Wp,-MD,../form.d ../form.c
    arm-elf-gcc -g -mcpu=arm7tdmi -mbig-endian -c 
    -o ../h.o -fverbose-asm -I -O2 -D__ECOS -DWEBS -DUEMF 
    -DWEBS_PAGE_ROM -DDIGEST_ACCESS_SUPPORT 
    -DOS="eCos" -DECOS -D__ECOS -D__NO_FCNTL=1 
    -I.. -Wall -I../../install/include -ffunction-sections 
    -fdata-sections -Wp,-MD,../h.d ../h.c
    arm-elf-gcc -g -mcpu=arm7tdmi -mbig-endian -c 
    -o ../handler.o -fverbose-asm -I -O2 -D__ECOS -DWEBS -DUEMF 
    -DWEBS_PAGE_ROM -DDIGEST_ACCESS_SUPPORT
    -DOS="eCos" -DECOS -D__ECOS -D__NO_FCNTL=1 
    -I.. -Wall -I../../install/include -ffunction-sections 
    -fdata-sections -Wp,-MD,../handler.d ../handler.c
    arm-elf-gcc -g -mcpu=arm7tdmi -mbig-endian -c 
    -o ../mime.o -fverbose-asm -I -O2 -D__ECOS -DWEBS -DUEMF 
    -DWEBS_PAGE_ROM -DDIGEST_ACCESS_SUPPORT 
    -DOS="eCos" -DECOS -D__ECOS -D__NO_FCNTL=1
    -I.. -Wall -I../../install/include -ffunction-sections 
    -fdata-sections -Wp,-MD,../mime.d ../mime.c
    arm-elf-gcc -g -mcpu=arm7tdmi -mbig-endian -c -o ../misc.o 
    -fverbose-asm -I -O2 -D__ECOS -DWEBS -DUEMF 
    -DWEBS_PAGE_ROM -DDIGEST_ACCESS_SUPPORT 
    -DOS="eCos" -DECOS -D__ECOS -D__NO_FCNTL=1 
    -I.. -Wall -I../../install/include -ffunction-sections 
    -fdata-sections -Wp,-MD,../misc.d ../misc.c
    ../misc.c: In function `gstrtoi':
    ../misc.c:662: warning: implicit declaration of function `atoi'
    arm-elf-gcc -g -mcpu=arm7tdmi -mbig-endian -c 
    -o ../page.o -fverbose-asm -I -O2 -D__ECOS -DWEBS -DUEMF 
    -DWEBS_PAGE_ROM -DDIGEST_ACCESS_SUPPORT 
    -DOS="eCos" -DECOS -D__ECOS -D__NO_FCNTL=1 
    -I.. -Wall -I../../install/include -ffunction-sections 
    -fdata-sections -Wp,-MD,../page.d ../page.c
    arm-elf-gcc -g -mcpu=arm7tdmi -mbig-endian -c 
    -o ../ringq.o -fverbose-asm -I -O2 -D__ECOS -DWEBS -DUEMF 
    -DWEBS_PAGE_ROM -DDIGEST_ACCESS_SUPPORT 
    -DOS="eCos" -DECOS -D__ECOS -D__NO_FCNTL=1 
    -I.. -Wall -I../../install/include -ffunction-sections 
    -fdata-sections -Wp,-MD,../ringq.d ../ringq.c
    arm-elf-gcc -g -mcpu=arm7tdmi -mbig-endian -c 
    -o ../rom.o -fverbose-asm -I -O2 -D__ECOS -DWEBS -DUEMF 
    -DWEBS_PAGE_ROM -DDIGEST_ACCESS_SUPPORT 
    -DOS="eCos" -DECOS -D__ECOS -D__NO_FCNTL=1 
    -I.. -Wall -I../../install/include -ffunction-sections 
    -fdata-sections -Wp,-MD,../rom.d ../rom.c
    arm-elf-gcc -g -mcpu=arm7tdmi -mbig-endian -c 
    -o ../sock.o -fverbose-asm -I -O2 -D__ECOS -DWEBS 
    -DUEMF -DWEBS_PAGE_ROM -DDIGEST_ACCESS_
    SUPPORT -DOS="eCos" -DECOS -D__ECOS -D__NO_
    FCNTL=1 -I.. -Wall -I../../install/include -ffunction-sections 
    -fdata-sections -Wp,-MD,../sock.d ../sock.c
    ../sock.c: In function `socketDoOutput':
    ../sock.c:506: warning: implicit declaration of function `inet_addr'
    arm-elf-gcc -g -mcpu=arm7tdmi -mbig-endian -c 
    -o ../sockGen.o -fverbose-asm -I -O2 -D__ECOS -DWEBS -DUEMF 
    -DWEBS_PAGE_ROM -DDIGEST_ACCESS_SUPPORT 
    -DOS="eCos" -DECOS -D__ECOS -D__NO_FCNTL=1 
    -I.. -Wall -I../../install/include -ffunction-sections 
    -fdata-sections -Wp,-MD,../sockGen.d ../sockGen.c
    ../sockGen.c: In function `socketOpenConnection':
    ../sockGen.c:134: warning: implicit declaration of function `inet_addr'
    ../sockGen.c: In function `socketAccept':
    ../sockGen.c:359: warning: passing arg 3 of `accept' from 
    incompatible pointer type
    ../sockGen.c: In function `socketSelect':
    ../sockGen.c:704: warning: unused variable `len'
    ../sockGen.c:704: warning: unused variable `nwords'
    arm-elf-gcc -g -mcpu=arm7tdmi -mbig-endian 
    -c -o ../security.o -fverbose-asm -I -O2 -D__ECOS -DWEBS -DUEMF
    -DWEBS_PAGE_ROM -DDIGEST_ACCESS_SUPPORT 
    -DOS="eCos" -DECOS -D__ECOS -D__NO_FCNTL=1
     -I.. -Wall -I../../install/include -ffunction-sections 
    -fdata-sections -Wp,-MD,../security.d ../security.c
    arm-elf-gcc -g -mcpu=arm7tdmi -mbig-endian 
    -c -o ../sym.o -fverbose-asm -I -O2 -D__ECOS -DWEBS -DUEMF 
    -DWEBS_PAGE_ROM -DDIGEST_ACCESS_SUPPORT
     -DOS="eCos" -DECOS -D__ECOS -D__NO_FCNTL=1 
    -I.. -Wall -I../../install/include -ffunction-sections 
    -fdata-sections -Wp,-MD,../sym.d ../sym.c
    arm-elf-gcc -g -mcpu=arm7tdmi -mbig-endian 
    -c -o ../uemf.o -fverbose-asm -I -O2 -D__ECOS -DWEBS -DUEMF 
    -DWEBS_PAGE_ROM -DDIGEST_ACCESS_SUPPORT 
    -DOS="eCos" -DECOS -D__ECOS -D__NO_FCNTL=1
    -I.. -Wall -I../../install/include -ffunction-sections 
    -fdata-sections -Wp,-MD,../uemf.d ../uemf.c
    arm-elf-gcc -g -mcpu=arm7tdmi -mbig-endian 
    -c -o ../url.o -fverbose-asm -I -O2 -D__ECOS
     -DWEBS -DUEMF -DWEBS_PAGE_ROM 
    -DDIGEST_ACCESS_SUPPORT -DOS="eCos"
    -DECOS -D__ECOS -D__NO_FCNTL=1 
    -I.. -Wall -I../../install/include -ffunction-sections 
    -fdata-sections -Wp,-MD,../url.d ../url.c
    arm-elf-gcc -g -mcpu=arm7tdmi -mbig-endian 
    -c -o ../value.o -fverbose-asm -I -O2 -D__ECOS 
    -DWEBS -DUEMF 
    -DWEBS_PAGE_ROM -DDIGEST_ACCESS_SUPPORT 
    -DOS="eCos" -DECOS -D__ECOS -D__NO_FCNTL=1 
    -I.. -Wall -I../../install/include -ffunction-sections 
    -fdata-sections -Wp,-MD,../value.d ../value.c
    gcc -o webcomp -O2 -DWEBS -DUEMF -DUNIX -I.. ../webcomp.c
    ../webcomp.c: In function 'compile':
    ../webcomp.c:121: warning: comparison of distinct pointer 
    types lacks a cast
    find ../web -name "*.*" >web_files
    ./webcomp ../web web_files >webrom.c
    arm-elf-gcc -g -mcpu=arm7tdmi -mbig-endian 
    -c -o webrom.o -fverbose-asm -I -O2 -D__ECOS -DWEBS -DUEMF
     -DWEBS_PAGE_ROM -DDIGEST_ACCESS_SUPPORT 
    -DOS="eCos" -DECOS -D__ECOS -D__NO_FCNTL=1 
    -I.. -Wall -I../../install/include -ffunction-sections
    -fdata-sections -Wp,-MD,webrom.d webrom.c
    arm-elf-gcc -g -mcpu=arm7tdmi -mbig-endian 
    -c -o ../webs.o -fverbose-asm -I -O2 -D__ECOS 
    -DWEBS -DUEMF 
    -DWEBS_PAGE_ROM -DDIGEST_ACCESS_SUPPORT
     -DOS="eCos" -DECOS -D__ECOS -D__NO_FCNTL=1
    -I.. -Wall -I../../install/include -ffunction-sections 
    -fdata-sections -Wp,-MD,../webs.d ../webs.c
    arm-elf-gcc -g -mcpu=arm7tdmi -mbig-endian 
    -c -o ../websuemf.o -fverbose-asm -I -O2 -D__ECOS -DWEBS 
    -DUEMF -DWEBS_PAGE_ROM -DDIGEST_ACCESS_
    SUPPORT -DOS="eCos" -DECOS -D__ECOS -D__NO_FCNTL=1
    -I.. -Wall -I../../install/include -ffunction-sections 
    -fdata-sections -Wp,-MD,../websuemf.d ../websuemf.c
    arm-elf-gcc -g -mcpu=arm7tdmi -mbig-endian
    -c -o ../websda.o -fverbose-asm -I -O2 -D__ECOS -DWEBS 
    -DUEMF -DWEBS_PAGE_ROM -DDIGEST_ACCESS_SUPPORT 
    -DOS="eCos" -DECOS -D__ECOS -D__NO_FCNTL=1 
    -I.. -Wall -I../../install/include -ffunction-sections 
    -fdata-sections -Wp,-MD,../websda.d ../websda.c
    In file included from ../websda.c:24:
    ../md5.h:48:20: warning: no newline at end of file
    arm-elf-gcc -g -mcpu=arm7tdmi -mbig-endian 
    -c -o ../md5c.o -fverbose-asm -I -O2 -D__ECOS -DWEBS 
    -DUEMF -DWEBS_PAGE_ROM -DDIGEST_ACCESS_
    SUPPORT -DOS="eCos" -DECOS -D__ECOS -D__NO_FCNTL=1 
    -I.. -Wall -I../../install/include -ffunction-sections 
    -fdata-sections -Wp,-MD,../md5c.d ../md5c.c
    In file included from ../md5c.c:26:
    ../md5.h:48:20: warning: no newline at end of file
    arm-elf-ar rv libwebs.a ../asp.o ../balloc.o
    ../base64.o ../default.o ../ejlex.o ../ejparse.o ../form.o ../h.o 
    ../handler.o ../mime.o ../misc.o ../page.o ../ringq.o ../rom.o 
    ../sock.o ../sockGen.o ../security.o ../sym.o ../uemf.o ../url.o 
    ../value.o webrom.o ../webs.o ../websuemf.o ../websda.o ../md5c.o
    a - ../asp.o
    a - ../balloc.o
    a - ../base64.o
    a - ../default.o
    a - ../ejlex.o
    a - ../ejparse.o
    a - ../form.o
    a - ../h.o
    a - ../handler.o
    a - ../mime.o
    a - ../misc.o
    a - ../page.o
    a - ../ringq.o
    a - ../rom.o
    a - ../sock.o
    a - ../sockGen.o
    a - ../security.o
    a - ../sym.o
    a - ../uemf.o
    a - ../url.o
    a - ../value.o
    a - webrom.o
    a - ../webs.o
    a - ../websuemf.o
    a - ../websda.o
    a - ../md5c.o
    arm-elf-gcc -g -mcpu=arm7tdmi -mbig-endian -o webs.elf 
    -fverbose-asm -I -O2 -D__ECOS -DWEBS -DUEMF 
    -DWEBS_PAGE_ROM -DDIGEST_ACCESS_SUPPORT 
    -DOS="eCos" -DECOS -D__ECOS -D__NO_FCNTL=1 -I..  \
    boot.o main.o libwebs.a -nostartfiles -L../../install/lib -Wl,
    --gc-sections -Ttarget.ld -nostdlib 
     
    $

    The ROM image of the website directory tree is constructed in a portable but inefficient manner: The webcomp program traverses the tree and generates a C-language file (webrom.c) containing a set of initialized byte arrays containing the directory tree's entire image. Compiling webrom.c may take a long time (several minutes).

  7. You may download the resulting ELF binary (the file named webs.elf) using a GDB, or convert it to binary or S-Record format for downloading via RedBoot: See Downloading a Program for more information about downloading programs to the DeviceMaster.

    $ arm-elf-objcopy -O binary webs.elf webs.bin
    $ arm-elf-objcoyp -O srec webs.elf webs.srec

Building the eCos Sample Applications (Serial and Ethernet)

The \DMDK\Sample_Apps\Source directory contains two example eCos applications that demonstrate the use of the DeviceMaster serial driver and the DeviceMaster Ethernet driver.

In the example below we'll assume that the user's home directory contains the demo.tar.gz and install.tar.gz files.

  1. If you have not done so, unpack and install the pre-compiled eCos libraries. See Installing the Pre-Compiled (Binary) eCos Libraries.

  2. Install the demo.tar.gz files. This example uses a directory named ecos-samples in the users home directory:

    $ cd
    $ mkdir ecos-samples
    $ cd ecos-samples
    $ tar xzf ~/demo.tar.gz

  3. If the install directory is somewhere else, edit the Makefile so that the ECOS variable points to the location of the install directory. The makefile in the demo directory assumes that the eCos install directory is in the same directory as the demo directory. For example:

     ECOS = /home/my-ecos-build-dir/install

  4. If the install directory is somewhere else, edit the Makefile so that the ECOS variable points to the location of the install directory. The makefile in the demo directory assumes that the eCos install directory is in the same directory as the demo directory. For example:

    ECOS = /home/my-ecos-build-dir/install

  5. Perform a make depend to fill in the srcdeps files.

    $ cd demo
    $ make depend

    Generating source dependencies
    arm-elf-gcc -mcpu=arm7tdmi -mbig-endian -fverbose-asm -g -Wa,-
    ahlsn=.lst -O0 -D__ECOS -I../install/include -M netecho.c 
    serecho.c >>srcdeps
  6. Perform a make to build the demo applications.

    $ make

    arm-elf-gcc -mcpu=arm7tdmi -mbig-endian -c -o netecho.o -fverbose-asm -g 
    -Wa,-ahlsn=netecho.lst -O0 -D__ECOS -I../install/include -Wall  netecho.c
    arm-elf-as --gstabs -EB -m arm7tdmi -amhlsnd=boot.lst  -o boot.o boot.s
    arm-elf-gcc -mcpu=arm7tdmi -mbig-endian -Wl,-Map,
    netecho.map -g -Wl,--gc-sections -nostartfiles -L../install/
    lib -o netecho.elf  netecho.o boot.o -Ttarget.ld -nostdlib
    arm-elf-gcc -mcpu=arm7tdmi -mbig-endian -c -o serecho.o 
    -fverbose-asm -g -Wa,-ahlsn=serecho.lst -O0 -D__ECOS 
    -I../install/include -Wall  serecho.c
    arm-elf-gcc -mcpu=arm7tdmi -mbig-endian -Wl,-Map,
    serecho.map -g -Wl,--gc-sections -nostartfiles -L../install/lib -o 
    serecho.elf  serecho.o boot.o -Ttarget.ld -nostdlib
    arm-elf-objcopy -O binary netecho.elf netecho.bin
    arm-elf-objcopy -O binary serecho.elf serecho.bin
    arm-elf-objcopy -O srec netecho.elf netecho.srec        
    arm-elf-objcopy -O srec serecho.elf serecho.srec 

The file raw.py is an example program that may be run on a Linux host that has Python 2.0 or later. It sends Ethernet frames to a DeviceMaster that is running the netecho demo application.

If you want to use eCos applications with the custom version of RedBoot, it's convenient if you build your image so that it has an entry point at address 0. That way you can download binary images and used the default start address of 0. Linking with boot.o (generated from boot.s) adds that entry point.

If you are downloading S-Record images with RedBoot, or using ELF images with a debugger, then you don't need an entry point at 0 and don't have to include boot.[so] in your build process. See Downloading a Program for information about downloading programs to the DeviceMaster.

SDK Procedures

You can use the following list to locate procedures throughout the SDK.

Using the Diagnostic Serial Port

The DeviceMaster circuit board has two diagnostic serial ports. Each port is accessed via 4-Pin header near one end of the board. The signal levels on the headers are not RS-232, and a converter cable is required to convert them to RS-232 levels for use with a standard serial port.

The DeviceMaster circuit board has two diagnostic serial ports. Each port is accessed via 4-Pin header near one end of the board. The signal levels on the headers are not RS-232, and a converter cable is required to convert them to RS-232 levels for use with a standard serial port.

[Note]
Note

The converter cable is included with the Software Development Kit.

The first diagnostic port is used for diagnostic output from calls to diag_printf(). It is also used by RedBoot as a command console.

The second diagnostic port also functions as a RedBoot console port. The second port can be used for a serial remote GDB connection, see Using GDB with Diagnostic Port 2 . The positions of these connectors are shown in the figures below.

4/8-Port Board (Top View)

16-Port Board (Top View)

Use the following procedure to set up the diagnostic serial port:

  1. Plug the diagnostic cable into the first diagnostic port (Diag Port 1) and connect it to a serial port configured for:

    • 57600 baud

    • 8 data bits

    • no parity

    • 1 stop bit

    • No flow control

  2. Connect a null-modem cable from an available COM port on your PC to serial Port 1 on the DeviceMaster.

    [Note]
    Note

    You may want to purchase or build a straight-through cable and purchase a null-modem adapter.

  3. If you monitor the data from that port and cycle power on the DeviceMaster, you should see startup messages from the bootloader and then a prompt:

    RAM OK 
    Sum OK 
    + 
    Pepperl+Fuchs Comtrol, Inc. DeviceMaster Boot Version 1.06 
    RedBoot(tm) debug environment - built 14:18:19, Jul 18 2001 
    Platform: Pepperl+Fuchs Comtrol, Inc. DeviceMaster (ARM 7TDMI) 
    Portions Copyright (C) 2000, Red Hat, Inc. 
    Portions Copyright (C) 2001, Comtrol Corp. 
    FLASH: 0x05030000 - 0x05400000, 61 blocks of 0x00010000 bytes each. 
    ks32c5000_eth_init() 
    found MAC address 00:C0:4E:0B:FF:F9 
    ks5000_ether: installInterrupts() 
    EthInit(00:C0:4E:0B:FF:F9) 
    ks32C5000 eth: 00:C0:4E:0B:FF:F9  Hardware CRC 
    ks32c5000_eth_start() 
    IP: 192.168.250.250, Mask: 255.255.255.0, Gateway: 192.168.250.1,
    Server: 0.0.0.0 
    RedBoot>
  4. At this point you can type bootloader commands. If a default application is configured in flash, and the default application time-out is set (15 seconds), you will see the default application start up after the time-out period:

     ARM DeviceMaster HAL (no virtual vectors) 
    AIOPIC serial driver: 16 channels 
    ks32c5000 old_init_handler() 
    Network stack using 262144 bytes for misc space 
    262144 bytes for mbufs 
    524288 bytes for mbuf clusters 
    ks32c5000_eth_init() 
    found MAC address 00:C0:4E:0B:FF:F9 
    ks5000_ether: installInterrupts() 
    EthInit(00:C0:4E:0B:FF:F9) 
    ks32C5000 eth: 00:C0:4E:0B:FF:F9  Hardware CRC 
    SocketServer 1.13 
    Copyright Comtrol Corp. 2001 
    Build date: Tue Jun 19 12:21:54 CDT 2001 
    
    Free RAM at 280700,  Len = 53F900 
    starting madmin 
    Bg started 
    madmin running 
    madmin MyMacAddr=00:C0:4E:0B:FF:F9 
    ks32c500 old_set_config_handler() 
    ks32c5000_eth_start() 
    IP = 0A000005 
    Mask = FF000000 
    Gate = 0A000001 
    Net init complete. 
    Net init done 
    socket server init 
    socket server active config: 05002000 
    TcpRx0: waiting on semaphore 
    TcpTx0 started 
    [...] 
                        

Testing Serial Ports

There are two commands that run loopback (internal, RS-232, or RS-422) or port-to-port (RS-485) serial tests.

Loopback Tests (loop)

With a loopback plug connected to a port, the loop command may be used to run a loop-back test in either internal loop-back mode, RS-232 mode or RS-422 mode. In RS-232 mode, modem control lines are also tested. In RS-422 mode and internal loop-back mode, only data paths are tested. If the test fails, a hexadecimal error code is displayed. The first digit of the error code indicates what portion of the test failed. Loop-back error codes are shown in the table below.

Examples of loopback test commands are shown below.

  • RS-232 loopback test on Port 2:

    RedBoot> loop 232 2 

    Loopback pass
  • RS-232 loopback test on Port 3:

    RedBoot> loop 232 3

    - Loopback failed RS-232: 10680
  • Internal loopback test on Port 1:

    RedBoot>  loop int 1  

    Loopback pass
Loopback Error CodesCode Description
0x1ssss No data was present in the receive FIFO when there should have been. The channel status register is displayed in the lower 4 digits (ssss).
0x2ssss An error flag was present when receive data was read.
0x3ttrr Receive data byte did not match transmit data byte. The transmit data byte is tt and the receive data byte is rr.
0x40000 Receive data was present after the expected last byte.
0x5ssss CTS signal did not match expected value.
0x6ssss RI signal did not match expected value.
0x7ssss DSR signal did not match expected value.
0x8ssss CD signal did not match expected value.

Port-to-Port RS-485 Test (t485)

Some DeviceMaster models have internal loopback hardware for use by the loop command.

For models that do not support the loopback command for RS-485 ports an RS-485 cross-over cable must be connected between two different ports on the DeviceMaster.

The t485 command is used to perform a bi-directional, half-duplex, data-transfer test between two ports. If ports 0 and 4 are connected with an RS-485 crossover cable, the command to perform the test is:

RedBoot> t485 0 4

485 pass

Testing ports not connected to each other results in a failure:

RedBoot> t485 0 1

 - Failed 485 test: 1220008

Downloading a Program

There are several methods available for downloading and running a DeviceMaster application:

  • RedBoot

    • TFTP via Ethernet (binary file or S-record)

    • X-Modem via RS-232 (binary file or S-record)

  • DeviceMaster Utilities

    • PortVision DX (binary, Windows XP through Windows 10)

    • RTS Command-line Updater utility (binary file)

    • nslinkadmin program (binary file, Linux only)

  • GDB

    • GDB via JTAG interface

    • GDB via remote protocol on Diagnostic Port 2

Each of these will be described. It is also possible to download a program and save it in flash ROM so that it is executed automatically when the DeviceMaster starts.

Using RedBoot

Use the following discussions to download a program using RedBoot. Use Disabling Auto-Load if you want to disable or remove the default application

Disabling Auto-Load

When shipped, the DeviceMaster will be configured so that RedBoot waits for 15 seconds after start-up before loading and running the default application from flash ROM. Since several of the download methods require that RedBoot be running, it may be convenient to disable auto-loading of the default application. You may configure RedBoot to not load a default application from flash ROM either of two ways.

  • To disable the default application, do the following:

    At the RedBoot command prompt, disable default application loading by setting the time-out parameter to zero:

    RedBoot> timeout 0

    Timeout 0 seconds
    RedBoot>
  • To delete the default application from flash, use the fis delete command at the RedBoot prompt:

    RedBoot> fis delete default

    Delete image ’default’ - are you sure (y/n)? y 
    ... Erase from 0x05030000-0x050c0000: ......... 
    ... Erase from 0x053f0000-0x05400000: . 
    ... Program from 0x007a0000-0x007b0000 at 0x053f0000: . 
    + 
    RedBoot>
Locating Further Information

The DeviceMaster platform includes a customized version of the RedBoot bootloader from RedHat. RedBoot is described in detail in Using the RedBoot Bootloader. RedBoot can be used to download application programs using either TFTP (via Ethernet) or X-Modem (via serial port). Examples of loading using the RedBoot load command can be found in Default Application. Once the file is loaded, it may be run using the RedBoot go command as shown in Default Application. For more information on using RedBoot on the DeviceMaster platform, see the documents listed below:

Using DeviceMaster Utilities

There are several DeviceMaster utilities (Linux and Windows) that can also be used to download and run a DeviceMaster applications. Instructions for using the utilities to download are found in the help files.

  • PortVision DX

    If you are using a Windows XP through Windows 10 system, you can use PortVision DX to load binary files. PortVision DX is the fastest and easiest way to update binary files, as long as you are connected to the same local network segment. For information about using PortVision DX, refer to the PortVision DX help system or the DeviceMaster Installation and Configuration Guide. You can download the latest version.

  • RTS Command Line Updater

    This is a Python program that can be used to download an application.

  • nslinkadmin tool (Linux)

    The nslinkadmin utility that is included with the Linux NS-Link device driver can be used to download and run a DeviceMaster application that has been converted to a binary file with an entry point at Address 0.

Using the RTS Command Line Updater

The download.py file is a Python program that can be used to download an application to the DeviceMaster. The program to be downloaded must be a pure binary file to be loaded starting at address 0x00000000. The RTS Command Line Updater is provided in the SDK.

Usage

download.py [-r] [-q] [-s] [-g] [hostname] [filename]

Options

The following table describes download.py options.

OptionDescriptions
-r Reset Sends a reset command to the DeviceMaster before it is downloaded. This is required if the DeviceMaster is running the SocketServer or NS-Link application. This is not required if RedBoot is already running (LED is flashing).
-q Quiet mode -- do not display address and byte count as program is loaded.
-sSkip vectors -- skips the first 0x20 bytes in the file. This is required if the downloaded program is to be debugged using GDB.
-gGo. After downloading start execution of the program at address 0x00000000.
Using download.py with GDB

When debugging with GDB via diagnostic serial port, downloading large applications can take a long time. It is possible to speed up the process by downloading the application binary file via Ethernet before starting GDB. This process uses a small download utility written in Python. The download.py program has been tested under Cygwin and Linux. The procedure is shown below:

  1. Connect serial cable to Diagnostic Port 2.

  2. Make sure RedBoot is running (status LED should be flashing at about 2 Hz). If necessary, cycle power to reset the DeviceMaster.

  3. Use the download.py program to download (but not start) the program. Use the -s option to tell download.py to skip downloading the vector table since overwriting the vector table will confuse RedBoot:

    $ download.py -s 10.0.0.12 socket.bin

    320:1400
    1720:1400
    3120:1400
    [...]
    564520:1400
    565920:1400
    567320:1120
    downloaded 568440 bytes
    
    $ _

    At this point, RedBoot should still be running (status LED flashing).

  4. Start GDB.

    $ agdb -b 57600

    GNU gdb 5.1.1
    Copyright 2002 Free Software Foundation, Inc.
    GDB is free software, covered by the GNU General Public License, and you are
    welcome to change it and/or distribute copies of it under certain conditions.
    Type "show copying" to see the conditions.
    There is absolutely no warranty for GDB.  Type "show warranty" for details.
    This GDB was configured as "--host=i586-pc-linux-gnu --target=arm-elf".
    The target is assumed to be big endian
    0x007c6968 in ?? ()
    (gdb)
  5. Load symbol info:

    (gdb) sym socket.elf

    Reading symbols from socket.elf...done.
  6. Set the starting address:

    (gdb) set $pc = reset_vector

    Current language: auto; currently asm
  7. Set a breakpoint:

    (gdb) tbreak cyg_user_start

    Breakpoint 1 at 0x91c: file main.c, line 70.
  8. Begin execution with the continue command:

    (gdb) cont

    Continuing.
    [New Thread 0]
    [Switching to Thread 0]
    cyg_user_start () at main.c:70
    70        LedOff();
    Current language:  auto; currently c
    (gdb)

To reload the application, exit GDB, reset the DeviceMaster, and repeat the process. It is not possible to download via network while a GDB session is active.

Using nslinkadmin

The nslinkadmin utility that is included with the Linux NS-Link device driver can be used to download and run a DeviceMaster application that has been converted to a binary file with an entry point at Address 0. The nslinkadmin program must run as root in order to access an Ethernet interface in raw mode. Therefore, you must be logged in as root or have nslinkadmin suid root. There are two ways to run nslinkadmin: interactive mode and command-line mode. For more information, see the nslinkadmin(8) manual page.

Interactive Mode

If your DeviceMaster is connected to an Ethernet interface other than eth0, use the -d option to specify the interface:

# /usr/sbin/nslinkadmin -d eth1

Using network device ‘eth1’
Checking network for any possible remotes. 
1) 00:c0:4e:0b:ff:f9  DeviceMaster          (idle,free) 
q) quit 
->_ 

If you have more than one DeviceMaster connected to the Ethernet network, the list shows each DeviceMaster found. Select the appropriate device by entering the corresponding number:

->1 
Other Pepperl+Fuchs Comtrol, Inc. Hub: 00:c0:4e:0b:ff:f9 
IP Utility 
?                        Display help information. 
ig                       Get/display flash IP config 
ic                       Get/display current IP config 
is <addr> <mask> <gate>  Set IP info 
ie                       Erase IP info 
l                        Load the remote. 
s                        Start the remote. 
z                        Shortcut for l, s 
r                        Reset the remote. 
x <filename>             Load and start the specified file. 
q                        Quit the test. 
->_ 

To download and start a DeviceMaster application, enter x followed by the file name of the binary file:

-> x serecho.bin 

Loading remote 
.................................................................. 
Starting remote 
->_ 

While loading, a “.�? displays for each packet downloaded. Once the file is downloaded, it starts automatically. Once the application starts, NS-Link will no longer be able to communicate with the DeviceMaster. To exit nslinkadmin, enter q and press the Return key.

Command Line Mode

Downloading using nslinkadmin in non-interactive command-line mode is done by specifying command line switches:

nslinkadmin Command Line SwitchesDescription
-d <ethdev> Controls the ethernet interface used: eth0 (default), eth1, etc.
-e <macaddr> Specifies the Ethernet address of the DeviceMaster device in xx:xx:xx:xx:xx:xx format.
-f <binfile>Specifies the path of the file to be downloaded.
-l Tells nslinkadmin to load and run the file.

For example:

nslinkadmin -d eth1 -e 00:c0:4e:0b:ff:f9 -l -f serecho.bin

Using GDB

This section discusses the following topics:

The gdbinit File

The .gdbinit file that is included in the demo application package assumes that we are using a JTAG interface that uses the RDI protocol over UDP/IP (such as the EPI Jeeni), and that hostname for the JTAG interface is jeeni.

If you are using a serial or serial/parallel connection to your JTAG interface, or the hostname for your JTAG interface is not jeeni, you must edit the .gdbinit file and modify the target command before running GDB

When GDB is started, it reads an initialization file from the current directory. This file contains GDB commands that are executed just as they would be if they were entered at the GDB command prompt.

[Note]
Note

Under UNIX, .gdbinit is the name of this file. Under Cygwin, GDB with the Insight GUI reads a file named gdb.ini instead of .gdbinit.

In the examples below, several macros were used that were defined in the .gdbinit file contained in the demo.tar.gz package:

  1. Turn off paging of GDB output:.

    1  set width 0 
    2  set height 0
  2. Turn of RDI/ADP heartbeat feature; it does not seem to work with either the Jeeni or the EmbeddedICE JTAG interface units.

    3  set rdiheartbeat off 
  3. Tell the debugger that we have ROM at zero to prevent it from automatically setting breakpoints on the interrupt vectors:

    4  set rdiromatzero on 
    5
  4. Define the resetcpu macro:

    6  # macro to "reset" the processor to a known state 
    7  # mostly just shut of the timers and disable all 
    8  # of the interrupts 
    9  
    10  define resetcpu 
    11    # map internal SRAM to 3fe0000 
    12    # map special regs to  3ff0000 
    13    # cache disabled 
    14    set *0x7ff0000 = 0x83ffffa0 
    15    
    16    # shut off timers 
    17    set *0x7ff6000  = 0 
    18    
    19    # set all port pins to input (disabling WD timer) 
    20    set *0x7ff5000  = 0 
    21    
    22    # disable WD in dallas part 
    23    set *(char*)0x760800f &= 0xfc 
    24    
    25    # shut off Ethernet MAC and BDMA 
    26    set *0x7ffa000 = 0 
    27    set *0x7ffa004 = 0 
    28    set *0x7ffa008 = 0 
    29    set *0x7ffa010 = 0 
    30  
    31    set *0x7ff9000 = 0 
    32    set *0x7ff9004 = 0 
    33    set *0x7ff9008 = 0 
    34    set *0x7ff900c = 0 
    35    
    36    # reset UARTS 
    37    set *0x7ffc000 = 0 
    38    set *0x7ffc004 = 0 
    39    set *0x7ffd000 = 0 
    40    set *0x7ffd004 = 0 
    41  
    42    # disable/clear interrupts 
    43    set *0x7ff4000 = 0 
    44    set *0x7ff4008 = 0xffffffff 
    45    set *0x7ff4004 = 0xffffffff 
    46  end 
    47
  5. Define the memconfig macro. The memconfig program is linked so that it runs in the 8K SRAM that is built into the Samsung uController. This will not work if the cache is enabled, so do a resetcpu first to disable cache.

    48  # macro to load memory config program into SRAM and run it 
    49  
    50  define memconfig      
    51    delete 
    52    symbol-file memconfig 
    53    load memconfig 
    54    tbreak __memoryConfigDone 
    55    cont 
    56    symbol-file 
    57  end 
  6. Define a macro that loads a program and sets breakpoints on the interrupt vectors. Note the display command at the end of the macro – that will tell GDB to evaluate and display the expression *(char*)0x760800f &= 0xfc every time execution is stopped. That expression disables the watchdog timer in the Dallas DS1511W – thus preventing the board from being reset while you are trying to decide what to do next after a breakpoint has been hit.

    59  define reload-with-break 
    60    resetcpu 
    61    delete 
    62    symbol-file 
    63    symbol-file $arg0 
    64    load $arg0 
    65    break *0x00 
    66    break *0x04 
    67    break *0x08 
    68    break *0x0c 
    69    break *0x10 
    70    break *0x14 
    71    break *0x18 
    72    break *0x1c
    73    display   *(char*)0x760800f &= 0xfc 
    74  end  
    75 
    The same macro without the breakpoints on the interrupt vectors.
    76  define reload 
    77    resetcpu 
    78    delete 
    79    symbol-file 
    80    symbol-file $arg0 
    81    load $arg0 
    82    display   *(char*)0x760800f &= 0xfc 
    83  end  
    84  
    85  # the "display *(char*)0x760800f &= 0xfc" will disable the 
    86  # watchdog timer in the Dallas Semi part whenever execution 
    87  # stops (when breakpoint is hit or when the user stops the 
    88  # program.)  If we don’t do this, the board will reset after 
    89  # a breakpoint has been hit. 
    90  
  7. Pick which set of register names you like:

    91  set dis std 
    92 
    8.	Make sure the debugger knows we’re running big-endian:
    93  set endian big
  8. The target command tells the debugger what protocol (rdi) and communications link (ethernet) we are going to use.

    94  # target rdi /dev/ttyS0 19200 
    95  # target rdi s=/dev/ttyS0,p=/dev/par0 19200 
    96  target rdi e=jeeni
  9. The target command tells the debugger what protocol (rdi) and communications link (ethernet)

  10. Force the CPU into a benign state using the macro we defined above:

    98  resetcpu
    99
Running GDB

This example will show how to use GDB to run a program via the JTAG interface. If you do not have a JTAG interface, please read and understand the differences between using the JTAG (Using GDB with the JTAG Interface) and serial port (Using GDB with Diagnostic Port 2) interfaces.

First we will start GDB in non-Window mode so that we can show the commands and their output.

  1. If you are using the insight GUI for GDB, enter the commands shown below in the console window.

    $ arm-elf-gdb -nw 

    GNU gdb 5.0 
    Copyright 2000 Free Software Foundation, Inc. 
    GDB is free software, covered by the GNU General Public License, 
    and you are welcome to change it and/or distribute copies of it  
    under certain conditions.
    Type "show copying" to see the conditions. 
    There is absolutely no warranty for GDB.  Type "show warranty" for 
    details. 
    This GDB was configured as "--host=i586-pc-linux-gnu --target=arm-elf". 
    JEENI (ADP,ARM7TDI,RST) Rev 2.2 
    Rebuilt on Jan 12 2001 at 14:22:34 
    SN=0102J069 ENET=00:80:CF:00:0C:CD IP=10.0.0.100 (255.255.0.0) 
    Connected to ARM RDI target. 
    (gdb) 
  2. Run the resetcpu macro which will put the CPU into a known state:

     (gdb) resetcpu

  3. Load the serecho program using the reload macro.

    (gdb) reload serecho

    Warning: the current language does not match this frame. 
    Loading section .rom_vectors, size 0x44 lma 0x340 
    Loading section .text, size 0x27cf4 lma 0x384 
    Loading section .rodata, size 0x167f lma 0x28078 
    Loading section .data, size 0x1610 lma 0x296f8 
    Loading section .boot, size 0x4 lma 0x0 
    Start address 0x384 , load size 174539 
    Transfer rate: 465437 bits/sec, 505 bytes/write.
  4. Set a temporary breakpoint at the cyg_user_start() function:

    (gdb) tbreak cyg_user_start 

    Breakpoint 1 at 0x99c: file serecho.c, line 72.
  5. Start execution with the continue command:

    (gdb) c

    Continuing. 
    cyg_user_start () at serecho.c:72 
    72        diag_printf("Entering cyg_user_start() function\n"); 
    1: *(char *) 123764751 &= 252 = 128 ’\200’ 
    Current language:  auto; currently c 
    We hit the breakpoint and stopped (at Line 72 in serecho.c).
    If we were using a GUI, the source window would show 
    serecho.c with Line 72 highlighted.
  6. Continue (no breakpoints are set, so it will run until you enter Ctrl-C to stop it).

    (gdb) c

    Continuing. 
  7. Press Ctrl-C, and the emulator stops the processor:

    JEENI: halt request 
    JEENI: halted 
    RDI_execute: you pressed Escape 
    
    Program received signal SIGINT, Interrupt. 
    idle_thread_main (data=1040807) at /opt/ecos/ecos-cvs/ecos/
    packages/kernel/current/src/common/thread.cxx:1148 
    1148    /opt/ecos/ecos-cvs/ecos/packages/kernel/current/
    src/common/thread.cxx: No such file or directory. 
    1: *(char *) 123764751 &= 252 = 128 ’\200’ 
    Current language:  auto; currently c++ 
    (gdb)

    In the example, the program was stopped in the built-in eCos idle task. This is typical, since the program does not do much and will spend most of its time idle. Since we do not have the eCos source files installed, the debugger can not display the source file line and warns us that it can not find the source file.

  8. If you had been watching the output from the diagnostic serial port, you should have seen something like this:

    ARM DeviceMaster HAL (no virtual vectors) 
    AIOPIC serial driver: 16 channels 
    ks32c5000 old_init_handler() 
    Network stack using 262144 bytes for misc space 
    262144 bytes for mbufs 
    524288 bytes for mbuf clusters 
    ks32c5000_eth_init() 
    found MAC address 00:C0:4E:0B:FF:F9 
    ks5000_ether: installInterrupts() 
    EthInit(00:C0:4E:0B:FF:F9) 
    ks32C5000 eth: 00:C0:4E:0B:FF:F9  Hardware CRC 
    Entering cyg_user_start() function 
    0: Beginning execution 
    2: Beginning execution 
    3: Beginning execution 
    4: Beginning execution 
    5: Beginning execution 
    6: Beginning execution 
    7: Beginning execution 
    8: Beginning execution 
    9: Beginning execution 
    10: Beginning execution 
    11: Beginning execution 
    12: Beginning execution 
    13: Beginning execution 
    14: Beginning execution 
    15: Beginning execution 
    1: Beginning execution 
    Bytes transferred: 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0  -- Idle Loops/Sec: 337263
    Bytes transferred: 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0  -- Idle Loops/Sec: 338232
    Bytes transferred: 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0  -- Idle Loops/Sec: 338233
    Bytes transferred: 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0  -- Idle Loops/Sec: 338232
    Bytes transferred: 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0  -- Idle Loops/Sec: 338234
    Bytes transferred: 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0  -- Idle Loops/Sec: 338234
    Bytes transferred: 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0  -- Idle Loops/Sec: 338229 
Using GDB with the JTAG Interface

The example in Running GDB shows how to use GDB to run a program via the JTAG interface.

The main things to make note of the example are:

  • Use the target rdi e=jeeni command instead of the target remote command. Replace with the device name of the serial port connected to the second diagnostic port (e.g. /dev/ttyS0).

  • To use JTAG debugging, make sure that the shorting jumper is placed on Pins 1 and 2 of the three-pin header on the DeviceMaster board (J1 on 4/8-port boards or J4 on the 16-port board that has one Ethernet port). Location of the jumpers is shown in Using the Diagnostic Serial Port.

    [Note]
    Note

    Contact Technical Support for information about the DeviceMaster 1-port or DeviceMaster 16 or 32-port devices with one Ethernet port..

Using GDB with Diagnostic Port 2

If you do not have a JTAG interface, it is possible to use the GDB stubs via the GDB remote protocol that is implemented by the RedBoot bootloader. Using GDB via Diag Port 2 is similar to using GDB via JTAG, but changes to the GDB initialization file (.gdbinit or gdb.ini) will need to be made. The differences are:

  • Use the target remote <dev> command instead of the target rdi command. Replace <dev> with the device name of the serial port connected to the second diagnostic port (e.g. /dev/ttyS0).

  • Start GDB with the command line flag \tt -b 57600 to specify the proper baud rate.

  • Do not execute the resetcpu or memconfig macros that were shown in the sample .gdbinit file. The GDB stubs in the Bootloader will insure that the processor and memory controller are in the proper states.

  • When starting an eCos program, you must set a breakpoint and stop execution somewhere after the eCos initialization code. The cyg_user_start function is a good place. If you load an eCos program and do a continue without any breakpoints, you will not be able to stop execution of the eCos application. After you have stopped at a breakpoint and then resumed execution you can interrupt the eCos application and return control to the debugger at any time by pressing Control-C, sending GDB a SIGINT signal, or pressing the stop button in Insight.

The easiest way to do this is to add the command tbreak cyg_user_start if 0 to the end of the reload macro (or whatever macro you use to load an eCos application). This will place a temporary breakpoint at the cyg_user_start function, but when that breakpoint is reached, execution will continue immediately because the condition if 0 is not true.

Saving a Program to Flash ROM

Once you have debugged your DeviceMaster application, you may want to save it in the DeviceMaster flash ROM so that it can be automatically executed when the DeviceMaster starts up. If you do this, your application will replace the existing SocketServer application that is present in the DeviceMaster flash ROM when it is shipped from the factory.

[Note]
Note

You can change back to the SocketServer default application if you want to later.

The procedure for downloading a DeviceMaster application and saving it to flash as the default application is shown in Using RedBoot to Update SocketServer.

[Note]
Note

Alternative methods for loading applications is available in Using DeviceMaster Utilities

Default Application

The DeviceMaster version of RedBoot will wait for a configured number of seconds after startup for connections from a host. If no connection from a host is made, the bootloader will look for a file named default in the flash file system. If a file named default exists, it will be loaded and executed. If a host initiates a download or if the dis command is entered during the waiting period, the default program will not be loaded.

Here is an example of the commands used to load a program from a TFTP server and save it in flash as the default application:

RedBoot> fis delete default

Delete image ’default’ - are you sure (y/n)? y
... Erase from 0x05030000-0x050c0000: .........
... Erase from 0x053f0000-0x05400000: .
... Program from 0x007a0000-0x007b0000 at 0x053f0000: .

RedBoot> load -v -h 192.168.1.2 socket.srec

Entry point: 0x00000384, address range: 0x00000000-0x000718a8 

RedBoot> fis create default

... Erase from 0x05030000-0x050b0000: ........
... Program from 0x00000000-0x000718a9 at 0x05030000: ........
... Erase from 0x053f0000-0x05400000: .
... Program from 0x007a0000-0x007b0000 at 0x053f0000: .
RedBoot>

If you wish to permanently disable the default application, use the fis delete command to delete it from the flash file system (example shown in fis delete).

To update the bootloader, load and execute the burn-redboot program that contains code to update the bootloader flash. This can be done by downloading a .bin file using one of the utilities provided with the SDK (PortVision DX, TFTP, the command line download.py utility, or the GUI download utility). It can also be done by downloading a .srec file using RedBoot.

For example:

RedBoot>load -v -h 192.168.4.3 burn-redboot.srec

Entry point: 0x00000000, address range: 0x00000000-0x000228d8/

RedBoot>go

Diag StartupburnId=0089,8897flash_erase_region(05010000,65536)sector
erase 05010000sector erase 05020000flash_program_buf(05010000,000028D8,65536)ROM
= 05000000done -- resetting...
            

At this point the bootloader has been updated, and the board should reset and run the new bootloader

Using the RedBoot Bootloader

DeviceMasters run a bootloader based on RedHat’s RedBoot program. In addition to the DeviceMaster compatible TCP and MAC mode network interfaces RedBoot provides a boot console interface that can be used to perform various functions.

This page provides examples of more commonly used RedBoot commands. Refer to the RedBoot Command Overview or the eCos Reference Manual for additional information about commands.

Board Configuration Commands

These functions are performed via a command-line interface that is accessible via external serial Port 0, the 4-pin debug header (57.6K, 8, none), or by telnet. When connected to the debug header or telnet you should see a RedBoot> prompt.

[Note]
Note

The start-up messages are displayed only on the 4-pin diagnostic head and will not be visible via telnet unless the version command is entered.

The external console port will be disabled on power-up. In order to start console services on that port, the string #!DM must be the first thing received on that port after power-up. When that string has been seen, the port will be enabled and a prompt will be displayed. A password is required for telnet access, but no password is required for serial port access.

Pepperl+Fuchs Comtrol, Inc. DeviceMaster Boot Version 0.01 
RedBoot(tm) debug environment - built 17:28:09, Mar  7 2001 
Platform: Pepperl+Fuchs Comtrol, Inc. DeviceMaster (ARM 7TDMI) 
Portions Copyright (C) 2000, Red Hat, Inc. 
Portions Copyright (C) 2001, Comtrol Corp. 
RAM: 0-7C0000 
Id=0089,8897 
FLASH: 0x05030000 - 0x05400000, 61 blocks of 0x00010000 bytes 
each. 
ks32C5000 eth: 00:C0:4E:0B:FF:FA  Hardware CRC 
IP: 192.168.1.23, Default server: 0.0.0.0 
RedBoot> 

To see a list of available commands, type help followed by a carriage-return. Optionally, you can refer to the RedBoot Procedures section in the DeviceMaster Installation and Configuration Guide.

RedBoot>  help

The board configuration commands are auth, boardrev, ip, mac, model, password, telnet, and timeout. Typing the command displays the current value of that configuration item. The command with a parameter will set the configuration item value.

[Note]
Note

For security reasons, the password command will not display the current password. If the password command is used with no parameters, the password will be set to the empty string.

Flash Image System

RedBoot implements a rudimentary file system that allows program and data files to be stored in flash. The are various fis commands that can be used to manipulate this file system. Typing fis followed by a carriage-return will display a list of sub-commands:

fis [create [-b base_address] [-l addr] [-s] [-f] [-e] [-r]] [delete] free] [init] [list] [load [-b] [-c] name]

RedBoot> fis
*** invalid ‘fis’ command: too few arguments 
Usage:                                      
fis create -b  -l [-s] [-f] [-e] [-r]
fis free                             
fis init [-f] 
fis list [-c] 
fis load [-b] [-c] name
fis create

The fis create command is used to store a region of RAM as a file in flash ROM. The basic form of the command is:

 RedBoot> fis create -b 0 -l 0x10000 foobar

... Erase from 0x05030000-0x05040000: . 
... Program from 0x00000000-0x00010000 at 0x05030000: . 
... Erase from 0x053f0000-0x05400000: .                
... Program from 0x007a0000-0x007b0000 at 0x053f0000: . 

fis list

RedBoot>  fis list

Name              FLASH addr   Mem addr    Length      Entry
point 
FIS directory     0x053F0000   0x053F0000  0x00010000  0x00000000 
foobar            0x05030000   0x00000000  0x00010000  0x00000000 
RedBoot> 

It is also possible to specify a program entry point with the -e option and a specific location for the file in flash ROM with the -f option. If no address or length is specified, it will use the address and length of the S-Record file most recently loaded to RAM via serial port or Ethernet..

fis delete

The fis delete command is used to delete a file from flash:

RedBoot>  fis delete default

Delete image ‘default’ - are you sure (y/n)? y

... Erase from 0x05030000-0x050b0000: ........ 
... Erase from 0x053f0000-0x05400000: .       
... Program from 0x007a0000-0x007b0000 at 0x053f0000: . 
    
Length Entry point 0x053F0000 0x00010000 0x00000000

RedBoot>  fis list

 Name              FLASH addr   Mem addr    Length      Entry
point 
FIS directory     0x053F0000   0x053F0000  0x00010000  0x00000000 
RedBoot> 
fis list

The fis list command displays a directory of the files currently stored in flash ROM:

RedBoot>  fis list

 Name               FLASH addr   Mem addr    Length      Entry point
FIS directory     0x053F0000   0x053F0000  0x00010000  0x00000000
default               0x05030000   0x00000000  0x00080000  0x00000384
RedBoot>

The FIS directory entry will always be there and is the file in which flash ROM bookkeeping information is stored. The default file is the program that will be run by RedBoot on startup. This is described further in Default Application. The list, delete, and create commands are the most frequently used.

fis load

The fis load command loads a file from flash ROM into RAM:

RedBoot>  fis load foobar

Executing a Program

The go command is used to execute a program. If no starting address is provided as a parameter to the go command, the entry address of the last file loaded into RAM will be used.

go [[-w <timeout>] [entry]]

load [[-r] ] [[-h ip] ] [filename]

RedBoot> load -r -h 10.0.0.2 socket.bin
Defaulting to entry point of 0x00000000.
Raw load done: 542101 bytes read 
Address range: 00000000-00084594, Entry point: 00000000, 
RedBoot> go
ARM DeviceMaster HAL (no virtual vectors) 
AIOPIC serial driver: 16 channels 
[...]   

If you wish to specify an entry point, you may do so:

RedBoot>  load -r -h 10.0.0.2 socket.bin
Defaulting to entry point of 0x00000000. 
Raw load done: 542101 bytes read 
Address range: 00000000-00084594, Entry point: 00000000,
RedBoot>  go 0x384
ARM DeviceMaster HAL (no virtual vectors) 
AIOPIC serial driver: 16 channels 
[...]
[Note]
Note

eCos application have two entry points: 0 and 0x384. The instruction at address 0 is a jump to 0x384.

HTTP Authentication

Controls the type of authentication required for HTTP access.

auth { [noaccess] [none] [basic] [md5] [invalid] }

HTTP Authentication TypesDescription
noaccess No HTTP access will be allowed; access forbidden error will be returned.
none No authentication will be required.
basic Plain text password authentication required
md5 MD5 encrypted password authentication required.
invalid No HTTP access will be allowed; invalid URL error will be returned.
RedBoot>  auth 
Auth: none
RedBoot>  auth basic
Auth: basic
RedBoot

The value of this setting is not used by RedBoot since it does not contain a web server. This setting is merely saved in I2C EPROM as a service to applications.

Loading a File

load [{-r} ] [{-v} ] [{-h <host>}] [{-m {TFTP | xyzmodem}] [{-b <base_addr>} <file_name>]

It is possible to load a program or data file into RAM from three sources: serial port (the 4-pin diagnostic header or external Port 0), Ethernet (from a TFTP server or via TCP), or from flash ROM on the DeviceMaster board. Loading from flash ROM is described in fis load. Loading from serial port or Ethernet is done using the load command. Files loaded with the load command default to Motorola S-Record format (which must end with a single “Entry-Point�? record).

It is possible to load a binary file with the load command by using the -r and -b options.

Loading via Ethernet TFTP

Loading a file from a TFTP server is done by using the -h option to load:

RedBoot>  load -v -h 192.168.1.2 socket.srec 

Entry point: 0x00000384, address range: 0x00000000-0x000718a8 
RedBoot> 

The -v option will cause a spinning status indicator to be displayed as the file is loaded. Do not use the -v option when connected via telnet. If you are loading a raw binary file, use the -r option.

Loading via Ethernet TCP

Loading a file via TCP can be done by connecting to the telnet server (TCP Port 23), logging in, and issuing a load -m d command. The telnet server will then expect to read an S-record file as input. Each line read will be acknowledged with a single line feed character. When the last line in the S-record file (which must be an Entry-Point record) has been processed, a load summary prints

Loading via Serial Port

Loading An S-record file via a serial port is done with a load command specify either xmodem or ymodem protocol.

RedBoot>  Load -m ymodem 

Start the ymodem transfer program.

Entry Point: 0x00000384, Address Range: 0x00000000-0x000718a8 
    RedBoot> 

It is also possible to load a binary file via x-modem. binary download will be approximately 2-3 times faster except for sparse files. the entry point for a binary file will be the base address specified in the load command (or a default of 0 if no entry point is specified). For DeviceMaster eCos executables, the base address should be normally 0:

RedBoot>  Load -b 0 -r -m X

Start X-modem Download
Crc Mode, 4085(Soh)/0(Stx)/0(Can) Packets, 2 Retries 
    RedBoot> 

RedBoot Command Overview

The DeviceMaster boards run a bootloader based on RedHat’s RedBoot program. In addition to the DeviceMaster compatible TCP and MAC mode network interfaces RedBoot provides a boot console interface that can be used to perform various functions:

RedBoot CommandsDescription
Autoload time-outSets the number of seconds after network initialization that the bootloader will wait before starting the default application program from flash ROM. A time-out value of 0 will disable auto-loading of the default application. The maximum value is 255 seconds.

timeout [{seconds}]

RedBoot> timeout
Timeout 9 seconds
RedBoot> timeout 5
Timeout 5 seconds
RedBoot> 
Board revision Sets or displays the board revision. Do not change the board revision of a DeviceMaster.
boardrev
RedBoot> boardrev 
BoardRev 7
Cache The cache command is ignored in the DeviceMaster Bootloader, the Bootloader is always cache disabled.

cache [[ON | ] [off]]

Chassis type The chassis command displays the hardware chassis type (DeviceMaster PRO, DeviceMaster RTS or DeviceMaster UP)
Checksum The cksum command computes and displays the POSIX 32-bit CRC checksum of the specified region.
Disable Executing the disable command will prevent the Bootloader from loading the default application after the initial timeout period (which is set using the timeout command).

disable

dump The dump command is used to display the contents of memory. The starting address of the region to be displayed is specified with the -b option (required). The length of the region to be displayed is specified with the -l option (defaults to 32-bytes).

dump [-b <location>] [-l <length>]

RedBoot> dump -b 0x10 -l 64
0x00000010: E59F F018 0000 0000  E59F F018 E59F F018   
    |................|
0x00000020: FFFF FFFF 007C 058C  007C 0610 007C 0648   
    |.....|...|...|.H|
0x00000030: 007C 06C4 FFFF FFFF  007C 07AC 007C 0794   
    |.|.......|...|..|   
Flash Image System (fis) RedBoot implements a rudimentary file system that allows program and data files to be stored in flash. The are various fis commands that can be used to manipulate this file system. Typing fis followed by a carriage-return will display a list of sub-commands:

fis [create [-b base_address] [-l addr] [-s] [-f] [-e] [-r]] [delete] free] [init] [list] [load [-b] [-c] name]

RedBoot> fis
*** invalid ‘fis’ command: too few arguments 
Usage:                                      
fis create -b  -l [-s] [-f] [-e] [-r]
fis free                             
fis init [-f] 
fis list [-c] 
fis load [-b] [-c] name

See Using the RedBoot Bootloader and Downloading Programs for fis procedures.

Executing a program The go command is used to execute a program. If no starting address is provided as a parameter to the go command, the entry address of the last file loaded into RAM will be used.

It is possible to load a program or data file into RAM from three sources: serial port (the 4-pin diagnostic header or external Port 0), Ethernet (from a TFTP server or via TCP), or from flash ROM on the DeviceMaster board.

Help The help command displays a list of available commands and a short usage specification for each command.
History The history command displays the command history buffer.
HTTP authentication method Controls the type of authentication required for HTTP access.

auth { [noaccess] [none] [basic] [md5] [invalid] }

IP configuration Setting the IP address to 255.255.255.255 disables IP networking. Setting the IP address to 0.0.0.0 causes the bootloader to use BOOTP to request an IP address.

ip [{ip_addr] [ip_mask] [ip_gateway}] 

RedBoot>  ip
IP Config: IpAddr=192.168.1.23 IpMask=255.255.255.0 IpGate=192.168.1.1
RedBoot>  ip 10.23.4.12 255.255.0.0 10.23.1.1
IP Config: IpAddr=10.23.4.12 IpMask=255.255.0.0 IpGate=10.23.1.1

If only one parameter is provided to the IP command, the IP address value will be changed and the mask and gateway will be unaffected. Changes to IP configuration will take effect after reset.

Loading a fileThe load command loads files into the DeviceMaster.

load [{-r} ] [{-v} ] [{-h <host>}] [{-m {TFTP | xyzmodem}] [{-b <base_addr>} <file_name>]

It is possible to load a program or data file into RAM from three sources: serial port (the 4-pin diagnostic header or external Port 0), Ethernet (from a TFTP server or via TCP), or from flash ROM on the DeviceMaster board. Loading from flash ROM is described in fis load. Loading from serial port or Ethernet is done using the load command. Files loaded with the load command default to Motorola S-Record format (which must end with a single “Entry-Point�? record).

It is possible to load a binary file with the load command by using the -r and -b options.

Loopback test The loop command runs a loopback test using an external RS232/422 loopback plug or (if supported) using the internal loopback feature of a single port.
MAC address Sets or displays the MAC (Ethernet) address. Do not change the MAC address of a DeviceMaster.

mac

RedBoot> mac
MAC: 00 C0 4E 0B FF FA
RedBoot> 
Memory compare The mcmp command compares two blocks of memory.
Memory copy The mcopy command copies a block of memory to a destination address.
Memory display The x command displays (examines) memory contents in hex.
Memory fill The mfill command fills a region of memory with a specified value.
Model number The model number is used by applications to determine what hardware features are available on the board. Do not change the model number of a DeviceMaster.

model

RedBoot> model
Model 5002120
RedBoot>
Password Changes the DeviceMaster password used to authenticate telnet and HTTP access. Unlink other commands, the password command will not display the current value of the password. The password command always sets the value of the password. The password length is limited to 15 characters.

password [{password}] 

RedBoot> password
Password ’’
RedBoot>  password FooBar1 
Password ’FooBar1’
RedBoot>
Ping The ping command sends ICMP ping requests to the specified address and displays the results.
Reset The reset command uses the watchdog timer hardware to perform a hardware reset of the DeviceMaster.

reset

Secure config enable The secureconf command sets/shows the state of the secure configuration flag.

If enabled, configuration changes will only be allowed via a secure connection (https, ssl, ssh).

Secure data enable The securedata command sets/shows the secure data enable flag.

If enabled, serial port data will only be transferred via secure connection (ssl).

SNMP enable The snmp command enables/disables the SNMP agent in the standard SocketServer and NS-Link applications.
Telnet enable/disable Allows the user to enable or disable telnet access to the DeviceMaster.

telnet [[disable | enable]] 

Accepted values are enable and disable:

RedBoot>  telnet
Telnet enable
RedBoot>  telnet disable
Telnet disable
Telnet timeout The teltimeout command sets/shows the idle timeout setting for telnet connections.
Terse mode In order to provide a console interface more amenable to programmatic control, the bootloader may be put into terse mode.

terse 

The significant features of terse mode are:

  • No prompt is issued.

  • Command strings are not echoed

  • All responses consist of a single line. If the command was successful, the response string begins with “+ �?. If the command failed, the response string begins with “- �?.

Pepperl+Fuchs Comtrol, Inc. recommends that supervisory programs written to the interface with the DeviceMaster bootloader ignore lines that do not begin with “+ �? or “- �? in case bugs in some commands improperly display diagnostic information.

Test RS-485 Ports The t485 command runs a port-to-port test of two RS-485 ports.
Version The version command displays the bootloader version and build date:
RedBoot> version
Comtrol DeviceMaster Boot Version 1.11
RedBoot(tm) debug environment - built 11:00:47, Feb 25 2002
Platform: Comtrol DeviceMaster (ARM 7TDMI) 
Portions Copyright (C) 2000, Red Hat, Inc.
Portions Copyright (C) 2001, Comtrol Corp.

Documentation

The following documentation is available for the SDK:

Cygwin Documentation

DocumentFilesDescription

Cygwin User's Guide

Revision 20.1.0; 1999-02-08

Open from CD

http://www.cygwin.com

Download

The User Guide provides overview and installation information. It also includes information about using and programming Cygwin.

DeviceMaster Documentation for the SDK

DocumentFilesDescription

DeviceMaster Ethernet Device Driver

Rev B

Open from CD

Download

This document describes the DeviceMaster Ethernet device driver for eCos. The driver supports the Ethernet controller built in to the Samsung KS32C5000A and S3C4510 ARM micro-controllers.

DeviceMaster SocketServer Extension Guide

Rev B

Open from CD

Download

This document describes information about how to add functionality to the sample SocketServer.

DeviceMaster Nserial Device Driver

Rev B

Open from CD

Download

This document describes the nserial device driver for eCos. The driver provides a high-level API that user applications can use to access the DeviceMaster serial ports.

DeviceMaster Installation and Configuration Guide

Rev F

Open from CD

Download

The DeviceMaster Installation and Configuration guide contains installation and configuration procedures.

eCos Documentation

DocumentFilesDescription
eCos Component Writer’s Guide2001

Letter size version

Open from CD

A4 size version

Open from CD

Download

This guide discusses eCos architecture.

You can download this document from the eCos web site.

eCos Reference Manual

1998-2003 Ed.

Letter size version

Open from CD

A4 size version

Open from CD

Download

The eCos Reference Manual includes information about Redboot.

RedBoot can be used to configure or update the DeviceMaster in the event that you cannot use PortVision DX. The DeviceMaster Installation and Configuration Guide provide basic information about using RedBoot with the DeviceMaster.

You can download this document from the eCos web site.

eCos User Guide

2003

Letter size version

Open from CD

A4 size version

Open from CD

Download

The eCos User Guide contains installation, programming, and configuration information.

You can download this document from the eCos web site.

GNU Documentation

DocumentFilesDescription
GNU: Using as

v2.19

Open from CD

Download

This discusses the GNU assembler.

GNU: bash

http://oreilly.com

Search for bash documentation

Access bash documentation from GNU.

You can also locate information about bash from these sites:

GNU: libbfd; The Binary File Descriptor Library

1st Edition

Open from CD

Download

This discusses the GNU binary file descriptor library (libbfd).

GNU: Binary Utilities

v2.19: October 2008

Open from CD

Download

This discusses GNU binary utilities.

GNU: The C Preprocessor

April 2001

Open from CD

Download

This discusses the C preprocessor.

GNU: Debugging with gdb

Ninth Edition

Open from CD

Download

This discusses debugging with gdb.

GNU: Using the GNU Compiler Collection

23 May 2004

Open from CD

Download

This discusses using the GNU compiler collection.

The GNU linker

v2.19

Open from CD

Download

This discusses the invocation, linker scripts, .machine dependent features, and bfd.

GNU:make

Access make documentation from GNU.

You can locate information about make from the GNU site.
GNU Coding Standards

July 22, 2007

Open from CD

Download

This discusses the GNU coding standards.

GNU: tar

Access make documentation from GNU.

You can locate information about make from the GNU site.

Troubleshooting

Review the following information before calling Technical Support because they will request that you perform many of the procedures or verifications before they will be able to help you diagnose a problem.

The following checklist may help you diagnose your problem:

  • Verify that you are using the correct types of cables on the correct connectors and that all cables are connected securely. See the DeviceMaster Installation and Configuration Guide for up-to-date cabling information.

    [Note]
    Note

    Most customer problems reported to Pepperl+Fuchs Comtrol, Inc. Technical Support are eventually traced to cabling or network problems.

  • Make sure that you have updated the DeviceMaster with the latest Bootloader version.

  • Make sure that the serial device settings have been selected in the NS-Link driver, and if necessary, the DeviceMaster Server Configuration web page to match the serial device that you are connecting to the port.

  • If you have a spare DeviceMaster try replacing the DeviceMaster.

For additional troubleshooting, you can refer to the Pepperl+Fuchs Comtrol, Inc. forum or contact Pepperl+Fuchs Comtrol, Inc. Technical Support . You may want to refer to the SDK Customer Support Policy before calling Technical Support for assistance beyond SDK installation.

SDK Customer Support Policy

Comtrol will provide free of charge, support on the installation of the DeviceMaster Software Developer kit.

Support beyond normal installation is provided on a per hour fee-for-services basis.

The fee for support is $100 per hour with a $200 minimum per case.

Customers wishing support on a fee-for-services basis must be pre-approved by Comtrol prior to receiving support. Please contact Comtrol Customer Service for more information regarding fee based support.

Contact Information

Download Page

Make sure that you installed the latest software. If you have not done so, check the Pepperl+Fuchs Comtrol, Inc. web site.

Customer Forum

If you are connected to the internet, you can view any available FAQs for your product in the support forum.

Online Support

You can access our online support instead of calling Technical Support. If you have not used this page before, you will need to register using your email address. Pepperl+Fuchs Comtrol, Inc. will email you a response within 24 hours (Monday through Friday).

Knowledge Center

If you are connected to the internet, you can view the Pepperl+Fuchs Comtrol, Inc. Knowledge Center.

Phone Support

You can contact Pepperl+Fuchs Comtrol, Inc. by calling 763-957-6000 (8AM to 6PM CST/USA).

Warranty Registration

Register your product online. You will need the model number, serial number, PO number, and purchase date of the product to complete the registration.

RMA Information

Access the RMA web page where you can locate a phone number to call, submit a request, or email a request to return a product. It also provides the procedures and address information.

Pepperl+Fuchs Comtrol, Inc. Software Packages

This discussion explains how to manipulate a device driver package (compressed driver files) downloaded from the Pepperl+Fuchs Comtrol, Inc. FTP/Web site or from the CD to your system for installation.

[Note]
Note

If the file extension is .bin (firmware), the file is not compressed.

The file name of the driver package is called pkgname in the following procedures. Use the appropriate procedure for your operating system:

  • Linux with a .tar.gz extension

  • Windows with a .exe, .msi, or .tar.gz extension

Linux

Use the following procedure to unpackage compressed tar or gnuzip files in Linux.

  1. Download pkgname or locate the pkgname on the distribution media and copy it to /usr/src directory. If downloaded to a DOS system, copy it to a DOS formatted diskette, using one of the following methods:

    • Use the mount command to mount a diskette in order to copy pkgname to the /usr/src directory. For example: mkdir /dos

      mount -t msdos /dev/fd0 /dos
      cp /dos/pkgname pkgname.tar.gz/usr/src/pkgname.tar.gz
      umount /dos
    • Use the mcopy command to copy pkgname to the /usr/src directory on your linux system. For example: mcopy a:pkgname/usr/src/pkgname.tar.gz

  2. In the /usr/src directory, use the tar command to uncompress and extract the driver files.

    tar xzvf pkgname.tar.gz 

    This creates a subdirectory (i.e. Pepperl+Fuchs Comtrol, Inc.) that contains the device driver and associated files.

For installation instructions, see the driver installation documentation for the driver.

Windows

Use the following procedure to extract driver files with an .EXE or .MSI extension.

  1. Download the .exe or .msi file or locate the pkgname on the distribution media and copy it to a temporary directory on your system. For example:

    c:\Pepperl+Fuchs Comtrol, Inc. 
  2. In the Windows Explorer, double-click on the pkgname.exe and follow the Extract or Installation wizard.

[Note]
Note

When unpacking .tar.gz files, disable smart or automatic handling of line endings for text files. Otherwise, WinZip will cause breakage by adding carriage returns to line endings.

Software Licenses

The software licences are provided for your reference. You may want to review the latest licence at the appropriate site discussed in the software licence. The DeviceMaster software development kit provides software licenses for:

Cygwin API Licensing Terms

Most of the tools are covered by the GNU GPL, some are public domain, and others have a X11 style copyright. To cover the GNU GPL requirements, the basic rule is if you give out any binaries, you must also make the source available. For the full details, be sure to read the text of the GNU General Public License (GPL).

This is a copy of CYGWIN_LICENSE from the cygwin sources.


 =======================================================================
 This program is free software; you can redistribute
 it and/or modify it under the terms of the GNU General Public License
 (GPL) as published by the Free Software Foundation; either version
 2 of the License, or (at your option) any later version. 
 This program
 is distributed in the hope that it will be useful, but WITHOUT ANY
 WARRANTY; without even the implied warranty of MERCHANTABILITY or
 FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
 for more details. 
 You should have received a copy of the GNU General Public
 License along with this program; if not, write to the Free Software
 Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307,
 USA. 
 =======================================================================
 *** NOTE *** 
 In accordance with section 10 of the GPL, Red
 Hat permits programs whose sources are distributed under a license that
 complies with the Open Source definition to be linked with libcygwin.a
 without libcygwin.a itself causing the resulting program to be covered
 by the GNU GPL. 
 This means that you can port an Open Source(tm)
 application to cygwin, and distribute that executable as if it didn't
 include a copy of libcygwin.a linked into it. Note that this does
 not apply to the cygwin DLL itself. If you distribute a (possibly
 modified) version of the DLL you must adhere to the terms of the
 GPL, i.e. you must provide sources for the cygwin DLL. 
 See for the precise Open Source Definition referenced above. 
 Red Hat
 sells a special Cygwin License for customers who are unable to provide
 their application in open source code form. For more information,call
 866-2REDHAT ext. 3007 
            

eCos License

This the text of the current license for eCos at the time this file was created.

Refer to http://ecos.sourceware.org/license-overview.html for the latest licensing information.


This file is part of eCos, the Embedded Configurable Operating
System. Copyright (C) 1998, 1999, 2000, 2001, 2002, 2003, 2004,
2005, 2006, 2007, 2008, 2009 Free Software Foundation, Inc.

eCos is free software; you can redistribute it and/or modify it
under the terms of the GNU General Public License as published
by the Free Software Foundation; either version 2 or (at your
option) any later version.

eCos is distributed in the hope that it will be useful, but
WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.

You should have received a copy of the GNU General Public
License along with eCos; if not, write to the Free Software
Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
02110-1301, USA.

As a special exception, if other files instantiate templates or
use macros or inline functions from this file, or you compile
this file and link it with other works to produce a work based
on this file, this file does not by itself cause the resulting
work to be covered by the GNU General Public License. However
the source code for this file must still be made available in
accordance with section (3) of the GNU General Public License
v2.

This exception does not invalidate any other reasons why a work
based on this file might be covered by the GNU General Public
License. 

The GNU General public license v2 which is referenced by the 
above eCos license is shown below (downloaded from
http://www.gnu.org/licenses/old-licenses/gpl-2.0.txt):

 GNU GENERAL PUBLIC LICENSE
 Version 2, June 1991

 Copyright (C) 1989, 1991 Free Software Foundation, Inc.,
 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
 Everyone is permitted to copy and distribute verbatim copies
 of this license document, but changing it is not allowed.

 Preamble

  The licenses for most software are designed to take away your
freedom to share and change it.  By contrast, the GNU General Public
License is intended to guarantee your freedom to share and change free
software--to make sure the software is free for all its users.  This
General Public License applies to most of the Free Software
Foundation's software and to any other program whose authors commit to
using it.  (Some other Free Software Foundation software is covered by
the GNU Lesser General Public License instead.)  You can apply it to
your programs, too.

  When we speak of free software, we are referring to freedom, not
price.  Our General Public Licenses are designed to make sure that you
have the freedom to distribute copies of free software (and charge for
this service if you wish), that you receive source code or can get it
if you want it, that you can change the software or use pieces of it
in new free programs; and that you know you can do these things.

  To protect your rights, we need to make restrictions that forbid
anyone to deny you these rights or to ask you to surrender the rights.
These restrictions translate to certain responsibilities for you if you
distribute copies of the software, or if you modify it.

  For example, if you distribute copies of such a program, whether
gratis or for a fee, you must give the recipients all the rights that
you have.  You must make sure that they, too, receive or can get the
source code.  And you must show them these terms so they know their
rights.

  We protect your rights with two steps: (1) copyright the software, and
(2) offer you this license which gives you legal permission to copy,
distribute and/or modify the software.

  Also, for each author's protection and ours, we want to make certain
that everyone understands that there is no warranty for this free
software.  If the software is modified by someone else and passed on, we
want its recipients to know that what they have is not the original, so
that any problems introduced by others will not reflect on the original
authors' reputations.

  Finally, any free program is threatened constantly by software
patents.  We wish to avoid the danger that redistributors of a free
program will individually obtain patent licenses, in effect making the
program proprietary.  To prevent this, we have made it clear that any
patent must be licensed for everyone's free use or not licensed at all.

  The precise terms and conditions for copying, distribution and
modification follow.

 GNU GENERAL PUBLIC LICENSE
TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION

  0. This License applies to any program or other work which contains
a notice placed by the copyright holder saying it may be distributed
under the terms of this General Public License.  The "Program", below,
refers to any such program or work, and a "work based on the Program"
means either the Program or any derivative work under copyright law:
that is to say, a work containing the Program or a portion of it,
either verbatim or with modifications and/or translated into another
language.  (Hereinafter, translation is included without limitation in
the term "modification".)  Each licensee is addressed as "you".

Activities other than copying, distribution and modification are not
covered by this License; they are outside its scope.  The act of
running the Program is not restricted, and the output from the Program
is covered only if its contents constitute a work based on the
Program (independent of having been made by running the Program).
Whether that is true depends on what the Program does.

  1. You may copy and distribute verbatim copies of the Program's
source code as you receive it, in any medium, provided that you
conspicuously and appropriately publish on each copy an appropriate
copyright notice and disclaimer of warranty; keep intact all the
notices that refer to this License and to the absence of any warranty;
and give any other recipients of the Program a copy of this License
along with the Program.

You may charge a fee for the physical act of transferring a copy, and
you may at your option offer warranty protection in exchange for a fee.

  2. You may modify your copy or copies of the Program or any portion
of it, thus forming a work based on the Program, and copy and
distribute such modifications or work under the terms of Section 1
above, provided that you also meet all of these conditions:

 a) You must cause the modified files to carry prominent notices
 stating that you changed the files and the date of any change.

 b) You must cause any work that you distribute or publish, that in
 whole or in part contains or is derived from the Program or any
 part thereof, to be licensed as a whole at no charge to all third
 parties under the terms of this License.

 c) If the modified program normally reads commands interactively
 when run, you must cause it, when started running for such
 interactive use in the most ordinary way, to print or display an
 announcement including an appropriate copyright notice and a
 notice that there is no warranty (or else, saying that you provide
 a warranty) and that users may redistribute the program under
 these conditions, and telling the user how to view a copy of this
 License.  (Exception: if the Program itself is interactive but
 does not normally print such an announcement, your work based on
 the Program is not required to print an announcement.)

These requirements apply to the modified work as a whole.  If
identifiable sections of that work are not derived from the Program,
and can be reasonably considered independent and separate works in
themselves, then this License, and its terms, do not apply to those
sections when you distribute them as separate works.  But when you
distribute the same sections as part of a whole which is a work based
on the Program, the distribution of the whole must be on the terms of
this License, whose permissions for other licensees extend to the
entire whole, and thus to each and every part regardless of who wrote it.

Thus, it is not the intent of this section to claim rights or contest
your rights to work written entirely by you; rather, the intent is to
exercise the right to control the distribution of derivative or
collective works based on the Program.

In addition, mere aggregation of another work not based on the Program
with the Program (or with a work based on the Program) on a volume of
a storage or distribution medium does not bring the other work under
the scope of this License.

  3. You may copy and distribute the Program (or a work based on it,
under Section 2) in object code or executable form under the terms of
Sections 1 and 2 above provided that you also do one of the following:

 a) Accompany it with the complete corresponding machine-readable
 source code, which must be distributed under the terms of Sections
 1 and 2 above on a medium customarily used for software interchange; or,

 b) Accompany it with a written offer, valid for at least three
 years, to give any third party, for a charge no more than your
 cost of physically performing source distribution, a complete
 machine-readable copy of the corresponding source code, to be
 distributed under the terms of Sections 1 and 2 above on a medium
 customarily used for software interchange; or,

 c) Accompany it with the information you received as to the offer
 to distribute corresponding source code.  (This alternative is
 allowed only for noncommercial distribution and only if you
 received the program in object code or executable form with such
 an offer, in accord with Subsection b above.)

The source code for a work means the preferred form of the work for
making modifications to it.  For an executable work, complete source
code means all the source code for all modules it contains, plus any
associated interface definition files, plus the scripts used to
control compilation and installation of the executable.  However, as a
special exception, the source code distributed need not include
anything that is normally distributed (in either source or binary
form) with the major components (compiler, kernel, and so on) of the
operating system on which the executable runs, unless that component
itself accompanies the executable.

If distribution of executable or object code is made by offering
access to copy from a designated place, then offering equivalent
access to copy the source code from the same place counts as
distribution of the source code, even though third parties are not
compelled to copy the source along with the object code.

  4. You may not copy, modify, sublicense, or distribute the Program
except as expressly provided under this License.  Any attempt
otherwise to copy, modify, sublicense or distribute the Program is
void, and will automatically terminate your rights under this License.
However, parties who have received copies, or rights, from you under
this License will not have their licenses terminated so long as such
parties remain in full compliance.

  5. You are not required to accept this License, since you have not
signed it.  However, nothing else grants you permission to modify or
distribute the Program or its derivative works.  These actions are
prohibited by law if you do not accept this License.  Therefore, by
modifying or distributing the Program (or any work based on the
Program), you indicate your acceptance of this License to do so, and
all its terms and conditions for copying, distributing or modifying
the Program or works based on it.

  6. Each time you redistribute the Program (or any work based on the
Program), the recipient automatically receives a license from the
original licensor to copy, distribute or modify the Program subject to
these terms and conditions.  You may not impose any further
restrictions on the recipients' exercise of the rights granted herein.
You are not responsible for enforcing compliance by third parties to
this License.

  7. If, as a consequence of a court judgment or allegation of patent
infringement or for any other reason (not limited to patent issues),
conditions are imposed on you (whether by court order, agreement or
otherwise) that contradict the conditions of this License, they do not
excuse you from the conditions of this License.  If you cannot
distribute so as to satisfy simultaneously your obligations under this
License and any other pertinent obligations, then as a consequence you
may not distribute the Program at all.  For example, if a patent
license would not permit royalty-free redistribution of the Program by
all those who receive copies directly or indirectly through you, then
the only way you could satisfy both it and this License would be to
refrain entirely from distribution of the Program.

If any portion of this section is held invalid or unenforceable under
any particular circumstance, the balance of the section is intended to
apply and the section as a whole is intended to apply in other
circumstances.

It is not the purpose of this section to induce you to infringe any
patents or other property right claims or to contest validity of any
such claims; this section has the sole purpose of protecting the
integrity of the free software distribution system, which is
implemented by public license practices.  Many people have made
generous contributions to the wide range of software distributed
through that system in reliance on consistent application of that
system; it is up to the author/donor to decide if he or she is willing
to distribute software through any other system and a licensee cannot
impose that choice.

This section is intended to make thoroughly clear what is believed to
be a consequence of the rest of this License.

  8. If the distribution and/or use of the Program is restricted in
certain countries either by patents or by copyrighted interfaces, the
original copyright holder who places the Program under this License
may add an explicit geographical distribution limitation excluding
those countries, so that distribution is permitted only in or among
countries not thus excluded.  In such case, this License incorporates
the limitation as if written in the body of this License.

  9. The Free Software Foundation may publish revised and/or new versions
of the General Public License from time to time.  Such new versions will
be similar in spirit to the present version, but may differ in detail to
address new problems or concerns.

Each version is given a distinguishing version number.  If the Program
specifies a version number of this License which applies to it and "any
later version", you have the option of following the terms and conditions
either of that version or of any later version published by the Free
Software Foundation.  If the Program does not specify a version number of
this License, you may choose any version ever published by the Free Software
Foundation.

  10. If you wish to incorporate parts of the Program into other free
programs whose distribution conditions are different, write to the author
to ask for permission.  For software which is copyrighted by the Free
Software Foundation, write to the Free Software Foundation; we sometimes
make exceptions for this.  Our decision will be guided by the two goals
of preserving the free status of all derivatives of our free software and
of promoting the sharing and reuse of software generally.

 NO WARRANTY

  11. BECAUSE THE PROGRAM IS LICENSED FREE OF CHARGE, THERE IS NO WARRANTY
FOR THE PROGRAM, TO THE EXTENT PERMITTED BY APPLICABLE LAW.  EXCEPT WHEN
OTHERWISE STATED IN WRITING THE COPYRIGHT HOLDERS AND/OR OTHER PARTIES
PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESSED
OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.  THE ENTIRE RISK AS
TO THE QUALITY AND PERFORMANCE OF THE PROGRAM IS WITH YOU.  SHOULD THE
PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF ALL NECESSARY SERVICING,
REPAIR OR CORRECTION.

  12. IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING
WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MAY MODIFY AND/OR
REDISTRIBUTE THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES,
INCLUDING ANY GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING
OUT OF THE USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED
TO LOSS OF DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY
YOU OR THIRD PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER
PROGRAMS), EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE
POSSIBILITY OF SUCH DAMAGES.

  END OF TERMS AND CONDITIONS

 How to Apply These Terms to Your New Programs

  If you develop a new program, and you want it to be of the greatest
possible use to the public, the best way to achieve this is to make it
free software which everyone can redistribute and change under these terms.

  To do so, attach the following notices to the program.  It is safest
to attach them to the start of each source file to most effectively
convey the exclusion of warranty; and each file should have at least
the "copyright" line and a pointer to where the full notice is found.

 <one line to give the program's name and a brief idea of what it does.>
 Copyright (C) <year>  <name of author>

 This program is free software; you can redistribute it and/or modify
 it under the terms of the GNU General Public License as published by
 the Free Software Foundation; either version 2 of the License, or
 (at your option) any later version.

 This program is distributed in the hope that it will be useful,
 but WITHOUT ANY WARRANTY; without even the implied warranty of
 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 GNU General Public License for more details.

 You should have received a copy of the GNU General Public License along
 with this program; if not, write to the Free Software Foundation, Inc.,
 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.

Also add information on how to contact you by electronic and paper mail.

If the program is interactive, make it output a short notice like this
when it starts in an interactive mode:

 Gnomovision version 69, Copyright (C) year name of author
 Gnomovision comes with ABSOLUTELY NO WARRANTY; for details type `show w'.
 This is free software, and you are welcome to redistribute it
 under certain conditions; type `show c' for details.

The hypothetical commands `show w' and `show c' should show the appropriate
parts of the General Public License.  Of course, the commands you use may
be called something other than `show w' and `show c'; they could even be
mouse-clicks or menu items--whatever suits your program.

You should also get your employer (if you work as a programmer) or your
school, if any, to sign a "copyright disclaimer" for the program, if
necessary.  Here is a sample; alter the names:

  Yoyodyne, Inc., hereby disclaims all copyright interest in the program
  `Gnomovision' (which makes passes at compilers) written by James Hacker.

  <signature of Ty Coon>, 1 April 1989
  Ty Coon, President of Vice

This General Public License does not permit incorporating your program into
proprietary programs.  If your program is a subroutine library, you may
consider it more useful to permit linking proprietary applications with the
library.  If this is what you want to do, use the GNU Lesser General
Public License instead of this License.

GNU License

The latest license can be located at: http://www.gnu.org/licenses/licenses.html.


  Version 2, June 1991
  
  Copyright © 1989, 1991 Free Software Foundation, Inc. 
  
  59 Temple
  Place, Suite 330
  Boston, MA  02111-1307
  USA
  
  
  
  Everyone is permitted to copy and distribute verbatim copies of this license document, but changing it is not allowed. 
  
  Version 2, June 1991
   


  Version 2, June 1991 

Copyright (C) 1989, 1991 Free Software Foundation, Inc.  
51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA

Everyone is permitted to copy and distribute verbatim copies
of this license document, but changing it is not allowed.

Preamble
The licenses for most software are designed to take away your freedom to
share and change it. By contrast, the GNU General Public License is intended
to guarantee your freedom to share and change free software--to make sure
the software is free for all its users. This General Public License applies
to most of the Free Software Foundation's software and to any other program
whose authors commit to using it. (Some other Free Software Foundation software
is covered by the GNU Lesser General Public License instead.) You can apply
it to your programs, too. 

When we speak of free software, we are referring to freedom, not price.
Our General Public Licenses are designed to make sure that you have the
freedom to distribute copies of free software (and charge for this service
if you wish), that you receive source code or can get it if you want it,
that you can change the software or use pieces of it in new free programs;
and that you know you can do these things. 

To protect your rights, we need to make restrictions that forbid anyone
to deny you these rights or to ask you to surrender the rights. These restrictions translate
to certain responsibilities for you if you distribute copies of the software,
or if you modify it. 

For example, if you distribute copies of such a program, whether gratis
or for a fee, you must give the recipients all the rights that you have.
You must make sure that they, too, receive or can get the source code. And
you must show them these terms so they know their rights. 

We protect your rights with two steps: (1) copyright the software, and (2) offer
you this license which gives you legal permission to copy, distribute and/or
modify the software. 

Also, for each author's protection and ours, we want to make certain that everyone
understands that there is no warranty for this free software. If the software
is modified by someone else and passed on, we want its recipients to know
that what they have is not the original, so that any problems introduced by
others will not reflect on the original authors' reputations. 

Finally, any free program is threatened constantly by software patents.
We wish to avoid the danger that redistributors of a free program will individually obtain
patent licenses, in effect making the program proprietary. To prevent this,
we have made it clear that any patent must be licensed for everyone's free
use or not licensed at all. 

The precise terms and conditions for copying, distribution and modification follow. 

TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION
0. This License applies to any program or other work which contains a notice placed
by the copyright holder saying it may be distributed under the terms of this
General Public License. The "Program", below, refers to any such program or
work, and a "work based on the Program" means either the Program or any derivative
work under copyright law: that is to say, a work containing the Program
or a portion of it, either verbatim or with modifications and/or translated
into another language. (Hereinafter, translation is included without limitation
in the term "modification".) Each licensee is addressed as "you". 

Activities other than copying, distribution and modification are not covered
by this License; they are outside its scope. The act of running the Program
is not restricted, and the output from the Program is covered only if its
contents constitute a work based on the Program (independent of having been
made by running the Program). Whether that is true depends on what the Program
does. 

1. You may copy and distribute verbatim copies of the Program's source code
as you receive it, in any medium, provided that you conspicuously and appropriately
publish on each copy an appropriate copyright notice and disclaimer of warranty;
keep intact all the notices that refer to this License and to the absence
of any warranty; and give any other recipients of the Program a copy of this
License along with the Program. 

You may charge a fee for the physical act of transferring a copy, and you
may at your option offer warranty protection in exchange for a fee. 

2. You may modify your copy or copies of the Program or any portion of it,
thus forming a work based on the Program, and copy and distribute such modifications or
work under the terms of Section 1 above, provided that you also meet all
of these conditions: 


a) You must cause the modified files to carry prominent notices stating
that you changed the files and the date of any change. 

b) You must cause any work that you distribute or publish, that in whole
or in part contains or is derived from the Program or any part thereof,
to be licensed as a whole at no charge to all third parties under the terms
of this License. 

c) If the modified program normally reads commands interactively when run,
you must cause it, when started running for such interactive use in the
most ordinary way, to print or display an announcement including an appropriate
copyright notice and a notice that there is no warranty (or else, saying
that you provide a warranty) and that users may redistribute the program
under these conditions, and telling the user how to view a copy of this
License. (Exception: if the Program itself is interactive but does not normally
print such an announcement, your work based on the Program is not required
to print an announcement.) 
These requirements apply to the modified work as a whole. If identifiable
sections of that work are not derived from the Program, and can be reasonably
considered independent and separate works in themselves, then this License,
and its terms, do not apply to those sections when you distribute them as
separate works. But when you distribute the same sections as part of a whole
which is a work based on the Program, the distribution of the whole must
be on the terms of this License, whose permissions for other licensees extend
to the entire whole, and thus to each and every part regardless of who wrote
it. 

Thus, it is not the intent of this section to claim rights or contest your rights
to work written entirely by you; rather, the intent is to exercise the right
to control the distribution of derivative or collective works based on the
Program. 

In addition, mere aggregation of another work not based on the Program with
the Program (or with a work based on the Program) on a volume of a storage
or distribution medium does not bring the other work under the scope of
this License. 

3. You may copy and distribute the Program (or a work based on it, under
Section 2) in object code or executable form under the terms of Sections
1 and 2 above provided that you also do one of the following: 

a) Accompany it with the complete corresponding machine-readable source
code, which must be distributed under the terms of Sections 1 and 2 above
on a medium customarily used for software interchange; or, 

b) Accompany it with a written offer, valid for at least three years, to
give any third party, for a charge no more than your cost of physically
performing source distribution, a complete machine-readable copy of the
corresponding source code, to be distributed under the terms of Sections
1 and 2 above on a medium customarily used for software interchange; or, 

c) Accompany it with the information you received as to the offer to distribute corresponding
source code. (This alternative is allowed only for noncommercial distribution
and only if you received the program in object code or executable form with
such an offer, in accord with Subsection b above.) 
The source code for a work means the preferred form of the work for making
modifications to it. For an executable work, complete source code means
all the source code for all modules it contains, plus any associated interface
definition files, plus the scripts used to control compilation and installation
of the executable. However, as a special exception, the source code distributed need
not include anything that is normally distributed (in either source or binary
form) with the major components (compiler, kernel, and so on) of the operating
system on which the executable runs, unless that component itself accompanies
the executable. 

If distribution of executable or object code is made by offering access
to copy from a designated place, then offering equivalent access to copy
the source code from the same place counts as distribution of the source
code, even though third parties are not compelled to copy the source along
with the object code. 

4. You may not copy, modify, sublicense, or distribute the Program except
as expressly provided under this License. Any attempt otherwise to copy,
modify, sublicense or distribute the Program is void, and will automatically
terminate your rights under this License. However, parties who have received
copies, or rights, from you under this License will not have their licenses
terminated so long as such parties remain in full compliance. 

5. You are not required to accept this License, since you have not signed
it. However, nothing else grants you permission to modify or distribute
the Program or its derivative works. These actions are prohibited by law
if you do not accept this License. Therefore, by modifying or distributing
the Program (or any work based on the Program), you indicate your acceptance
of this License to do so, and all its terms and conditions for copying,
distributing or modifying the Program or works based on it. 

6. Each time you redistribute the Program (or any work based on the Program), the
recipient automatically receives a license from the original licensor to copy,
distribute or modify the Program subject to these terms and conditions. You
may not impose any further restrictions on the recipients' exercise of the rights
granted herein. You are not responsible for enforcing compliance by third
parties to this License. 

7. If, as a consequence of a court judgment or allegation of patent infringement
or for any other reason (not limited to patent issues), conditions are imposed
on you (whether by court order, agreement or otherwise) that contradict the
conditions of this License, they do not excuse you from the conditions of this
License. If you cannot distribute so as to satisfy simultaneously your obligations
under this License and any other pertinent obligations, then as a consequence
you may not distribute the Program at all. For example, if a patent license
would not permit royalty-free redistribution of the Program by all those
who receive copies directly or indirectly through you, then the only way you
could satisfy both it and this License would be to refrain entirely from distribution
of the Program. 

If any portion of this section is held invalid or unenforceable under any
particular circumstance, the balance of the section is intended to apply
and the section as a whole is intended to apply in other circumstances. 

It is not the purpose of this section to induce you to infringe any patents
or other property right claims or to contest validity of any such claims;
this section has the sole purpose of protecting the integrity of the free
software distribution system, which is implemented by public license practices.
Many people have made generous contributions to the wide range of software
distributed through that system in reliance on consistent application of
that system; it is up to the author/donor to decide if he or she is willing
to distribute software through any other system and a licensee cannot impose
that choice. 

This section is intended to make thoroughly clear what is believed to be
a consequence of the rest of this License. 

8. If the distribution and/or use of the Program is restricted in certain
countries either by patents or by copyrighted interfaces, the original copyright holder
who places the Program under this License may add an explicit geographical
distribution limitation excluding those countries, so that distribution is
permitted only in or among countries not thus excluded. In such case, this License
incorporates the limitation as if written in the body of this License. 

9. The Free Software Foundation may publish revised and/or new versions
of the General Public License from time to time. Such new versions will
be similar in spirit to the present version, but may differ in detail to
address new problems or concerns. 

Each version is given a distinguishing version number. If the Program specifies a
version number of this License which applies to it and "any later version", you
have the option of following the terms and conditions either of that version
or of any later version published by the Free Software Foundation. If the Program
does not specify a version number of this License, you may choose any version
ever published by the Free Software Foundation. 

10. If you wish to incorporate parts of the Program into other free programs whose
distribution conditions are different, write to the author to ask for permission.
For software which is copyrighted by the Free Software Foundation, write
to the Free Software Foundation; we sometimes make exceptions for this. Our
decision will be guided by the two goals of preserving the free status of all
derivatives of our free software and of promoting the sharing and reuse
of software generally. 

NO WARRANTY

11. BECAUSE THE PROGRAM IS LICENSED FREE OF CHARGE, THERE IS NO WARRANTY
FOR THE PROGRAM, TO THE EXTENT PERMITTED BY APPLICABLE LAW. EXCEPT WHEN
OTHERWISE STATED IN WRITING THE COPYRIGHT HOLDERS AND/OR OTHER PARTIES PROVIDE
THE PROGRAM "AS IS" WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESSED OR IMPLIED,
INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY
AND FITNESS FOR A PARTICULAR PURPOSE. THE ENTIRE RISK AS TO THE QUALITY
AND PERFORMANCE OF THE PROGRAM IS WITH YOU. SHOULD THE PROGRAM PROVE DEFECTIVE,
YOU ASSUME THE COST OF ALL NECESSARY SERVICING, REPAIR OR CORRECTION. 

12. IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING
WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MAY MODIFY AND/OR REDISTRIBUTE
THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES, INCLUDING
ANY GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING OUT OF
THE USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED TO LOSS
OF DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY YOU OR
THIRD PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER PROGRAMS),
EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE POSSIBILITY OF
SUCH DAMAGES. 


END OF TERMS AND CONDITIONS
How to Apply These Terms to Your New Programs
If you develop a new program, and you want it to be of the greatest possible use
to the public, the best way to achieve this is to make it free software which
everyone can redistribute and change under these terms. 

To do so, attach the following notices to the program. It is safest to attach them
to the start of each source file to most effectively convey the exclusion of
warranty; and each file should have at least the "copyright" line and a pointer
to where the full notice is found. 

one line to give the program's name and an idea of what it does.
Copyright (C) yyyy  name of author

This program is free software; you can redistribute it and/or
modify it under the terms of the GNU General Public License
as published by the Free Software Foundation; either version 2
of the License, or (at your option) any later version.

This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
GNU General Public License for more details.

You should have received a copy of the GNU General Public License
along with this program; if not, write to the Free Software
Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301,
USA.

Also add information on how to contact you by electronic and paper mail. 

If the program is interactive, make it output a short notice like this when
it starts in an interactive mode: 

Gnomovision version 69, Copyright (C) year name of author
Gnomovision comes with ABSOLUTELY NO WARRANTY; for details
type `show w'.  This is free software, and you are welcome
to redistribute it under certain conditions; type `show c' 
for details.

The hypothetical commands `show w' and `show c' should show the appropriate parts
of the General Public License. Of course, the commands you use may be called
something other than `show w' and `show c'; they could even be mouse-clicks
or menu items--whatever suits your program. 

You should also get your employer (if you work as a programmer) or your
school, if any, to sign a "copyright disclaimer" for the program, if necessary.
Here is a sample; alter the names: 

Yoyodyne, Inc., hereby disclaims all copyright
interest in the program `Gnomovision'
(which makes passes at compilers) written 
by James Hacker.

signature of Ty Coon, 1 April 1989
Ty Coon, President of Vice

This General Public License does not permit incorporating your program into proprietary
programs. If your program is a subroutine library, you may consider it more
useful to permit linking proprietary applications with the library. If this
is what you want to do, use the GNU Lesser General Public License instead of
this License. 



--------------------------------------------------------------------------------


Return to the GNU Project home page. 

Please send FSF & GNU inquiries to [email protected]. There are also other
ways to contact the FSF. 
Please send broken links and other corrections (or suggestions) to [email protected]

Please see the Translations README for information on coordinating and submitting
translations of this article. 

Copyright notice above.
51 Franklin Street, Fifth Floor, Boston, MA 02110, USA 
Verbatim copying and distribution of this entire article is permitted in
any medium without royalty provided this notice is preserved.

GoAhead License

Copyright © 2004 GoAhead Software
 
 10900
 NE 8th Street Suite 1200
 Bellevue, WA  98004
 USA
 (425)
 453-1900
 
 Version 2.1

 License Agreement 
 
 THIS LICENSE AGREEMENT IS BETWEEN YOU AND GOAHEAD (BOTH AS DEFINED BELOW).
 THIS AGREEMENT GRANTS YOU ONLY A LIMITED LICENSE TO USE GOAHEAD PROPRIETARY COMPUTER
 SOFTWARE.  BY EXECUTING THIS AGREEMENT OR USING THE SOFTWARE, YOU CERTIFY
 THAT YOU WILL USE THE SOFTWARE ONLY IN THE MANNER PERMITTED HEREIN. 
 
 1. Definitions. 
 
 1.1 "Documentation" means any documentation GoAhead provides with the Original Code. 
 
 1.2 "GoAhead" means GoAhead Software, Inc. 
 
 1.3 "Agreement" means this document. 
 
 1.4 "Modifications" means any addition to or deletion from the substance
 or structure of either the Original Code or any previous Modifications. 
 
 1.5 "Original Code" means the source code to GoAhead’s proprietary computer software
 entitled GoAhead WebServer that is provided to You by GoAhead. 
 
 1.6 "You" means an individual or a legal entity exercising rights under,
 and complying with all of the terms of, this license or a future version
 of this license.  For legal entities, "You" includes any entity that controls,
 is controlled by, or is under common control with You.  For purposes of
 this definition, "control" means (a) the power, direct or indirect, to cause
 the direction or management of such entity, whether by contract or otherwise,
 or (b) ownership of fifty percent (50%) or more of the outstanding shares
 or beneficial ownership of such entity. 
 
 1.7 "Response Header" means the first portion of the response message output
 by the GoAhead WebServer, containing but not limited to, header fields for
 date, content-type, server identification and cache control. 
 
 1.8"Server Identification Field" means the field in the Response Header
 which contains the text "Server: GoAhead-Webs". 
 
 2. License. 
 
 2.1 Limited Original Code Grant. 
 
 Subject to the terms of this Agreement, GoAhead hereby grants You a worldwide, royalty-free,
 nonexclusive, nontransferable license, without right of sublicense, subject
 to third party intellectual property claims, (a) to use and reproduce the
 Original Code, (b) to create Modifications from the Original Code, and (c)
 to distribute source code copies of the Original Code from solely when embedded
 in other software (in a manner that does not allow the Original Code to
 be separated) that provides material functionality in addition to the functionality
 provided by the Original Code.
 
 2.2 Binary Code. 
 
 Subject to the terms of this Agreement, GoAhead hereby grants You a worldwide, royalty-free,
 nonexclusive, nontransferable license, without right of sublicense, to copy
 and distribute binary code copies of the Original Code together with Your
 Modifications in binary code. 
 
 2.3 Restrictions on Use. 
 
 You may sublicense third parties to use Your Modifications if You enter
 into a license agreement with such third parties that bind such third parties
 to all the obligations under this Agreement applicable to You and that are
 otherwise substantially similar in scope and application to this Agreement
 (without limiting the protections afforded to GoAhead).  You may not rent,
 lease, or loan the software. 
 
 2.4 Documentation. 
 
 Subject to the terms of this Agreement, GoAhead hereby grants You a worldwide, royalty-free,
 nonexclusive, nontransferable license, without right of sublicense, to copy
 and distribute the Documentation in connection with the authorized distribution
 of the Original Code and Modifications.
 
 2.5 License Back to GoAhead. 
 
 You hereby grant in both source code and binary code to GoAhead a world-wide, royalty-free,
 non-exclusive license to copy, modify, display, use and sublicense any Modifications
 You make that are distributed or planned for distribution.  Within 30 days
 of either such event, You agree to ship to GoAhead a file containing the
 Modifications (in a media to be determined by the parties), including any
 programmers’ notes and other programmers’ materials. Additionally, You will
 provide to GoAhead a complete description of the product, the product code
 or model number, the date on which the product is initially shipped, and
 a contact name, phone number and e-mail address for future correspondence.
 GoAhead will keep confidential all data specifically marked as such. 
 
 3. Trademarks and Brand.
 
 3.1 License and Use. 
 
 GoAhead hereby grants to You a limited world-wide, royalty-free, non-exclusive license
 to use the GoAhead trade names, trademarks, logos, service marks and product
 designations posted in Exhibit A (collectively, the "GoAhead Marks") in connection
 with the activities by You under this Agreement. Additionally, GoAhead grants
 You a license under the terms above to such GoAhead trademarks as shall
 be identified at a URL (the "URL") provided by GoAhead. The use by You of GoAhead
 Marks shall be in accordance with GoAhead’s trademark policies regarding
 trademark usage as established at the Web site designated by the URL, or
 as otherwise communicated to You by GoAhead at its sole discretion. You
 understand and agree that any use of GoAhead Marks in connection with this
 Agreement shall not create any right, title or interest in or to such GoAhead
 Marks and that all such use and goodwill associated with GoAhead Marks will
 inure to the benefit of GoAhead.
 
 3.2 Promotion by You of GoAhead WebServer Mark.
 
 In consideration for the licenses granted by GoAhead to You herein, You
 agree to notify GoAhead when You incorporate the GoAhead WebServer in Your
 product and to inform GoAhead when such product begins to ship. You agree
 to promote the Original Code by prominently and visibly displaying a graphic
 of the GoAhead WebServer mark on the initial Web page of Your product that
 is displayed each time a user connects to it. You also agree that GoAhead
 may identify your company as a user of the GoAhead WebServer by placing
 your company logo on its Web site. You may further promote the Original
 Code by displaying the GoAhead WebServer mark in marketing and promotional
 materials such as the home page of your Web site or Web pages promoting
 the product.
 
 3.3 Copyright Notice. 
 
 You agree to include copies of the following notice (the "Notice") regarding proprietary
 rights in all copies of the Original Code and Modifications that You distribute,
 as follows: (a) embedded in the binary code; and (b) on the title pages
 of all documentation.  Furthermore, You agree to use commercially reasonable
 efforts to cause any licensees of your products to embed the Notice in object
 code and on the title pages or relevant documentation.  The Notice is as
 follows: Copyright (c) 20XX GoAhead Software, Inc.  All Rights Reserved.
 Unless GoAhead otherwise instructs, the year 20xx is to be replaced with
 the year during which the release of the Original Code containing the notice
 is issued by GoAhead.  If this year is not supplied with Documentation,
 GoAhead will supply it upon request.
 
 3.4 No Modifications to Server Identification Field.  
 
 You agree not to remove or modify the Server identification Field contained
 in the Response Header as defined in Section 1.7 and 1.8.
 
 4. Term. 
 
 This Agreement and license are effective from the time You execute this
 Agreement until this Agreement is terminated.  You may terminate this Agreement
 at any time by uninstalling or destroying all copies of the Original Code
 including all binary versions and removing any Modifications to the Original
 Code existing in any products.  This Agreement will terminate immediately
 and without further notice if You fail to comply with any provision of this
 Agreement.  All restrictions on use, and all other provisions that may reasonably
 be interpreted to survive termination of this Agreement, will survive termination
 of this Agreement for any reason.  Upon termination, You agree to uninstall
 or destroy all copies of the Original Code, Modifications, and Documentation.
 
 5. Warranty Disclaimers. 
 
 THE ORIGINAL CODE, THE DOCUMENTATION, AND THE MEDIA UPON WHICH THE ORIGINAL CODE
 IS RECORDED (IF ANY) ARE PROVIDED "AS IS" AND WITHOUT WARRANTIES OF ANY KIND,
 EXPRESS, STATUTORY OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
 OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE, TITLE, AND NON-INFRINGEMENT. 
 
 The entire risk as to the quality and performance of the Original Code (including
 any Modifications You make) and the Documentation is with You.  Should the Original
 Code or the Documentation prove defective, You (and not GoAhead or its distributors,
 licensors or dealers) assume the entire cost of all necessary servicing
 or repair.  GoAhead does not warrant that the functions contained in the
 Original Code will meet your requirements or operate in the combination that
 You may select for use, that the operation of the Original Code will be uninterrupted
 or error free, or that defects in the Original Code will be corrected. 
 No oral or written statement by GoAhead or by a representative of GoAhead
 shall create a warranty or increase the scope of this warranty. 
 
 GOAHEAD DOES NOT WARRANT THE ORIGINAL CODE AGAINST INFRINGEMENT OR THE LIKE WITH
 RESPECT TO ANY COPYRIGHT, PATENT, TRADE SECRET, TRADEMARK OR OTHER PROPRIETARY
 OR INTELLECTUAL PROPERTY RIGHT OF ANY THIRD PARTY AND DOES NOT WARRANT THAT
 THE ORIGINAL CODE DOES NOT INCLUDE ANY VIRUS, SOFTWARE ROUTINE OR OTHER SOFTWARE
 DESIGNED TO PERMIT UNAUTHORIZED ACCESS, TO DISABLE, ERASE OR OTHERWISE HARM
 SOFTWARE, HARDWARE OR DATA, OR TO PERFORM ANY OTHER SUCH ACTIONS. 
 
 Any warranties that by law survive the foregoing disclaimers shall terminate
 90 days from the date You received the Original Code. 
 
 6. Limitation of Liability. 
 
 YOUR SOLE REMEDIES AND GOAHEAD'S ENTIRE LIABILITY ARE SET FORTH ABOVE. 
 IN NO EVENT WILL GOAHEAD OR ITS DISTRIBUTORS OR DEALERS BE LIABLE FOR DIRECT,
 INDIRECT, INCIDENTAL OR CONSEQUENTIAL DAMAGES RESULTING FROM THE USE OF
 THE ORIGINAL CODE, THE INABILITY TO USE THE ORIGINAL CODE, OR ANY DEFECT
 IN THE ORIGINAL CODE, INCLUDING ANY LOST PROFITS, EVEN IF THEY HAVE BEEN
 ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 
 
 You agree that GoAhead and its distributors and dealers will not be LIABLE
 for defense or indemnity with respect to any claim against You by any third
 party arising from your possession or use of the Original Code or the Documentation. 
 
 In no event will GoAhead’s total liability to You for all damages, losses,
 and causes of action (whether in contract, tort, including negligence, or
 otherwise) exceed the amount You paid for this product. 
 
 SOME STATES DO NOT ALLOW LIMITATIONS ON HOW LONG AN IMPLIED WARRANTY LASTS,
 AND SOME STATES DO NOT ALLOW THE EXCLUSION OR LIMITATION OF INCIDENTAL OR
 CONSEQUENTIAL DAMAGES, SO THE ABOVE LIMITATIONS OR EXCLUSIONS MAY NOT APPLY
 TO YOU.  THIS WARRANTY GIVES YOU SPECIFIC LEGAL RIGHTS AND YOU MAY HAVE
 OTHER RIGHTS THAT VARY FROM STATE TO STATE. 
 
 7. Indemnification by You. 
 
 You agree to indemnify and hold GoAhead harmless against any and all claims, losses,
 damages and costs (including legal expenses and reasonable counsel fees)
 arising out of any claim of a third party with respect to the contents of Your
 products, and any intellectual property rights or other rights or interests
 related thereto.
 
 8. High-Risk Activities.  
 
 The Original Code is not fault-tolerant and is not designed, manufactured
 or intended for use or resale as online control equipment in hazardous environments
 requiring fail-safe performance, such as in the operation of nuclear facilities,
 aircraft navigation or communication systems, air traffic control, direct
 life support machines or weapons systems, in which the failure of the Original
 Code could lead directly to death, personal injury, or severe physical or
 environmental damage.  GoAhead and its suppliers specifically disclaim any express
 or implied warranty of fitness for any high-risk uses listed above. 
 
 9. Government Restricted Rights. 
 
 For units of the Department of Defense, use, duplication, or disclosure
 by the Government is subject to restrictions as set forth in subparagraph
 (c)(1)(ii) of the Rights in Technical Data and Computer Software clause
 at DFARS 252.227-7013.  Contractor/manufacturer is GoAhead Software, Inc.,
 10900 N.E. 8th Street, Suite 1200, Bellevue, Washington 98004. 
 
 If the Commercial Computer Software Restricted rights clause at FAR 52.227-19 or
 its successors apply, the Software and Documentation constitute restricted computer
 software as defined in that clause and the Government shall not have the
 license for published software set forth in subparagraph (c)(3) of that clause. 
 
 The Original Code (i) was developed at private expense, and no part of it
 was developed with governmental funds; (ii) is a trade secret of GoAhead
 (or its licensor(s)) for all purposes of the Freedom of Information Act;
 (iii) is "restricted computer software" subject to limited utilization as
 provided in the contract between the vendor and the governmental entity;
 and (iv) in all respects is proprietary data belonging solely to GoAhead
 (or its licensor(s)). 
 
 10. Governing Law and Interpretation. 
 
 This Agreement shall be interpreted under and governed by the laws of the
 State of Washington, without regard to its rules governing the conflict
 of laws.  You hereby consent to the exclusive jurisdiction of the state
 and federal courts located in King County, Washington over any disputes
 arising out of related to this Agreement.  If any provision of this Agreement
 is held illegal or unenforceable by a court or tribunal of competent jurisdiction,
 the remaining provisions of this Agreement shall remain in effect and the
 invalid provision deemed modified to the least degree necessary to remedy
 such invalidity.
 
 11. Entire Agreement. 
 
 This Agreement is the complete agreement between GoAhead and You and supersedes all
 prior agreements, oral or written, with respect to the subject matter hereof. 
 
 If You have any questions concerning this Agreement, You may write to GoAhead Software,
 Inc., 10900 N.E. 8th Street, Suite 1200, Bellevue, Washington 98004 or send
 e-mail to [email protected]
 
 
 
 
 
 GoAhead Software Inc., 10900 NE 8th Street, Suite 1200, Bellevue, WA 98004 (425)
 453-1900
 
 © 2004 GoAhead Software. All rights reserved. GoAhead is a registered trademark of
 GoAhead Software, Inc. SelfReliant and Service Availability are trademarks of
 GoAhead Software, Inc. All other brand and product names are trademarks
 or registered trademarks of their respective holders.
 
            


nice color