elephantrobotics / pymycobot

This is a python API for ElephantRobotics product.
MIT License
107 stars 54 forks source link

jog_coord does not behave as I thought it would #71

Open michelle-aa-robotics-photonics opened 2 weeks ago

michelle-aa-robotics-photonics commented 2 weeks ago

Describe the bug I'm trying to get the robot to grasp an upright optical element by bracing the claw against the "lip" and moving vertically upward (with no rotation of the claw). My understanding based on https://docs.elephantrobotics.com/docs/pdf/myCobot-en.pdf is that the coordinates of the head of the robot are encoded as [x, y, z, r_x, r_y, r_z]. In order to move vertically upward, I thought I would simply jog coordinate z, and the other coordinates would remain fixed (i.e., no rotation or lateral movement). However, when I send jog_coord(3, 1, 1), (which should be telling it to increase it's z-axis coordinate at a speed of 1), the head rotates while it moves upward.

https://github.com/elephantrobotics/pymycobot/assets/173008148/4fcc8382-d8be-4b99-b384-6b1f0d0ff624

https://github.com/elephantrobotics/pymycobot/assets/173008148/ca92a2f5-ea40-4637-80dd-4f48dda8a8ab

To Reproduce Steps to reproduce the behavior:

  1. Lay the robot arm out flat on the ground
  2. Send jog_coord(3, 1, 1)
  3. Send jog_coord(3, 0, 1)
  4. See that the gripper rotates as the arm moves upwards.

Expected behavior I expect the head of the joint to hold the same rotational and x-y coordinate (visually stay steady) as the arm moves up in the vertical direction.

Screenshots Videos are attached.

Desktop (please complete the following information):

Smartphone (please complete the following information):

Additional context Add any other context about the problem here.