Free your Arduino code from the Arduino board
However, the hardware – the Arduino boards, all 150,000 variations of
– may not necessarily work very well for every occasion. Depending on your application there may simply be no space for a 2″x2.5″ board. Additionally, there’s always the question of cost: an MCU chip and a couple of extra components that you actually need for the project may not always justify the cost of the whole Arduino board, voltage regulators, LEDs and all of the extra goodness it provides.
I set out to figure out what it’s going to take to create an MCU development environment in which the code could be developed using all the familiar Arduino tools and then transferred to a stand-alone Atmel MCU so the Arduino board could be reused for future projects, along with all the above mentioned savings. My item of particular interest was to make all this work in Ubuntu Linux – my OS of choice for the last 4 years.
The quest has been helped in no small part by Newark – an electronic components distributor – who has generously provided an Atmel AVRISP MKII programmer – an essential tool for moving the code to stand-alone MCU chips. They carry a whole line of MCU development tools for your MCU family of choice and the AVRISP is one of the most economic ways to get you started programming Atmel chips. Check them out! Read the rest of this entry »
DVD-CNC. Laser cutter DIY Project. Concept.
This project came about as a result of my propensity to never throw away parts that were designed to or can be adapted to move electrons. I am also very interested in mechatronics and motor control in general and so it was all but certain that over time I would have accumulated enough of various discarded data storage devices because they are so cleverly combining parts of both mechanics and electronics. We live in world filled with discarded devices that only a few years ago were the stuff of science fiction. I always feel bad about the discarded yesterday’s technology and it gives me an extra kick to have it re-purposed for today’s needs. Read the rest of this entry »
TTL-controlled Laser Diode Driver. Updated schematics.
During the course of my DIY laser cutter project I needed a laser diode driver that I could control with a CNC software, such as EMC2. I’ve already made an attempt to build one based on Linear Technology’s LT1121 voltage regulator with Enable input but the driver design that came out was not exactly successful
So, I took another stub at it … Read the rest of this entry »
World’s Smallest Stepper Motor with Arduino and EasyDriver
This little wonder of electromechanical engineering came from inside a laser diode sled of an HP CT10L Bluray drive I’ve opened some time ago. The device on the picture consists of several parts, all easily fitting on a dime coin: a bipolar stepper motor with lead screw, a linear stage, a lens, and even an end position sensor (I’ve yet to make use of the sensor though). The entire assembly is only 14mm x 9mm x 4mm. This post is about making this tiny motor move. Keep reading! Read the rest of this entry »
Upgrading a DVD spindle three phase BLDC motor

Shroud (bell) with new magnets ready to be put back on the stator
Brushless DC (BLDC) motor with Arduino. Part 3 – The Stroboscope Project
It has been all dry theory in the Brushless DC (BLDC) motor with Arduino series up to this point. This is where it gets to be more fun. If you’ve just arrived, please check out the previous two installments:
- Driving a three-phase brushless DC motor with Arduino – Part 1. Theory
- Brushless DC (BLDC) motor with Arduino – Part 2. Circuit and Software
In this final part of the trilogy I am describing the hardware part of the stroboscope project and the making of the zoetrope animations themselves, in hopes that my visitors can take this further and come up with their own animations, which I would absolutely love to see. More details below! Read the rest of this entry »
Brushless DC (BLDC) motor with Arduino – Part 2. Circuit and Software
In this post I will describe the hardware and the software part of a project involving the use of BLDC (Brushless DC) motor salvaged from a broken XBox 360. This is a second installment in the series of posts related to Arduino and brushless DC motors. Please see the first part for a bit of info on the theory behind the commutation sequence. Once you understand the commutation sequence for the particular design of the BLDC motor, the circuit design for the BLDC driver becomes pretty clear. It is not much different from a bipolar stepper driver in that we need the be able to both source and sink current at all ends of the windings, except of course in this case there are only three ends whereas the bipolar stepper has four. The circuit diagram below is a concept that should work with any microprocessor (or a specialized driver IC) that is able to produce the correct commutation sequence: Read the rest of this entry »
Blu-Ray Teardown – HP CT10L BD-ROM / DVD Rewriter
This time the broken drive teardown is performed on an HP CT10L BD-ROM/DVD Rewriter drive (HP part number HP nPC P/N:491775-6CO). This is an older drive (manufactured in October 2008) and I expected it to have some useful parts – my experience has been that the most useful for disassembly parts are usually from 2003-2008 time frame. I was surprised to find not only two useful laser diodes inside but also an interesting part I did not expect to be in there … Read the rest of this entry »
Driving a three-phase brushless DC motor with Arduino – Part 1. Theory

Typical CD/DVD Spindle BLDC Motor With 12 Magnetic Poles and 9 Wound Cogs
This is the first part of what will probably be two (or more) posts describing one of my latest projects – an Arduino Stroboscope based on the spindle motor of a broken Xbox 360 DVD drive. I will save some practical information (like why I chose Xbox’s drive) for the second post. Here I wanted to concentrate on the theory behind using Arduino or another MCU to drive a three-phase Brushless DC electric motor such as a CD or DVD drive (or HDD for that matter) spindle motor, such as the one pictured further in the text. Read the rest of this entry »
Arduino Code Tidbits – #1 – Declaring an Array with Pin Values

Arduino Code - simple yet sometimes so challenging!
Every once in a while you come to a point in writing a software program where you spend unexpectedly long time trying to write just one line of code correctly. Has it ever happened to you?
I had one of those forehead slapping moments a couple of days ago writing a program controlling a brushless DC motor. I’ll post the full program that came out later as a part of the description of an upcoming project. Just wanted to say that ironically, the Arduino code tidbit I want to describe here did not actually make it into the final version of the sketch! But I was surprised by having to spend so much time researching such a simple issue and finding it mentioned in neither official Arduino references nor elsewhere online.
Read the rest of this entry »




