AnsweredAssumed Answered

[Error li1021]  audio example

Question asked by ivan@@ivan on Sep 14, 2012
Latest reply on Sep 17, 2012 by CraigG

Hi,

 

I'm working on the Audio_Loopback example on BF548 and I'm trying to define the AD1980Callback function in a different file.

I get the following linker error:

 

[Error li1021]  The following symbols referenced in processor 'p0' could not be resolved:

        'AC97RegAccessComplete [_AC97RegAccessComplete]' referenced from '.\Debug\f_audio.doj'

        'AC97RegAccessComplete [_AC97RegAccessComplete]' referenced from 'Audio_Loopback.doj'

        'InboundBuffer0 [_InboundBuffer0]' referenced from '.\Debug\f_audio.doj'

        'InboundBuffer0 [_InboundBuffer0]' referenced from 'Audio_Loopback.doj'

        'InboundBuffer1 [_InboundBuffer1]' referenced from '.\Debug\f_audio.doj'

        'InboundBuffer1 [_InboundBuffer1]' referenced from 'Audio_Loopback.doj'

        'InboundData0 [_InboundData0]' referenced from '.\Debug\f_audio.doj'

        'InboundData0 [_InboundData0]' referenced from 'Audio_Loopback.doj'

        'InboundData1 [_InboundData1]' referenced from '.\Debug\f_audio.doj'

        'InboundData1 [_InboundData1]' referenced from 'Audio_Loopback.doj'

        'OutboundData0 [_OutboundData0]' referenced from '.\Debug\f_audio.doj'

        'OutboundData0 [_OutboundData0]' referenced from 'Audio_Loopback.doj'

        'OutboundData1 [_OutboundData1]' referenced from '.\Debug\f_audio.doj'

        'OutboundData1 [_OutboundData1]' referenced from 'Audio_Loopback.doj'

 

Linker finished with 1 error

 

I've defined it as follows,

Header file:

#pragma once

#ifndef   _F_AUDIO_H

#define  _F_AUDIO_H

#include <cdefBF548.h>

#include <ccblkfn.h>

#include <sys/exception.h>

#include <drivers/adi_dev.h>

#include <sys/exception.h>

#include <drivers/codec/adi_ad1980.h>

#pragma section ("L1_code")

extern void AD1980Callback(void *AppHandle,u32 Event,void *pArg);

extern ADI_DEV_1D_BUFFER InboundBuffer0,InboundBuffer1;

extern volatile u8 AC97RegAccessComplete;

extern section ("InboundAudio")  u16 InboundData0 [BUFFER_SIZE_PER_CHANNEL * NUM_ADC_CHANNELS];

extern section ("InboundAudio")  u16 InboundData1 [BUFFER_SIZE_PER_CHANNEL * NUM_ADC_CHANNELS];

extern section ("OutboundAudio") u16 OutboundData0[BUFFER_SIZE_PER_CHANNEL * NUM_DAC_CHANNELS];

extern section ("OutboundAudio") u16 OutboundData1[BUFFER_SIZE_PER_CHANNEL * NUM_DAC_CHANNELS];

#endif

 

C file (f_audio.c):

#include "f_audio.h"

#include <cdefBF548.h>

#include <ccblkfn.h>

#include <sys/exception.h>

#include <drivers/adi_dev.h>

#include <sys/exception.h>

#include <drivers/codec/adi_ad1980.h>

 

void AD1980Callback( void *AppHandle,          u32  Event,          void *pArg)

{

     \\ function without changes from original file

}

 

Any ideas?

Much appreciated

Outcomes