This is the closest thing to a pinout I could find for the PXIe-2525. You will have to check connectivity between the 160 pin connector and the 50 position terminals.
NI MAX 2020 doesn't list this board.
GUID-04647FDC-4447-45DA-9BB2-4E10EA993437-a5.svg
You will have to convert the OpenCV MAT to LV picture. The MAT object has a ToBitmap method, which can generate a LV compatible bitmap.
I attached a VI that uses the EmguCV .NET wrapper.
The next question is what removes measurements from this array? Except the INIT command, there is nothing that reduces its size. Over time, with new measurement names, it will always increase in size.
If you have a permanent license of LV, stick to it. The current subscription model is way too expensive for a casual (<2 projects/year) user. NI didn't add any compelling features to LV since adding maps (2019?).
You have to divide this problem into smaller parts:
1. Detect start, top and bottom positions of the potentiometer
2. Calculate distance based on potentiometer position.
4. Calculate speed (distance over time)
5. Detect repeats.
6. LabVIEW has the XY graph control, it can create a bar display.
Your image source is U8 grayscale, your destination is floating point double. Are you sure this is correct? Also, try using a different image other than one from the stack - pass another NIIMAGE to calibrate_response. I think you are overwriting the 1st image in the stack.
Are you on Windows? If so, the .NET picturebox control is faster than the native LV control for such operations. It also has other nice features, such as double buffering.