venerdì 5 gennaio 2018

The DrawingBot







In this post I describe the making of a small robot called DrawingBot which draws some simple shapes or lines on a sheet of paper using a simple felt tip pen.





For the impatient one below the video of the making and the video of drawing executed by DrawingBot.

















Project


The project is intended for everyone that want to realize a small robot from scratch and the ones with the main purpose to learn and experiment.

Once realized the DrawingBot it is possible to draw some simple drawing which are not really accurate. However the main goal is not to draw but to build and understand how the DrawingBot works from mechanical, electrical and software point of view.


The project is made by the major elements:
  • the  STL files for the 3D printing of the chassis 






  • the Arduino code (sketch) to control the robot
  • a simple python app which allow the user to pro grammatically generate drawings on screen  and that automatically generates the DrawingBot commands

All the files are available on my github [here]

Making

Let's now see the steps to build and make the DrawingBot


1- Printing of the  DrawingBot


Download the STL file for each component from my  github [here] and print them with your 3D printer


2- DrawingBot Assembling- Mechanical part


In the initial video I have assembled the DrawingBot from scratch hence all the steps are available in the video.

Below the Bill of Material of the  DrawingBot containing all the necessary components







The assembling of the mechanical parts is quite simple and can be complete with a normal screw driver and just few bolt and nuts.


3- DrawingBot Assembling- Electrical part

Once all the 3D printed components are assembled it is time for the electronics which is based on standard and inexpensive components: 1x Arduino Uno, 2x stepper and  1x Servo.

The assembling of the circuit is very simple and it is done through the use of few rainbow DuPont wires, hence using a color code. For this reason this circuit can be made by everyone including kids and beginners.















In order to achieve a quite clean and ordered cabling I have realized a simple connection board by using a small strip board.
















Software forArduino

The DrawingBot's software is avaiable on my github [here].


There are few parameters that can be tweaked based on your specific needs:

  • PEN_DOWN:  rotation angle of the servo when the pen is down (drawing)
  • PEN_UP: rotation angle of the servo when the pen is up (moving)
  • wheel_dia: wheel's diameter in mm
  • wheel_dia_correction: correction factor to make the DrawingBot more accurate
  • wheel_base: width wheel-to-wheel in mm

Drawing Software

The drawingbot.py file contains a simple app in python that allow:

  • create and show on screen a programmatic drawing
  • automatically generate the commands for the DrawingBot

The programmatic drawing should be included in the following method: def drawing()





This generates a drawing on the screen





and in the console the DrawingBot's command will be printed




Now in the  drawingbot.ino file, after the below line just add the commands generated in the previous step

/* Insert here the drawing commands */


Compile and upload your sketch and after 5 seconds the DrawingBot will automatically start to execute the drawing

Happy DrawingBot-ting!!!! :)









Nessun commento:

Posta un commento