Electric Pencil Sharpener
by TomPaulaJulia in Circuits > Sensors
1914 Views, 13 Favorites, 0 Comments
Electric Pencil Sharpener
Nowadays everything is electronic, all the most basics and mechanical tasks that we can imagine. The electronic can solve any discomfort and what is more uncomfortable than to sharpen a pencil? Twist the wrist, get your hands dirty, hold the pencil with one hand and the sharpener with the other... We propose a solution that can solve this bother situation.
Supplies
For the construction of the prototype we need:
- 600x300x4 mm MDF wood
- laser cut machine or something to cut the wood
- (1) sharpener
- (2) bearings size 22x10 mm
- (1) cilinder stik diameter 10mm and 80mm large
- (1) elastic band
- tape
- glue
- (5) pieces of foam
For the electronic we need:
- (1) 9V battery
- (1) Arduino UNO
- (1) 5V stepper motor
- (1) prototype board
- (11) Cables
- (1) 2 Battery connectors
- (1) 12V stepper motor driver
- (1) Resister
Blueprints
The dimensions for the construction of the case are in the jpg attached. We cut the pieces on a laser cutter but if you don’t have one, you can print them and use them as a template. The bases are 15 x 15 cm.
Structure
After cutting the pieces, we only need to assemble everything in the right way. There are 3 bases, in one of them, we drill two holes for the bearings 45mm separated one to the other. This mesure is very important to make sure the mechanism works well.
When you have glued the bearings in the holes, cut the stick in to 5 and 3 cm and glue the largest one with one bearing (it doesn’t matter which one you choose). Next, glue the biggest gear to the sharpener and the smaller to the top of the long stick. The 3cm stick is the one which fix the sharpener to the bearing, so glue it with a pice of wood to make it more stable.
Place the walls of the box, but wait! Don’t glue it! You can fix it with the tape just in case something goes wrong inside and you have to repite any step.
Arduino
The arduino is connected through the 8,9,10,11 pins to the Stepper controller which in turn is hooked up to the battery and the motor itself. Over on A0 we solder up a 10k𝜴 resistor, ground and 5V. We’ve soldered it so that all the components are removable without desoldering so they can be used in other projects, this is a little more work but useful if you have multiple projects on the go!
We have also attached slightly modified sketchbook code to test and debug each component while you are wiring it up!
Here is the test for the motor:
/* Stepper Set speed
* Tom, Julia and Paula
* 1/12/21
*
* Test software for stepper motor. Runs motor at 200 to test it works.
*/
#include
const int stepsPerRevolution = 64;
Stepper myStepper(stepsPerRevolution, 8, 9, 10, 11);
int stepCount = 0;
int motorSpeed = 200;
void setup() {
}
void loop() {
myStepper.setSpeed(motorSpeed);
myStepper.step(stepsPerRevolution);
}
Here is the test for the sensor:
/*
AnalogReadSerial
Reads an analog input on pin 0, prints the result to the Serial Monitor.
Graphical representation is available using Serial Plotter (Tools > Serial Plotter menu).
Attach the center pin of a potentiometer to pin A0, and the outside pins to +5V and ground.
This example code is in the public domain.
https://www.arduino.cc/en/Tutorial/BuiltInExample...
*
/ the setup routine runs once when you press reset:
void setup() {
// initialize serial communication at 9600 bits per second:
Serial.begin(9600);
}
// the loop routine runs over and over again forever:
void loop() {
// read the input on analog pin 0:
int sensorValue = analogRead(A0);
// print out the value you read:
Serial.println(sensorValue);
delay(1); // delay in between reads for stability
}
The code can be copied and pasted from here:
/*
Automated Pencil Sharpener
By Tom, Julia and Paula
1/12/21
More pressure, more motor speed.
Pressure sensor to A0
Stepper to 8 9 10 11
*/
#include
const int stepsPerRevolution = 64; // set to the angle of our motor, you can change this to yours if its different
Stepper myStepper(stepsPerRevolution, 8, 9, 10, 11);
int stepCount = 0;
void setup() {
}
void loop() {
//reads the sensor, maps to usable speed, only turns on if theres a good amount of pressure
int sensorReading = analogRead(A0);
int motorSpeed = map(sensorReading, 0, 1023, 100, 200);
if (motorSpeed > 200) {
myStepper.setSpeed(motorSpeed);
myStepper.step(stepsPerRevolution);
}
}
Motorizing the Sharpener.
Paste all the electronic to the base of the box. The sensor goes bellow and the rest inside. You need to do a small hole in the wood for passing the cables of the sensor from the inside to the outside.
Make sure the motor is fixed to the base. For this step we used two pieces of wood and we screwed to the base.
Now we need to put a pice of foam to avoid the direct contact between the sensor and the box. Also we put one pice of foam to each corner to keep the prototype stable.
The Final Result.
If you want, you can paint the electric sharpener to make it more cooler. We preferred to leave it like this because we like the wood color and texture.
Now you can sharpen a pencil in an easy and confortable way.
We hope you enjoy the project!