Fruit Picking Robot using Arduino

Fruit Picking Robot - Arduino Project for Kids! 🤖🍎

🤖 Fruit Picking Robot!

Build your very own robotic arm with Arduino that can pick fruits! 🍎 A super fun STEM project for curious kids who love science and technology!

🎓 Ages 10+ ⏱️ 2–3 Hours 💰 Budget Friendly 🟢 Beginner Level 👩‍🔬 STEM Project
Fruit Picking Robot Arm ARDUINO UNO R3 ON Servo 1 Servo 2

🔩 Robot Parts

  • 🟦 Arduino Uno board
  • ⚙️ SG90 Servo motors (3×)
  • 🦾 Cardboard / PVC arms
  • 🔌 Jumper wires (20+)
  • 🔋 9V Battery pack
  • 🕹️ Joystick module
  • 💡 LED + 220Ω resistor
  • 🍎 Soft sponge gripper tip
  • 🧲 Hot glue gun

👆 This is what your finished fruit-picking robot will look like! Cool, right? 😎

🧠 How Does It Work?

🕹️

You move the joystick

🟦

Arduino reads signals

⚙️

Servos rotate arms

🦾

Gripper picks fruit!

The Arduino is the robot's brain! It reads your joystick movements and sends signals to the servo motors, telling them exactly where to rotate. The servos move the arm joints, and the gripper opens or closes to grab the fruit! Press the joystick button to grab — press again to release! 🍊

🛒 What You Need to Buy

🟦

Arduino Uno

The brain of our robot! Reads inputs and controls all the motors.

× 1
⚙️

SG90 Servo Motor

Tiny motors that rotate to move each joint of the arm precisely.

× 3
🕹️

Joystick Module

Like a game controller! Move it to steer the robot arm around.

× 1
🔌

Jumper Wires

Colorful wires that connect all the components together.

× 20+
🔋

9V Battery + Clip

Powers the Arduino board so it doesn't need a computer cable.

× 1
📦

Cardboard / PVC

Build the arm structure from thick cardboard or lightweight PVC pipe.

Several pieces
🧲

Hot Glue Gun

Sticks all the arm parts and servo motors firmly together.

× 1
💡

LED + 220Ω Resistor

A little light that glows to show the robot is switched on!

× 1 each
🧱

Mini Breadboard

A pluggable board that makes connecting multiple wires easy.

× 1
⚠️

Safety First, Young Scientist! 🦺

  • Always ask a parent or teacher to help with the hot glue gun — it gets very hot!
  • Never connect the battery while you are still wiring things up — always double-check first
  • Keep water and drinks far away from your electronics at all times
  • Handle servos gently — never force them past their movement limits or they will break
  • Work on a wooden or plastic surface — never on metal, which can cause short circuits
  • If anything smells like burning or gets very hot, unplug power immediately and ask an adult

🔌 Circuit Connections

Follow this wiring table carefully! Match each wire by color so you don't get confused. Always connect ground (GND) first and power (5V) last for safety.

📋 Complete Wiring Guide

Component Pin / Wire Arduino Pin Wire Color
Servo 1 — Base (rotates left/right) Signal Digital Pin 9 Orange
Servo 1 — Base Power (VCC) 5V Pin Red
Servo 1 — Base Ground GND Brown / Black
Servo 2 — Elbow (moves up/down) Signal Digital Pin 10 Orange
Servo 2 — Elbow Power + Ground 5V + GND Red & Black
Servo 3 — Gripper (opens/closes) Signal Digital Pin 11 Orange
Servo 3 — Gripper Power + Ground 5V + GND Red & Black
Joystick Module X-axis (VRx) — Left & Right Analog Pin A0 Blue
Joystick Module Y-axis (VRy) — Up & Down Analog Pin A1 Green
Joystick Module Button (SW) — Press to grab! Digital Pin 2 Purple
Joystick Module VCC & GND 5V & GND Red & Black
LED (status light) Anode (+) via 220Ω resistor Digital Pin 13 Red
LED (status light) Cathode (−) short leg GND Black

💡 All servo red wires (VCC) share the Arduino's 5V pin via a breadboard. All black/brown wires share GND.
Use different colored wires for each signal to avoid mix-ups! Color coding is your best friend! 🌈

🔧 Step-by-Step Build Guide

1

🏗️ Build the Arm Structure

Cut three pieces of thick cardboard or PVC pipe for the arm segments. Make them about 15 cm (upper arm), 12 cm (forearm), and 8 cm (gripper holder) long. Use a hole punch or adult-supervised drill to make small holes at each end — this is where the servo horns (the plastic X-piece) will connect to each segment.

💡 Pro Tip: Layer 3–4 popsicle sticks together with hot glue for super strong, lightweight arm pieces!
2

⚙️ Attach the Servo Motors

Hot-glue Servo 1 to a flat base board — this one rotates the whole arm left and right. Hot-glue Servo 2 at the elbow joint between the upper arm and forearm — this moves the arm up and down. Attach Servo 3 at the wrist end for the gripper. Use the tiny screws that come with the servo to attach the horn (plastic cross) to each cardboard arm segment.

⚠️ Ask an adult to help with the hot glue gun — it reaches over 180°C and can burn skin instantly!
3

🦾 Make the Gripper

Cut two L-shaped pieces of stiff cardboard for the gripper fingers. Attach one finger to each side of Servo 3's horn so that when it rotates, the fingers pinch inward like a claw. Wrap the very tips of the fingers with a thick rubber band, foam, or a small piece of sponge — this makes the grip softer so it doesn't bruise delicate fruits!

🍎 Did you know? Real industrial fruit-picking robots use inflatable silicone fingers to grip fruits without any damage!
4

🔌 Wire the Circuit

Place your Arduino on a flat surface with a breadboard beside it. Follow the wiring table above step by step. Start by connecting all GND wires first, then signal wires, and power (5V) last. Plug the joystick's X wire to A0, Y wire to A1, and button to pin 2. Plug servo signal wires into pins 9, 10, and 11. Finally connect the LED through a 220Ω resistor to pin 13. Triple-check before powering on!

🔍 Color code your connections — use the same color wire for the same type of connection. It makes finding mistakes 10x easier!
5

💻 Upload the Code

Download the free Arduino IDE from arduino.cc/en/software. Connect your Arduino to your computer using a USB-A to USB-B cable. Open the IDE, paste in the complete code below, then go to Tools → Board → Arduino Uno and select the correct COM port. Click the → Upload button and watch the progress bar. The LED will blink 3 times when it's ready!

📱 The Arduino IDE is completely free and works on Windows, Mac, and Linux. Download it once and keep it forever!
6

🧪 Test and Calibrate!

Connect the 9V battery and try moving the joystick in all directions. The base should rotate left and right, and the elbow should move up and down. Press the joystick button to close the gripper! If a servo moves the wrong direction or goes too far, adjust the map() values in the code. Place a soft toy fruit nearby and practice picking it up. It might take a few tries — keep going, you've got this! 🏆

🎮 Open the Arduino Serial Monitor (magnifying glass icon) to see live readings of joystick values while testing — super useful!

💻 The Complete Arduino Code

Copy all the code below into your Arduino IDE and click Upload! Read the grey comment lines starting with // — they explain exactly what every line does in plain English. Learning to read code comments is a superpower for programmers! 🦸

fruit_picking_robot.ino
// ============================================
// 🤖 FRUIT PICKING ROBOT — Arduino Code
// A fun STEM project for curious kids!
// Controls a 3-servo robotic arm with a joystick
// ============================================

// Step 1: Include the Servo library
// This gives us special commands to control servo motors
#include <Servo.h>

// Step 2: Create three servo "objects"
// Each one controls a different joint of the arm
Servo baseServo;     // Joint 1: Rotates left and right
Servo elbowServo;    // Joint 2: Moves arm up and down
Servo gripperServo;  // Joint 3: Opens and closes the gripper

// Step 3: Define pin numbers — these must match your wiring!
const int BASE_PIN    = 9;   // Digital pin 9  → Servo 1 signal
const int ELBOW_PIN   = 10;  // Digital pin 10 → Servo 2 signal
const int GRIPPER_PIN = 11;  // Digital pin 11 → Servo 3 signal

// Joystick input pins
const int JOY_X   = A0;  // Analog A0 → Joystick X axis (left & right)
const int JOY_Y   = A1;  // Analog A1 → Joystick Y axis (up & down)
const int JOY_BTN = 2;   // Digital 2  → Joystick button (press to grab!)

// LED indicator pin
const int LED_PIN = 13;  // Built-in LED on pin 13

// Starting position for each servo (in degrees, 0–180)
int basePos    = 90;  // 90° = center (pointing forward)
int elbowPos   = 90;  // 90° = arm horizontal (middle height)
int gripperPos = 0;   // 0°  = gripper fully open

// Dead zone — ignore tiny joystick wobbles smaller than this
const int DEADZONE = 50;  // Joystick values range from 0–1023, center is 512

// ============================================
// SETUP — Runs once when Arduino turns on
// ============================================
void setup() {

  // Attach each servo object to its physical pin
  baseServo.attach(BASE_PIN);
  elbowServo.attach(ELBOW_PIN);
  gripperServo.attach(GRIPPER_PIN);

  // Set joystick button as INPUT with internal pull-up resistor
  // (This means: not pressed = HIGH, pressed = LOW — a bit backwards!)
  pinMode(JOY_BTN, INPUT_PULLUP);

  // Set LED as an output so we can turn it on and off
  pinMode(LED_PIN, OUTPUT);

  // Move all servos to their starting positions
  baseServo.write(basePos);
  elbowServo.write(elbowPos);
  gripperServo.write(gripperPos);

  // Start the serial monitor at 9600 baud (for debugging)
  Serial.begin(9600);
  Serial.println("🤖 Fruit Picking Robot is READY!");
  Serial.println("Move joystick to control the arm.");
  Serial.println("Press button to grab fruit!");

  // Blink LED 3 times to signal the robot is ready
  for (int i = 0; i < 3; i++) {
    digitalWrite(LED_PIN, HIGH);  // LED ON
    delay(200);                      // Wait 200 milliseconds
    digitalWrite(LED_PIN, LOW);   // LED OFF
    delay(200);                      // Wait again
  }
  digitalWrite(LED_PIN, HIGH);  // Keep LED ON — robot is running
}

// ============================================
// LOOP — Runs forever while robot is on
// ============================================
void loop() {

  // --- Step A: Read the joystick values ---
  // analogRead gives us a number from 0 to 1023
  // When joystick is centered, both values are near 512
  int joyX   = analogRead(JOY_X);
  int joyY   = analogRead(JOY_Y);
  int joyBtn = digitalRead(JOY_BTN);

  // --- Step B: Convert joystick X to base servo angle ---
  // map() converts one range of numbers to another range
  // Here: joystick 0–1023 becomes servo angle 0°–180°
  int newBase = map(joyX, 0, 1023, 0, 180);

  // --- Step C: Convert joystick Y to elbow servo angle ---
  // Limiting to 30°–150° so the arm stays safe
  int newElbow = map(joyY, 0, 1023, 30, 150);

  // --- Step D: constrain() makes sure values don't go out of range ---
  newBase  = constrain(newBase,  0,  180);
  newElbow = constrain(newElbow, 30, 150);

  // --- Step E: Only move if joystick went past the dead zone ---
  // abs() gives the absolute value (removes the minus sign)
  // This stops the arm jittering when the joystick rests at center
  if (abs(joyX - 512) > DEADZONE) {
    baseServo.write(newBase);  // Send angle command to Servo 1
    basePos = newBase;          // Remember new position
  }

  if (abs(joyY - 512) > DEADZONE) {
    elbowServo.write(newElbow);  // Send angle command to Servo 2
    elbowPos = newElbow;          // Remember new position
  }

  // --- Step F: Button controls the gripper ---
  // LOW = button pressed (because of INPUT_PULLUP — it's inverted!)
  if (joyBtn == LOW) {
    gripperServo.write(90);   // Close the gripper — GRAB! 🍎
    Serial.println("🍎 GRABBING FRUIT!");
  } else {
    gripperServo.write(0);    // Open the gripper — RELEASE!
  }

  // --- Step G: Print debug info to Serial Monitor ---
  // Open Tools → Serial Monitor in Arduino IDE to see this!
  Serial.print("Base: ");
  Serial.print(basePos);
  Serial.print("°  |  Elbow: ");
  Serial.print(elbowPos);
  Serial.print("°  |  Raw X: ");
  Serial.print(joyX);
  Serial.print("  Raw Y: ");
  Serial.println(joyY);

  // --- Step H: Small pause before reading again ---
  // 15ms is fast enough to feel smooth and responsive
  delay(15);

  // ============================================
  // 🎉 That's it! The loop runs this entire code
  //    again and again — about 60 times per second!
  // ============================================
}

🌟 Super Cool Robot Facts!

🏭

Real Farm Robots!

Companies like Harvest CROO build robots that can pick 8 strawberries per second — faster than any human picker in the world!

🍅

Gentle Grip Magic

Professional fruit-picking robots use air-filled soft silicone grippers that squeeze gently — just like a careful human hand holding a ripe tomato!

👁️

Robot Vision!

Advanced farm robots use cameras and AI to "see" which fruits are ripe by analyzing their color, size, and shape — just like your own eyes and brain do!

🌍

Saving the Planet

Picking robots can work at night, save water, reduce food waste, and help farmers grow more food with less energy — helping to feed the whole world!

🚀 Make It Even More Awesome!

Once your basic robot is working perfectly, try these upgrades! Each one teaches you something brand new about real-world engineering and computer science. You could turn this simple project into an amazing science fair entry! 🏆

📡

Bluetooth Control

Add an HC-05 Bluetooth module and a free app to control your robot wirelessly from your smartphone!

📷

Camera Vision

Add an ESP32-CAM module so the robot can stream live video and "see" exactly where the fruit is!

🤖

Auto Pick Mode

Program a special button that makes the robot automatically reach out, grab, and drop fruit in a basket — all by itself!

🎯

3D Printed Arms

Design proper robot arm parts using free Tinkercad software and print them at school or a local makerspace!

🧩 Test Your Knowledge!

Let's see how much you learned! Answer these questions about your fruit picking robot. No peeking! 👀

1. 🤔 Which component is the "brain" of the fruit picking robot?

2. ⚙️ What type of motor is used to move the robot arm joints?

3. 🎮 In the code, what does the joystick button do when pressed?

4. 🔌 Why do we wrap the gripper tips with sponge or rubber?

🎉 — Great job, robot scientist!

🎉 You're a Robot Builder!

Amazing work learning about robotics, electronics, and coding! This project uses the very same ideas as robots used by real scientists and engineers all around the world. Keep building, keep learning — the future is yours to invent! Every expert was once a beginner just like you! 🌟

SEO Keywords: fruit picking robot arduino, kids robotics project, arduino servo arm, STEM for kids, beginner arduino project

Comments

Product Cards
Buddy Bot eBook
⭐ New 2026 Release
Build Your
Own Robot!
3D design, wiring &
Arduino coding.
Young inventors love it!
🖨️
3D Print
All parts
Wire it
Circuit guide
💻
Code it
Arduino IDE
🤖
Watch it
Walk & react
📋 Your Details
Enter your name
Valid 10-digit no.
Enter a valid email
Special Website Offer
₹499 300
🌍 International: $5 USD
One-time · Instant digital delivery
🔒 Secured by Razorpay · Your data is safe
📄 Download Free Sample Copy
🔒 Secured by Razorpay · Your data is safe
🍓
Raspberry Pi Pico Mastery
21 Projects
⚡ Launch Price — 80% OFF
Learn Pico
Build 21 Projects!
MicroPython · Wokwi
IoT · Certificate
Perfect for beginners!
🖥️
Wokwi
No hardware
🐍
MicroPy
From zero
🔨
21 Projects
IoT + sensors
📄
Certificate
Verified cert
📋 Your Details
Enter your name
Valid 10-digit no.
Enter a valid email
Special Launch Offer
₹999 200 80% OFF
🌍 International: $5 USD
One-time · Lifetime access · No subscription
🔒 Secured by Razorpay · UPI · Cards · NetBanking
🎉

You're in!

Payment successful! Your Buddy Bot eBook is ready. Time to build!

📖 Access Your eBook Now
🎉

Enrolled!

Payment successful! Lifetime access to all 21 Pico Projects is yours!

🍓 Go to My Course