K22F DAC glitches when crossing midpoint

キャンセル
次の結果を表示 
表示  限定  | 次の代わりに検索 
もしかして: 

K22F DAC glitches when crossing midpoint

1,279件の閲覧回数
scottm
Senior Contributor II

I'm using the MK22FN1M0AVLH12's 12-bit DAC for audio output and I'm seeing a consistent glitch in the DAC's output.  Every time the signal crosses the midpoint of the DAC's range I get a brief (~0.7 us) excursion of about +60 mV.

I've got it sending samples via DMA, and the DAC's buffer is enabled.  To rule out a problem in my reconstruction filter I've removed it completely; I'm just measuring straight from the DAC.  I set it up to do a slow ramp across the full range and the problem is consistent.

0.7 us is consistent with the code-to-code settling time given in the datasheet but I'm surprised by the amplitude of the glitch.  Is there a way to reduce this?

Thanks,

Scott

ラベル(1)
タグ(2)
2 返答(返信)

1,167件の閲覧回数
mjbcswitzerland
Specialist V

Scott

I believe that there was a similar discussion about 2..3 years ago and I also could reproduce a similar effect when I tested at the time (not sure on which part but possible a KL processor). Unfortunately I haven't been able to locate the thread anymore.
Try avoiding the mid-point value (round up or down to next possible) since if I remember correctly not using the value that causes the jump meant that it was then more or less worked around.

Regards

Mark

1,167件の閲覧回数
scottm
Senior Contributor II

Yeah, I was going to give that a try and see if it's the code itself or if it's the transition across the midpoint that's causing the glitch.  Fortunately the way my code is set up, the audio is all run through a lookup table anyway to handle volume level adjustment so avoiding a code won't cause a performance hit.

Now, what I'd really like is a lookup table function built into the DMA controller, even if it was limited to a small block of dedicated RAM.  That would make some of this stuff way more efficient...

Scott

0 件の賞賛
返信