• 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 » BIOS » BIOS forum » ECU can't work
Share
BIOS
  • Forum
  • Announcements
Options
  • Subscribe via RSS

Forums

ECU can't work

This question is answered
golden tiger
Posted by golden tiger
on Jul 05 2012 00:09 AM
Intellectual615 points

Hi  Charlie,

I  have  tried  the manner   you  said.   The  sout_buffer  is still same as  sin_buffer.  

While the code is running, I can see that there is no data being put into the Far-end expanded delay line  and that the Foreground Filter segment coefficients are not updating.  

I  see that  ecuContext.expand_ptr   is not   updating.   The value is always 0xB700409E  and ecuContext.rxout_buf_base  is 0xB7004000.

The ecuContext.pack_ptr  is updating.

Can you tell me  how   Far-end delay line  is  expanded   to   Far-end expanded delay line  by  pcm_expand_tbl ?

I  have allocated all the memory as requested by the ecuGetSizes function and confirmed the correct  size and allignment on the memory blocks I pass into ecuNew.

I  doubt   whether   ECU  is  compatible  with  C674  dsp  or  C6A816x  platform.  It  is possible that  a bug exist  when  ECU  is used  in  C674 or C6A816x platform.

Regards,

Tiger

ECU volib c674 c6a8168
Report Abuse
  • Reply
You have posted to a forum that requires a moderator to approve posts before they are publicly available.
All Replies
  • CharlieF
    Posted by CharlieF
    on Jul 16 2012 10:30 AM
    Verified Answer
    Verified by golden tiger
    Intellectual1535 points

    Hi Tiger,

    The ECU should be fully compatible with the C674x device, provided you are using the C64x+ ECU library and the endian-ness is correct.

    How are you packing the PCM samples before sending to the ECU?  Can you attach the code you are using?  Until we see this working properly, it is no use looking anywhere else.

    Please pardon me if this is a repeat question, but what do the samples in the delay line look like when you pass in a constant value (e.g., packed PCM zeros = 0xFFFF for u-law and 0x5555 for a-law)?

    Regards,
    Charlie

     

     

    VoLIB ECU
    Report Abuse
    • Reply
    You have posted to a forum that requires a moderator to approve posts before they are publicly available.
  • Jean-Denis Boyer
    Posted by Jean-Denis Boyer
    on Jul 18 2012 21:55 PM
    Verified Answer
    Verified by golden tiger
    Prodigy235 points

    Hello.

    I am also trying to use the ECU module on the C674x of an OMAP-L138 without any success yet. I am using CCSv5.1.1.

    I've checked to be sure the data are given correctly, that is:

    void ecuSendIn (void *ecuInst, void *vsend_in, void *vrecv_in, void *vsend_out);

    The input vsend_in are PCM linear samples, while the recv_in are a-law samples packed on 8-bits words.

    To answer your question about what the delay line looks like, here is the answer.

    First, if I look into the "Far-end delay line" buffer, which in my case is 592 bytes, I see correctly packed a-law PCM samples. Using the Memory Browser (Hex 16 Bit), I see the following:

    5555 5555 5555 5555 5555 5555 5555 5555 5555 5555 5555 5555 5555 5555 5555 5555
    5555 5555 5555 5555 5555 5555 5555 5555 5555 5555 5555 5555 5555 5555 5555 5555
    5555 5555 5555 5555 5555 5555 5555 5555 D5D5 D5D5 D5D5 D5D5 D5D5 D5D5 D5D5 D5D5
    D5D5 D5D5 D5D5 D5D5 D5D5 D5D5 D5D5 55D5 5555 5555 5555 5555 D5D5 D5D5 D5D5 D5D5
    D5D5 D5D5 D5D5 D5D5 D5D5 D5D5 D5D5 D5D5 D5D5 D5D5 D5D5 D5D5 D5D5 D5D5 D5D5 D5D5
    [...]

    Well, the phone line is silent, so they're all silence patterns. Nothing more to say... BUT, just after the execution of ecuSendIn, if I look into the volatile "Far-end expanded delay line" buffer, it is not what I expected to see. It may be normal, tough, you tell me. Here is what the Memory Browser (16 Bit Signed Integer) gives me:

    -8 -5504 -8 -5504 -8 -5504 -8 -5504
    -8 -5504 -8 -5504 -8 -5504 -8 -5504
    -8 -5504 -8 -5504 -8 -5504 -8 -5504
    -8 -5504 -8 -5504 -8 -5504 -8 -5504
    [...]

    Which is the expansion of 0x55 and 0x00 !!! Is this normal?

    Regards,

    Jean-Denis

     

    VoLIB ECU
    Report Abuse
    • Reply
    You have posted to a forum that requires a moderator to approve posts before they are publicly available.
  • CharlieF
    Posted by CharlieF
    on Jul 19 2012 10:38 AM
    Verified Answer
    Verified by David Friedland
    Intellectual1535 points

    Hi Jean-Denis,

    Can you try building and running the unit test project that comes with the delivery?  Detailed directions for ECU unit test (simulation) are linked from the VoLIB User Manual.

    Please let me know if this works correctly for you -- I just re-verified that it is working on my end.

    Charlie

    Report Abuse
    • Reply
    You have posted to a forum that requires a moderator to approve posts before they are publicly available.
  • Jean-Denis Boyer
    Posted by Jean-Denis Boyer
    on Jul 19 2012 15:11 PM
    Verified Answer
    Verified by golden tiger
    Prodigy235 points

    Hi Charlie.

    Yes, it works! I've looked at the resulting sout.pcm and the echo is clean compared to sin.pcm.

    Actually, this give me some input to compare with my implementation.

    So I'll continue my investigations. More info later...

    Thanks for your help.

    Jean-Denis

    Report Abuse
    • Reply
    You have posted to a forum that requires a moderator to approve posts before they are publicly available.
  • CharlieF
    Posted by CharlieF
    on Jul 19 2012 15:29 PM
    Verified Answer
    Verified by golden tiger
    Intellectual1535 points

    Hi Jean-Denis,

    Great!  Let me know if I can help you narrow things down. 

    By the way -- did you run on C674x or C64x+?

    Charlie

    VoLIB ECU
    Report Abuse
    • Reply
    You have posted to a forum that requires a moderator to approve posts before they are publicly available.
  • golden tiger
    Posted by golden tiger
    on Jul 27 2012 09:12 AM
    Verified Answer
    Verified by golden tiger
    Intellectual615 points

    Hi  Charlie,


    1. I  test the EUC unit  test project  by CCS  and  the test project can  cancel echo.  It means that ECU can work  in C674.


    2. I pack the PCM samoles in the following manner:

        linSample rinLinear[N];
        tint      rinCompr[N];
        tword     rinBuffer[N];
        tint length = N;
        tint i;
       
        /* Compress U-law delay line samples */
        muaTblUlawCmpr (length, rinLinear, rinCompr);

        /* Pack samples for delay line compression */
        for (i=0; i<length; i++) {
          rinBuffer[i] = rinCompr[i] & 0xFF;
        }

    3.  I  set all rinBuffer  value to 0xFF.

        The delay line data:

        0 -32124 0 -32124 0 -32124 0 -32124 0 -32124 0 -32124 0 -32124 0 -32124 0 -32124 0 -32124
        0 -32124 0 -32124 0 -32124 0 -32124 0 -32124 0 -32124 0 -32124 0 -32124 0 -32124 0 -32124
        0 -32124 0 -32124 0 -32124 0 -32124 0 -32124 0 -32124 0 -32124 0 -32124 0 -32124 0 -32124
        0 -32124 0 -32124 0 -32124 0 -32124 0 -32124 0 -32124 0 -32124 0 -32124 0 -32124 0 -32124
        0 -32124 0 -32124 0 -32124 0 -32124 0 -32124 0 -32124 0 -32124 0 -32124 0 -32124 0 -32124
        0 -32124 0 -32124 0 -32124 0 -32124 0 -32124 0 -32124 0 -32124 0 -32124 0 -32124 0 -32124

        Why -32124 exist in expand delay line?   I think that the delay line should be all 0.

    4.  If  ecu_ENABLE_NLP  is  enabled,   the all soutBuffer  value  is  always  0  whatever   rinBuffer   and sinBuffer  value is. 

    5. In ECU test project,  the  PIU  and sgn   is used.  But  is necessary   PIU  and sgn  ???

      

    Report Abuse
    • Reply
    You have posted to a forum that requires a moderator to approve posts before they are publicly available.
  • golden tiger
    Posted by golden tiger
    on Jul 31 2012 08:45 AM
    Verified Answer
    Verified by golden tiger
    Intellectual615 points

    Hi Charlie,

    1.  If   I   add  my own ECU code  to ECU test project   and  CCS  is  used,   and  the ECU  can cancel  echo.  

         But  I  only  use my ECU code in my own project  and CCS  is not used,  ECU  can't  cancel  echo.

         I  use ECU test project code  to my own project   and  CCS  is  not  used,  ECU   can't  also  cancel echo.

    Why  ECU  can't  cancel  echo  when CCS  project  in ECU test project  is not used ???

    2.  When  ECU can't  cancel  echo, I  set all rinBuffer  value to 0xFF.

        The delay line expand buffer data:

        0 -32124 0 -32124 0 -32124 0 -32124 0 -32124 0 -32124 0 -32124 0 -32124 0 -32124 0 -32124
        0 -32124 0 -32124 0 -32124 0 -32124 0 -32124 0 -32124 0 -32124 0 -32124 0 -32124 0 -32124
        0 -32124 0 -32124 0 -32124 0 -32124 0 -32124 0 -32124 0 -32124 0 -32124 0 -32124 0 -32124
        0 -32124 0 -32124 0 -32124 0 -32124 0 -32124 0 -32124 0 -32124 0 -32124 0 -32124 0 -32124
        0 -32124 0 -32124 0 -32124 0 -32124 0 -32124 0 -32124 0 -32124 0 -32124 0 -32124 0 -32124
        0 -32124 0 -32124 0 -32124 0 -32124 0 -32124 0 -32124 0 -32124 0 -32124 0 -32124 0 -32124

    Why -32124 exist in expand delay line?   I think that the expand delay line should be all 0.

     

    Report Abuse
    • Reply
    You have posted to a forum that requires a moderator to approve posts before they are publicly available.
  • golden tiger
    Posted by golden tiger
    on Aug 01 2012 08:10 AM
    Verified Answer
    Verified by golden tiger
    Intellectual615 points

    Hi Charlie,

    I   new  a  CCS  project  and  add  my  own  ECU code to  the new project.   The  project  can   cancel  echo.

    But   the  ECU  can't  cancel  echo  when  I  add the  code  to   EZSDK(5_02_02_60).

    Did you test  ECU  in EZSDK  when CCS  is not used ?

    I run  AER lib, G.729 lib  in EZSDK  and they  can work  good.     I  get  these  lib  from TI.

    Why  my ECU code can  work in CCS  and can't  work  in EZSDK ?

    Report Abuse
    • Reply
    You have posted to a forum that requires a moderator to approve posts before they are publicly available.
  • Jean-Denis Boyer
    Posted by Jean-Denis Boyer
    on Aug 09 2012 15:38 PM
    Verified Answer
    Verified by golden tiger
    Prodigy235 points

    Hi Charlie,

    I managed to have the ECU work! And this is a library issue... There seems to be 3 libraries related to the ecu: "ecu_a, ecu_c, ecu_cm". The third one (ecu_cm) should not be present in the link.

    When I created the project with CCSv5, and added VoLIB and the ECU, it automatically added the 3 libraries to the file "linker.cmd". If I manually remove "ecu_cm" and re-link, the ecu works!

    We all noticed that in the delay line expansion buffer, there was 1 sample out of 2 which was invalid. Then, I used the test case from the ecu library, and injected the exact same data, and the delay line expansion worked correctly. I begun to disassemble the library function "ecu_dline_expand_seg", and it did the job in the test case, but in my program, the disassembly showed a completely different implementation. This function is present in 2 of the 3 libraries, and apparently, it took the wrong one.

    So, my question is obvious: "What is the purpose of library "ecu_cm", why does CCS add it in the link, and how can I remove it?"

    Regards,

    Jean-Denis Boyer

     

    Report Abuse
    • Reply
    You have posted to a forum that requires a moderator to approve posts before they are publicly available.
  • CharlieF
    Posted by CharlieF
    on Aug 09 2012 16:03 PM
    Verified Answer
    Verified by golden tiger
    Intellectual1535 points

    Jean-Denis,

    Thank you for delving deep into this and (hopefully) solving the underlying problem. 

    The "ecu_cm" library should not be linked in a production build.  This is the "C model" library which we use as a model for creation of  the "a" (assembly code) library.  My guess, before looking, is that the C model code hasn't been updated properly from C55x to C6x.

    I will try to recreate this locally and respond to all with my findings.

    Regards, Charlie

     

    VoLIB ECU
    Report Abuse
    • Reply
    You have posted to a forum that requires a moderator to approve posts before they are publicly available.
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