This is one of 3 branches, this branch is the main app, the playground, you can only play in this branch, if you want to record data go to the "Recorder App" branch, else if you want to playback your recording, go to "Recorder App" branch.
Kinematic 2D 2 link arm for pick and place controlled by a color blob detected by an Image processing algorithm.
Download the project and open it in processing 3.5.4, to be able to run the code, it is indispensable to have the Box2D library installed.
The project has two subprojects, the first one being the "BloblDetectionWithColorGiver", this code is to help you select the parameters for the object with which you plan to do the tracking.
The second subproject is the robotic arm, once the parameters are passed to the main tab ("Box2dRoboticArmWithVision"), the program is ready to use.
Requirements to be able to run de code
Install processing 3.5.4 or the latest stable release, and open it.
To install the librarie go to Sketch -> Import Library -> Add Library... and search for
Box2D for Processing
and
Video The Processing Foundation
To install the project you can download the zip file or you can clone it
$ git clone https://github.com/carlossando/RoboticArmWithVision.git
This code is going to be used to obtain the detection parameters of the color blob for our second program.
Once you run the program, you will press the color you want to track with the mouse. To adjust the parameters you will use A and Z for the distance threshold, and S and X for the color threshold. Your target is to find a single blob that doesnt fluctuate. These parameters will vary depending on the background, lighting, etc.
Once you got the parameters your are going to pass the to the next program. In this case the parameters are:
Color: -13280642 //Given in the Console
Distance Threshold: 50 //Given in the Console or in the top right area of the screen
Color Threshold: 40 //Given in the Console or in the top right area of the screen
To get the robotic arm to follow the blob, show the blob to the camera and click on the gripper, then you will be able to see the force vector and the robotic arm trying to follow the blob.
- Carlos Sandoval Contreras - CarlosSando
See also the list of contributors who participated in this project.