Filter component does nothing

Tip / Sign in to post questions, reply, level up, and achieve exciting badges. Know more

cross mob
lock attach
Attachments are accessible only for community members.
Anonymous
Not applicable

Hello there, i am working on a project where a filter is needed. This filter is implemented in PSOC.

   

I am feeding the filter with a DMA, and using the output to set a PWM module, using the CPU.

   

I get a output almost similar to the input, except it is a bit small (also at DC). The filter is a RIAA filter. 

   

What can i have done wrong?

   

Project is attached.

0 Likes
5 Replies
Bob_Marlowe
Level 10
Level 10
First like given 50 questions asked 10 questions asked

At very first sight: You are probably not able to handle 44100 interrupts per second.

   

    CyDmaTdSetConfiguration(tdChanA, 3u, tdChanA, CY_DMA_DISABLE_TD);

   


I am not very fit with PSoC5 DMA, but doesn't the above mean to cease the DMA after the current TD finishes? I feel like best would be to repeat with tdChanA forever.

   

 

   

Bob

0 Likes
Anonymous
Not applicable

You might be right about the DMA, i had a hard fight getting it to work, i will look into it.

   

Is the DMA faster than the interrupt? In that case i will try to use DMA for both filter input and output.

0 Likes
Bob_Marlowe
Level 10
Level 10
First like given 50 questions asked 10 questions asked

DMA is faster but more complicated getting it to work. 😉

   

 

   

Bob

0 Likes
lock attach
Attachments are accessible only for community members.
Anonymous
Not applicable

I have gotten both the filter input and the output to work with DMA. It works but i am not certain that there is not any errors. 

   

The filter does still not work. If anyone is able to help me out with this, i will appreciate.

   

The updated version with both DMA's is attached.

0 Likes
odissey1
Level 9
Level 9
First comment on KBA 1000 replies posted 750 replies posted
        Check filter demo projects exemplifying DMA in/out from Filter https://www.hackster.io/bmah/psoc-5lp-16-bit-and-24-bit-digital-filter-code-examples-ddcf9c   
0 Likes