开发者

circular array in c for a delay line

开发者 https://www.devze.com 2023-02-04 09:24 出处:网络
I\'m trying to find any resources online for programming a delay line in c. I tried implementing this one here

I'm trying to find any resources online for programming a delay line in c.

I tried implementing this one here

https://ccrma.stanford.edu/~jos/doppler/Variable_Delay_Line_Software.ht开发者_Go百科ml.

The problem with this is where it says

A[wptr++] = x; 

The compiler throws an error because wptr is a pointer and not an integer.

Could somebody point me toward an example of a compiler friendly example?


Replace:

    A[wptr++] = x; 
y = A[rptr++];

with:

    *(wptr++) = x;
y = *(rptr++);


this should be:

*(wptr++) = x;
0

精彩评论

暂无评论...
验证码 换一张
取 消

关注公众号