Machine Vision

cancel
Showing results for 
Search instead for 
Did you mean: 

Remaining delay memory

I did a program on LV 2012 to recognize pattern matching images in real time with NI IMAQdx and Basler Cameras through networking connection, in many parts of the code I used shared variables to carry the data along the proyect.
The program was successful and I compiled it to generate the executable but working with executable I could see some problems, strangely when I used long time the program it become to take slow on the acquisition of images, it seems to be a remaining in memory that take hard the process to do in real time.
I would like to know what is the best performance on a program with this characteristics avoiding whatever delay that affect the acquisition image in real time.
0 Kudos
Message 1 of 2
(4,581 Views)

Hello Seifer,

 

Make sure that you are enabling the RT FIFO option in the shared variables properties when transfering data between deterministic structures (i.e timed loops) or between deterministic structures and non deterministic structures (i.e between a tiemd loop doing Real Time tasks and a normal while loop doing some non deterministic job like logging).

 

"Use Shared Variables Effectively (Real-Time Module)"

http://zone.ni.com/reference/en-XX/help/370622K-01/lvrtbestpractices/rt_bp_svars/

 

A second option you could use for inter-process communications is the RT FIFO function instead of shared variables (would do the same).

 

"RT FIFO Functions"
http://zone.ni.com/reference/en-XX/help/370622L-01/lvrtvihelp/rtfifovipal/

 

Basically, what both options tells us is that we should make sure to be using a deterministic FIFO (instead of a non deterministic FIFO like queues) when transfering data between deterministic structures or between deterministic structures and non deterministic structures, in the same VI (this is called inter process communication) to mantain determinism.

 

 

Regards,

 

Daniel C.

0 Kudos
Message 2 of 2
(4,556 Views)