• Join
  • Sign In with my.TI Login
Texas Instruments
  • Products
  • Applications
  • Tools & Software
  • Support & Community
  • Sample & Buy
  • About TI
Sample & Purchase Cart Sample & Purchase Cart
  • Search
  • Advanced
TI E2E™ Community
  • Support Forums
  • Blogs
  • Groups
  • Videos
  • 简体中文
  • More ...
TI Home » TI E2E Community » Support Forums » Embedded Software » Multimedia Software Codecs » Multimedia Software Codecs forum » Unable to build project using c64x+ G.711 encoder library under CCSv5
Share
Multimedia Software Codecs
  • Forum
Options
  • Subscribe via RSS

Forums

Unable to build project using c64x+ G.711 encoder library under CCSv5

This question is not answered
Joseph Zolyak
Posted by Joseph Zolyak
on Jul 10 2012 14:18 PM
Intellectual470 points

I have an OMAP-L138 development board, and the following version of software tools installed:

CCSv5 = 5.1.0.08020, BIOS = 6.32.04.49, XDCTOOLS = 3.22.03.41, XDAIS  = 7.21.01.05

I have successfully converted a C6726 based product from CCSv3.3 over to CCSv5.1 and gotten it to run on the OMAP-L138 dev board. My project did not use or require any XDC or SYS/BIOS components, and it runs just fine. I am switching over to a C6747 or C6748 chip so that I can take advantage of the C64x+ software libraries such as the G.711, G.722, and G.726 encoder/decoders.

I downloaded c64xplus_g711_1_12_00_000_production, created an "Empty Project" from the "Empty Project" templates, replaced the dummy main.c file with TestAppEncoder.c, and added g711enc_tii.l64P and XDM source files to the project that I created. When I attempted to build the project I  got the following error messsage:

     #5 could not open source file "std.h"    alg_create.c    /g711_enc    line 16    C/C++ Problem

After reading thru the TI forums, it seems that many people have run into this same problem. The two recommended solutions were either: (1)  to go to the project "Build Options -> Include Options" and manually add the include paths to find std.h in xdctools, or (2) create a new project, but this time use the "Empty RTSC Project" template. I chose the second option.  This resolved the missing "std.h" file problem, but then I ran into another build problem:

     This project does not contain a buildable RTSC Configuration (.cfg) file. In order for it to build, this project must contain one RTSC Configuration file that is not    excluded from build.

For whatever reason creating a "Empty RTSC Project" from the template does not produce a .cfg along with the project. [NOTE:  I selected "ti.targets.c674" as the TARGET, and "ti.platforms.sim67xx" as the PLATFORM for these empty template projects].

After reading thru the TI forums again, it seems that my choices were either to:  (1) create a SYS/BIOS project from one of the templates and use the .cfg that was created, or (2) use one of the .cfg files under  C:\ti\ccsv5\ccs_base\simulation\bin\configurations. I created app.cfg from the "SYS/BIOS -> Minimal" template, as well as hello.cfg from "SYS/BIOS -> Examples -> Hello"  template. 

When I added either app.cfg or hello.cfg to my g711 project, and then attempt to rebuild it, I get the following error message:

     Unsupported device!    .xdchelp    /g711_enc    237    C/C++ Problem

Finally I tried using one of the .cfg files from the ..\simulation\bin\configurations subdirectory. I tried separately building my g711 project using tisim_c674x_ca.cfg, tisim_C6747_ca.cfg, or tisim_C6747_pv.cfg.  In each case I got the following error message:

      missing ; before statement    tisim_c674x_ca.cfg    /g711_enc    6    C/C++ Problem

I have no idea what that error message means or how to resolve it.

Overall, I have searched all over the TI Forums and wiki pages, and I can't find a simple explanation of how to create a simple main.c file that creates a single instance of the g711 encoder that will build and run under CCSv5.  As soon as you use the common XDM files alg_create.c and alg_malloc.c, you then need to use std.h, and then you go down the tool chain rabbit hole.

Bottom line, how do you create a project in CCSv5 to create and build an instance of the g711 encoder that is found in c64xplus_g711_1_12_00_000_production.zip ?



C6747 OMAP-L138 SYS/BIOS G711 C6748 CCSv5 XDCtools
Report Abuse
  • Reply
You have posted to a forum that requires a moderator to approve posts before they are publicly available.
All Replies
  • Joseph Zolyak
    Posted by Joseph Zolyak
    on Jul 12 2012 15:31 PM
    Intellectual470 points

    I went back and re-examined G711_Codec_C64PLUS_UserGuide.pdf that was included as part of dm6446_g711enc_1_12_00_000_production.tar.  The installation instructions are for CCSv3.3, and don't apply to building a project under CCSv5.

    I did some further searches on the TI wiki pages and came across the following link:

         http://rtsc.eclipse.org/docs-tip/Consuming_Configurable_Content

    It appears that this RTSC repository should have had a file like g711enc.cfg which would look like:

        var System = xdc.useModule("xdc.runtime.System");

    And TestAppEncoder.c should have two lines at the top of the file stating:

        #include <xdc/std.h>

        #include <xdc/runtime/System.h>


    I went back to the TI website where I downloaded the g711 encoder/decoder, i.e.

         http://software-dl.ti.com/dsps/dsps_public_sw/codecs/C64XPlus_Speech/index_FDS.html

    According to the website it says:

         All codecs are eXpressDSP compliant and implement one of the XDM 1.0 interfaces.
         Each codec is XDC packaged and validated on DM6446 EVM in a Codec Engine based test framework.


    I am seeking instructions on how to create a project in CCSv5 to build TestAppEncoder.c  either for an OMAP-L138 platform or the C674x software simulator. I haven't used any of the XDC tools in CCSv5, and I need help specifying a repository path(?) to the proper location in the unzipped .tar package to build the test application.






    Report Abuse
    • Reply
    You have posted to a forum that requires a moderator to approve posts before they are publicly available.
  • Michael S
    Posted by Michael S
    on Jul 13 2012 10:30 AM
    Genius9710 points

    Hello team,

    Has anyone had an opportunity to review this inquiry?

    Regards,

    Regards,

    Michael S.

    ACSC Digital Apps

     

    Report Abuse
    • Reply
    You have posted to a forum that requires a moderator to approve posts before they are publicly available.
  • Alan DeMars
    Posted by Alan DeMars
    on Jul 13 2012 11:08 AM
    Genius14085 points

    Joseph,

    I tried to recreate the scenario you described but failed. Can you publish your CCS project?

    Alan

    Report Abuse
    • Reply
    You have posted to a forum that requires a moderator to approve posts before they are publicly available.
  • Joseph Zolyak
    Posted by Joseph Zolyak
    on Jul 13 2012 12:21 PM
    Intellectual470 points

    Hello,

    I have attached a zipped file containing my project. The following are the steps I used to create the project:

    1.  I copied the contents of the untarred file dm6446_g711enc_1_12_00_000_production to the location C:\Vx12\CCSv5_workspace.

    2.  I created an Empty RTSC project located at:

              C:\Vx12\CCSv5_workspace\dm6446_g711enc_1_12_00_000_production\packages\ti\sdo\codecs\g711enc\package

         (I zipped up all the files below ..\g711enc)

    3.  Next I added the following files to the project: TestAppEncoder.c, TestAppEncoder.h, TestAppConfigParser.c, TstApp.h, alg_create.c, alg_malloc.c.

    4.  When I build the project I get the following error message:

             #5 could not open source file "std.h"    TestAppEncoder.c    /g711enc    line 18    C/C++ Problem

    5.  Next I hand modify TestAppEncoder.c, alg_malloc.c, and alg.create.c to change

            #include <std.h>   to  #include <xdc/std.h>

    6.  When I recompile the modified files I get the following error messages:

             #5 could not open source file "alg.h"    alg_create.c    /g711enc    line 17    C/C++ Problem
             #5 could not open source file "xdas.h"    TestApp.h    /g711enc    line 20    C/C++ Problem

    This is my latest attempt at trying to build the test app for the g711 encoder.  I was hoping that you can tell me what I did wrong, and how to properly build  an instance of the g711 encoder.

    4135.g711enc.zip


    Report Abuse
    • Reply
    You have posted to a forum that requires a moderator to approve posts before they are publicly available.
  • Joseph Zolyak
    Posted by Joseph Zolyak
    on Jul 13 2012 15:08 PM
    Intellectual470 points

    Addendum:

    1.  The header files alg.h and _alg.h do not exist under C:\ti\xdias_7_21_01_05_eng or  C:\ti\xdctools_3_22_03_41 (which were installed as part of CCSv5 installation).  My attempt to fix the problem was to use the header files located under C:\CCStudio_v3.3\C6000\xdias\src\api.

    2.  The header file xdas.h is located under C:\ti\xdias_7_21_01_05_eng\packages\ti\xdias, so I am not sure why the CCSv5 tool chain could not find it.

    Report Abuse
    • Reply
    You have posted to a forum that requires a moderator to approve posts before they are publicly available.
  • Chris Ring
    Posted by Chris Ring
    on Jul 13 2012 18:55 PM
    Genius16190 points

    I'm going to move this to the Codec forum as this appears to be specific to the G.711 codec and its build process.

    Hopefully someone there can help.

    Chris

    Report Abuse
    • Reply
    You have posted to a forum that requires a moderator to approve posts before they are publicly available.
  • Joseph Zolyak
    Posted by Joseph Zolyak
    on Jul 19 2012 11:39 AM
    Intellectual470 points

    Since I haven't received any feedback in 6 days, I continued to do some additional research on my own.

    The C6748, C6747, and C66xx processors are all capable of running code built for a C64x+ target, so I went to the codec download page for the C66xx processor:

         http://software-dl.ti.com/dsps/dsps_public_sw/codecs/C6X_Speech/2_00_000/index_FDS.html

    The G.711 release notes indicate that the codec will run on C674x processor, so I downloaded c64xplus_g711_2_00_000_production.exe and it unpacked itself under

          C:\Program Files (x86)\c64xplus_g711_2_00_000_production

    On the C66xx codec download page it says:

         All codecs are ELF builds, eXpressDSP compliant, and implement XDM 1.0 interfaces.
         The codec package was generated using GenCodecPkg wizard included in Codec Engine 3.xx.

    After wandering around lots of TI wiki pages and Forum pages, it seems that I need some sort of wizard in order to "consume" an XDM compliant package.  It is my impression that the "wizard" will configure the Code Composer project to locate the necessary files to build the project.

    What wizard do I need to open and build a G.711 codec package under CCSv5?  Please provide instructions on how to build any of the G.711 test applications found in c64xplus_g711_2_00_000_production using CCSv5 tools.

    C6747 C64x+ C6748 CCSv5 G.711 codec
    Report Abuse
    • Reply
    You have posted to a forum that requires a moderator to approve posts before they are publicly available.
  • janet
    Posted by janet
    on Jul 19 2012 14:58 PM
    Expert5315 points

    Joseph,

    I tried to reproduce your problem, first with the g711_1_12 encoder.  I ran into the same errors you did, and tried to work around them.  I eventually stopped this route, since the TestAppEncode.c was calling BCACHE APIs, which are a part of BIOS 5, and from your first post, I see that you have BIOS 6.

    So then I downloaded the 2.00.00 g711 software and attempted to build the test app for g711aenc.  With some effort, I was able to do this.  Here are the steps I did:

    1. Created an empty CCS project.

    2. Replaced main.c with g711Encodermain.c (located in g711\ti\sdo\codecs\g711aenc\app\Client\Test\Src)

    3. Added the following search paths for include files:

           ti\xdctools_3_22_04_46\packages\xdc

           ti\xdctools_3_22_04_46\packages

           g711\ti\sdo\codecs\g711aenc\app\Inc

           ti\xdais_7_21_01_07\packages\ti\xdais

    4. Added alg_malloc.c and alg_create.c (located in g711\ti\sdo\codecs\g711aenc\app\Client\Test\Src) to the project.  But when I tried to build, I got an error for a missing header file, alg.h, which I couldn't find anywhere, so I created my own.  It has these lines, and you need to add its location to the include search path:

    typedef IALG_Handle ALG_Handle;

    Content of missing alg.h:

    #ifndef ti_sdo_ce_alg_ALG_
    #define ti_sdo_ce_alg_ALG_

    #include <ialg.h>

    typedef IALG_Handle ALG_Handle;


    extern ALG_Handle ALG_create(IALG_Fxns *fxns, IALG_Handle p, IALG_Params *prms);
    extern Void ALG_delete(ALG_Handle alg);

    #endif

    5. I changed the compiler options to build elf fomat (Under C6000 Compiler -> Runtime Model Options, change coffabi to elfabi in the "Application binary interface" dropdown box)

    7. Add the codec library and path to the link options (Project Build Options -> C6000 Linker -> File Search Path)

    After doing all that, I was able to build a .out file.  I didn't try to run it, though.

    Best regards,

        Janet

    Report Abuse
    • Reply
    You have posted to a forum that requires a moderator to approve posts before they are publicly available.
  • Joseph Zolyak
    Posted by Joseph Zolyak
    on Jul 20 2012 10:13 AM
    Intellectual470 points

    According to the following TI wiki page:

         http://processors.wiki.ti.com/index.php?title=RTSC_Codec_And_Server_Package_Wizards

    there should be some sort of RTSC Codec Package Wizard that was used to create the packages found in c64xplus_g711_2_00_000_production. Likewise there should be some sort of RTSC Server Package Wizard to "consume" the package and enable the user to build a project with these files. The neither the Release Notes or User's Guide for g711adec, g711aenc, g711udec, or g711uenc have any instructions on which tool to use, or how to use the tool to build the test application.

    I have the following version of software tools installed:

         CCSv5 = 5.1.0.08020, BIOS = 6.32.04.49, XDCTOOLS = 3.22.03.41, XDAIS  = 7.21.01.05

    Under the Project tab in CCSv5.1, I selected  "Import Existing CCS/CCE Eclipse Project".  The tools ask you to enter a  "Select search-directory:"   Starting at:

         C:\Program FIles (x86)\c64xplus_g711_2_00_000_production

    and working my way down through each subdirectory, CCSv5 could not find a project to open. I had hoped the CCSv5.1 would have had the proper tool to recognise TI's own packaged up software, but it looks like it doesn't.  It seems like I need some sort of other wizard to prep the package before it can be used.

    So I am back to asking the same question again.  Which tool(s) do I need and what are the steps  that I have to follow so that I can create and build a test application in CCSv5 using g711 package contents found in c64xplus_g711_2_00_000_production.

    XDM C6747 C6748 CCSv5 G.711 codec RTSC XDC Tools
    Report Abuse
    • Reply
    You have posted to a forum that requires a moderator to approve posts before they are publicly available.
  • janet
    Posted by janet
    on Jul 20 2012 11:52 AM
    Expert5315 points

    Joseph,

    This FAQ explains the GenAlg wizard.  This wizard generates packaging needed for distributing XDM compliant algorithms:

    http://processors.wiki.ti.com/index.php/XDM_GenAlg_Wizard_FAQ

    If your codec is going to be consumed by Codec Engine, then you should use GenCodecPkg:

    http://processors.wiki.ti.com/index.php/Codec_Engine_GenCodecPkg_Wizard_FAQ

    Best regards,

        Janet

    Report Abuse
    • Reply
    You have posted to a forum that requires a moderator to approve posts before they are publicly available.
  • Joseph Zolyak
    Posted by Joseph Zolyak
    on Jul 20 2012 13:53 PM
    Intellectual470 points

    Hello Janet,

    You still haven't answered my question. I have already been two both wiki pages, and neither page provides enough information on how to "consume" a package.

    Likewise, on the Codec Engine wiki it says:

         "If you intend your algorithm to be consumed by Codec Engine, GenCodecPkg is recommended. If you know your algorithm will never run within the Codec Engine framework, you can use GenAlg to avoid any Codec Engine dependencies."

    When you follow the instructions under XDM_GenAlg_Wizard_FAQ (for either CCS tools or Batch File), a GUI window appears.  Your only choice is to build a package, not extract  information from a package so that you can build a project.

    XDM C6747 C6748 CCSv5 G.711 codec RTSC
    Report Abuse
    • Reply
    You have posted to a forum that requires a moderator to approve posts before they are publicly available.
  • janet
    Posted by janet
    on Jul 20 2012 14:57 PM
    Expert5315 points

    Joseph,

    One option is to include the codec header files in your source code, and link the codec library into your application.  That is how the g711 test is consuming the codec.

    Another option, if you're building a codec engine server, for example, is to add 'xdc.useModule('your codec module') to your server's configuration file.  (To do this, you would need to have used the GenCodecPkg wizard to package your codec.)  This is how your codec engine server consumes the codec.  For example, to consume the g711aenc codec in this manner, you would add the following line to your .cfg file:

        xdc.useModule('ti.sdo.codecs.g711aenc.G711AENC');

    A third option, if you're not using codec engine but still have a RTSC configuration file, you can consume your codec package by adding

        xdc.loadPackage('your codec package')

    to your configuration file.  This will cause the codec library to be linked into your application.  For example

        xdc.loadPackage('ti.sdo.codecs.g711anc');

    You can find more information on the RTSC packaging of codecs here if you are interested:

    http://processors.wiki.ti.com/index.php/XDC_packaging_an_add-on_library

    Best regards,

        Janet

    Report Abuse
    • Reply
    You have posted to a forum that requires a moderator to approve posts before they are publicly available.
  • Joseph Zolyak
    Posted by Joseph Zolyak
    on Jul 24 2012 14:10 PM
    Intellectual470 points

    Hello,

    I followed a footnote from your posted wiki page which led me to:

         http://rtsc.eclipse.org/docs-tip/RTSC_Packaging_Primer/Lesson_0

    This filled in one of the missing pieces to this puzzle. According to this primer, the producer of an RTSC package is responsible for providing 3 files: package.xdc, package.bld, and package.cfg.  The c64xplus_g711_2_00_00_000_production is missing the .cfg necessary to build the g711aenc package (or any of the other encoder or decoders for that matter).  I mistakenly got side tracked into thinking that the unpackaging tool created this file. It does not.

    I went back and created a new project per your instructions of July 19th. When I build the project I end up with the same error that I reported two weeks ago:

         This project does not contain a buildable RTSC Configuration (.cfg) file. In order for it to build, this project must contain one RTSC Configuration file that is not excluded from build.    g711aenc        g711aenc    TI Problem Marker

    I need assistance obtaining the missing .cfg file that should have been part of the deliverable codec package.



    XDM C6747 C6748 CCSv5 G.711 codec RTSC
    Report Abuse
    • Reply
    You have posted to a forum that requires a moderator to approve posts before they are publicly available.
  • janet
    Posted by janet
    on Jul 24 2012 15:15 PM
    Expert5315 points

    Joseph,

    I think that the g711 package contains all the necessary files.  The error message indicates that the project you are trying to build is missing a .cfg file.  This could have happened if you based your project on the SYS/BIOS hello example, and then removed the hello.cfg from your project.

    When you attempted to follow my instructions for building the test encoder (the July 19 post), did you start by creating a new Project based on an Empty CCS project (not the SYS/BIOS or Empty RTSC project)?  Here is the one I used:

    When you create this project, you should just have a main.c.  There are no .cfg files.  You should be able to build the project at this point.  Now, if you want to build the g711aenc test app (in the g711aenc 2.00.00.000 zip file)  you first replace main.c in this project with

        ti\sdo\codecs\g711aenc\app\Client\Test\Src\g711Encodermain.c

    If you attempt to build now, you will get errors such as the ones you encountered in your first post (can't find header files, etc).  You should not get a missing .cfg file error, just by replacing main.c with g711Encodermain.c  Now, you can continue with the instructions from my July 19 post, and get your project to build.  You will also need to remove the line:

    #include <_alg.h>

    from the file alg_create.c.  This file is missing, but whatever was in it did not seem to be used anyway.  This step is missing from the July 19 instructions.

    Best regards,

        Janet

    Report Abuse
    • Reply
    You have posted to a forum that requires a moderator to approve posts before they are publicly available.
  • janet
    Posted by janet
    on Jul 24 2012 15:19 PM
    Expert5315 points

    Sorry, my picture didn't show up in the post.  I picked the "Empty Project" from the "Empty Projects" list.

    Best regards,

        Janet

    Report Abuse
    • Reply
    You have posted to a forum that requires a moderator to approve posts before they are publicly available.
123
TI E2E™ Community
  • Support Forums
  • Blogs
  • Videos
  • Groups
  • Site Support & Feedback
  • Settings
TI E2E™ Community Groups
  • TI University Program
  • Make the Switch
  • Microcontroller Projects
  • Motor Drive & Control
Other Communities
  • Deyisupport
  • Designsomething.org
  • beagleboard.org
  • TI on Element 14
  • TI on TechXchangeSM
Other Technical & Support Resources
  • WEBENCH® Design Center
  • Product Information Centers
  • Technical Documents
  • TI Design Network
  • TI Technical Articles
  • TI Training

All content and materials on this site are provided "as is". TI and its respective suppliers and providers of content make no representations about the suitability of these materials for any purpose and disclaim all warranties and conditions with regard to these materials, including but not limited to all implied warranties and conditions of merchantability, fitness for a particular purpose, title and non-infringement of any third party intellectual property right. TI and its respective suppliers and providers of content make no representations about the suitability of these materials for any purpose and disclaim all warranties and conditions with respect to these materials. No license, either express or implied, by estoppel or otherwise, is granted by TI. Use of the information on this site may require a license from a third party, or a license from TI.

Content on this site may contain or be subject to specific guidelines or limitations on use. All postings and use of the content on this site are subject to the Terms of Use of the site; third parties using this content agree to abide by any limitations or guidelines and to comply with the Terms of Use of this site. TI, its suppliers and providers of content reserve the right to make corrections, deletions, modifications, enhancements, improvements and other changes to the content and materials, its products, programs and services at any time or to move or discontinue any content, products, programs, or services without notice.

Follow Us Texas Instruments on Facebook Texas Instruments on Twitter Texas Instruments on LinkedIn Texas Instruments on Google+
TI Worldwide | Contact Us | my.TI Login | Site Map | Corporate Citizenship | mobile m.ti.com (Mobile Version)

TI is a global semiconductor design and manufacturing company. Innovate with 100,000+ analog ICs and
embedded processors, along with software, tools and the industry’s largest sales/support staff.

© Copyright 1995-2013 Texas Instruments Incorporated. All rights reserved.
Trademarks | Privacy Policy | Terms of Use