Robot suction pump to carry wooden blocks

1 Functional description

The robot will use the suction pump to carry wooden blocks from point A to point B

2 Hardware connection

Insert one side of the Lego connection key into the suction pump

Then insert the other side of the Lego connection key into the quick-change servo, and then insert the gripper wire into the interface on either side of the servo

Then connect it to the gripper socket of the robot arm base

Connect one end of the suction pump wire to the suction pump box

Connect the other end of the suction pump wire to the suction pump interface of the robot arm

Install the quick-change servo to the end of the robot arm

3 Module test

After the hardware is connected, the robot arm needs to be reset

from pymycobot import ultraArm,utils

if __name__=="__main__":
    arm=ultraArm(utils.get_port_list()[0])
    arm.go_zero()

Pump test

from pymycobot import ultraArm,utils
import time

if __name__=="__main__":
    arm=ultraArm(utils.get_port_list()[0])
    arm.set_gpio_state(0)
    time.sleep(2)
    arm.set_gpio_state(1)
    time.sleep(1)

Servo test

from pymycobot import ultraArm,utils
import time

if __name__=="__main__":
    arm=ultraArm(utils.get_port_list()[0])
    arm.set_gripper_state(50,100)

4 Software Usage

Use the fast moving function of myblockly to teach the grabbing point and placement point of the wooden block, and record the position information. After teaching, you need to disconnect the serial port connection, otherwise the serial port will be reported when running the python script. The error is that the serial port is occupied.

5 Composite Application

from pymycobot import ultraArm,utils
import time

grab_point=[217.26, 68.87, 8.0, 27.0]#Grab point coordinates
place_point=[217.26, -114.13, 10.0, 27.0]#Placement point coordinates

if __name__=="__main__":
    arm=ultraArm(utils.get_port_list()[0])
    arm.set_gpio_state(0)#Turn off the suction pump first
    arm.set_angles([0,0,0,0],100)#Return to the zero point of the joint
    time.sleep(2)
    arm.set_coords([grab_point[0],grab_point[1],grab_point[2]+50,grab_point[3]],100)#Move to 50mm above the grab point
    time.sleep(2)
    arm.set_coords([grab_point[0],grab_point[1],grab_point[2],grab_point[3]],100)#Move to the grab point
    time.sleep(2)
    arm.set_gpio_state(0) #Turn on the suction pump
    time.sleep(2)
    arm.set_coords([grab_point[0],grab_point[1],grab_point[2]+50,grab_point[3]],100)#Move to 50mm above the grab point
    time.sleep(2)

    arm.set_coords([place_point[0],place_point[1],place_point[2]+50,place_point[3]],100)#Move to 50mm above the placement point
    time.sleep(2)
    arm.set_coords([place_point[0],place_point[1],place_point[2],place_point[3]],100)#Move to the placement point
    time.sleep(2)
    arm.set_gpio_state(1)#Turn off the suction pump
    time.sleep(2)
    arm.set_coords([place_point[0],place_point[1],place_point[2]+50,place_point[3]],100)#Move to 50mm above the placement point
    time.sleep(2)

6 Effect display

results matching ""

    No results matching ""