NI Home > Community > NI Discussion Forums

Multifunction DAQ

Showing results for 
Search instead for 
Do you mean 
Reply
Member
HRGartenbauer
Posts: 4
0 Kudos
Accepted Solution

how to use the 9191 IP Address as device name in DAQmxCreateAOCurrentChan

I have a 9265 analog out unit in a 9191 chassis.

Can I use the IP address in the name of the physical channel in the call to DAQmxCreateAOCurrentChan?

For instance, "192.168.1.4/ao0".

I thought I saw this somewhere in the documentation, but it does not work.

Is this possible?

Active Participant
margasan
Posts: 226
0 Kudos

Re: how to use the 9191 IP Address as device name in DAQmxCreateAOCurrentChan

Hello HR,

 

My first answer will be no, as the Create Channel VI uses the Alias that the device has in MAX to create a reference, and you can not put the IP address as the device name as MAX does not allow you to do that. Can you tell me where did you find that information??

 

Regards

 

Mart G

Member
HRGartenbauer
Posts: 4
0 Kudos

Re: how to use the 9191 IP Address as device name in DAQmxCreateAOCurrentChan

I'm not sure where I saw it, and I can't find it again, so probably I am mistaken.

In the MAX program, the help string for the 'Hostname' says:

"""

Enter a name for the remote system. This field is limited to 31 characters and can contain only alphanumeric characters and hyphens. The name cannot start or end with a hyphen. If you do not enter a name, the remote system is identified in the configuration tree by its IP address.

"""

which implies that it will use the IP Address for the device name?

 

Active Participant
margasan
Posts: 226
0 Kudos

Re: how to use the 9191 IP Address as device name in DAQmxCreateAOCurrentChan

Hello HR,

 

I believe that applies to Real Time Targets and does not apply for cDAQ chassis or carriers.

 

Regards

 

Mart G

Active Participant
Tom_W_[DE]
Posts: 1,718
0 Kudos

Re: how to use the 9191 IP Address as device name in DAQmxCreateAOCurrentChan

Hey All-

 

To add to Mart's post, the restriction on hostname contents is one that is chosen for best compatibility with network naming systems.  See here for some more background; excerpting:

 

The Internet standards (Request for Comments) for protocols mandate that component hostname labels may contain only the ASCII letters 'a' through 'z' (in a case-insensitive manner), the digits '0' through '9', and the hyphen ('-'). The original specification of hostnames in RFC 952, mandated that labels could not start with a digit or with a hyphen, and must not end with a hyphen.

 

If you modify the hostname of a cDAQ-918x/919x chassis before you Add it to the system (via DAQmx Add Network Device or in MAX), the DAQmx Device Name will be assigned as the hostname and can be addressed using DAQmx I/O controls in LabVIEW.  This might be useful to you if you are choosing descriptive hostnames (e.g. "PumpRoomChassis1"), but you still wouldn't be able to assign the IP address as the hostname.

 

One other technology you might be interested in for correlating IP addresses and hostnames (and, by extension, DAQmx names) would be the NI System Configuration API.  This article links to some other references for the NI System Configuration API.

 

Hopefully this helps-

Tom W
National Instruments