From Friday, April 19th (11:00 PM CDT) through Saturday, April 20th (2:00 PM CDT), 2024, ni.com will undergo system upgrades that may result in temporary service interruption.
We appreciate your patience as we improve our online experience.
From Friday, April 19th (11:00 PM CDT) through Saturday, April 20th (2:00 PM CDT), 2024, ni.com will undergo system upgrades that may result in temporary service interruption.
We appreciate your patience as we improve our online experience.
07-28-2011 02:47 AM
Dear All,
Let me explain my set up first:
I am communicating with 3 modbus devices paralllely, means i have 3 while loops in parallel to read register.
After reading these register i am inserting the values in the database.
I am using 3 different vis for all 3 loops ( not reentrant).
Also i am opening & closing the visa and database connection in the loops.
The monitored the cpu usage and the memory, they are not increasing and are steady.
Problem: While i am running the above setup for a day then after about 16-20 hrs the program stops,
i am not understaning as 3 parallel loops are running with different vis, then also all the 3 loops does'nt respond.
Can anyone suggest anything,
Thank you in advance.
Regards,
Shrek
07-28-2011 08:58 AM
Have you considered NOT opening and closing the resources within the loops? If you are doing something repeatedly, then constantly opening and closing resources may be causing problems like a memory leak.
Are all 3 VI's accessing the same resource? If so, you might want to create a VI that is a single point of access for a given resource and let the 3 parallel VI's all interact with that.
07-28-2011 11:44 AM
I'm giving a kudos for adverb invention.
07-29-2011 12:09 AM
Thanks for the reply,
________________________________________________________________________________________________________________________________________
Have you considered NOT opening and closing the resources within the loops? If you are doing something repeatedly, then constantly opening and closing resources may be causing problems like a memory leak.
________________________________________________________________________________________________________________________________________
In some of the document from NI only i have read that the connection opened should be closed or the memory size will increase.
I am experiencing the problem of memory size increase when i am not closing the connection (in other application).
________________________________________________________________________________________________________________________________________
Are all 3 VI's accessing the same resource? If so, you might want to create a VI that is a single point of access for a given resource and let the 3 parallel VI's all interact with that.
______________________________________________________________________________________________________________________________________
All the 3 loops contains Modbus master vi which polls for a specific device and inserts that value in the same database. I tried doing it with reentrant vi,
Calling the same (reentrant) vi in all the loops but the modbus comm. was giving error.
Regards,
Shrek