X-Git-Url: https://git.kernelconcepts.de/?p=karo-tx-redboot.git;a=blobdiff_plain;f=doc%2Fhtml%2Fuser-guide%2Fusing-commandline-testcase.html;fp=doc%2Fhtml%2Fuser-guide%2Fusing-commandline-testcase.html;h=0000000000000000000000000000000000000000;hp=ab5dd47367971fbbfe308ba7ca6e79e8017d3612;hb=739c21725ce2774a605a0f1de3edaac2c43aea0f;hpb=ae71e0fa8076a1b59600b3a0ea10155a2cb534ae diff --git a/doc/html/user-guide/using-commandline-testcase.html b/doc/html/user-guide/using-commandline-testcase.html deleted file mode 100644 index ab5dd473..00000000 --- a/doc/html/user-guide/using-commandline-testcase.html +++ /dev/null @@ -1,397 +0,0 @@ - - - - - - - - -Using the command line -
eCos User Guide
PrevChapter 12. Running an eCos Test CaseNext

Using the command line

Start a command shell (such as a Cygwin shell window in Windows) -with the environment variables set as described in the toolchain -documentation. Change to the directory in which you set up your build -tree, and invoke GDB on the test -program.

To run the bin_sem0 test (which will -test the kernel for the correct creation and destruction of binary -semaphores) type:

$ TARGET-gdb -nw install/tests/kernel/<version>/tests/bin_sem0

You should see output similar to the following in the command -window:

GNU gdb THIS-GDB-VERSION
-Copyright 2001 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=THIS-HOST --target=THIS-TARGET".
-(gdb)

If you are trying to run a synthetic target test on Linux, skip the following connection and download -steps. Otherwise, connect to the target by typing:

(gdb) set remotebaud 38400
-(gdb) target remote /dev/ttyS0

on Linux or

(gdb) set remotebaud 38400
-(gdb) target remote com1

on Windows or

(gdb) target sim

to use a simulator in either host O/S.

Check the documentation for the target board for the actual baud rate -to use when connecting to real targets.

You will see output similar to the following:

Remote debugging using /dev/ttyS1
-0x0000d50c in ?? ()
-    at BASE_DIR/kernel/<version>/src/common/kapi.cxx:345
-
-Current language:  auto; currently c++
-(gdb) 

Or if you are using the simulator:

Connected to the simulator.
-(gdb)

Now download the program to the target with

(gdb) load

You should see output similar to the following on your screen:

Loading section .text, size 0x4b04 lma 0x108000
-Loading section .rodata, size 0x738 lma 0x10cb08
-Loading section .data, size 0x1c0 lma 0x10d240
-Start address 0x108000, load size 21500
-Transfer rate: 24571 bits/sec, 311 bytes/write.
-(gdb)

You are now ready to run your program. If you type:

(gdb) continue

you will see output similar to the following:

Continuing.
-PASS:<Binary Semaphore 0 OK>
-EXIT:<done>

Note: If you are using a simulator or the synthetic target rather - than real hardware, you must use the GDB command - “run” rather than “continue” to - start your program.

You can terminate your GDB session with -Control+C, otherwise it will sit in the -“idle” thread and use up CPU time. This is not a problem -with real targets, but may have undesirable effects in simulated or -synthetic targets. Type quit and you are -done.


PrevHomeNext
Running an eCos Test CaseUpTesting Filters
\ No newline at end of file