Hi Krishna,
Can you show us line numbers and also what is in second.h? I copied
this source into CCS and it only got to line 133 so where are the rest
of the lines where the warnings are for?
Al
--- In c..., "krishna_h_aries" wrote:
>
> Hi everyone..
> my name is Krishna.. from ITB (Indonesia..)
> I make ANC, and confuse bout the warning of my program...
> //FXLMS control
>
> #include
> #include
> #include
> #include "DSK6713_AIC23.h" //codec-DSK
> support file
> #include "second.h"
> //float S[128]
> #include "FXLMS_ctrlcfg.h"
>
> Uint32 fs=DSK6713_AIC23_FREQ_8KHZ; //set sampling rate
>
> #define LEFT 0 //left
> channel
> #define RIGHT 1 //right
> channel
> #define GAIN_IN 10
> #define GAIN_OUT 10
> #define jum_orde 128
> #define jum_orde_identifikasi 128
> #define BUFFER_MAX 128
> #define LOOP_MAX 60000
> #define SKALA 32768
> #define miu 0.0007
> //miunya dibikin 2 yah?? miu W sm miu S??
> #define besar 128 // the
> biggest between jum_orde & jum_orde_identifikasi!!!
>
> float x[besar];
> float W[jum_orde];
> float signal_out=0;
> float y=0,antinoise=0;
> float x[besar];
> float W[jum_orde];
> float x_bar[besar];
> float refference_mic=0, error_mic=0;
>
> short output_buff[LOOP_MAX], refference_buff[LOOP_MAX],
> error_buff[LOOP_MAX];
>
> short output=0;
> //short output_buff[LOOP_MAX], error_buff[LOOP_MAX],
> refference_buff[LOOP_MAX];
>
> int i=0,orde_besarsar,l=0,loop=0;
>
> volatile union{unsigned int uint; short channel[2];}AIC23_data;
>
> void init_var()
> {
> for(i=0;i
> {
> x[i]=0;
> x_bar[i]=0;
> }
> for(i=0;i
> W[i]=0;
> for(i=0;i
> {
> output_buff[i]=0;
> error_buff[i]=0;
> refference_buff[i]=0;
> }
> }
>
> void kendali(float input_sig, float error_sig)
> {
> for(i=orde_besar-1;i>0;i--)
> x[i]=x[i-1];
>
> x[0]=input_sig;
>
> for(i=orde_besar-1;i>0;i--)
> x_bar[i]=x_bar[i-1];
>
> x_bar[0]=0;
>
> for(i=0;i
> x_bar[0]=x_bar[0]+S[i]*x[i];
>
> y=0;
> for(i=0;i
> y=y+W[i]*x[i];
>
> antinoise=y;
>
> for(i=0;i
> W[i] = W[i] - miu*x_bar[i]*error_sig;
> }
>
> interrupt void c_int11()
> {
> signal_out = antinoise*GAIN_OUT*SKALA;
> output=((short)signal_out);
> output_sample(output);
>
> output_buff[loop]=output;
>
> AIC23_data.uint = input_sample()*GAIN_IN; //input 32-bit from
> both channels
> refference_mic = (AIC23_data.channel[LEFT]);
> error_mic =(AIC23_data.channel[RIGHT]);
> refference_buff[loop]=refference_mic;
> error_buff[loop]=error_mic;
> if (l < jum_orde_identifikasi) ++l;
> else l=0;
>
> if(loop>20000){
> kendali(refference_mic/SKALA,error_mic/SKALA);
> }
> if (loop < LOOP_MAX)
> loop++;
> else{
> puts("Finish!!!\n");
> exit(1);
> }
> return;
> }
>
> void main()
> {
> init_var();
> comm_intr();
> while(1);
> }
>
> it result some warning...
> --------------------------- FXLMS_ctrl.pjt - Debug -----------------
> ----------
> [FXLMS_ctrl.c] "C:\CCStudio_v3.1\C6000\cgtools\bin\cl6x" -g -
> fr"C:/CCStudio_v3.1/MyProjects/FXLMS_ctrl/Debug" -d"CHIP_6713" -mv6710
> --mem_model:data -@"Debug.lkf" "FXLMS_ctrl.c"
> "C:/CCStudio_v3.1/c6000/bios/include/std.h", line 140: warning:
> typedef name has already been declared (with same type)
> "C:/CCStudio_v3.1/c6000/bios/include/std.h", line 143: warning:
> typedef name has already been declared (with same type)
> "C:/CCStudio_v3.1/c6000/bios/include/std.h", line 146: warning:
> typedef name has already been declared (with same type)
> "C:/CCStudio_v3.1/c6000/bios/include/std.h", line 151: warning:
> typedef name has already been declared (with same type)
> "C:/CCStudio_v3.1/c6000/bios/include/std.h", line 161: warning:
> typedef name has already been declared (with same type)
> "C:/CCStudio_v3.1/c6000/bios/include/std.h", line 165: warning:
> typedef name has already been declared (with same type)
>
> [Linking...] "C:\CCStudio_v3.1\C6000\cgtools\bin\cl6x" -@"Debug.lkf"
> Build Complete,
> 0 Errors, 6 Warnings, 0 Remarks.
> I'm using DSP/BIOS config, like the book Rulp Chassaing "Digital
> Signal Processing and Applications with the C6713 and C6416 DSK" teach
> in chapter 9...
>
> I just confuse, why there is some warning like that..
> thank u for u help..
> I'm very appreciate that... ^o^
>