Debugging VxWorks BSP for ARM


   To debug a VxWorks BSP for the LPC2106 microprocessor and the to test project in the minimal configuration (without the network and the serial communication), a JTAG debugging is a very important.
   The Rowley's CrossWorks CrossStudio for ARM (IDE for the ARM processors) is a convenient and inexpensive tool for this purpose.

   The CrossStudio uses the GCC compiler, therefore a debugging information format is similar to the Tornado's GNU toolchain.
   The CrossStudio for ARM is used here for the load/debug purpose only (not for the compiling/linking). Tornado automatically creates the Makefile in the test project directory. CrossStudio for ARM uses this makefile to build/rebuild a test project. It means that all project's compiling/linking/building stages are performed by the Tornado's tools.

1. Test project in Tornado

   A test project for the LPC2106 BSP should use a GNU toolset.
   In the Tornado's dialog "Properties: build specification 'default_romResident'", the check box 'Include debug info' must be checked.

2. Test project in CrossStudio for ARM

   Create a new project in the CrossStudio for ARM as the "Externally Build Executable" project (File -> New -> New project -> Externally Build Executable).
  A CrossStudio's project/solution should be created (placed) in the directory of the Tornado's test project.

    2.1 Makefile processing

   To prepare the Makefile processing in the CrossStudio for ARM:
      - create a separate batch file in the directory of the Tornado's test project (for instance, the file's name is a mke.bat).

   This is a batch file contents:

  rem Command line build environments
  set WIND_HOST_TYPE=x86-win32
  rem Put here correct Tornado's path
  set WIND_BASE=C:\Tornado22

  make %1

       - copy the file make.exe from the directory \host\x86-win32\bin to the test project directory

    2.2 Project options

   In the CrossStudio for ARM, open a dialog "Project options" and the tab "External Build".
   Fill input fields (see the picture below):
      -  Build Command   - full path of the test project directory + mke.bat
      -  Clean Command  - full path of the test project directory + mke.bat clean
      -  Executable File     - full path of the test project directory + vxWorks_romResident

    2.3 Debugging

   To set a debugging breakpoints, add a source files (CrossStudio for ARM, a window "Project Explorer" -> the folder "Source files") which you want to debug (for example, the  file sysLib.c from a BSP directory and usrAppInit.c from the test project directory)
   Before building the project in CrossStudio for ARM, a Tornado's project should be build inside the Tornado - it creates a valid Makefile for the CrossStudio for ARM. Then, after the building and loading from the CrossStudio for ARM, it is possible to make a source level debugging.
   With the Wiggler JTAG adapter, a test project's loading time is 5-6 sec.

Full size

Downloads   The file contains a project file for the CrossStudio(r) ARM IDE to debug a VxWorks's BSP for the Philips LPC2106 microprocessor.