3.8. Testing Imported Flash Algorithms

You can test imported flash algorithms from within Eclipse. The tests performed by Eclipse are similar to those that are present in the test harness in your flash algorithm project. The benefit of also running the Eclipse tests is that you can gain additional confidence that Eclipse has imported your flash algorithm correctly and is able to use it as expected.

To test an imported flash algorithm:

  1. Select Target → Manage Targets… from the Eclipse main menu. The Manage Targets dialog opens.

  2. Either select an existing flash configuration or create a new flash configuration (see Creating a Flash Configuration).

  3. Click the Test… button. The Test Target dialog opens.

  4. Select a connection method, and click Configure…. A configuration dialog opens that you must use to configure the connection to your target. After configuring your connection save and close this configuration dialog.

  5. After closing the configuration dialog the CPU drop-down list in the Test Target dialog is populated with the available cores. Select the core that you want to connect to (see Figure 8).

    Figure 8. Configuring a test target

    Configuring a test target
  6. Click Test device… to begin testing your flash algorithm. During testing a progress dialog is shown and logging appears on the Eclipse console. Testing causes the current contents of the flash device to be lost.

  7. The Flash Programmer Results dialog opens when testing is complete (see Figure 9). The results indicate whether the tests passed or failed and the time taken to perform various operations.

    Figure 9. The tests results dialog

    The tests results dialog

If a failure is indicated you must examine the log in the Eclipse console to determine the cause. Check that you have entered the correct parameters in your flash configuration. Check that your flash algorithm adheres to the instructions given in Basic Principles, such as not requiring a heap and coping with watchdog timers.

Copyright © 2007. All rights reserved.DAI0190A
Non-Confidential