Adds a Network cDAQ device to the system and, if specified, attempts to reserve it.

Syntax

Namespace: NationalInstruments.DAQmx

public Device AddNetworkDevice(string ipAddress, string deviceName, [MarshalAs(UnmanagedType.U1)] bool attemptReservation, double timeout)

Remarks

MAX automatically attempts to reserve a device when the device is added, but this method does not, unless attemptReservation  is set to true.

Parameters

NameTypeDescription
ipAddressstring

Specifies the string containing the IP address (in dotted decimal notation) of the device to add to the system.

deviceNamestring

The name to assign to the device. If unspecified, NI-DAQmx chooses the device name.

attemptReservationbool

Specifies whether a reservation should be attempted after the device is successfully added.

timeoutdouble

Specifies the time in seconds to wait for the device to respond before timing out.

Returns

The device object the operation applied to.

Exceptions

TypeDescription
NationalInstruments.DAQmx.DaqException

The NI-DAQmx driver returned an error.