Instruments Technology for

Build/Run Instructions for Codec Engine Examples

General Information

This page explains how to build the examples provided in the Codec Engine (CE) product.

Examples currently contain the simple pass-through (copy) codecs, implemented in the XDM algorithm standard.

More details are available at the Codec Engine Examples wiki article.


See the Release Notes for the specific software and hardware components this release of Codec Engine has been validated against.

Directory Structure

Examples are provided in zip file format under the directory

where <CE_INSTALL_DIR> is the root directory of your Codec Engine insatallation. Under the archive directory, you will find directories named for platforms containing zipped examples specific to the given platform. Each example is self-contained, so that it can be unzipped and built in a directory of your choice. It is also possible to build all the examples for your platform from the makefile located in <CE_INSTALL_DIR>/examples.

Directories containing examples:
    +---archive  Platform directories 
        +---C6A8149_bios_elf Zipped BIOS examples for C6A8149 EVM 
        +---C6678_bios_elf Zipped BIOS examples for C6472 EVM 
        +---C6472_bios_elf Zipped BIOS examples for C6472 EVM 
        +---OMAP3530_bios_elf Zipped BIOS examples for OMAP3530 EVM 
        +---TI814X_bios_elf Zipped BIOS examples for TI814X EVM 
        +---TI816X_bios_elf Zipped BIOS examples for TI816X EVM 
		+---TI811X_bios_elf Zipped BIOS examples for TI811X EVM 
The archive folders ending in "_elf" build the BIOS executables with ELF format.

Building the examples: step-by-step instructions

Here we will describe the steps to build all the examples for your platform, from the root of the examples directory.

Important: throughout the rest of this document, we will use the following notation:

1. Dependencies

Dependencies can be set in $(CE_INSTALL_DIR)/products.mak. This file is then included by the individual example makefiles, if they are built under <CE_INSTALL_DIR>/examples. You can also copy the $(CE_INSTALL_DIR)/products.mak to a specific example directory if you move the example to another location.


Codegen Tools

2. [Optional] Copy the entire "examples" tree out of the product.

It may no longer be necessary to copy the entire "examples" tree out of the product, since all examples are now contained in .zip files, which can be re-extracted to recover the original example. However, if you do copy the examples folder to another location, you will need to

3. Manage examples makefile

At the root of the examples directory you will find the makefile, which must be edited for your particular platform. Edit the following variable in makefile, as described below.

NOTE: You may not want to build all the examples for a particular platform. For example, if you have the EZSDK for the TI816X platform, you should not build the BIOS or remote Linux VIDEO-M3 and VPSS-M3 examples. You can control to some extent, which examples are built by editing the examples.inc file at the root of the examples directory, and commenting out the examples you do not want to build. For example, by commenting out these lines in examples.inc, when you run make at the root of the examples directory, none of the BIOS only examples will be unzipped and built for the TI816X platform:

ifeq ("$(DEVICE)","TI816X")

#    example_apps += TI816X_bios_elf/ex01_universalcopy_dsp
#    example_apps += TI816X_bios_elf/ex01_universalcopy_video
#    example_apps += TI816X_bios_elf/ex01_universalcopy_vpss

You will also need to edit the makefile of the unzipped remote Linux example, if you don't want to build the remote VIDEO-M3 and VPSS-M3 examples. For example, comment out all lines containing video and vpss in ex01_universalcopy_remote/makeflle as shown below:

	$(MAKE) -C  codec_dsp
	$(MAKE) -C  dsp
#	$(MAKE) -C  codec_video
#	$(MAKE) -C  video
#	$(MAKE) -C  codec_vpss
#	$(MAKE) -C  vpss
	$(MAKE) -C  host

	$(MAKE) -C  host INSTALL_DIR=$(INSTALL_DIR) install
	$(MAKE) -C  dsp INSTALL_DIR=$(INSTALL_DIR) install
#	$(MAKE) -C  video INSTALL_DIR=$(INSTALL_DIR) install
#	$(MAKE) -C  vpss INSTALL_DIR=$(INSTALL_DIR) install

	$(MAKE) -C  host $@
	$(MAKE) -C  codec_dsp $@
	$(MAKE) -C  dsp $@
#	$(MAKE) -C  codec_video $@
#	$(MAKE) -C  video $@
#	$(MAKE) -C  codec_vpss $@
#	$(MAKE) -C  vpss $@


The DEVICE variable indicates which hardware platforms should be built for. Set this variable to one of the supported platforms listed in the makefile.

The makefile in the top-level example directory unzips the examples for the specified device, into the examples directory, and then builds them. Each example contains a GNU makefile and a products.mak, which enable you to build it in the directory where it is unzipped. The products.mak for the individual example will look for a products.mak file one, two, or three directories above, to allow for a common products.mak file that can be used for the examples.

Please keep in mind that MOST BUILD TROUBLES OCCUR WHEN ONE OF THE VARIOUS *_INSTALL_DIR VARIABLES ARE INCORRECT! Make sure there are no extra spaces (check the end of lines!), that every individual path (segment separated by the semicolon) is correct, character for character, and the build process is very likely to go smoothly.

4. Build examples

After updating the variables described above, from your examples/ directory, type:

    gmake clean

All examples appropriate for your specified environment and device will be built. This will include codecs, extensions, servers (if applicable) and apps.

To copy the built examples to a location on your target's file system, type:

    gmake install INSTALL_DIR=<INSTALL_DIR>

where <INSTALL_DIR> is the location to copy to.

If for whatever reason you want to remove all the extracted examples, type:

    gmake clobber

Running the example applications

All of these examples are single core examples that can be run by loading the executable on the corresponding core in CCS and letting it run till the end. In most cases logging/trace is enabled and that will generate useful output on the Console.

Memory map

The platform specific memory maps for the servers that are used by remote apps, are located in the _config.bld file where the server is built. For example, ex01_universalcopy_dsp/dsp/_config.bld contains the memory map for the DSP.

In case you need to modify the memory map, you can modify the _config.bld file as needed.

Last updated: June 13, 2013