Roles No Roles
Full Name Hans Haase
Company (optional) KHM
Hi! Yes I managed that you can see here:
Do you need realtime change of your path? Or is it OK to once generate your trajectory and then just give the robot a go to perform a certain movement?
This can be tricky, because you need to take care of the exact syntax. Look how my Python script looks like:
cmd_str = "def socketdriverProg(): " + "\n"
cmd_str += " " + "if q == 2.0:" + "\n"cmd_str += " " + "servoj(get_inverse_kin(p[q,q,q,q,q,q]), t=%f)" % (servojTime) + "\n"cmd_str += " " + "end" + "\n"Take care of control character, space etc. when sending the script. Try first something very easy like switching an I/O or s.th to the that the communication in general works.
In the end I send the program as one long string to the port.
As I wrote you need to take care of the characters, including the whitespace character. URScript works like Python so whitespace character is an issue so thats why I included them in my string.
Make your program easier for beginning just to see if the syntax is correct:
my_str="def testPopUp():\n ";
my_str+= "popup(\”Messages\”, title=\”The Headline in the Blue box\”, blocking=True)\n";
The exact syntax I don't know because I don't know much about c++
It works now. Sponge suspension is not working, thats the reason why the line is not comletly gone.
Thanks for your help.