03-25-2020 07:48 AM
I am Controlling a device that requires an 1d Array of 1d Arrays as Input. It does not work if I connect an 1d or a 2d Array to it. When i automatically "create Control", it produces an empty Array and the error remains.
How can i create the correct data type or circumvent the Problem?
Thanks a lot!
Error Msg: "You have connected an array data type to its element data type. This type conflict may be resolved by indexing the array to access individual elements of the array. Check for a tunnel on a loop that has indexing incorrectly enabled.
The type of the source is 1D array of
long [32-bit integer (-2147483648 to 2147483647)].
The type of the sink is 1D array of
1D array of
long [32-bit integer (-2147483648 to 2147483647)]."
03-25-2020 07:57 AM
You can't create an array of arrays directly in LV, you either have to create an array of clusters containing arrays, or an array of variants that can be arrays. I don't think either works as input to this function though, but it's worth a try.
/Y
03-25-2020 08:32 AM
That argument has both an input and output node. If you click create indicator on the output node, does it also make an error wire?
Saying "Thanks that fixed it" or "Thanks that answers my question" and not giving a Kudo or Marked Solution, is like telling your waiter they did a great job and not leaving a tip. Please, tip your waiters.
03-25-2020 08:52 AM
Thanks for the Suggestion. Unfortunately you were Right and it doesn't work either:
These cannot be wired together because their data types (numeric, string, array, cluster, etc.) do not match. Show the Context Help window to see what data type is required.
The type of the source is 1D array of
cluster of 1 element.
The type of the sink is 1D array of
1D array of
long [32-bit integer (-2147483648 to 2147483647)].
03-25-2020 08:54 AM
yes, creating an indicator at the Output also produces an empty Array and the error remains.
03-25-2020 09:17 AM
I don't think this will work either, but the absolutely closest match much be an array of array-DVRs. 🙂
/Y
03-25-2020 09:41 AM
Solved - I found an extra function from the device manufacturer that converts the LabVIEW Array cluster into the correct type of "jagged Array". It seems to be impossible on a fundamental Level in LabVIEW to define the correct data type directly.
Thanks everyone
02-05-2021 10:18 AM
Hi, could you please tell me the name of the function that converts the LabVIEW Array cluster into the correct type?
02-08-2021 09:33 AM
The thing that worked for the OP is unlikely to help you, as that seems to be a function which is specific to that driver and seems from the documentation to use a separate C++ or .NET class to allow that functionality for the LabVIEW wrapper - https://www.swabianinstruments.com/static/documentation/TimeTagger/sections/api.html#coincidences
You can create the relevant data type in LV using a 1D array inside a cluster inside a 1D array. That way, each internal array can have a different size.