Is a reliable interaction between LabVIEW Client and GreenMode.Asyncio DS possible?

Hi everyone, I am wondering if it is possible to work from LabVIEW client with a GreenMode.Asyncio DS? I simply update a scalar double DS attribute from a VI. When DS Asyncio mode is used, after some times writing I get the error:

Error -1 occurred at tango.lvlib:_TangoExceptionToLabviewError.vi

Possible reason(s):

[TangoWriteAttributes.vi] - ERROR - API_CorbaException - TRANSIENT CORBA system exception: TRANSIENT_CallTimedout - DeviceProxy:write_attributes - ERROR - API_DeviceTimedOut - Timeout (3000 mS) exceeded on device test/lvproxy/1 - DeviceProxy:write_attributes
Complete call chain:
tango.lvlib:_TangoExceptionToLabviewError.vi
tango.lvlib:_TangoWriteAttributes.vi
tango.lvlib:_TangoWriteDoubleScalarAttribute.vi
Sinus Generator.vi


No problem, if I don't use Asyncio or hide it behind a synchronios interface.
Hi ALex,
Can you confirm that your pyTango device behaves properly with another client?
E.g. a simple pyTango one or even Jive.
Edited 2 weeks ago
Hello Nicolas,
No, i can not…
Here is the test DS:

class LVProxyAsync(Device):
green_mode = GreenMode.Asyncio

async def init_device(self):
super().init_device()
self._sinus_signal=float('nan')
self._saw_signal = float('nan')
self.set_change_event('sinus_signal', True, False)
self.set_change_event('saw_signal', True, False)
self.set_state(DevState.RUNNING)
self._values={}

@attribute(dtype=float)
async def sinus_signal(self):
return self._sinus_signal

@sinus_signal.write
async def set_sinus_signal(self, nValue):
self.debug_stream(f"Write Sinus: {nValue}")
self._sinus_signal = nValue
self.push_change_event("sinus_signal", nValue, time.time() , q.ATTR_VALID)

@attribute(dtype=float)
async def saw_signal(self):
return self._saw_signal

@saw_signal.write
async def set_saw_signal(self, nValue):
self._saw_signal=nValue
self.push_change_event("saw_signal", nValue, time.time() , q.ATTR_VALID)


Here is the test code:
from tango.asyncio import DeviceProxy as aDS
import numpy, asyncio, tango

lvproxy_async = await aDS("lvproxyasync/lvproxyasync/1")
for i in range(100):
try:
await lvproxy_async.write_attribute("sinus_signal", numpy.sin(i))
await lvproxy_async.write_attribute("sinus_signal", numpy.sin(i))
await asyncio.sleep(0.1)
except:
print(f"Error after {i} try")
break

I think more easier is not possible… I will ask pyTango community.
Edited 2 weeks ago
Yes, please ask the pyTango experts what they think about the problem and let see what I could do to help.
OK, here come some confusing details…
I have assumed that my Windows setup is again the problem. So I have moved the DS to Ubuntu VM where my Tango config DB also lives.
But at the end Jive-ATK-monitor panels seems to be causing the problem. It's like Schrödinger's cat: alive as long as you don't look at it. As soon as you start ATK Monitor, errors come up.
Ok. Can you please validate the implementation of your python device with the experts? Just to be sure that it's not the root cause of your problem. The reported error is a timeout that tends to reveal a response time problem on server side. The fact that you also observe the problem with Jive reinforce the idea of a problem in the server behavior. You don't think I can help you more. I simply invite you to post on the Python dev forum.
 
Register or login to create to post a reply.