LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Maximum Array Sizes

Hi all,

Is there a maximum on the size a 1D array of double precision data can be?

I have a VI that is reading data from a queue and appending it to an array and at around ~300,000 points the array stops appending?

This is despite seeing 600,000+ points being written to it.

Any advice on an alternative? I've been using a 1D array as its passed through the SVE to a Waveform graph but I'm sure this isn't particularly efficient.

0 Kudos
Message 1 of 13
(3,992 Views)

Theoretically you can make array with 2^32 elements, but really memory limited.
But If you have a problem with memory, you'll get error message.
Try allocate array before fill it
Or show your code for check

q.png

0 Kudos
Message 2 of 13
(3,968 Views)

Hi thanks for the reply.

I unfortunately can't allocate the array before use as it is of variable size and it's important that there are no extraneous elements.

I've shown attached an image showing the code that I have trouble with.

I neglected to mention this is on a cRIO RT target, hence the FPGA interfacing.

0 Kudos
Message 3 of 13
(3,956 Views)

Oh! with FPGAs and it was necessary to begin.
Of course this is too large an array and so it is impossible.
You have the FIFO buffer, so, wait for necessary size and get all elements as array not by one.
I do not currently have a FPGA module, I can not make an example, but I think it should be standard.

Message 4 of 13
(3,949 Views)

I dont think there is a limitation to the size of the array. I think that your FPGA FIFO might be full or the FIFO is not sending the data because of the timeout in the FPGA. If possible upload the FPGA vi screen image or give the details of the FPGA acquisition.


CLD Using LabVIEW since 2013
Message 5 of 13
(3,944 Views)

I see.

I was hoping to have the UI graph indicator update as it went along. Would it be more sensible then to use a waveform chart and just send single values at a time rather than shift registering a large array with all the values?

0 Kudos
Message 6 of 13
(3,943 Views)

It's not the FIFO I don't think. I have a latched indicator connected to the timeout that would indicate if it times out at any point and that remains false throughout.

0 Kudos
Message 7 of 13
(3,935 Views)

The image shown is the RT VI.  There you can have variable sized arrays.


Certified LabVIEW Architect, Certified Professional Instructor
ALE Consultants

Introduction to LabVIEW FPGA for RF, Radar, and Electronic Warfare Applications
0 Kudos
Message 8 of 13
(3,922 Views)

That's what I thought. It isn't the variable sized arrays that are causing the issue.

I think I may have resolved it though, I was foolishly using a waveform graph instead of a chart when I only want to update one point at a time - something the chart does better anyway. Thanks

Message 9 of 13
(3,917 Views)

In the snippet you have shown, you are appending to an array. Each time you appended to an array it makes a new buffer for the new array, thus you can run out of memory quickly. Can you allocate the array beforehand and insert into the array instead of appending?

 

mcduff

0 Kudos
Message 10 of 13
(3,902 Views)