nScopeAPI  v0.8
Macros | Typedefs | Enumerations
nScopeAPI_defs.h File Reference

header file for common definitions More...

Macros

#define NSCOPE_API_EXPORT
 
#define NSCOPE_API_CALL
 
#define NSCOPE_API   NSCOPE_API_EXPORT NSCOPE_API_CALL
 

Typedefs

typedef struct scopeDev_ * ScopeHandle
 
typedef struct request_ * Request
 

Enumerations

enum  ErrorType {
  SUCCESS = 0, UNKNOWN_ERROR = -100, NSCOPE_NOT_OPEN = -101, NSCOPE_CHANNEL_OFF = -102,
  NSCOPE_POWER_OFF = -103, NO_DATA_AVAILABLE = -104, INVALID_TRIGGER = -105, INVALID_REQUEST = -106,
  COMM_ERROR = -107, INTERRUPT_STOPPED = -108, FW_API_INCOMPATIBLE = -109, VALUE_ERROR_TOO_SMALL = -110,
  VALUE_ERROR_TOO_LARGE = -111, VALUE_ERROR_OUT_OF_RANGE = -112, VALUE_WARNING_TOO_SMALL = -120, VALUE_WARNING_TOO_LARGE = -121
}
 
enum  TriggerEdge { FALLING_EDGE = 1, RISING_EDGE = 2 }
 
enum  PowerState {
  NOT_CONNECTED = -1, POWER_OFF = 0, POWER_ON = 1, SHORTED = 2,
  OVERCURRENT = 3
}
 
enum  WaveType { SINE_WAVE = 0, TRIANGLE_WAVE = 1 }
 

Documentation

header file for common definitions

Macro Definition Documentation

#define NSCOPE_API   NSCOPE_API_EXPORT NSCOPE_API_CALL

API export and call macro

#define NSCOPE_API_CALL

API call macro

#define NSCOPE_API_EXPORT

API export macro

Typedef Documentation

typedef struct request_* Request

nScope request handle

typedef struct scopeDev_* ScopeHandle

nScope structure handle

Enumeration Type Documentation

enum ErrorType

nScope error types

return type for all nScopeAPI functions

Enumerator
SUCCESS 

No error was encountered

UNKNOWN_ERROR 

An unknown error occurred

NSCOPE_NOT_OPEN 

nScope is not open, or has been disconnected unexpectedly

NSCOPE_CHANNEL_OFF 

the desired channel is currently off

NSCOPE_POWER_OFF 

nScope power is off

NO_DATA_AVAILABLE 

There is no data available

INVALID_TRIGGER 

The trigger settings are invalid

INVALID_REQUEST 

The request is invalid

COMM_ERROR 

A communication error has occurred

INTERRUPT_STOPPED 

TODO: no clue

FW_API_INCOMPATIBLE 

Firmware and API are incompatible

VALUE_ERROR_TOO_SMALL 

Value error: a parameter is too small

VALUE_ERROR_TOO_LARGE 

Value error: a parameter is too large

VALUE_ERROR_OUT_OF_RANGE 

Value error: a parameter is out of range

VALUE_WARNING_TOO_SMALL 

Value warning: a parameter is very small

VALUE_WARNING_TOO_LARGE 

Value warning: a parameter is very large

enum PowerState

Power state of nScope

Enumerator
NOT_CONNECTED 

nScope is not connected

POWER_OFF 

power is off

POWER_ON 

power is on

SHORTED 

a short has been detected

OVERCURRENT 

an overcurrent has been detected

Trigger edges of nScope

Enumerator
FALLING_EDGE 

trigger on the falling edge

RISING_EDGE 

trigger on the rising edge

enum WaveType

Wave Types of nScope

Enumerator
SINE_WAVE 

analog output is a sine wave

TRIANGLE_WAVE 

analog output is a triangle wave