03-14-2017 11:16 AM
Hello.
Im triing to do a typecast for this variant (content below as copy/pasted from a probe of my variant).:
'topic' -> "pupil"
'norm_pos' -> [2]
(430.396E-3, 726.106E-3)
'method' -> "2d c++"
'confidence' -> 858.839E-3
'timestamp' -> 717.154E+3
'id' -> 0
'ellipse' -> {[2]
, [2]
, 137.336E+0}
'diameter' -> 64.408E+0
I thought to create a cluster which contains the above variablenames (topic,nor_pos,...) and variabletypes (string, array of doubles, ...) and insert the variant as well as the type template (my cluster definition) to some function. I never did typecasts in labview and would need some help here which functions to use for that.
Thanks a lot!
03-14-2017 11:23 AM
Important: save your cluster as Type Def. control!
03-14-2017 11:47 AM
That variant data looks more like variant attributes than a cluster the was cast to a variant. Where is the variable coming from?
03-14-2017 02:33 PM
I'm attaching a Cluster that resembles the text you showed. I took a few liberties with spelling (removing unneeded underscores) and capitalization. I left "Ellipse" as a blank Cluster, as I couldn't figure out what this was supposed to be from your post (is it an array? something else? Don't know). This has been saved as a TypeDef called "My Cluster.ctl" (on my PC) ...
Bob Schor