Pick and Place with RV-2AJ Arm

On this project, I worked together with Barabas Szabolcs and Barabas Antoniu in the summer of 2010. The goal was to control the RV-2AJ robotic arm with a Graphical User Interface in which Virtual Reality simulation is integrated. Meanwhile, we added another feature, pick and place, with object location and position detection.

The GUI and the simulation are similar to my first project, so the challenge was to control the robot and automate the pick and place process. The communication between the GUI and control unit of the arm is based on TCP/IP protocol. In the program, we calculated the joint angles from the desired certain coordinates of the gripper using the inverse kinematics of the arm. We were sending the COSIROP commands (the programming environment for Mitsubishi robots) to set the desired joint positions. The robotcontrol.m file contains the commands sent to the arm controller. We used a wrist-mounted webcam to detect the object's position and orientation. The implementation can be found in the camera.m file, but this is part of the main program, so it won't work alone as an *.m file.

The robot had four types of control modes:

  • direct joint control, setting the angles of the links,

  • end-effector control, giving the position and orientation of the gripper

  • end-effector control with joystick

  • pick and place objects

The application can be found at the bottom of the page: RV-2AJ_V3.6.zip


The equipment:

  • RV-2AJ 5-Axis Robot Arm

  • CR1-571 Robot Controller Unit

  • R28TB Robot Teach Pendant

  • Webcam

Developed Graphical User Interface:

Matlab GUI communicates on TCP/IP protocol.

  • Direct and inverse control or by joystick

  • Image processing

  • Simulation

  • Virtual Reality

Robot control commands

Classical MelfaBasic4 commands were used to control the robot but with command prefix “EXEC”. Thanks to Freire's and Santiago's thesis here is a list of some useful commands:

  • CNTL control (smooth movements)

  • CNTLON enable smooth control

  • CNTLOFF disable smooth control

  • PPOSF get robot position (x, y, z, a, b)

  • MOV move

  • EXECMOV move to a position in the list

  • RSTALRM reset alarm

  • SPD designate the speed

  • EXECSPD set the speed

  • EXECCOSIROP set final robot position

  • MVS move S

  • EXECMVS PCOSIROP

  • JOVRD J override

  • EXECJOVRD

  • EXECJCOSIROP set move parameters x, y, z, a, b

  • J_CURR

  • EXECMOV J_CURR + JCOSIROP

  • SERVO

  • EXECSERVO ON

  • EXECSERVO OFF

  • HOPEN/HCLOSE

  • ECECHOPEN/EXECHCLOSE