08-12-2010 01:52 PM
I have a work around for this based on posts here, but I thought I might pose this question anyway. I have a shared variable that I use to initiate communication (a simple time stamp sent from the host). The SV tells the server that it is listening and that it can commence execution. As such, I have a wait on the SV set to wait forever (until a fresh value is found). Now, regardless of whether I read the SV to clear the buffer and set up the subscription the wait only seems to execute properly in two cases:
To get everything talking correctly, I do the former, but this is still irritating. Can someone please explain to me if I am doing something incorrect or is this expected behavior? It is a little disconcerting that I have to do this (and just a little cumbersome when I am in the process of trying to debug an application and hence having to due the first case over and over again).
Peace, Matt
08-19-2010 03:03 PM
Have you tried writing to clientTime once (on both target and host) before using it? i.e. in an initialization routine on startup.
08-20-2010 10:02 AM
Hey Arrow,
Thanks for the reply. Soooo...
It is indeterminate ahead of time which will turn on before hand (stupid users ), so I can't rely on the host coming on before the target. The variable clientTime is a heartbeat, so I need to be able to poll this value beforehand (it will tell the target whether the host is active). The odd thing about this that it works if I undeploy and redeploy; and it works when I put the value in a loop; it just doesn't work as above. Go figure.
One thing that I failed to mention above is that the variables are hosted on the target.
Peace, Matt