QN9080 DMA transfers arbitrary waveform to DAC update speed problems

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

QN9080 DMA transfers arbitrary waveform to DAC update speed problems

795 Views
puhongwang
Contributor I

      When the frequency of AHB and APB is 2M, the DMA sends 1024 word long data according to the sinusoidal code value of the table lookup. The refresh frequency of DAC is 1/6 of the set frequency.

      If the frequency of sinusoidal code value is less than 100Hz, the output frequency is correct.At the same time, other parameters did not change, and APB only adjusted the corresponding divider coefficient after modifying the AHB clock to make the DAC output frequency unchanged, and the same sine wave code value, the output frequency was also increased synchronously. When AHB frequency was up to 32M, the frequency of DAC output was 2/3 of the set value.

      I doubt that DMA cannot fully occupy the system bus bandwidth when actually transferring data, resulting in that the transmission bandwidth of actual DMA cannot meet the output rate requirements of DAC, and DAC cannot produce a corresponding output value under a single clock.

       How to solve this problem?

0 Kudos
4 Replies

642 Views
puhongwang
Contributor I
libs is <math.h>
#include <math.h>
There are all kinds of mathematical calculation library functions that can be called. 
My experimental conclusion is: if it is necessary to use DMA to output to DAC, then the maximum frequency of DAC is 333KHz; otherwise, the speed of DMA is insufficient, and there is loss value in the middle, resulting in that DAC cannot reach the original set frequency.
I can't solve this problem, but I know why.
0 Kudos

642 Views
FelipeGarcia
NXP Employee
NXP Employee

Hi puhong wang,

 

QN9080 includes a 1M samples per second DAC. I think maybe your issue is caused by the math.h library and it's velocity calculations. Could you please try generating the sine wave by using a simple array just to see if you have the same frequency issues?

Also, there is a sine wave example included in the SDK using DAC.

Best regards,

Felipe

0 Kudos

642 Views
FelipeGarcia
NXP Employee
NXP Employee

Hi puhong wang,

If I'm understanding correctly you are trying to change the frequency of the sinusoidal by changing AHB and APB am I right?

How are you generating the sinusoidal wave?

Could you please tell me which SDK example are you working on?

Best regards,

Felipe

0 Kudos

642 Views
puhongwang
Contributor I

hello!

libs is <math.h>

#include <math.h>

There are all kinds of mathematical calculation library functions that can be called.

My experimental conclusion is: if it is necessary to use DMA to output to DAC, then the maximum frequency of DAC is 333KHz; otherwise, the speed of DMA is insufficient, and there is loss value in the middle, resulting in that DAC cannot reach the original set frequency.

知我者谓我心忧,不知我者谓我何求。

On 10/16/2018 01:52,nxf46115<admin@community.nxp.com> wrote:

|

|

NXP Community

|

|

Re: QN9080 DMA transfers arbitrary waveform to DAC update speed problems

reply from Felipe Garcia in Wireless Connectivity - View the full discussion

Hi puhong wang,

If I'm understanding correctly you are trying to change the frequency of the sinusoidal by changing AHB and APB am I right?

How are you generating the sinusoidal wave?

Could you please tell me which SDK example are you working on?

Best regards,

Felipe

Reply to this message by replying to this email, or go to the message on NXP Community

Start a new discussion in Wireless Connectivity by email or at NXP Community

Following Re: QN9080 DMA transfers arbitrary waveform to DAC update speed problems in these streams: Inbox

This email was sent by NXP Community because you are a registered user.

You may unsubscribe instantly from NXP Community, or adjust email frequency in your email preferences

|

|

0 Kudos