a1tD0000006lSqfIAE

Course: Introduction to Dobot
Lesson 3: Gripper Attachment

  • 9-12 grade
  • Beginner

Lesson Description:

Objective:
Learn to use the gripper attachment for Dobot, and write code to control it.

image description

Lesson Modules


Teaching Tips:

We highly recommend that only teachers or trusted upper level students handle attachment installation.

Air Pump

The air pump is the mechanism that provides gripping and suction power to the gripper and suction cup attachments. These attachments will not function without the air pump.


Here are the instructions to complete the air pump installation:

#1  Connect power line labeled SW1 on the pump box with the interface on the Dobot labeled GP1.


#2  Tighten air pump kit onto the end of the Dobot with the butterfly nut.


#3  Connect GP3 of Joint4 servo line with forearm connector GP3, which should be the connector closest to the attachment end of the forearm.



Pneumatic Gripper

The gripper and suction cup attachments share the same air pump kit. So when switching between those two attachments it is faster to just remove the gripper or suction cup, rather than disassembling the whole air pump.

#1  If the suction cup is attached, unscrew it from the air pump with the smallest hex wrench.

(Be careful, the screws are very tiny. It might help to hold them in a water bottle cap if you are worried about misplacing them.)


#2  Install the gripper kit using the black coupler (in pictures it is metallic).

#3  When you are done, it should look like this:

(It may help to wrap some tape around the handle of the wrench)


#4  Attach the air tube to the adapter. 

(It isn't always easy to attach the tube, don't worry, you won't break it.)





Teaching Tips:

General troubleshooting:

Ensure that your Dobot is:

  • Plugged into power
  • Powered on
  • Connected to your computer via USB
  • Connected via DobotStudio

If your Dobot is not moving as you expected, press the home button and allow it to recalibrate.

We highly recommend you have an emergency stop code for the air pump in case a student runs into an error. When a code breaks, the air pump will continue to work if was operating before the code broke. Having a "When 'space' pressed, gripper stop' block section is a great way to stop the air pump without having to emergency stop.


Challenge Solution

Steps:

  1. When the Go Flag is clicked
  2. Set the end effector to gripper
  3. Set a variable to hold the end tower's Z coordinate
  4. Set to loop 2 times
  5. Jump to directly above the block's initial location.
  6. Open the gripper
  7. Wait one second
  8. Move Z coordinate down to the block
  9. Close the gripper
  10. Wait one second
  11. Jump to the end tower location, including the saved Z
  12. Open the Gripper
  13. Wait one second
  14. Increase the saved variable by the amount of Z a single block is


NOTE: The values for locations WILL differ depending on student starting and ending locations. Also, there are multiple solutions including different types of movement (using joints vs Cartesian and using jump vs relative move, etc.). The solution we've provided uses a loop and a variable z (if students haven't been taught loops or variable assignment it is understandable the movement blocks will just be repeated and numbers calculated outside of the program). BlockLab image coming soon!

BlockLab

These two blocks control most of the Gripper functionality.


Setting > Set End Effector

Tell the program what attachment you are using for the Dobot.

This block should be placed at the beginning of each program.

Motion > Gripper Close/Open/Stop

Close and open the gripper and stop the air pump during the run of the program.


Here is an example of a responsive program using these blocks:


1. Tell the program what attachment you are using for the Dobot.

2. Repeat the inner blocks (steps 3-8) 10 times.

3. Move to a location you specify.

4. Close the Gripper.

5. Pause for 1 second (and do nothing during this time)

6. Move to a location you specify.

7. Open the Gripper.

8. Pause for 1 second (and do nothing during this time)



Script

Example program in Python script - coming soon!

Challenge (see teacher tips for solution)

Write a program that:

  1. Picks up a block with the gripper
  2. Places it down in a location you specifty
  3. Picks up another block (from the same location from step 1)
  4. Places it on top of the first block

When your program is done running, you should have a stack of two blocks. Hint: Remember to give your gripper some wait time to open and close.