06-28-2013 02:43 PM - edited 06-28-2013 02:44 PM
First off let me say, I understand sending any sort of heartbeat in a timeout case is not a good practice. What I am looking for here is why this is happening.
I am launching a VI in its own loop using the "start asynchronous call" VI. The launched process then loads a large HTML file into an ActiveX web browser. When this loading happens, the event structure of the loop that originally did the launching doesn't timeout and no heartbeat message is sent. Can anyone speak to the reasoning of this? Is the event structure somehow being blocked by the ActiveX doing stuff in the UI thread. At first I thought my whole application was hanging, but then I pulled the heartbeat out into its own loop that sends it every 100 ms and the problem went away. It is obviously related to the event structure itself. The included VIs and HTML file reproduce the problem.
Thoughts?
Edit: It won't let me post the HTML file (or a ZIP file with the HTML file in it); you will have to download it from the LAVA link above.
06-28-2013 03:45 PM - edited 06-28-2013 03:47 PM
@for(imstuck) wrote:
First off let me say, I understand sending any sort of heartbeat in a timeout case is not a good practice. What I am looking for here is why this is happening.
I am launching a VI in its own loop using the "start asynchronous call" VI.
Wouldn't it be nice if you loaded the FP into memory?
06-28-2013 03:51 PM - edited 06-28-2013 03:58 PM
@JÞB wrote:
@for(imstuck) wrote:
First off let me say, I understand sending any sort of heartbeat in a timeout case is not a good practice. What I am looking for here is why this is happening.
I am launching a VI in its own loop using the "start asynchronous call" VI.
Wouldn't it be nice if you loaded the FP into memory?
I'm confused...am I doing something wrong? Is this a "feature" you wish NI had available. Sorry if I'm being dense. Proof that ActiveX is the culprate of the large delay is that if you disable the loading of the file into the active X control, there no longer is an issue. Obviously there is some delay due to the start asynch call taking some time to execute, but it's no where near the 3.5 seconds I'm seeing when I load a file into the browser.
06-28-2013 04:12 PM
I'm not seeing your problem. It works just fine for me.
Windows 7 64-bit, LabVIEW 2012SP1 with f3 patch.
06-28-2013 04:21 PM - edited 06-28-2013 04:28 PM
@crossrulz wrote:
I'm not seeing your problem. It works just fine for me.
Windows 7 64-bit, LabVIEW 2012SP1 with f3 patch.
Seriously? Ugh. It's happening on my customer's computer also (which is a touch screen from NI, single core crummy etc etc).
I am noticing it is now intermitant since I rebooted my computer, but every now and then it still does happen.
Edit: starting to think it may have to do with CPU hits. I was hitting 100% before; now I'm not. The thing that I found strange was hitting 100% didn't effect the heartbeat if I had it in another loop. Maybe I need to continue doing my debugging to narrow it down further.