Before starting construction, I made a CAD model of the machine to make sure that everything would
fit, and to figure out the dimensions of the parts. Some screenshots of the machine's CAD model are
above.
The y-axis is on the bottom of the machine, and provides a moving base for the engraved piece.
The x-axis is on the top, and moves the laser assembly (the laser isn't shown in the model).
The machine uses ballscrews and linear bearings to control the position and motion of the X and Y
axes.
The specifications of the machine's ballscrews and accessories are:
16mm ballscrew, 400mm length (462mm including machined ends)
5mm pitch
C7 accuracy rating
BK12/BF12 ballscrew supports
I chose to use ballscrews due to their very high accuracy (minimal backlash), rigidity and efficiency.
Since the ballscrew nut consists of ball bearings rolling in a track against the ballscrew, there is very
little friction, which means the motors can run at higher speeds without stalling.
The second photo shows a test fitting for the x-axis. On either side of the ballscrew is a linear bearing
on a steel shaft. This configuration is quite common for cnc machines, and provides a stable
foundation for the base plate (Y-axis) and laser assembly (X-axis).
The parts I used are:
16mm hardened chromed shaft , 500mm length (qty: 4)
16mm linear bearing - SC16LUU (qty:4)
16mm shaft support - SK16 (qty:8)
The ballscrew nut's rotational orientation is locked using a piece ofaluminium (this is how we spell
it in Australia!) angle attached to the moving component of the axis. This can be seen in the last
photo, which shows the y-axis. The base plate is fastened to the two linear bearings, and to the
ballscrew nut (through the aluminium angle). Rotation of the ballscrew shaft results in thelinear
motion of the base plate.
The ballscrew supports and shaft supports are mounted on 50mm x 50mmhollow aluminium posts.
These posts are used for all major structural parts of the machine, and are actually aluminium fence
posts (purchased at Bunnings, if anyone from Australia is reading). The thickness of the aluminium is
about2mm.
I chose to use these posts because they are easy to cut and drill, and also hold their shape well when
supporting heavy loads. In addition, because they are square, they provide excellent reference
surfaces to make sure things are parallel / perpendicular.
The holes were drilled using a cordless drill, and the posts were cut using a mitre saw. (It is also
possible to cut the aluminium posts with a hacksaw).
M5 socket head cap screws, and M5 nuts were used to hold most of the parts together. I didn't use
a permanent fastening method because I wanted to keep everything adjustable. Using screws also
means that the machine is easy to disassemble and modify for future upgrades.
Some pictures of the frame being built are above. The base of the Y-axis is made up of several A4sized 4.5mm thick clear acrylic sheets.
After some poor results with NEMA 17 stepper motors in an earlier design, I decided to use
some NEMA 23 motors with a decent torque rating for this machine. Strong stepper motors also
require strong drivers to get the most out of them. As a result, I chose to use a dedicated stepper
driver for each motor.
Some details about the chosen components are below:
Stepper Motor (qty:2)
NEMA 23 frame size
The laser diode I chose is a 1.5W 445nm diode mounted in a 12mm aixiz housing, with a focusable
glass lens. These can be found, preassembled, on eBay. Since it is a 445nm laser, the light it
produces is visible blue light.
The laser diode requires a heatsink, when running at high power levels. I used two SK12 12mm
aluminium shaft supports, to both mount and cool the laser module.
The intensity of the laser output is dependent on the current that goes through it. The diode by itself
cannot regulate current, and if connected directly to a supply, it will draw more and more current until
it destroys itself. So, a regulated current circuit is required to protect the laser diode and control its
brightness. A circuit diagram of my laser driver is above.
This circuit requires at least a 10V DC supply, and has a simple on/off signal input, which is provided
by the Arduino. The LM317T chip is a linear voltage regulator, which has been configured as
a current regulator. A potentiometeris included in the circuit to allow the regulated current to be
adjusted.
The values of the resistors are:
R1 - 1 ohm (3W)
R2 - 5 ohm (15W) potentiometer
R3 - 180 ohm (0.5W)
(R1 and R2 need to have sufficient power ratings to support the power that is dissipated through
them)
R1 and R2 together control the value of the regulated current. The range of current outputs for this
circuit are:
The machine has two separate power supplies, due to different voltage requirements. The stepper
motor drivers can accept a 20V-50V DC supply. Each stepper motor has a maximum current of 3.0A,
but in normal operation, the motors don't need 3.0A. When they are running continuously, I found that
they need less than 1A each. When the motors are changing speed, they usually need less than 2A
each. The power supply I used to supply both stepper drivers is a 100W lab power supply, with a
maximum output of 36V at 3A.
The laser driver requires a supply voltage of at least 10V, with current of at least 1.25A. I used
an ATX PC PSU as a 12V power supply. The laser driver is connected to the PSU through
a breakout box that I made, which provides standard banana jacks for +5V and +12V terminals. The
box also has analog ammeters for monitoring current. For instructions on how to create an ATX PSU
breakout box, there are a number of other instructables on this site.
An Arduino provides the brains for the machine. It outputs step and direction signals for the stepper
drivers, and a laser enable signal for the laser driver. In the current design, only 5 output pins are
required to control the machine.
A diagram showing all the electrical connections is above.
An important thing to remember is that the grounds for all components should be connected
together.
I used solid core 22AWG wire for signal lines and power cables. For power cables, the power supply
ends were terminated with banana plugs.
values used in the Processing sketch and Arduino sketch have to be compatible.
The Processing sketch also provides a progress status, by counting the total number of instruction
blocks, and continuously reporting how many instruction blocks have been sent to the Arduino.
The sketch is at the bottom of the page
Handshaking - by "spiralout11235"
The first improvement is from "spiralout11235" (clever username!) who has implemented serial
handshaking between the Processing sketch and the Arduino (for raster engraving). This eliminates
the need for setting time delays in the Processing sketch. In addition, the Arduino sketch features
PWM control of laser output, and a few other changes you'll notice if you look through the code
closely.
He has kindly offered to share his ideas and code. Here are his notes:
Arduino sketch: version 4.0 Handshake
Processing sketch: 2.0 Handshake
Version notes: Handshaking is now implemented: no longer need to set delay times in Processing.
This means Arduino and Processing send and receive data when the other is ready. Processing waits
until it receives Serial data: SerialEvent() triggers and reads until the line break '\n'. So Serial.print()'s
until Serial.println() is the entire command from Arduino. (Black and white images only; no greyscale)
1. Arduino println's out an "A" and waits for Processing to receive this and send it back. "Connection
established".
2. Arduino sends a "1" to signal that it is ready for the "linelength" of the next instructions set.
3. If Processing receives "1" it sends (linelength + 10) (reason explained in code).
4. Arduino is now expecting linelength. Reads serial when it comes and writes linelength = linelength-
The Processing and Arduino files are in the "Handshake.zip" file below.
If you'd like to share your improvements or suggestions, send me a message (via Instructables or
getburnt1@gmail.com), and I can upload them to this step.
Some images that the machine has engraved are above. (For the engraved photo and Arduino logo,
some image processing was required before sending the bitmap to the C sharp application).
For more images, have a look on my website:http://getburnt.weebly.com/gallery.html
Final Thoughts
Overall, I think this project was worth the time and effort. I gained a lot of knowledge that can be
transferred to future projects. Probably the most useful thing I learnt is to make sure all the parts can
work together effectively - if there is a weak component, it has the ability to limit the whole machine,
due to dependencies between components. For example, the motors have to be strong enough to
move the axes, but then the frame has to be strong enough to hold the motors, and so on...
There are also a few future updates that would make the machine better:
- Install a stronger laser to speed up the machine
- Add limit switches on both axes to protect the machine from crashing into itself (haven't had a crash
yet, but it is inevitable without limit switches)
- Refine the C sharp program, so that larger images don't take 15min+ to process into instruction files