01-12-2012 03:39 AM
Hi all,
There is probably a extremly simple solution to this, but I didn't manage to find it !
I use LabView 2009 and 2010.
I'd like to concatenate the strings "Dev4" (device chosen by the user in the GUI) and e.g. "PFI0" to get a string that I could connect directly to a DAQmx vi.
Is it possible to do that ?
Thanks a lot for your help !
JB
01-12-2012 04:00 AM
You should be able to wire it direct, if not you use the attached vi.
01-12-2012 04:39 AM
Hi,
Thanks for your answer.
However, I don't know what you mean by "wire it direct", and I cannot open your vi either with LV 2009 or 2010.
Thanks,
Cheers,
JB
01-12-2012 04:46 AM
Just do a variant to data as shown, make this in to a vi.
01-12-2012 05:14 AM
Hi,
In the help of labview, look for "Physical Channel Syntax", you have the description of daqmx channel syntax.
With this you can use string to generate your daqmx channels (see the screenshot).
Yoann
01-12-2012 06:09 AM
Great, thanks a lot !
11-07-2012 08:19 AM
Hi,
I'm back again with this problem.
Concatenating strings works fine for strings like "Dev3/ai0" for example, like this:
but when I try to do the same kind of thing for a ai trigger source (in my case "/Dev3/PFI1"), it doesn't work. Here is how I try to do it:
When I put a probe on the wire at the far right of the screen capture above, I get what I want, ie "/Dev3/PF1", but no trigger are received and there is no error message. Everything works fine when I simply use a constant like this:
I don't really understand why it doesn't work. Any clue ?
Thanks for your help !!
11-07-2012 08:55 AM
Maybe it is because the name you are using are not the same as the port
You use PF1, but the name in should be PFI1
11-07-2012 09:07 AM
@dkfire wrote:
Maybe it is because the name you are using are not the same as the port
You use PF1, but the name in should be PFI1
And you really do not need the varient to data function. DAQmx actually looks up those purple wires by the string displayed in the control wired in anyway so only the string is important. Wire in a string and you are good to go.
11-07-2012 09:47 AM
Ooooops !
It works... I really need new glasses !
All the best,
JB