I'm using a ATxMega128A4U and the DAC with a DDS to produce an audible Sinewave. I'm using the schematic in the attachement directly connected to the DAC. Switching my device on and off i hear a plopping sound. Switching the device on and off without the connection to the mikrocontroller i hear no plopping sound. On the oscilloscope i can see the folling on the output of the DAC.
Has someone an idea what that could be. In my software I do the following after start:
PORTB.DIR = 0b11111100; PORTB.OUTCLR = PIN2_bm; DACB.CTRLA = DAC_CH0EN_bm | DAC_ENABLE_bm; DACB.CTRLB = DAC_CHSEL_SINGLE_gc; DACB.CTRLC = DAC_REFSEL_AVCC_gc; DACB.CH0OFFSETCAL = g_settings.cDACOffset; DACB.CH0GAINCAL = g_settings.cDACGain; while(!(DACB.STATUS & DAC_CH0DRE_bm)); DACB.CH0DATA = 0;
Tank you very much for every idea!
EDIT:Now with correct screenshots :)