4.2. Creating a new test

You can add new tests to the testcodes directory. Use the designtest_m0 test as a guide to the format you can use. For example, you can use the following process to create a new test:

  1. Create a new directory in the testcodes/ directory. For example:

    1. cd <installation_directory>/designstart_FPGA/resources/fpga_testbench/fpga/testcodes

    2. mkdir mytest

  2. Copy the files that are located in the designtest_m0/ directory to your new test directory, and then rename the test file. For example:

    1. cd mytest

    2. cp ../designtest_m0/* .

    3. mv designtest_m0.c mytest.c

  3. Edit the makefile to rename designtest_m0.c to mytest.c.

  4. Ensure that the output .elf file has the same name as the directory name, for example mytest.elf. This enables the makefile in rtl_sim/ directory to copy the .elf file to the rtl_sim/ directory before the simulation starts.

  5. If required, you can add the name of your new test to the TEST_LIST variable in the makefile located in the rtl_sim/ directory.

Copyright © 2015-2016 ARM. All rights reserved.ARM DUI 0934B