DSPRelated.com
Forums

ADSP 21065L

Started by naveen s July 6, 2007
Dear Sir

I am using SHARC 21065L Processor, and VDSP4.0++ Simulator. My Querry is How to Declare a Circular Buffer of Array Size 25?, And How to call the Buffer.

with Regards
Naveen S

Send free SMS to your Friends on Mobile from your Yahoo! Messenger. Download Now! http://messenger.yahoo.com/download.php
naveen wrote:
>
> Dear Sir
>
> I am using SHARC 21065L Processor, and VDSP4.0++ Simulator. My
> Querry is How to Declare a Circular Buffer of Array Size 25?,

With the circular buffer registers, like so:

In the data section, declare the data array:

"
.VAR circular_buffer_data[25];
"

In the code section, initialize the circular buffer registers:

"
b0 = circular_buffer_data; // base address of circular buffer
l0 = length(circular_buffer_data); // length register
"

Now you can use i0 as a circular buffer index register. For example,
reading and writing can be done like this:

"
f0=dm(i0,0); // read output from circular buffer into f0
dm(i0,1) // store input f4 into circular buffer
"

This would implement a standard delay functionality.

> And How to call the Buffer.

Circular Buffer?

:-)

>
> with Regards
> Naveen S

Regards,
Andor