sikuli-driver team mailing list archive
-
sikuli-driver team
-
Mailing list archive
-
Message #48627
Re: [Question #674152]: Detect VNC disconnect
Question #674152 on Sikuli changed:
https://answers.launchpad.net/sikuli/+question/674152
Dillon gave more information on the question:
I do have a function that can be used to keep retrying to reconnect to
VNC in the event that the server is still powered off, but this still
requires a hard coded time to wait for the server to power off and power
back on.
def restartVNC(reg, ip_, port_, password_, time):
reg.stop()
log("Reconnecting to VNC connection after {0} seconds.".format(time))
wait_(time)
while(True):
try:
reg = vncStart(ip = ip_, port = int(port_), password = password_, connectionTimeout = 10, timeout = 1000)
except:
pass
if reg:
log("VNC connection reestablished.")
break
return reg
--
You received this question notification because your team Sikuli Drivers
is an answer contact for Sikuli.