01-26-2016 12:25 PM
Ha! Thanks for catching that, sometimes you get so wrapped up in your own head...
The "Is Not Equal To Zero", of course, converts non-zero data to boolean TRUE. The NOT operator was included because I realized that my RS422-to-TTL converter inverted the data.
I'll go back and replave both with "Is Equal to Zero". Nice catch.
01-26-2016 01:25 PM - edited 01-26-2016 01:26 PM
James.Morris wrote:
Why do you suggest only reading 24 samples at a time? Wouldn't reading a larger chunk of data and then processing it in a parallelized For loop be faster?
Producer/Consumer In other words, have this loop read the 24 bits and then send it off to another loop for processing. It saves some of the array manipulation (1D to 2D function). And you can't guarantee the parallelized FOR loop since that does add overhead.
But here is also another possibility for the conversion. Since you already have U32s, just shift the data by the bit number and add. This will save the whole conversion from U32 Array to Boolean Array and then to U32. Not completely sure if it is more efficient as I have not ran any benchmarks.
Also note that I have a wait in the FALSE case of that case structure, so that loop is not greedy.
01-26-2016 01:49 PM
I'll give that a shot. Note: For some reason the DAQ is returning U32s that are either ZERO or TWO, so I would have to account for that.
This looks like an excellent FPGA solution, not sure if the i7 architecture can't do better with the matrix operations though.
01-26-2016 03:06 PM
@Jed_Davidow wrote:
For some reason the DAQ is returning U32s that are either ZERO or TWO, so I would have to account for that.
That seems strange to me. But if that is what you are getting, then you could just do the shift by i-1. Simple fix.
01-26-2016 07:29 PM
use array resize icon and resize it to 2d array with 24 column and continuous row