• 1
    Tools and Materials

    The following tools and materials were used in this project:

    • Solder iron and wire. I had to solder some terminals to Nunchuk's wires in order to connect it to the Arduino;
    • Shrinking tube. Some pieces of shrinking tube were used for a better isolation of the conductors;
    • Screwdriver. The structure is mounted using some bolts and nuts;
    • 6-axis mechanical desktop robotic arm (link). This awesome kit already comes with several components as described bellow. It's reliable and easy to assemble;
    • 12V power supply (2A or more);
    • ESP8266-01 (link / link). It's used as a 'WiFi modem'. It receives signals from the control interface to be performed by the Arduino;
    • Male-female jumper wires (5 wires);
    • Arduino Mega (link / link / link). Notice that the robotic arm kit I've used also has a board and controller bundle that already comes with this Arduino board. If you you're not using on of those kits, you might use other Arduino boards as well;

    Sain Smart 6-axis mechanical desktop arm already comes with the following components:

    • Arduino Mega 2560 R3 (link)
    • Control board shield (link)
    • NRF24L01+ Wireless Transceiver Module (link)
    • MPU6050 3-axis gyroscope and a 3-axis accelerometer (link)
    • 71 x M3X8 screw
    • 47 x M3 nut
    • 2 x U bracket
    • 5 x servo bracket
    • 4 x 9kg servo (link)
    • 2 x 20kg servo (link)
    • 6 x metal servo tray
    • 3 x U bracket
    • 21 x right-angled bracket
    • 3 x flange bearing
    • 1 x gripper

    You might find other robotic arm kits online (link), or even design your own. There are some awesome projects you can 3D print, for instance.

    In the next step I'll show you how to assemble the arm kit before wiring up the circuits. If you doesn't have a similar kit, feel free to jump some steps. You can use another robotic arm kit, assemble it and jump directly to the electronics and programming steps.

  • 2
    Assembling the Robotic Arm

    In this step I'll show you how to assemble the arm kit (mechanical parts) I've used (link). If you doesn't have a similar kit, feel free to jump some steps. You can use another robotic arm kit, assemble it and jump directly to the electronics and programming steps.

    1. The first part to be assembled is the base of the robot. It's made of two U shaped brackets, joined back to back using four M3 bolts and nuts, as shown in the pictures;
    2. The first servomotor is mounted perpendicular to the base, using a servo bracket. This profile is attached to the base using four M3 bolts and nuts, as it's shown in the pictures. Servo #1 is place on it's top, and attached using four M3 bolts and nuts. A circular metal horn is attached to the servo axis. The kit comes with several plastic horns. They won't be used for assembling the robot.
    3. Another servo bracket is mounted perpendicular to the previous one. It's connected to servo #1 horn using four M3 bolts. Servo #2 is installed with four M3 bolts and nuts, and also uses a circular metal horn. An U bracket is then attached to the horn using four bolts. Notice that a M3 bolt is used oposite the servo axis. It gives stability to the structure. A bearing fits on this bolt, and it's locked in position using another M3 nut. This way the U bracket is tightly attached to servo #2 center axis.
    4. Another U bracket is mounted using four M3 bolts and nuts. On the other end, servo #3 is installed, using a circular metal horn and four bolts. A servo bracket is connected to the servo motor, and a L shaped profile is linked to the servo bracket using some bolts and nuts. Notice that another bearing is used oposite to the servo axis, as described before.
    5. Another U bracket is connected to the L shaped profile using a set of four M3 bolts and nuts. Similarly to the previous step, servo #4 is mounter to the U bracket using four bolts. Another servo bracket is connected to the servo.
    6. The fifth servo is connected perpendicular to servo #4 using another servo bracket, installed using four M3 bolts and nut.
    7. The gripper is then connected to servo #5 axis. On it's top, servo #6 is connected using some bolts, nuts and a metal horn. The gripper has some gears, which will turn the rotation of the servo into a linear movement of the gripper.
  • 3
    Wiring Up the Circuits

    Once the structure is assembled, you'll be ready to wire up the circuits. I used the controll board shield that came along with my robotic arm kit. It makes the connection of the components easier, since it already comes with specific connectors for the servomotors, power supply, etc.

    Unfortunatelly this controll board doesn't have a specific connector for the ESP8266. So I had to use some jumper wires to connect that Wi-Fi module to my Arduino Mega.

    Connect the components as follows:

    ESP8266:

    • ESP8266 RX => Arduino Mega Pin 14 (on the shield)
    • ESP8266 TX => Arduino Mega Pin 15 (on the shield)
    • ESP8266 Vcc => Ardino Mega Pin 3V3 (on the shield)
    • ESP8266 Gnd => Arduino Mega Pin Gnd (on the shield)
    • ESP8266 CH_PD => Arduino Mega Pin 3V3 (on the shield, in the connector reserved for the 24L01 module)

    You'll notice that the servo control shield has two pins labeled as 5V. Although, one of then is actually a 3.3V pin. Test it with a voltage meter.

    Servos:

    • Control shield terminal 11 => Servo #1
    • Control shield terminal 12 => Servo #2
    • Control shield terminal 13 => Servo #3
    • Control shield terminal 8 => Servo #4
    • Control shield terminal 9 => Servo #5
    • Control shield terminal 10 => Servo #6

    If you're not using the control shield, you should use the following pin configuration:

    • Arduino Pin 11 => Servo #1 (Sgn)
    • Arduino Pin 12 => Servo #2 (Sgn)
    • Arduino Pin 13 => Servo #3 (Sgn)
    • Arduino Pin 8 => Servo #4 (Sgn)
    • Arduino Pin 9 => Servo #5 (Sgn)
    • Arduino Pin 10 => Servo #6 (Sgn)
    • Arduino Gnd => Servos Gnd
    • 6V Power supply => Servos Vcc

    You'll also need to connect an external 12V power supply. I suggest one with more than 2A output. The servos consume a lot of power, and if the power supply is not powerfull enough, the servos will vibrate and get really hot. They will also lose their strenght.

    Don't connect the power source until you've uploaded the Arduino code (shown in later steps). There's a power button on the shield. Keep it on the off position.

    Plug an USB cable on the Arduino and proceed to the next step.

    Warning! You'll notice I've connected my ESP8266 RX/TX pins directly to the Arduino TX/RX pins. It worked for me, but I don't recommend doing the same. ESP8266 works with 3.3V, and the Arduino pins run on 5V. Some say it might burn your ESP8266 module (although I've tested it several times, and had no issue). You might use a voltage divider or a voltage level shifter if you want to convert 5V to 3.3V.