ARM AEB-1 Hardware Setup


The ARM AEB-1 comes with tools in ROM. These include a simple FLASH management tool and the Angel® monitor. eCos for the ARM AEB-1 comes with GDB stubs suitable for programming into the onboard FLASH. GDB is the preferred debug environment for GDB, and while Angel provides a subset of the features in the eCos GDB stub, Angel is unsupported.

Both eCos and the stubs support both Revision B and Revision C of the AEB-1 board. Stub ROM images for both types of board can be found in the loaders/arm-aeb directory under the root of your eCos installation. You can select which board you are using by selecting either the aeb or aebC platform by selecting the appropriate platform HAL in the eCos Configuration Tool.

The GDB stub can be downloaded to the board for programming in the FLASH using the board's on-board ROM monitor:

  1. talk to the AEB-1 board with a terminal emulator (or a real terminal!)

  2. use the board's rom menu to download a UU-encoded version of the GDB stubs which will act as a ROM monitor

  3. tell the board to use this new monitor, and then hook GDB up to it for real debugging

Talking to the Board

Connect a terminal or computer's serial port to the ARM AEB-1. On a PC with a 9-pin serial port, you can use the cable shipped by ARM with no modification.

Set the terminal or terminal emulator to 9600N1 (9600 baud, no parity, 1 stop bit).

Reset the board by pressing the little reset button on the top. You will see the following text:

	ARM Evaluation Board Boot Monitor 0.01 (19 APR 1998)
	Press ENTER within 2 seconds to stop autoboot

Press ENTER quickly, and you will get the boot prompt:


Downloading the Stubs via the Rom Menu

Using the AEB-1 rom menu to download the GDB stubs from the provided ".UU" file.

Note: This is an annotated 'terminal' session with the AEB-1 monitor:

+Boot: help
Module is BootStrap       1.00 (14 Aug 1998)
Help is available on:
Help          Modules       ROMModules    UnPlug        PlugIn
Kill          SetEnv        UnSetEnv      PrintEnv      DownLoad
Go            GoS           Boot          PC            FlashWrite
FlashLoad     FlashErase
Boot: download c000
Ready to download. Use 'transmit' option on terminal
emulator to download file.
... at this point, download the ASCII file "loaders/arm-aeb/
    gdb_module.img.UU". The details of this operation differ
    depending on which terminal emulator is used. It may be
    necessary to enter "^D" (control+D) when the download completes
   to get the monitor to return to command mode. 
Loaded file gdb_module.img.bin at address
0000c000, size = 19392 

Activating the GDB Stubs

Commit the GDB stubs module to FLASH:

	Boot: flashwrite 4018000 C000 8000

Verify that the eCos/"GDB stubs" module is now added in the list of modules in the board:

	Boot: rommodules

You should see output similar to the following:

	Header   Base     Limit
	04000004 04000000 040034a8 BootStrap       1.00 (14 Aug 1998) 
	04003a74 04003800 04003bc0 Production Test 1.00 (13 Aug 1998) 
	0400e4f4 04004000 0400e60f Angel           1.02 (12 MAY 1998) 
	0401c810 04018000 0401cbc0 eCos              1.3  (27 Jan 2000)
GDB stubs

Now make the eCos/"GDB stubs" module be the default monitor:

	Boot: plugin eCos

Note: Since the GDB stubs are always linked at the same address (0x4018000), the operation of writing to the FLASH and selecting the stubs as default monitor is an idempotent operation. You can download a new set of stubs following the same procedure - you do not have to unregister or delete anything.

Building the GDB Stub FLASH ROM Images

Pre-built GDB stubs images are provided in the directory loaders/arm-aeb relative to the root of your eCos installation, but here are instructions on how to rebuild them if you should ever need to.

Building the GDB Stubs with the eCos Configuration Tool

  1. Start with a new document - selecting the File -> New menu item if necessary to do this.

  2. Choose the Build -> Templates menu item, and then select the ARM AEB-1 hardware.

  3. While still displaying the Build->Templates dialog box, select the "stubs" package template to build a GDB stub image. Click OK.

  4. If applicable, set the "AEB board revision" option to "C" from "B" depending on the board revision being used.

  5. Build eCos using Build -> Library.

  6. When the build completes, the image files can be found in the bin/ subdirectory of the install tree. The GDB stub ROM images have the prefix "gdb_module".

Building the GDB Stub ROMs with ecosconfig

  1. Make an empty directory to contain the build tree, and cd into it.

  2. To build a GDB stub ROM image, enter the command:

    $ ecosconfig new aeb stubs
  3. If applicable, edit ecos.ecc and set the AEB board revision. (CYGHWR_HAL_ARM_AEB_REVISION) from the default "B" to "C" by uncommenting the user_value property and setting it to "C".

  4. Enter the commands

    $ ecosconfig tree
    $ make

  5. When the build completes, the image files can be found in the bin/ subdirectory of the install tree. The GDB stub ROM images have the prefix "gdb_module".