This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

Code Composer Library/out files and Time domain graph display problem

Other Parts Discussed in Thread: CCSTUDIO

Hi guys,

 

I am using Code Composer 3.1 for my final year project  and I tried to generate a random noise using Chassaing book’s , “Digital Signal Processing and Applications with the C6713 and C6416 DSK”, example of “Noise_gen”

 

When I rebuild the project the following error displayed

 

“"Noise_gen.c", line 3: fatal error: could not open source file "DSK6713_AIC23.h"

 

On my Pc “include” and “lib” files are located in C:\CCStudio_v3.1\C6000\dsk6713\include  and  C:\CCStudio_v3.1\C6000\dsk6713\lib

 

So, I use the “project build option” and added the include search path for the pre-processor section and also the Library search path for the linker.

 

The project builds successfully and I got the “Noise_gen.out” in the debug folder. However, when I load the out file to the board I couldn’t hear the noise on the mic out. Whenever I load Chassaing’s exaple of “Noise_gen.out” I can hear the noise but after rebuilding and loading the recent Noise_gen.out” I couldn’t.

Is this something to do with the library and include path? If so how can I fix it?

 

The second problem:  unable to display the right magnitude of Time domain graph

 

I used the following setup in graph property dialog to display the noise in Time domain and connected Prob point using “Noise_gen.c” on line 22 at  output_sample(prnseq)  function

 

 

Start Address -Output_sample

Acquisition buffer Size -2048

Index increment- 1

Display data size - 2048

DSP data type  - 32-bit signed integer

Sampling arte -8000

Maximum Y-value - 10,000

 

Part of the code of  Noise_gen.c

 

interrupt void c_int11()           //interrupt service routine
{
 short prnseq;                       //for pseudo-random sequence
 
 if(sreg.bt.b0)                    //sequence{1,-1}based on bit b0
prnseq = -8000;                    //scaled negative noise level
 else
prnseq = 8000;                   //scaled positive noise level
 fb  =(sreg.bt.b0)^(sreg.bt.b1);   //XOR bits 0,1
 fb ^=(sreg.bt.b11)^(sreg.bt.b13); //with bits 11,13 ->fb
 sreg.regval<<=1;                  //shift register 1 bit to left
 sreg.bt.b0 = fb;                                //close feedback path
                         
 output_sample(prnseq);                   //output scaled sequence
 return;                                     //return from interrupt

 

The out put will be either 1 or 0 and it is scaled by 80000 for display purposes.

 

So, I am expecting +8000 or -8000. However, the graph always display more of 10,000 and a couple of -10000

 

Did I miss any setup information? Why the graph displayed the maximum scale (+10000,-10000) rather than displaying 8000 or -8000?

 

Could you please advise me what I need to do to fix those problems?

 

Thanks,

Gim

 

 

  • Please refer to the Chassaing book for the detailed instructions to rebuild the supplied example code. If you cannot find any steps that have been followed incorrectly, then you may be required to compare the compiled code or some smaller parts, so that you can determine what is different between your build and that of the author.

  • Thanks Randy , I thoroughly  followed  Chassaing instructions but still the  problem persists. Do you know any program that enables me to read the two "noise_gen.out" files for comparison?

     

  • Perhaps the Chassaing program was built with an older version of the code generation tools than what you are using? Does the book include a copy of the older tools so you could try to install and use those? If not, there may be an archive of past code generation tools (may require a search of the E2E forum and tiexpressdsp.com and www.ti.com, or a new posting in the appropriate sub-forum).

    The Object File Display utility will generate a text file in XML format that you can parse for comparison of the two executable object files. It is described briefly in the Assembly Language Tools User's Guide spru186.

  • Many thanks Randy, I will try those options.