Jump to content
  • 0

Incorrect first sample using AnalogIn_Record.py


Ferdinand

Question

Hello,

I observed a strange phenomenon, while trying out the sample python scripts. When I run the script WaveFormsSDK/samples/AnalogIn_Record.py everything works as expected. But when I change the sleep time from 2 seconds to 2.25 seconds, I expect to see the same sine wave but then shifted by 1/4 period. When I run the script, the sine wave is shifted by 1/4 period, but the first sample is incorrect. To be more precise, it is in between zero and the second sample. I have included the graph below.

AnalogIn_Record_figure.png.22b8a43fef1a67ebbb77caff4ca5b299.png

I can easily fix this by taking a couple of samples more and strip the first couple of samples.

But I would like to understand what is happening here. Is this due to the maximum slew rate of a component, or is it a software problem, or something else....?

Additional information:

  • OS: Windows 7 Enterprise SP1, 64bit
  • Python: 3.6.6, 64-bit
  • DWF Version: 3.9.1
  • Analog Discovery 2

     

Link to comment
Share on other sites

1 answer to this question

Recommended Posts

Archived

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

×
×
  • Create New...