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.

Overhead due to probe points

Hello,

Its me again. I am designing a simple FIR filter implementation using the C6748 DSP and the BIOS platform. The idea is to load filter coefficients based on selections of the DIP switches which is done in a PRD at 1Hz, the audio samples are read in an interrupt which also contains the FIR code. The strange problem I face is that when ever I try to read in data using probe points (be it a single number), I loose output from the audio port. However, if I don't use the probe point and keep the same code, the audio is looped back (for testing purposes). I wanted to know what is the overhead incurred due to using probe points for inputting data. I have attached the code to show the place I have inserted the probe points. Thank you very much.

//---------------------------------------------------------
// main.c
//---------------------------------------------------------
#include "alllabcfg.h"			//BIOS include file
#include "framework.h"

#define N 147
void dataIO(void);


//Variables
uint8_t sel=255;
uint32_t dip_stat;

//Arrays for holding the filter coefficients and the input samples from both channels
float h[N]; //4*147=588 bytes
float x[2][N]; //1176 bytes

//Pointers for the circular buffer
int8_t pt_cur=0,pt_conv=0;


//---------------------------------------------------------
//---------------------------------------------------------
void main(void)
{
	uint8_t i;
	for(i=0;i<N;i++)
	{
		x[0][i]=0;
		x[1][i]=0;
		h[i]=0;
	}
	initAll();				
	return;  		// return to BIOS scheduler
}


//---------------------------------------------------------
//---------------------------------------------------------
void dipPRD(void)					
{
	uint8_t dip_status8;
	uint32_t dip_stat_prev;
	
	DIP_getAll(&dip_stat);
	DIP_get(DIP_8, &dip_status8);
	if(dip_status8)
	{
		LED_turnOn(LED_2);
		sel=1;
		
	}
	else 
	{
		LED_turnOff(LED_2);
		//sel=0;
	}
	dip_stat_prev=dip_stat;
	//printf("The DIP switch status is read to be %c",dip_status8);
	dip_stat=(255-dip_stat)&0x0000000F;
	if(dip_stat!=dip_stat_prev)
	{
	if(dip_stat==1|dip_stat==2|dip_stat==3) 
	sel=255;
	else if(dip_stat==9) 
	sel=2;
	else if(dip_stat==13) 
	sel=3;
	else if(dip_stat==10) 
	sel=5;
	else if(dip_stat==14) 
	sel=6;
	else if(dip_stat==11) 
	sel=8;
	else if(dip_stat==15) 
	sel=9;
	else 
	sel=255;
	dataIO();//Put probe point for data input here
	sel=10;//a dummy value to make sure the multiplcation loop is executed
}
	
}


//---------------------------------------------------------
//---------------------------------------------------------
void audioHWI(void)
{
	uint8_t i;
	uint32_t s,out;
	uint16_t sl,sr,outr,outl;
	float output_left=0,output_right=0;

	s = read_audio_sample();
	if(sel!=1)
	{
	sl=(uint16_t)(s>>16);
	sr=(uint16_t)s;
	x[0][pt_cur]=(float)sl;
	x[1][pt_cur]=(float)sr;
	pt_conv=pt_conv;
	
	for(i=0;i<31;i++)
	{
	output_left=output_left*output_left;//Test multiplications to check how many can be performed 
										// in a single interrupt
		//output_left+=h[i]*x[0][pt_conv];
		//output_right+=h[i]*x[1][pt_conv];
		pt_conv--;
		if(pt_conv==-1)pt_conv=(N-1);
	}

	pt_cur++;
	outr=(uint32_t)output_right;
	outl=(uint32_t)output_left;
	out=(uint32_t)(outl&0xFFFF0000)|(outr>>16);
	}
	write_audio_sample(s); //Loop back the audio to test the program
	
	//}
}
void dataIO()
{
	return;
}
	

  • Welcome back, Muhammad,

    The default emulation mode is called "stop mode" in which an event causes the processor to stop executing while JTAG is used for some monitoring or control. In this case, a signal must be received by the JTAG controller and CCS software indicating the event has occurred, and then CCS will do some action such as uploading memory contents or downloading data to a variable.

    The time that the DSP is halted is indeterminate, and this is a figure that we do not measure to report as a benchmark. It is not related to the direct operation of the DSP. The time depends largely on the clock speed of the JTAG clock TCK, but also on the internal speed of the JTAG controller and on the speed and loading on the PC that is running the CCS software.

    You can work out a way to measure the time, but it will likely vary depending on what is being done in CCS at that time and what is running on the PC at that time.

    A Moderator will move this thread to the Code Composer Forum for more insights, if you still need more answers.

    If this is sufficient, please mark this as Answered.

    Regards,
    RandyP