11-11-2014 10:14 AM
Try SetValVariant
11-11-2014 10:29 AM
That does not work either. Runs with no errors.
Note that SetValVariant does not allow for the object to be created. Therefore the objref_FPGA was created in TestStand as an object reference.
11-11-2014 07:41 PM
It doesn't work but runs with no errors?
So I'm not as familiar with LVOOP but I'm not sure what the object for it looks like. I don't think it is just a reference like you are thinking. I think you need to set each subproperty individually. So basically if your LVOOP cluster is like a container with a string and boolean then you need to access the cluster and set the cluster in TS.
Regards,
11-13-2014 03:00 PM
I canot access components of the private class data as if the Object Reference in Test Stand were really a container type.
This help site: http://zone.ni.com/reference/en-XX/help/370052M-01/tsfundamentals/infotopics/object_ref/
says you can set object references in Test Stand from the TestStand API. I have been able to set the Object Reference in TestStand from labVIEW to a reference like 'This VI'. I cannot however set the TestStand variable to be a 'LabVIEW Class object'. As referenced in the article you can set Object References through a code module output. I have done this and it works. So I am able to store LV Class Objects in Test Stand. NI has yet shown me that the TestStand API is able to write LV Class Objects to TestStand from LabVIEW.
Any other thoughts?
11-13-2014 03:25 PM
Here is more info...
This manual: http://www.ni.com/pdf/manuals/375070c.pdf under the section 'Using LabVIEW Classes with TestStand' there is no detail about how to change Object References from the Test Stand API. It looks like it is a relatively new change that LabVIEW Class Objects can be stored in Object References. I am using TS 2013 and LV 2013 and the update was made in 2010 as per this article: http://digital.ni.com/public.nsf/allkb/EE3EA0A08FBB6E4A862573A9004C5A07. I may use the workaround listed in that article to move on from this issue if NI does not come up with an answer or I don't see any forum suggestions.
11-17-2014 09:11 AM
So LVOOP, as far as I understand, isn't really object reference based. You are still passing around the data in the wire. So trying to assign it to a reference doesn't make sense. So what you need to do is get the cluster or values out of the object and assign them individually to the variable/s in TestStand that correspond. So for instance-
If I have an LVOOP object that has a boolean and string in it then you need some accessor function to get the string and boolean out of the object and then assign them to a string and boolean variable in TestStand. Or just pass them back through the connector pane.
Again, this is going off of my limited understand of LVOOP but that's how I see it.
Hope this helps,
11-17-2014 09:33 AM
Jiggawax,
I see what you are saying. breaking the Class Object into its individual components and into a TS Container would essentially do the same thing since the data is copied and not really a reference.
I have approached the problem differently in order to have a by reference variable in TestStand. I am relying on DVRs which I cannot write directly to a object reference in TestStand. Therefore I convert it to a binary string as a variant. If you see this causing an issue later then please advise.