06-27-2013 03:28 PM
I've created a histogram by making a large array with 600 elements for each of the bins. The histogram is working in that it collects the data, but it doesn't retain it through the program. It resets after a while and returns to zero and continues counting. I need it to be count the entire run time. Any ideas as to the problem?
Solved! Go to Solution.
06-28-2013 01:42 PM
Here is the code that I am using with some descriptions of what each part is doing.
06-28-2013 03:51 PM
Hi sssmcd,
It appears the histogram array is continuously being added to. How many iterations is the outside while loop performing before the data reset to zero? How long does this take before it is reset to zero? It is possible that you could be reaching the numeric limits of a 32-bit integer if you have this code running for a very long time. How much data are you working with?
07-01-2013 01:30 PM
BluesKnight,
I seem to have fixed the problem by taking the output of the histogram array and adding it to the shift register. I will have to keep in mind the limits of a 32-bit integer, because it will be running for some time.
Thank you for your assistance in this matter.
ssmcd