Skip to content

GlobosNik/ESP32_IoT_Robotic_Arm

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

4 Commits
 
 
 
 
 
 

Repository files navigation

ESP32 IoT Robotic Arm

Control a robotic arm with 3 joints remotely using the ESP32 microcontroller and the Arduino IoT Cloud platform. This project allows you to move the robotic arm's base, hand, and gripper through a simple cloud dashboard.


✨ Features

  • Remote Control: Move the base, hand, and gripper using a web or mobile dashboard.
  • Arduino IoT Cloud Integration: Real-time updates and easy access from anywhere.
  • Simple Wiring: Just three servos and an ESP32 board.
  • Expandable: Add more features or sensors as needed.

🛠️ Hardware Requirements

  • ESP32 Development Board (e.g., ESP32 DevKit v1)
  • 3x Servo Motors (SG90 or MG90S recommended)
  • Robotic Arm Kit (or custom 3D printed parts)
  • Jumper Wires
  • Breadboard (optional, for prototyping)
  • 5V Power Supply (for servos, recommended to power separately from ESP32)

🧑‍💻 Software & Libraries

  • Arduino IDE (latest version recommended)
  • Arduino IoT Cloud Account
  • Please check if the Arduino Create Agent app is running in your device.
  • Libraries:
    • ESP32Servo (install from Library Manager)
    • Arduino IoT Cloud libraries (auto-installed when setting up the Thing)

🚦 Arduino IoT Cloud Setup Instructions

Follow these steps to set up your ESP32 robotic arm with the Arduino IoT Cloud: https://docs.arduino.cc/arduino-cloud/guides/overview/

1. Create an Arduino IoT Cloud Account

2. Add Your Device

  • Click on Devices in the sidebar.
  • Select Add Device > Set up a 3rd Party Device > ESP32.
  • Select the Board type (eg: 'ESP32 Dev Module' or 'DOIT ESP32 DEVKIT V1')

3. Create a New Thing

  • Click on Things > Create Thing.
  • Link your newly added ESP32 device to the Thing.

4. Add Variables (Cloud Properties)

Add the following variables (make sure to set the variable types and update permissions as shown):

Name Variable Name Type Update By Description
base base int Dashboard Base rotation (0-180 deg)
hand hand int Dashboard Hand angle (0-180 deg)
grip grip bool Dashboard Gripper open/close (true/false)
  • For each variable, click Add Variable, fill details, and select the on change event trigger.

5. Configure the Dashboard

  • Create a new dashboard and add widgets:
    • Slider for base (0-180)
    • Slider for hand (0-180)
    • Switch/Toggle for grip
  • Link each widget to its corresponding variable.

6. Program the ESP32

DIRECT PROGRAMMING METHOD:

  • The .ino and thingProperties.h files are respectively generated when the sketch for the the Thing is set up. DO NOT EDIT THE thingProperties.h FILE.
  • Replace the main .ino file content with the provided Robot_Arm.ino sketch directly in the IoT cloud sketch tab.
  • Install the ESP32Servo library via the Library Manager.
  • Select the correct board and port in the setup tab.
  • Upload the code to your ESP32.

DOWNLOAD CODE METHOD:

  • Download the automatically generated .ino file and thingProperties.h from your Thing.
  • Replace the main .ino file content with the provided Robot_Arm.ino sketch in the Arduino IDE.
  • Make sure thingProperties.h is in your project folder. (DO NOT EDIT THIS FILE)
  • Install the ESP32Servo library via the Library Manager.
  • Select the correct board and port in the Arduino IDE.
  • Upload the code to your ESP32.

⚡ Wiring Diagram

ESP32 Pin Servo Function
13 Base Servo
12 Hand Servo
14 Gripper Servo

Note: Connect all servo power lines to 5V (external recommended) and grounds together with ESP32 GND.


🚀 Usage

  1. Power the ESP32 and servos.
  2. Open your Arduino IoT Cloud dashboard.
  3. Move the sliders and toggle the grip switch to control your robotic arm in real time!

🧩 Customization

  • Add more servos or sensors by expanding the code and dashboard.
  • Integrate with voice assistants or automate actions using Arduino Cloud automations.

📝 License

This project is licensed under the MIT License.


🙌 Credits

  • Inspired by the Arduino IoT Cloud documentation and the ESP32Servo library.

📬 Support

For questions or suggestions, open an issue in this repository. Do share your thoughts!

About

Control a robotic arm using ESP32 and Arduino IoT Cloud platform.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages