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.

6713dsk with mic in example

Other Parts Discussed in Thread: TLV320AIC23B
hello sir,
//Fir3LP.c FIR using 3 lowpass coefficients with three different BW

#include "lp600.cof"		 	    //coeff file LP @ 600 Hz 
#include "lp1500.cof"			    //coeff file LP @ 1500 Hz 
#include "lp3000.cof"			    //coeff file LP @ 3000 Hz
#include "dsk6713_aic23.h"			//codec-dsk support file
Uint32 fs=DSK6713_AIC23_FREQ_8KHZ;	//set sampling rate
#define DSK6713_AIC23_INPUT_MIC 0x0015
#define DSK6713_AIC23_INPUT_LINE 0x0011
Uint16 inputsource=DSK6713_AIC23_INPUT_MIC; // select MIC IN
short LP_number = 0; 		        //start with 1st LP filter
int yn = 0;					 	    //initialize filter's output
short dly[N];            		    //delay samples
short h[3][N];  	    			//filter characteristics 3xN

interrupt void c_int11()		    //ISR
{
	short i;
 
	dly[0] = input_left_sample();     	 //newest input @ top of buffer
	yn = 0;                          //initialize filter output
	for (i = 0; i< N; i++)
	   yn +=(h[LP_number][i]*dly[i]);//y(n) += h(LP#,i)*x(n-i)
	for (i = N-1; i > 0; i--)        //starting @ bottom of buffer
	   dly[i] = dly[i-1];            //update delays with data move
 	output_left_sample(yn >> 15);	     //output filter
 	return;				   			 //return from interrupt
}

void main()
{
 	short i;
       	for (i=0; i<N; i++)
         { 
		 dly[i] = 0;                //init buffer
  		h[0][i] = hlp600[i];  	    //start addr of LP600 coeff
   		h[1][i] = hlp1500[i];  	    //start addr of LP1500 coeff
   		h[2][i] = hlp3000[i]; 	    //start addr of LP3000 coeff
         }
    comm_intr();                    //init DSK, codec, McBSP
    while(1);    		   	    	//infinite loop
}

actually we are following rulph chassing book for dsk6713 programming. and sample programs are given in the book itself it says when input is to be captured just change code line from LINE to MIC like:
Uint16 inputsource=DSK6713_AIC23_INPUT_LINE;  //line input

to read

Uint16 inputsource=DSK6713_AIC23_INPUT_MIC;   //mic input
rest of the program is not to be altered....
we are connecting the mic to the MIC IN input of the dsk6713 kit and observing the output through loudspeakers from HEADPHONES output of the dsk kit. 
the program is working well when we are giving input from LINE IN input of the kit...
we have also tried simple voice input to same voice output program...

sir please guide through full details. If some specific type of mics or loudspeakers are to be used please mention. Also when we are giving input from LINE IN we are using simple mp3 format file and it is working properly. Sir please help with this problem and any extra suggestion would be a great help.
Thankyou

  • waiting for your response.....

    thank you

  • We are working on your post.
  • Hi,

    Thanks for your post.

    For DSK C6713, It should be TLV320AIC23B codec and it has its own register map in its codec data manual below:

    http://www.ti.com/lit/ds/symlink/tlv320aic23b.pdf

    In the above doc., please check the register details (page no. 21)

    Analog Audio Path Control (Address: 0000100) , in which kindly check D2(INSEL), D1 (MICM) & D0 (MICB). By default, MICM would be muted (set to 1), so change it to normal (set to 0) and again MICB set it to 1. Also, please ensure to select the ADC input to Microphone which needs to be set to 1 and by default, input select for ADC would be line input (0)

    INSEL Input select for ADC 0 = Line 1 = Microphone

    Also, please check the register Power Down Control (Address: 0000110), D1 bit needs to be enabled   which is the MIC Microphone input 0 = On 1 = Off. By default, it is set to Off (1) and need to turn On (0).

    Kindly take care the above manipulations and configure the codec registers accordingly in the code.

    Please refer Section 3.2.2 in the above mentioned codec data manual document for more details on microphone input circuitry. Also refer Section 3.2.6 for side tone insertion mode and usually, the TLV320AIC23B codec has a side tone insertion mode where the microphone input is routed to the line and headphone outputs.

    Thanks & regards,

    Sivaraj K

    -------------------------------------------------------------------------------------------------------

    Please click the Verify Answer button on this post if it answers your question.

    -------------------------------------------------------------------------------------------------------