DSRemoteConnect C++ Library 1.1.3.24
Remote connection library for Dewesoft measurement applications
Loading...
Searching...
No Matches
DSRemoteConnect_Documented.h File Reference
#include "DSXInstance.h"
#include "DSXDCOMInstance.h"
#include "DSXNETInstance.h"

Go to the source code of this file.

Macros

#define DSREMOTECONNECT_API   __declspec(dllimport)
 

Typedefs

typedef DSXInstance * DSXInstanceHandle
 Handle to a DSX instance for connection management.
 
typedef ChannelInstance * ChannelInstanceHandle
 Handle to a measurement channel instance.
 

Functions

DSREMOTECONNECT_API int dsconGetVersion (char *version, size_t len)
 Get the library version string.
 
DSREMOTECONNECT_API int dsconCreateInstance (DSXInstanceHandle *handle, int connectionType)
 Create a new DSX instance.
 
DSREMOTECONNECT_API int dsconConnect (DSXInstanceHandle handle, char *connectionString)
 Connect to a Dewesoft application.
 
DSREMOTECONNECT_API int dsconDestroyInstance (DSXInstanceHandle handle)
 Destroy a DSX instance.
 
DSREMOTECONNECT_API int dsconDisconnect (DSXInstanceHandle handle)
 Disconnect from Dewesoft application.
 
DSREMOTECONNECT_API int dsconLoadSetup (DSXInstanceHandle handle, char *fileName)
 Load a Dewesoft setup file.
 
DSREMOTECONNECT_API int dsconSetAppWindowVisible (DSXInstanceHandle handle, bool visible)
 Set Dewesoft application window visibility.
 
DSREMOTECONNECT_API int dsconSetBufferSize (DSXInstanceHandle handle, int bufferSize)
 Set buffer size for data acquisition.
 
DSREMOTECONNECT_API int dsconGetChannelCount (DSXInstanceHandle handle, size_t *count)
 Get the total number of available channels.
 
DSREMOTECONNECT_API int dsconEnumerateChannels (DSXInstanceHandle handle, ChannelIdList *channelIdList, size_t *count)
 Enumerate all available channels.
 
DSREMOTECONNECT_API int dsconFreeEnumerateChannels (DSXInstanceHandle handle, ChannelIdList *channelIdList)
 Free memory allocated by channel enumeration.
 
DSREMOTECONNECT_API int dsconInitChannelIdEnum (DSXInstanceHandle handle)
 Initialize channel ID enumeration iterator.
 
DSREMOTECONNECT_API int dsconGetNextChannelId (DSXInstanceHandle handle, ChannelID id)
 Get next channel ID in enumeration.
 
DSREMOTECONNECT_API int dsconGetNextChannelIdSize (DSXInstanceHandle handle, int *size)
 Get size of next channel ID.
 
DSREMOTECONNECT_API int dsconCreateChannelInstance (DSXInstanceHandle handle, ChannelID id, ChannelInstanceHandle *chInstance)
 Create a channel instance by ID.
 
DSREMOTECONNECT_API int dsconCreateChannelInstanceByName (DSXInstanceHandle handle, char *chName, ChannelInstanceHandle *chInstance)
 Create a channel instance by name.
 
DSREMOTECONNECT_API int dsconFreeChannelInstance (ChannelInstanceHandle chInstance)
 Free a channel instance.
 
DSREMOTECONNECT_API int dsconChannelGetName (ChannelInstanceHandle channel, char *name, size_t len)
 Get channel display name.
 
DSREMOTECONNECT_API int dsconGetSampleRate (ChannelInstanceHandle handle, double *sampleRate)
 Get channel sample rate.
 
DSREMOTECONNECT_API int dsconGetChannelType (ChannelInstanceHandle handle, int *chType)
 Get channel type.
 
DSREMOTECONNECT_API int dsconIsChannelControl (ChannelInstanceHandle handle, bool *result)
 Check if channel is a control channel.
 
DSREMOTECONNECT_API int dsconGetChUnit (ChannelInstanceHandle handle, char *resultUnit, size_t len)
 Get channel measurement unit.
 
DSREMOTECONNECT_API int dsconChannelSetTransferred (ChannelInstanceHandle handle, bool transferred)
 Set channel transfer state.
 
DSREMOTECONNECT_API int dsconIsInAqusition (DSXInstanceHandle handle, bool *value)
 Check if measurement is active.
 
DSREMOTECONNECT_API int dsconStartMeasurement (DSXInstanceHandle handle)
 Start measurement.
 
DSREMOTECONNECT_API int dsconStopMeasurement (DSXInstanceHandle handle)
 Stop measurement.
 
DSREMOTECONNECT_API int dsconBeginRead (DSXInstanceHandle handle, double *startTime, double *endTime)
 Begin data reading session.
 
DSREMOTECONNECT_API int dsconChannelReadScalarData (ChannelInstanceHandle handle, double **data, double **timestamps, size_t *count)
 Read scalar data from channel (legacy version)
 
DSREMOTECONNECT_API int dsconChannelReadScalarData_2 (ChannelInstanceHandle handle, double *data, double *timestamps, size_t *count)
 Read scalar data from channel (recommended version)
 
DSREMOTECONNECT_API int dsconChannelReadScalarData_2abs (ChannelInstanceHandle handle, double *data, double *timestamps, size_t *count)
 Read scalar data with absolute timestamps.
 
DSREMOTECONNECT_API int dsconControlChannelWriteData (ChannelInstanceHandle handle, double data)
 Write data to control channel.
 
DSREMOTECONNECT_API int dsconEndRead (DSXInstanceHandle handle)
 End data reading session.
 

Variables

const std::string VER_DSREMOTE = "1.1.3.24"
 DSRemoteConnect library version string.
 

Macro Definition Documentation

◆ DSREMOTECONNECT_API

#define DSREMOTECONNECT_API   __declspec(dllimport)

Definition at line 125 of file DSRemoteConnect_Documented.h.

Typedef Documentation

◆ ChannelInstanceHandle

Handle to a measurement channel instance.

This handle represents a specific measurement channel and provides access to channel data, properties, and control capabilities.

Definition at line 159 of file DSRemoteConnect_Documented.h.

◆ DSXInstanceHandle

Handle to a DSX instance for connection management.

This handle represents a connection to a Dewesoft application instance. It encapsulates either a DCOM or NET connection type.

Definition at line 150 of file DSRemoteConnect_Documented.h.

Function Documentation

◆ dsconBeginRead()

DSREMOTECONNECT_API int dsconBeginRead ( DSXInstanceHandle handle,
double * startTime,
double * endTime )

Begin data reading session.

Prepares the system for data reading and optionally sets time bounds.

Parameters
[in]handleDSX instance handle
[in,out]startTimePointer to start time (can be NULL for current time)
[in,out]endTimePointer to end time (can be NULL for current time)
Returns
DX_ERROR_CODE
Return values
DSX_NO_ERRORSuccess
DSX_NULL_HANDLERInvalid handle
Note
Always call dsconEndRead() when finished reading data
See also
dsconEndRead(), dsconChannelReadScalarData_2()

◆ dsconChannelGetName()

DSREMOTECONNECT_API int dsconChannelGetName ( ChannelInstanceHandle channel,
char * name,
size_t len )

Get channel display name.

Retrieves the human-readable name of the channel.

Parameters
[in]channelChannel instance handle
[out]nameBuffer to store channel name
[in]lenBuffer length
Returns
DX_ERROR_CODE
Return values
DSX_NO_ERRORSuccess
DSX_NULL_HANDLERInvalid handle
DSX_COUNT_OUT_OF_BOUNDSBuffer too small

◆ dsconChannelReadScalarData()

DSREMOTECONNECT_API int dsconChannelReadScalarData ( ChannelInstanceHandle handle,
double ** data,
double ** timestamps,
size_t * count )

Read scalar data from channel (legacy version)

Reads measurement data and timestamps from a channel. Memory is allocated internally and must be managed carefully.

Parameters
[in]handleChannel instance handle
[out]dataPointer to store data array pointer
[out]timestampsPointer to store timestamp array pointer
[out]countPointer to store number of samples read
Returns
DX_ERROR_CODE
Return values
DSX_NO_ERRORSuccess
DSX_NULL_HANDLERInvalid handle
DSX_DCOM_NO_DATANo data available
DSX_TOO_MANY_SAMPLES_AVAILABLEMore data available than requested
Deprecated
Use dsconChannelReadScalarData_2() instead for better memory management
See also
dsconChannelReadScalarData_2()

◆ dsconChannelReadScalarData_2()

DSREMOTECONNECT_API int dsconChannelReadScalarData_2 ( ChannelInstanceHandle handle,
double * data,
double * timestamps,
size_t * count )

Read scalar data from channel (recommended version)

Reads measurement data and timestamps into user-provided buffers. This is the recommended function for data reading.

Parameters
[in]handleChannel instance handle
[out]dataPre-allocated array to store data values
[out]timestampsPre-allocated array to store timestamp values
[in,out]countInput: buffer size, Output: actual samples read
Returns
DX_ERROR_CODE
Return values
DSX_NO_ERRORSuccess
DSX_NULL_HANDLERInvalid handle
DSX_DCOM_NO_DATANo data available
DSX_TOO_MANY_SAMPLES_AVAILABLEMore data available than buffer size
Note
Timestamps are relative to measurement start time
See also
dsconBeginRead(), dsconEndRead()
double data[1000];
double timestamps[1000];
size_t count = 1000;
if (dsconChannelReadScalarData_2(channel, data, timestamps, &count) == DSX_NO_ERROR) {
for (size_t i = 0; i < count; i++) {
printf("Time: %f, Value: %f\n", timestamps[i], data[i]);
}
}
@ DSX_NO_ERROR
No error - operation successful.
DSREMOTECONNECT_API int dsconChannelReadScalarData_2(ChannelInstanceHandle handle, double *data, double *timestamps, size_t *count)
Read scalar data from channel (recommended version)

◆ dsconChannelReadScalarData_2abs()

DSREMOTECONNECT_API int dsconChannelReadScalarData_2abs ( ChannelInstanceHandle handle,
double * data,
double * timestamps,
size_t * count )

Read scalar data with absolute timestamps.

Similar to dsconChannelReadScalarData_2() but returns absolute timestamps instead of relative ones.

Parameters
[in]handleChannel instance handle
[out]dataPre-allocated array to store data values
[out]timestampsPre-allocated array to store absolute timestamp values
[in,out]countInput: buffer size, Output: actual samples read
Returns
DX_ERROR_CODE
Return values
DSX_NO_ERRORSuccess
DSX_NULL_HANDLERInvalid handle
DSX_DCOM_NO_DATANo data available
Note
Timestamps are absolute system time values
See also
dsconChannelReadScalarData_2()

◆ dsconChannelSetTransferred()

DSREMOTECONNECT_API int dsconChannelSetTransferred ( ChannelInstanceHandle handle,
bool transferred )

Set channel transfer state.

Enables or disables data transfer for the channel.

Parameters
[in]handleChannel instance handle
[in]transferredtrue to enable transfer, false to disable
Returns
DX_ERROR_CODE
Return values
DSX_NO_ERRORSuccess
DSX_NULL_HANDLERInvalid handle

◆ dsconConnect()

DSREMOTECONNECT_API int dsconConnect ( DSXInstanceHandle handle,
char * connectionString )

Connect to a Dewesoft application.

Establishes connection to a Dewesoft application using the specified connection string.

Parameters
[in]handleDSX instance handle
[in]connectionStringConnection-specific string:
  • DCOM: Empty string "" for local connection
  • NET: "hostname:telnet_port:data_port" (e.g., "localhost:8999:8001")
Returns
DX_ERROR_CODE
Return values
DSX_NO_ERRORSuccess
DSX_NULL_HANDLERInvalid handle
DSX_INVALID_CONNECTION_STRINGInvalid connection string format
DSX_DCOM_COULD_NOT_CONNECTFailed to connect via DCOM
DSX_NET_UNABLE_TO_CONNECTFailed to connect via NET
Note
For NET connections, ensure Dewesoft is running with NET server enabled
See also
dsconDisconnect()

◆ dsconControlChannelWriteData()

DSREMOTECONNECT_API int dsconControlChannelWriteData ( ChannelInstanceHandle handle,
double data )

Write data to control channel.

Writes a control value to a control channel. The channel must be configured as a control channel in the Dewesoft setup.

Parameters
[in]handleChannel instance handle (must be control channel)
[in]dataValue to write to the control channel
Returns
DX_ERROR_CODE
Return values
DSX_NO_ERRORSuccess
DSX_NULL_HANDLERInvalid handle
DSX_CH_IS_NOT_CONTROLChannel is not a control channel
Note
Verify channel is a control channel using dsconIsChannelControl()
See also
dsconIsChannelControl()
bool isControl;
dsconIsChannelControl(channel, &isControl);
if (isControl) {
}
DSREMOTECONNECT_API int dsconControlChannelWriteData(ChannelInstanceHandle handle, double data)
Write data to control channel.
DSREMOTECONNECT_API int dsconIsChannelControl(ChannelInstanceHandle handle, bool *result)
Check if channel is a control channel.

◆ dsconCreateChannelInstance()

DSREMOTECONNECT_API int dsconCreateChannelInstance ( DSXInstanceHandle handle,
ChannelID id,
ChannelInstanceHandle * chInstance )

Create a channel instance by ID.

Creates a channel instance handle for accessing a specific channel. The channel ID should be obtained from enumeration functions.

Parameters
[in]handleDSX instance handle
[in]idChannel ID string
[out]chInstancePointer to store created channel instance handle
Returns
DX_ERROR_CODE
Return values
DSX_NO_ERRORSuccess
DSX_NULL_HANDLERInvalid handle
DSX_DCOM_CHANNEL_ID_NOT_FOUNDChannel ID not found
DSX_CANNOT_MAKE_CH_INSTANCEFailed to create channel instance
Note
Always call dsconFreeChannelInstance() when done
See also
dsconFreeChannelInstance(), dsconCreateChannelInstanceByName()

◆ dsconCreateChannelInstanceByName()

DSREMOTECONNECT_API int dsconCreateChannelInstanceByName ( DSXInstanceHandle handle,
char * chName,
ChannelInstanceHandle * chInstance )

Create a channel instance by name.

Creates a channel instance handle using the channel's display name.

Parameters
[in]handleDSX instance handle
[in]chNameChannel display name
[out]chInstancePointer to store created channel instance handle
Returns
DX_ERROR_CODE
Return values
DSX_NO_ERRORSuccess
DSX_NULL_HANDLERInvalid handle
DSX_DCOM_CHANNEL_ID_NOT_FOUNDChannel name not found
DSX_CANNOT_MAKE_CH_INSTANCEFailed to create channel instance
Note
Always call dsconFreeChannelInstance() when done
See also
dsconFreeChannelInstance(), dsconCreateChannelInstance()
dsconCreateChannelInstanceByName(instance, "AI 1", &channel);
ChannelInstance * ChannelInstanceHandle
Handle to a measurement channel instance.
DSREMOTECONNECT_API int dsconCreateChannelInstanceByName(DSXInstanceHandle handle, char *chName, ChannelInstanceHandle *chInstance)
Create a channel instance by name.

◆ dsconCreateInstance()

DSREMOTECONNECT_API int dsconCreateInstance ( DSXInstanceHandle * handle,
int connectionType )

Create a new DSX instance.

Creates a new and bla bla bla instance for connecting to Dewesoft applications. The connection type determines the communication protocol used.

Parameters
[out]handlePointer to store the created instance handle
[in]connectionTypeConnection type (DSX_CONNECTION_TYPE_DCOM or DSX_CONNECTION_TYPE_NET)
Returns
DX_ERROR_CODE
Return values
DSX_NO_ERRORSuccess
DSX_NULL_HANDLERInvalid handle pointer
DSX_UNKNOWN_ERRORFailed to create instance
Note
Always call dsconDestroyInstance() when done with the instance
See also
dsconDestroyInstance(), DSX_CONNECTION_TYPE

◆ dsconDestroyInstance()

DSREMOTECONNECT_API int dsconDestroyInstance ( DSXInstanceHandle handle)

Destroy a DSX instance.

Cleans up and destroys the DSX instance. This should be called for every instance created with dsconCreateInstance().

Parameters
[in]handleDSX instance handle to destroy
Returns
DX_ERROR_CODE
Return values
DSX_NO_ERRORSuccess
DSX_NULL_HANDLERInvalid handle
Note
Automatically disconnects if still connected
See also
dsconCreateInstance()

◆ dsconDisconnect()

DSREMOTECONNECT_API int dsconDisconnect ( DSXInstanceHandle handle)

Disconnect from Dewesoft application.

Closes the connection to the Dewesoft application while keeping the instance alive.

Parameters
[in]handleDSX instance handle
Returns
DX_ERROR_CODE
Return values
DSX_NO_ERRORSuccess
DSX_NULL_HANDLERInvalid handle
DSX_DCOM_NOT_CONNECTEDNot connected via DCOM
See also
dsconConnect()

◆ dsconEndRead()

DSREMOTECONNECT_API int dsconEndRead ( DSXInstanceHandle handle)

End data reading session.

Finalizes the data reading session started with dsconBeginRead().

Parameters
[in]handleDSX instance handle
Returns
DX_ERROR_CODE
Return values
DSX_NO_ERRORSuccess
DSX_NULL_HANDLERInvalid handle
See also
dsconBeginRead()

◆ dsconEnumerateChannels()

DSREMOTECONNECT_API int dsconEnumerateChannels ( DSXInstanceHandle handle,
ChannelIdList * channelIdList,
size_t * count )

Enumerate all available channels.

Gets a list of all channel IDs in the current setup. The returned list must be freed using dsconFreeEnumerateChannels().

Parameters
[in]handleDSX instance handle
[out]channelIdListPointer to store array of channel ID strings
[in,out]countInput: expected count, Output: actual count
Returns
DX_ERROR_CODE
Return values
DSX_NO_ERRORSuccess
DSX_NULL_HANDLERInvalid handle
DSX_DCOM_NOT_CONNECTEDNot connected
DSX_DCOM_NO_CHANNELS_TO_ENUMERATENo channels available
Note
Always call dsconFreeEnumerateChannels() to free memory
See also
dsconFreeEnumerateChannels(), dsconGetChannelCount()
size_t count;
dsconGetChannelCount(instance, &count);
ChannelIdList channelList;
dsconEnumerateChannels(instance, &channelList, &count);
// Use channel list...
dsconFreeEnumerateChannels(instance, &channelList);
DSREMOTECONNECT_API int dsconEnumerateChannels(DSXInstanceHandle handle, ChannelIdList *channelIdList, size_t *count)
Enumerate all available channels.
DSREMOTECONNECT_API int dsconFreeEnumerateChannels(DSXInstanceHandle handle, ChannelIdList *channelIdList)
Free memory allocated by channel enumeration.
DSREMOTECONNECT_API int dsconGetChannelCount(DSXInstanceHandle handle, size_t *count)
Get the total number of available channels.

◆ dsconFreeChannelInstance()

DSREMOTECONNECT_API int dsconFreeChannelInstance ( ChannelInstanceHandle chInstance)

Free a channel instance.

Frees the memory and resources associated with a channel instance.

Parameters
[in]chInstanceChannel instance handle to free
Returns
DX_ERROR_CODE
Return values
DSX_NO_ERRORSuccess
DSX_NULL_HANDLERInvalid handle
See also
dsconCreateChannelInstance(), dsconCreateChannelInstanceByName()

◆ dsconFreeEnumerateChannels()

DSREMOTECONNECT_API int dsconFreeEnumerateChannels ( DSXInstanceHandle handle,
ChannelIdList * channelIdList )

Free memory allocated by channel enumeration.

Frees the memory allocated by dsconEnumerateChannels().

Parameters
[in]handleDSX instance handle
[in]channelIdListChannel ID list to free
Returns
DX_ERROR_CODE
Return values
DSX_NO_ERRORSuccess
DSX_NULL_HANDLERInvalid handle
See also
dsconEnumerateChannels()

◆ dsconGetChannelCount()

DSREMOTECONNECT_API int dsconGetChannelCount ( DSXInstanceHandle handle,
size_t * count )

Get the total number of available channels.

Returns the number of channels available in the current setup.

Parameters
[in]handleDSX instance handle
[out]countPointer to store channel count
Returns
DX_ERROR_CODE
Return values
DSX_NO_ERRORSuccess
DSX_NULL_HANDLERInvalid handle
DSX_DCOM_NOT_CONNECTEDNot connected
See also
dsconEnumerateChannels()

◆ dsconGetChannelType()

DSREMOTECONNECT_API int dsconGetChannelType ( ChannelInstanceHandle handle,
int * chType )

Get channel type.

Returns the channel type (async, sync, or single value).

Parameters
[in]handleChannel instance handle
[out]chTypePointer to store channel type (DSX_CH_TYPE)
Returns
DX_ERROR_CODE
Return values
DSX_NO_ERRORSuccess
DSX_NULL_HANDLERInvalid handle
See also
DSX_CH_TYPE

◆ dsconGetChUnit()

DSREMOTECONNECT_API int dsconGetChUnit ( ChannelInstanceHandle handle,
char * resultUnit,
size_t len )

Get channel measurement unit.

Returns the physical unit of measurement for the channel (e.g., "V", "A", "°C").

Parameters
[in]handleChannel instance handle
[out]resultUnitBuffer to store unit string
[in]lenBuffer length
Returns
DX_ERROR_CODE
Return values
DSX_NO_ERRORSuccess
DSX_NULL_HANDLERInvalid handle
DSX_COUNT_OUT_OF_BOUNDSBuffer too small

◆ dsconGetNextChannelId()

DSREMOTECONNECT_API int dsconGetNextChannelId ( DSXInstanceHandle handle,
ChannelID id )

Get next channel ID in enumeration.

Retrieves the next channel ID in the enumeration sequence.

Parameters
[in]handleDSX instance handle
[out]idBuffer to store channel ID (must be pre-allocated)
Returns
DX_ERROR_CODE
Return values
DSX_NO_ERRORSuccess - channel ID retrieved
DSX_END_OF_ENUMNo more channels
DSX_NULL_HANDLERInvalid handle
Note
Use dsconGetNextChannelIdSize() to determine required buffer size
See also
dsconInitChannelIdEnum(), dsconGetNextChannelIdSize()

◆ dsconGetNextChannelIdSize()

DSREMOTECONNECT_API int dsconGetNextChannelIdSize ( DSXInstanceHandle handle,
int * size )

Get size of next channel ID.

Returns the buffer size needed for the next channel ID in enumeration.

Parameters
[in]handleDSX instance handle
[out]sizePointer to store required buffer size
Returns
DX_ERROR_CODE
Return values
DSX_NO_ERRORSuccess
DSX_END_OF_ENUMNo more channels
DSX_NULL_HANDLERInvalid handle
See also
dsconGetNextChannelId(), dsconInitChannelIdEnum()

◆ dsconGetSampleRate()

DSREMOTECONNECT_API int dsconGetSampleRate ( ChannelInstanceHandle handle,
double * sampleRate )

Get channel sample rate.

Returns the sample rate of the channel in Hz.

Parameters
[in]handleChannel instance handle
[out]sampleRatePointer to store sample rate value
Returns
DX_ERROR_CODE
Return values
DSX_NO_ERRORSuccess
DSX_NULL_HANDLERInvalid handle

◆ dsconGetVersion()

DSREMOTECONNECT_API int dsconGetVersion ( char * version,
size_t len )

Get the library version string.

Parameters
[out]versionBuffer to store version string
[in]lenLength of the buffer
Returns
DX_ERROR_CODE
Return values
DSX_NO_ERRORSuccess
DSX_COUNT_OUT_OF_BOUNDSBuffer too small
char version[50];
dsconGetVersion(version, sizeof(version));
printf("DSRemoteConnect version: %s\n", version);
DSREMOTECONNECT_API int dsconGetVersion(char *version, size_t len)
Get the library version string.

◆ dsconInitChannelIdEnum()

DSREMOTECONNECT_API int dsconInitChannelIdEnum ( DSXInstanceHandle handle)

Initialize channel ID enumeration iterator.

Initializes an iterator for sequential channel enumeration. Use with dsconGetNextChannelId() and dsconGetNextChannelIdSize().

Parameters
[in]handleDSX instance handle
Returns
DX_ERROR_CODE
Return values
DSX_NO_ERRORSuccess
DSX_NULL_HANDLERInvalid handle
See also
dsconGetNextChannelId(), dsconGetNextChannelIdSize()

◆ dsconIsChannelControl()

DSREMOTECONNECT_API int dsconIsChannelControl ( ChannelInstanceHandle handle,
bool * result )

Check if channel is a control channel.

Determines whether the channel can be used for writing control data.

Parameters
[in]handleChannel instance handle
[out]resultPointer to store result (true if control channel)
Returns
DX_ERROR_CODE
Return values
DSX_NO_ERRORSuccess
DSX_NULL_HANDLERInvalid handle
See also
dsconControlChannelWriteData()

◆ dsconIsInAqusition()

DSREMOTECONNECT_API int dsconIsInAqusition ( DSXInstanceHandle handle,
bool * value )

Check if measurement is active.

Determines whether a measurement is currently running.

Parameters
[in]handleDSX instance handle
[out]valuePointer to store result (true if measuring)
Returns
DX_ERROR_CODE
Return values
DSX_NO_ERRORSuccess
DSX_NULL_HANDLERInvalid handle
DSX_DCOM_NOT_CONNECTEDNot connected

◆ dsconLoadSetup()

DSREMOTECONNECT_API int dsconLoadSetup ( DSXInstanceHandle handle,
char * fileName )

Load a Dewesoft setup file.

Loads a .dxs setup file into the connected Dewesoft application. This configures channels, sample rates, and other measurement parameters.

Parameters
[in]handleDSX instance handle
[in]fileNameFull path to the .dxs setup file
Returns
DX_ERROR_CODE
Return values
DSX_NO_ERRORSuccess
DSX_NULL_HANDLERInvalid handle
DSX_DCOM_NOT_CONNECTEDNot connected
DSX_NET_SETUP_NOT_FOUNDSetup file not found (NET connection)
Note
The setup file must be accessible by the Dewesoft application
dsconLoadSetup(instance, "C:\\Measurements\\MySetup.dxs");
DSREMOTECONNECT_API int dsconLoadSetup(DSXInstanceHandle handle, char *fileName)
Load a Dewesoft setup file.

◆ dsconSetAppWindowVisible()

DSREMOTECONNECT_API int dsconSetAppWindowVisible ( DSXInstanceHandle handle,
bool visible )

Set Dewesoft application window visibility.

Shows or hides the Dewesoft application window.

Parameters
[in]handleDSX instance handle
[in]visibletrue to show window, false to hide
Returns
DX_ERROR_CODE
Return values
DSX_NO_ERRORSuccess
DSX_NULL_HANDLERInvalid handle
DSX_DCOM_NOT_CONNECTEDNot connected

◆ dsconSetBufferSize()

DSREMOTECONNECT_API int dsconSetBufferSize ( DSXInstanceHandle handle,
int bufferSize )

Set buffer size for data acquisition.

Configures the internal buffer size used for data acquisition. Larger buffers can handle higher data rates but use more memory.

Parameters
[in]handleDSX instance handle
[in]bufferSizeBuffer size in samples
Returns
DX_ERROR_CODE
Return values
DSX_NO_ERRORSuccess
DSX_NULL_HANDLERInvalid handle
Note
Call before starting measurement for best results

◆ dsconStartMeasurement()

DSREMOTECONNECT_API int dsconStartMeasurement ( DSXInstanceHandle handle)

Start measurement.

Begins data acquisition on all configured channels.

Parameters
[in]handleDSX instance handle
Returns
DX_ERROR_CODE
Return values
DSX_NO_ERRORSuccess
DSX_NULL_HANDLERInvalid handle
DSX_DCOM_NOT_CONNECTEDNot connected
DSX_NET_STARTACQ_FAILEDFailed to start acquisition (NET)
Note
Ensure setup is loaded and channels are configured before starting
See also
dsconStopMeasurement(), dsconLoadSetup()

◆ dsconStopMeasurement()

DSREMOTECONNECT_API int dsconStopMeasurement ( DSXInstanceHandle handle)

Stop measurement.

Stops the current measurement session.

Parameters
[in]handleDSX instance handle
Returns
DX_ERROR_CODE
Return values
DSX_NO_ERRORSuccess
DSX_NULL_HANDLERInvalid handle
DSX_DCOM_NOT_CONNECTEDNot connected
DSX_NET_STOPPING_ACQ_FAILEDFailed to stop acquisition (NET)
See also
dsconStartMeasurement()

Variable Documentation

◆ VER_DSREMOTE

const std::string VER_DSREMOTE = "1.1.3.24"

DSRemoteConnect library version string.

Definition at line 141 of file DSRemoteConnect_Documented.h.