Jump to content
  • 0

WaveformSDK, DwfState


alpanth

Question

Hello, first time working with the WaveformSDK and when looking at the DwfState's I saw something weird.

DwfStateTriggered and DwfStateRunning is set to same value 3.

Is there a reason for that? It seems like the number 6 is missing. If it is a typo I would like to know which state should be 6.

 

From dwf.h with

/************************************************************************/
/*  Revision History:                                                   */
/*                                                                      */
/*  06/6/2009(KovacsLA) : Created                                       */
/*                                                                      */
/************************************************************************/

 

Starting at line 104:

// instrument states:
typedef unsigned char DwfState;
const DwfState DwfStateReady        = 0;
const DwfState DwfStateConfig       = 4;
const DwfState DwfStatePrefill      = 5;
const DwfState DwfStateArmed        = 1;
const DwfState DwfStateWait         = 7;
const DwfState DwfStateTriggered    = 3;
const DwfState DwfStateRunning      = 3;
const DwfState DwfStateDone         = 2;

 

Link to comment
Share on other sites

5 answers to this question

Recommended Posts

  • 0

Hi @alpanth,

Attila (who created this material) is out of the office until next week to give an official answer, but I believe this is intentional based on the WaveForms SDK Reference Manual (available in the WaveForms installation folder on your computer); the start of section 5, Analog In (Oscilloscope) describes the Analog In instrument states and Running and Trig'd be described in the same state, which makes sense because once a trigger condition is met the acquisition would then be running.

image.png

Let me know if you have any questions about this.

Thanks,
JColvin

Link to comment
Share on other sites

  • 0

Hi @alpanth

I raised this very issue with Atilla at some point in the distant past, because I ran into the same thing when making pydwf, and indeed this is intentional -- they are essentially two labels for the same number. Some instruments use the "triggered" terminology while others use the "running" terminology.

I personally think it would be best of one of those labels were eliminated, because it just causes confusion. What adds to the confusion, of course, is that the value 6 is unused.

Cheers, Sidney

Link to comment
Share on other sites

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 account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...