Forum

Forum Navigation
You need to log in to create posts and topics.

Set servo (gripper) with command python

Hi,

I use your robot with python command and send messages for the movements work well, but I have a problem with the gripper.

With your software dorna, I can set the gripper, but I can't with python command. For exemple, when I do this, it doesn't work.  :

>> robot.play({"command": "set_io", "prm": {"servo": 500}})
'[{"id": 60, "state": 0, "error": null, "message": null, "command": "set_io", "fulfill": true, "prm": {"servo": 500}}]'

And when I test the io, I think it don't find the servo but a laser. Also that i haven't a laser. :

>> robot.io()
'{"out1": 1, "out2": 1, "out3": 1, "out4": 1, "in1": 0, "in2": 0, "in3": 0, "in4": 0, "do1mo": 1, "do2mo": 1, "do3mo": 1, "do4mo": 1, "di1mo": 0, "di2mo": 0, "di3mo": 0, "di4mo": 0, "servo": null, "laser": 1}'

Maybe I just forget a command for set my gripper but i don't find the solution, can you help me ?

Thank you and excuse my English

Boris

Boris,

We will take a look into the issue. Could you please confirm the software and the API version that you are using. Also please make sure you update the firmware after you switch between the older version of the software and the API (not needed for the new version of the software )

Hi,

Thank you for you answer. For the software, i use Python 3.7 (64-bit) and this dorna API :

https://github.com/dorna-robotics/dorna/releases

And i used the function .update_firware() before .set_io for the gripper.

 

Ask me more if you want more information

Thank you for your time

Boris

 

Hi,

Try this method, it can work with my robot :

cmd='{"command":"servo","prm":500}'
robot.play(cmd)

 

Jzn

 

It works ! Thank you, it was the method I research, others dont' work for me.

Best regards

Boris