Jump to content
  • 0

Unexplained initial DC offset with Waveforms SDK


timmolter

Question

Hi, When I use the SDK and create an analog out pulse, either custom or square, doesn't matter, I see this offset of about 0.03 V only on the first run through. I'm not sure if it's the AWG or the scope. Any ideas? Attached are screenshots showing what I mean. I can add my code if need be. Thanks in advance!

 

Screen Shot 2017-02-14 at 4.01.47 PM.png

Screen Shot 2017-02-14 at 4.01.41 PM.png

Link to comment
Share on other sites

3 answers to this question

Recommended Posts

Solved. It's the oscilloscope, not the analog out. If I run the following code on app startup, it's all fine:

/////////////////////////////////////////////////////////////
// Analog In //////////////////////////////////////////////
/////////////////////////////////////////////////////////////
dwf.FDwfAnalogInChannelEnableSet(DWF.OSCILLOSCOPE_CHANNEL_1, true);
dwf.FDwfAnalogInChannelRangeSet(DWF.OSCILLOSCOPE_CHANNEL_1, 2.5);
dwf.FDwfAnalogInChannelEnableSet(DWF.OSCILLOSCOPE_CHANNEL_2, true);
dwf.FDwfAnalogInChannelRangeSet(DWF.OSCILLOSCOPE_CHANNEL_2, 2.5);

I got a clue from `analogin_record.cpp`:

// wait at least 2 seconds with Analog Discovery for the offset to stabilize, before the first reading after device open or offset/range change
Wait(2);

 

Link to comment
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...