![]() |
script to automate vnc connection
hello,
i'm asking if it is possible to make a script for auto connection to a specific ip. basically the script should do this: - open vnc viewer - open connection on choosen ip - pass the vnc password i understand that is not correct to ask for the script itself (but if someone have already made it it will be great :-) ) and i'm not a total noob, but my knowledge are limited to windows and high level programming (.net, java), so if make the script is not so hard some advice on how to do that will be appreciated thank you all giovanni |
Re: script to automate vnc connection
Have a look at the excellent Presence VNC. With it you can save the password associated with an ip address, so all you have to do on startup is select the ip (you don't even need to do that if you only have one saved) and press connect.
I'm not sure if VNC Viewer has been updated of late, but Presence VNC had just about everything you needed and was much much more touchscreen friendly by the time I removed VNC Viewer last year. |
Re: script to automate vnc connection
Presence VNC still doesn't let me do the one thing I want to be able to do - move scroll bars in the window I'm VNC'ing to, as it just moves the screen around. Unless that feature is there, and I've just not read about it at all.
|
Re: script to automate vnc connection
Quote:
|
Re: script to automate vnc connection
VNC eneter a wibble !&9
|
Re: script to automate vnc connection
i will try presencevnc but the scrollbar "bug" is a bad thing also for me...
anyway i' looking for a 1 click solution, like a shortcut on desktop that do what i explain. searching this forum i found a thread with sample code to realize a script to do a similar thing. i try it but it give me an error... this is my script (sorry i dont know the tag to put it in a 'code' box) -------------------- #!/bin/sh # Waits for machine to boot and keeps trying to access it (retries only with ssh) # by Cue from maemo talk initialwait=10 retrywait=10 waitmessage() { count=$1 while [ $count -ge 0 ] do sleep 1 clear echo $2 $count $3 count=`expr $count - 1` done } # is there the right number of arguments if [ $# -ne 1 ] && [ $# -ne 3 ] then echo "Usage $0 00-17-C4-40-BE-6D marie 192.168.1.4" exit 2 fi if [ $# -eq 3 ] then ssh $2@$3 error=$? else error=1 fi if [ $error -ne 0 ]; then echo "machine probably not on. sending magic packet." #wake machine with previously written shell script #/home/user/MyScripts/wakeonlan.py $1 #use this instead if you use the indirect wake on lan script #/home/user/MyScripts/wakeonlan.sh $1 error=$? if [ $error -ne 0 ] then echo "wake on lan script was not found encountered an error" else #Wait for "initialwait" seconds for machine to boot echo "Magic Packet Sent" waitmessage $initialwait 'Waiting' 'seconds for remote machine to boot' echo "apro vnc" vncviewer if [ $# -eq 1 ]; then vncviewer else while true do ssh $2@$3 error=$? if [ $error -ne 0 ]; then waitmessage $retrywait 'Retrying in' 'seconds, press Ctrl+C to exit' echo "Trying to connect" else break fi done fi fi fi ----------------- the error is: ERROR:maemo-vnc-viewer.c:50:create_data: assertion failed: (result->osso) Aborted any idea? |
Re: script to automate vnc connection
That's way above my level of competence, so I can't help you there sorry. However I just did a google search for your error code and found this from a previous version that ran on the NITs. Maybe it can be of assistance.
FWIW I've just being having a look at the preferences in PresenceVNC and rediscovered that you can assign mouse wheel up and down to the volume rocker, which can help with the scrollbar issue. For your script you might want to ask in the PresenceVNC thread, maybe the author could assist you anyway. |
Re: script to automate vnc connection
Quote:
- Edit - Quote:
|
All times are GMT. The time now is 04:57. |
vBulletin® Version 3.8.8