ESP32 Wifi Eggbot - Drawing Robot Plotter Pen
by bluino_electronics in Circuits > Robots
7324 Views, 27 Favorites, 0 Comments
ESP32 Wifi Eggbot - Drawing Robot Plotter Pen
The Eggbot is a drawing art robot that can draw on spherical or egg-shaped objects. You could also use this machine to draw on ping pong balls and golf balls. You will needs two stepper motors, a micro servo motor to lift the pen, a bearing, V-slot frame 2060, spring and linear rod. And of course, you’re going to need the electronic bits to drive it all.
If you have a 3D Printer you can create this Eggbot drawing robot, It was also decided to build the main frame from acrylic sheets.
Conceptually, one stepper rotates the egg around X axis of symmetry, the other rotates the pen’s Y axis so that it can travel north-south, and the servo lifts up the pen between strokes.
The firmware Eggbot is based on the cool Grbl_Esp32 project of bdring
This project was done for being a good introduction to CNC machines because you can clearly see and learn all the firmware and hardware concepts that involves them in a fun way.
Supplies
Part List of ESP32 Drawing Robot Shield:
- 1 x PCB ESP32 Drawing Robot Shield
- 1x ESP32 DEVKIT V1 board
- 2x Driver Stepper Motor A4988
- 2x Micro-SD Adapter module
- 1x LED 3mm
- 2x V-Regulator 5V AMS1117 (SMD)
- 1x Resistor 10K Ohm
- 1x Capacitor 0.1uF
- 2x Capacitor 100uF/16V
- 1x Capacitor 1000uF/16V
- 1x DPDT Lock Switch 8.5x8.5mm
- 1x Barel Socket DC
- 2x Female Header 15 pin
- 4x Female Header 8 pin
- 2x Male Header 4 pin
- 1x Male Header 3 pin
- 2x Male Header 2 pin
Part List Eggbot
You can download design file Eggbot frame for 3D printed part here thingiverse.com/thing:4972516
Part List of Eggbot:
- 1x X Motor Support
- 1x Y Motor Support
- 1x Frame Cover
- 1x Left Egg Holdert
- 1x Right Egg Holder
- 1x End Cap
- 1x Vertical Y Arm
- 1x Pen Holder
- 1x Egg Holder Support
- 4x Spacer 3mm 3D Printed Part
- 1x V-slot Frame 2060 15cm
- 1x Controller ESP32 Drawing Robot Shield
- 2x Stepper Motor Nema17
- 1x Servo SG90
- 1x MicroSD 8GB
- 1x Bearing 693ZZ
- 1x Power Supply Adaptor 3A 8V
- 1x Linear Rod Dia. 3mmx100mm (ex DVD room)
- 1x Press Spring
- 1x Knob M3
- 4x M5x6mm Hex Socket Screw
- 2x M5x8mm Hex Socket Screw
- 1x M5x12mm Hex Socket Screw
- 4x M3x8mm screw
- 8x M3x6mm screw
- 1x M3x25mm screw
- 1x M3 Nut
- 1x M2x10mm screw
- 1x M2 Nut
- 1x Marker
Circuit Diagram
PCB (PCBWay)
This article is proudly sponsored by PCBWAY.
To make this project you need to order a prototype PCB on PCBWAY. How to order is very easy and you will get 10 Pcs PCB for $5 with very great PCB quality.
Step to Order:
1. SignUp/Log in on pcbway.com
2. Open this PCB project link ESP32 Drawing Robot Shield
3. Click Add to cart.
4. Wait moment for PCB review, then Click Check Out.
Soldering SMD & MicroSD Module
- This shield has one SMD component, it is not too difficult to solder because the size of the SMD component is quite large, so don't worry. You will need tweezers as a tool to hold the components when soldered.
- Solder 8 pin male header to microSD adapter module.
- Remove plastic holder use pliers.
- Attach microSD adapter with male header soldered to PCB.
- Solder pins male header on the back of PCB.
- Cut the long legs male header.
Soldering Components
- After finish solder SMD component and microSD adapter, next attach other trough hole components on the PCB following the pictures and symbols on the PCB.
- Solder all the component legs on the back of the PCB.
- Cut all the long legs of the component wire.
Attach Modules
- Attach the ESP32 board and two Driver Stepper Motor A4988 into the female header socket as shown, look at the pin name dont get the wrong orientation.
X Axis Motor Support
- Attach X motor support acrylic into left side of V-slot frame 2060.
- Then tigthen use 2 M5x6mm screw.
- Insert one T-nut M5 into front top slot of V-slot frame 2060 as shown.
- Insert two T-nut M5 into back slot of V-slot frame 2060 as shown.
- Attach cover acrylic into right side of V-slot frame 2060.
- Then tigthen use 2 M5x6mm screw.
Install Controller
- To install controller use 4 set M3x8mm & spacer 3mm. The hole patterns are match for Arduino Uno board.
- Attach controller into base acrylic as shown below.
- Then tigthen four screws.
Install X Axis Motor
- Attach 3D printed part Left Egg Holder into shaft/head of motor Nema17.
- Install motor Nema17 into base acrylic as shown below.
- Then tigthen use 4 M3x6mm screw.
Install Y Axis Motor
- Attach Y motor support into back of V-slot frame 2060, align holes with t-nut as shown.
- Then tigthen use 2 M5x8mm screw.
- Install 3D printed part vertical Y arm into shaft/head of stepper motor Nema17.
- Attach stepper motor Nema17 into Y motor support acrylic. Positioning less or upper depends on the curvature of the egg surface to be drawn.
- Then tigthen use 4 M3x6mm screw.
- Install 3D printed part Pen Holder use M3x25mm screw.
- Then tigthen use M3 nut, but dont get too tight so that the pen holder can move up and down.
- Install knob clamp pen use M3 nut.
Install Servo
- Before install servo SG90, insert M2 nut into slot of vertical Y arm 3D printed part.
- Attach servo SG90 as shown below, then tighten use M2x10mm screw.
- To pull back pen holder using a rubber band that is installed as shown below.
Connect Hardware
- Connect the pin header as shown bellow, pay attention not to get wrong orientation. X Y Stepper Motor Nema17 and Servo SG90.
- Insert micro-SD card.
Install Egg Holder
- Insert 3mm linear rod into right ehh holder as shown below.
- Insert spring into linear rod.
- Attach bearing 693ZZ into egg holder support 3D printed part. Then insert 3mm linear rod into inner hole of bearing as shown.
- Attach 3D printed part end cap into end of linear rod.
- Install right egg holder assy into top of V-slot fram 2060.
- Tighten use M5x12mm screw. Position of right egg holder are depends on size of the egg that you want to drawn.
Compile and Upload Firmware
The ESP32 version of the Eggbot uses Grbl_ESP32 firmware.
Follow the compile instructions.
Use the eggbot.h file for your machine definition files.
- Copy eggbot.h file into "../Grbl_Esp32-main/Grbl_Esp32/src/Machines/"
- then on file Machines.h for customize set up to #include "Machines/eggbot.h"
- Select the Minimal SPIFFS (1.9MB APP with OTA/190KB SPIFFS) partition scheme.
- Select the serial port that corresponds to your ESP32.
- Click on the Upload button to begin the compilation/upload process.
- Scroll to the bottom to see the final upload result "Done Uploading".
Setting Up Eggbot
Before starting to draw on the egg the first step must be to adjust the position of the pen according to the shape and size of the egg. There are two settings you need to pay attention to according to eggs.
- Slide Y Motor Support depending on height of Egg, slide left for tall Eggs and slide right for short Egg.
- Slide Motor Stepper depending on round shape of Egg, slide up for round Eggs and slide down for oval Eggs.
Using of CAM Programs
Overview to generete gcode you can following this guidance.
You can use basic CAM programs to generate gcode for pen plotters. Here I am use Carbide Create free version.
- Download and install Carbide Create software
- Open software create New file, on the Design tab select Job Setup, on the Job Setup window configure the some of parameter:
- Width (X) 160mm depends on average length of the circumference of the egg surface
- Height (Y) 40mm depends on average height of egg surface
- Thickness (Z) 1mm
- Toolpath Zero Center-Left
- Unit MM
- Click the icon Import then select the vector file (dxf,svg) do you want convert to gcode.
- After the vector imported, select all of object path then use Transform tool for move or scale the path.
- After completed edit the picture/path, select all the path then click Toolpath tab, on 2D Toolpaths option select Contour, on Contour Tollpath window set offset direction to No Offset, next klik OK to save.
- Last step, click Save GCode to save gcode with forman .nc on your directory.
You can test the gcode has been generate to your Eggbot, open/connect to your Eggbot via browser then call the IP address of Eggbot controller. Then upload the gcode file over wifi. Click Play button on file gcode to start draw on egg surface.