cancel
Showing results for 
Search instead for 
Did you mean: 

The unstable of sine wave generating signal by DAC

SPhon.1
Associate

Hello, I have the problem of sine wave generation by DAC. Time to time when I generate the sine wave signal from MCU (STM32F302R8T6), the signal is unstable. I try to debug, and found that the issue might results from the hardware which is MCU. I would like to ask what is the solution to solve this issue.

I have upload the schematic, the code and the video.

This is the video link : https://drive.google.com/file/d/14H5SwWmWiqGRgMHV2Tm5EA9vfEXYJYwO/view?usp=sharing

Thank you

5 REPLIES 5
Gudgel.boB
Senior

It looks kind of like the DAC output might be intermittently hitting another trace that has 3.3V on it.

I would look at the traces adjacent to the DAC output just in case that is happening. Maybe even the micro pins on either side of the DAC pin.

Also, what happens if you try tapping the PCB in the DAC trace area ? Does it make the problem better or worse ?

Have you tried another PCB and micro ? I am guessing that what you show in your video doesn't happen on a second unit.

boB

Hi boB, First of all thank you for your help. I check the rule of PCB design. So, the clearance between each trace is 6 mil (0.15 mm).

Do you think that it is too close for the PCB trace? By the way, I assembled another board (same PCB design) and tested it, but the problem still happened to another as well. Actually, it just worked in the beginning. Then, the issue occurs. I have no idea to solve it. If you have any idea to solve this issue, please let me know.

Thank you

0693W00000BaEpsQAF.jpg0693W00000BaEpdQAF.jpg

Javier1
Principal

It looks like you might have a bad contact between the oszi probe and your pcb, or a defective probe.

Have you calibrated/tested the probe?

To make sure is not a DAC issue you could turn dac off and use the GPIO pin ON OFF ON OFF ON OFF ON OFF and see if you find similar behaviour

we dont need to firmware by ourselves, lets talk

I was thinking a bad probe might be the problem as well but when his signal goes away, it goes to 3.3V looks like.

But yeah, the test setup could be suspect when more than one PCB does this.

6 mil spacing is real close but not too small by today's standards.

yup, what about bad chip soldering?

we dont need to firmware by ourselves, lets talk