I'm using Analog Discovery 2 to perform data acquisition through the two channels of the Oscilloscope, using the AnalogIn_Record.py code available in the SDK as a base.
However, when the sampling frequency is greater than 600k Hz, samples are always lost and corrupted. For sampling periods longer than 120 seconds the losses are increased.
Writing to a file takes almost the same time as acquisition, which makes the program uninteresting for the application I need. To minimize the effects of such a delay, I use a Thread that writes to file 'in parallel' with acquisition. With this, the problem of delay in writing to the file is satisfactorily minimized. However, the problem regarding corruptions and losses is not solved.
The example program AnalogIn_Record.py does not present any solution to this problem. It only requests that the sampling frequency be reduced, which is not satisfactory. After all, Analog Discovery 2 supports frequencies higher than those I want to use.
Is there any implementation better suited to mitigate such an error?
Question
Tamires
Hi,
I'm using Analog Discovery 2 to perform data acquisition through the two channels of the Oscilloscope, using the AnalogIn_Record.py code available in the SDK as a base.
However, when the sampling frequency is greater than 600k Hz, samples are always lost and corrupted. For sampling periods longer than 120 seconds the losses are increased.
Writing to a file takes almost the same time as acquisition, which makes the program uninteresting for the application I need. To minimize the effects of such a delay, I use a Thread that writes to file 'in parallel' with acquisition. With this, the problem of delay in writing to the file is satisfactorily minimized. However, the problem regarding corruptions and losses is not solved.
The example program AnalogIn_Record.py does not present any solution to this problem. It only requests that the sampling frequency be reduced, which is not satisfactory. After all, Analog Discovery 2 supports frequencies higher than those I want to use.
Is there any implementation better suited to mitigate such an error?
Thank you in advance for your help.
Link to comment
Share on other sites
3 answers to this question
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now