Top Banner
http://www.instructables.com/id/HDDJ-Turning-an-old-hard-disk-drive-into-a-rotary/ Food Living Outside Play Technology Workshop HDDJ: Turning an old hard disk drive into a rotary input device by nvillar on November 10, 2008 Table of Contents HDDJ: Turning an old hard disk drive into a rotary input device . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1 Intro: HDDJ: Turning an old hard disk drive into a rotary input device . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2 Step 1: Crack open a hard disk drive . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2 Step 2: Solder wires to the spindle motor contacts . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 3 Step 3: Probing the motor output . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 3 Step 4: Amplifying the output . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 4 Step 5: Measuring direction and velocity of spin . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 5 Step 6: Schematics and firmware for the HDDJ device . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 6 File Downloads . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 7 Step 7: Video summary . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 7 Related Instructables . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 7 Comments . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 7
12
Welcome message from author
This document is posted to help you gain knowledge. Please leave a comment to let me know what you think about it! Share it to your friends and learn new things together.
Transcript
Page 1: HDDJ Turning an Old Hard Disk Drive Into a Rotary

http://www.instructables.com/id/HDDJ-Turning-an-old-hard-disk-drive-into-a-rotary/

Food      Living       Outside        Play        Technology       Workshop

HDDJ: Turning an old hard disk drive into a rotary input deviceby nvillar on November 10, 2008

Table of Contents

HDDJ: Turning an old hard disk drive into a rotary input device . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1

Intro:   HDDJ: Turning an old hard disk drive into a rotary input device . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2

Step 1:   Crack open a hard disk drive . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2

Step 2:   Solder wires to the spindle motor contacts . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 3

Step 3:   Probing the motor output . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 3

Step 4:   Amplifying the output . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 4

Step 5:   Measuring direction and velocity of spin . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 5

Step 6:   Schematics and firmware for the HDDJ device . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 6

File Downloads . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 7

Step 7:   Video summary . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 7

Related Instructables . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 7

Comments . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 7

Page 2: HDDJ Turning an Old Hard Disk Drive Into a Rotary

http://www.instructables.com/id/HDDJ-Turning-an-old-hard-disk-drive-into-a-rotary/

Intro:  HDDJ: Turning an old hard disk drive into a rotary input deviceA couple of years ago we built a fun system that would allow DJs to mix music tracks in interesting ways . Our design called for an input device that would allow the DJ toquickly seek through a track and find a specific playback position, and we wanted to be able to do this by spinning a rotary control with a flick of the wrist - much liketurntable DJs can spin the record back and forth to do the same.

We found that we had only limited choices for building our device: we first tried to use rotary encoders , but it is not easy to find a cheap encoder that spins smoothly andfreely. Another alternative was to buy some audio equipment (like turntables) that spin well and feel good to use - but this seemed both expensive and wasteful for ourpurposes. Then, while looking for inspiration amongst assorted junk in the lab, we came upon a broken hard disk drive with its case open. We admired the quality of thebearings in the motor that drives the disk plates, enjoyed the fact that even a soft flick would get it spinning for a long time, and wondered whether we could sample anoutput from it when it was spun by hand, in much the same way that an electric motor, when turned, acts as a dynamo and outputs a voltage.

The answer is yes - and it's a very simple process to turn a hard disk into a rotary input device that has some unique properties. All you'll need is an old hard disk drive, afew op amps , resistors and a programmable microcontroller of some kind.

In this Instructable we'll show the basic principles behind this hack, then provide the schematics and firmware for the HDDJ device (shown below) that we used in ourproject , and which includes a few extra buttons, lights and a motorized slider for good measure.

Step 1: Crack open a hard disk drive

Old, unwanted or broken hard disk drives (HDDs) are usually free and easy to get hold of. They come in all shapes and sizes, but the most common are the 3.5" HDDsthat are used inside desktop PCs. We experimented with a number of different 3.5" HDD models, and found that most are suitable for our purposes (and would guessthat smaller, laptop-sized disks would work just as well). The largest variation lies in how easy it is to open the case of some compared to others. Seagate HDDs, whichoften use plain Phillips screws in the casing, are our favorite.

The first step is to open the drive by removing all the screws that hold the case closed. Often these are torx screws , and you'll need an appropriate screw driver.Sometimes a screw will be hidden behind a label - so if you have trouble opening the case after all the screws seemed to have been removed, poke at the labels to findthe culprit. If there is a label saying "Warranty Void if Removed," then, for sure, remove it.

Open the case, and reveal the disk platters in all their untouched glory. Never again will they be so free of fingerprints.

Remove the actuator that holds the read-write head, which stops the platters from spinning around freely. It's up to you how much more you want/need to remove (rule ofthumb: anything sharp should go). The only thing that you need to keep attached are the frame, platters and spindle motor.

Thanks to Wikipedia for the "Anatomy of a Hard Disk Drive " image.

Page 3: HDDJ Turning an Old Hard Disk Drive Into a Rotary

http://www.instructables.com/id/HDDJ-Turning-an-old-hard-disk-drive-into-a-rotary/

Image Notes1. Unscrew2. Unscrew3. Unscrew4. Unscrew5. Unscrew6. Unscrew7. Unscrew8. These three were hiding under the label.

Step 2: Solder wires to the spindle motor contacts

Turn the HDD over, with the exposed platters facing down. Some older HDDs will have four wires coming out of the back of the spindle motor , in which case you can skipthis step. Most, however, have an orangy-transparent flat-flex cable. In this case, what we are looking for are four exposed contacts at the back of the motor that we cansolder some wires to.

Image Notes1. We could solder four cables to these four points.2. Or we could solder here.

Image Notes1. You'll probably want to solder much longer cables than these.

Step 3: Probing the motor output

This is not really a necessary step, but more an illustration of what exactly we are trying to do.

If you have a access to an oscilloscope with multiple inputs, connect three of them to three of the wires soldered to the spindle motor contacts in the previous step (itdoesn't matter which three). Connect the probes' ground clips to the fourth wire, then set the platter spinning.

The scope images below show the three waveforms that are generated when the HDD platter is spun by hand (the scale is set to 500mV per division in the vertical axis,and 20ms per division in the horizontal axis). Three perfect phase-shifted sinusoidal waveforms !

The three different pictures show what happens to the waveforms as the platter gradually slows down: they all decrease in both frequency and amplitude by the sameamount.

These waveforms carry a lot of information, not only how fast the platter is spinning, but also in which direction it is spinning (clockwise, or anti-clockwise). More on thislater.

The raw signals, as generated by spinning the motor by hand, are simply too subtle to be sampled directly by a microcontroller, so the next step is to amplify them intouseful levels.

Page 4: HDDJ Turning an Old Hard Disk Drive Into a Rotary

http://www.instructables.com/id/HDDJ-Turning-an-old-hard-disk-drive-into-a-rotary/

Step 4: Amplifying the outputNow you have signals coming from your HDD's spindle motor, it's time to amplify them, and in the process convert them to square waves that can be fed into amicrocontroller.

The amplification can be done with a simple comparator circuit. Each comparator (the triangles in the schematic) has two inputs (+ and -) and one output. When thevoltage on the (+) input is less than the voltage on the (-) input the output will be pulled down to the negative supply voltage, otherwise it will be pulled to the positivesupply voltage or, depending on the model of comparator, float at high impedance (in which case a pull up resistor is required).

In the schematic below we have wired an LM324D opamp to function as a comparator (an explanation of how this works can be found here ). The LM324D includes 4comparator modules in a single package, which is perfect because in our case we need three (the 4th is not shown in the schematic).

One of the lines from the HDD is used as a reference, and is connected to the (-) inputs of all the comparators. The other three lines are connected to each ofcomparators (+) inputs. Not shown in the schematic, but also important, are the power supply pins of the comparators. The negative supply is connected to ground, whilethe positive supply is connected to Vcc (in our case +5V).

When the voltage of a signal pin from the HDD is greater than the reference the comparator output will be +5V, otherwise it will be ground. The outputs of this circuit(second image) can now be connected directly to the input pins of the microcontroller.

Page 5: HDDJ Turning an Old Hard Disk Drive Into a Rotary

http://www.instructables.com/id/HDDJ-Turning-an-old-hard-disk-drive-into-a-rotary/

Step 5: Measuring direction and velocity of spinIn this step we take the outputs from the amplifier circuit in step 4 and input it to a microcontroller to convert them to something a bit more useful.

The images below show the output from the amplifier circuit as the HDD platter is spinning at various decaying velocities. As the velocity decreases the period of thewave increases. The first two images below show the platter turning in different directions. If we look at order in which the rising edges of the waves occur we see that inthe first image (spinning clockwise) it's Yellow Blue Pink, whereas in the second (spinning anticlockwise) its Yellow Pink Blue.

The code for the microcontroller watches the inputs from amplifier for a rising edge. It also keeps track of which inputs the last two rising edges occurred on (we'll call theinputs Y, P and B). If we detect a rising edge on input Y, and the previous rising edge was on P and before that B, we know that the platter is spinning clockwise, samefor P, B, Y and B, Y, P. Conversely if we detect a rising edge on Y, and the previous two rising edges were on B and P respectively, we know the direction isanticlockwise, and same for B, P, Y and P, Y, B. Any other combinations are regarded as noise and ignored.

In our implementation we use a PIC microcontroller. The inputs from the amplifier are connected to the interrupt pins of the microcontroller; these generate an interrupt onthe rising edge of the input. Our code then looks at which input generated the interrupt and which inputs generated the last two interrupts. If a clockwise spin is detected a'>' character is output to the PC, if an anticlockwise spin is detected a '<' is output.

Because the frequency of the interrupts depends directly on the frequency of the waves, which is proportional to the speed of the platter the computer software can workout the velocity of the platter from the frequency at which it receives '<' or '>' characters.

Page 6: HDDJ Turning an Old Hard Disk Drive Into a Rotary

http://www.instructables.com/id/HDDJ-Turning-an-old-hard-disk-drive-into-a-rotary/

Step 6: Schematics and firmware for the HDDJ deviceFor our original DJing project we equipped the hard disk drive with eight additional buttons, six LEDs and a motorized fader to make the HDDJ device. We designed acustom circuit board and wrote some firmware that allowed us to connect all these controls (plus the input from the HDD platter) to a PC via USB. Here you can downloadthe files needed to recreate this design in EAGLE format, plus the firmware that needs to run on the PIC microcontroller (youll need a suitable PIC programmer to dothis).

How to test the HDDJ Device

1. Install the driver provided in the ZIP file

2. Plug in the HDDJ to a USB port of your computer (it will mount as a virtual serial connection, and assign it a COM port)

3. Use a terminal program (like Putty) to connect to the COM port, at 115200bps, 8 data bits, no parity bit, and one stop bit.

4. Try spinning the HDDJ platter: you should see a stream of '<' characters appear as it spins counter-clockwise, and '>' characters as it spins clockwise. The frequencyof characters will depend on the velocity of spin.

5. Moving the fader will output the character 'f' followed by a number between 0 and 100. To control the position of the fader type the character m into the terminalwindow, followed by a number between 0 and 100, and then hit return.

6. Pressing the buttons will output the character 'b' followed by a number between 0 and 8. To turn the LEDs on and off type the character l into the terminal window,followed by a number between 0 and 6, and then hit return.

For our project we wrote a bit of software that communicated with the HDDJ via the USB serial line using this protocol. It would be a relatively small (but useful) step toadapt it to, for example, translate the control sequences MIDI messages, which would let you use the HDDJ with generic music or VJ'ing software out of the box.

Page 7: HDDJ Turning an Old Hard Disk Drive Into a Rotary

http://www.instructables.com/id/HDDJ-Turning-an-old-hard-disk-drive-into-a-rotary/

File Downloads

HDDJ.zip (210 KB)[NOTE: When saving, if you see .tmp as the file ext, rename it to 'HDDJ.zip']

Step 7: Video summaryHere we have a video summary, showing the HDD connected to:

1. A comparator circuit, which amplifies to the output from the motors.

2. An oscilloscope, which shows the nice amplified square waves.

3. A microcontroller, which takes the square waves as input and uses them to determine the direction of spin. The microcontroller outputs (via serial line) the "<" characterwhile the disk is spinning counter-clockwise, and the ">" character when it is spinning clockwise.

4. A computer, that takes the output of the serial line and shows it on the screen.

In the video we're pretty excited because we just got this working for the first time :)

Related Instructables

Tesla turbinefrom old harddrives andminimal tools bygerrit_hoekstra

Apple FloppyAmp by jeffkobi

Techno-geekRoulette (orWho Makes theCoffee?) byAndyGadget

Building aSteampunk NAS- System byHoratius.Steam

Wall CLOCKfrom Old HardDrives by grybaz

Several EasySteps to BoostYourComputer'sSpeed bylukethebook333

Comments

50 comments Add Comment view all 113 comments

 project dude says:  May 11, 2010. 12:50 PM  REPLY Solder what kind of cables, standard electrical cables or audio or video cables?

 Data643 says:  Jun 28, 2011. 7:18 PM  REPLYThere isn't much of a difference between the two...

Page 8: HDDJ Turning an Old Hard Disk Drive Into a Rotary

http://www.instructables.com/id/HDDJ-Turning-an-old-hard-disk-drive-into-a-rotary/

 recordmasta001 says:  Feb 23, 2011. 1:43 PM  REPLY22 gauge wire will do fine :)

 SaNjA2659 says:  Apr 11, 2009. 6:41 AM  REPLYWANT A PARTS LIST, And can somebody tell me, how can I put files into microcontroller, or can I ask to write files there in a radio shack?

 blackbeardlion says:  May 16, 2011. 1:37 PM  REPLYno you can't bring it to radio shack but you can make your own software using an avr microcontroller and the usb keyboard and mouse library. it's a bit ofa task but you could learn allot if your new to microcontrolers

 offnot says:  Feb 6, 2011. 5:48 PM  REPLYYou have to read some books about PIC.If you are a beginner of PIC, I'll recommand you an easy book.

Add me up as a MSN friend, "[email protected]"

 natman3400 says:  Jul 6, 2010. 9:16 AM  REPLYYou need a microcontroller programmer.

 MECHOL says:  May 1, 2011. 6:55 AM  REPLYincomprehensible

 MECHOL says:  May 1, 2011. 6:55 AM  REPLYincomprehensible

 rlapse says:  Apr 12, 2011. 1:03 AM  REPLYcould this be done with the old spinny drums from VCR's, i think that that would look boss.

 Lowkill says:  Mar 3, 2011. 5:05 AM  REPLYDoes the hard drive needs to be powered or I'm missing something here?

 mman1506 says:  Apr 9, 2011. 6:34 AM  REPLYno. It does not, When you spin the platter it creates about 500 mv thats why you need a amplifier

 CBMalloch says:  Feb 27, 2011. 4:06 PM  REPLYI'm somewhat confused. The sine waves show three phases spaced at 120deg apart, and this implies that the fourth wire is some kind of common. Thisconflicts with the idea of "pick any three", because one is special.

Then, the outputs of the comparators show two signals in quadrature (90 deg apart) and one signal that is the inverse of one of the first two. Doesn't seemlike the same device is being shown.

With four wires all alike, I'd expect them to be 90 deg apart, so there would be two pairs of inverse signals, with one pair leading the other by 90 deg. Withthree wires and a common (wye) I'd expect the three wires to be at 120 deg apart.

Do your pictures represent two different disk drives, wired differently?

Thanks for the instructable -- I'm going to try it myself.

 efiscp says:  Dec 25, 2010. 8:47 AM  REPLYI'm gonna implement this as a scrollwheel. A very fast scrollwheel. ;)

 the_prototype says:  Dec 6, 2010. 1:33 PM  REPLYhehe just realised I'm using exactly the same HDD as you are in the instructable :DIt's an IBM Desktstar, isn't it?^^Really cool idea, my friends are gonna be like "wtf?" :D

Page 9: HDDJ Turning an Old Hard Disk Drive Into a Rotary

http://www.instructables.com/id/HDDJ-Turning-an-old-hard-disk-drive-into-a-rotary/

 tomtortoise says:  Nov 17, 2010. 3:36 PM  REPLYcan you make a schematic for JUST the rotary part no buttons or fader or lights and stuff because im thinking of using one of these for the most legit steeringwheel ever for pc gaming

 FurtherThanTesla says:  Nov 16, 2010. 4:50 PM  REPLYone prob though. Once the platter stops rotating it gets a little upity. the lights blink with the slightest vibration of the whole thing, but once the platter isrotated again, its running smoothly. I Imagine this oversensitivity could be corrected with a high value resistor, or low value capacitor

 FurtherThanTesla says:  Nov 16, 2010. 4:47 PM  REPLYJust tested it, and it outputs the Grey Code as expected and behaves just like I imagined. Tesla would be proud :D

 FurtherThanTesla says:  Nov 16, 2010. 4:12 PM  REPLYIt should also give you some error detection. like, it is impossible for it to go from 11 to 00, or vise-versa, so you can tell it is misreading either by going tooslow or too fast and ignore the reading

 FurtherThanTesla says:  Nov 16, 2010. 4:09 PM  REPLYHey, my HDD only had three wires (im guessing a motor in a "whye" config) but it gave me an idea. use the green wave as the reference for the other two(save urself an opamp) and it will output a grey code like a rotary encoder! this will also improve your resoloution since a 2-bit grey code has four states perrevoloution, while your three-phase setup gives three per rev. it goes like this- Green wave is higher than other two= 00, green goes below red=10, yellowgoes up above green allong with red= 11, red starts to fall below green while yellow stays = 01 - This pattern will repeat and give you four steps per rev whilesaving an exta op amp! ill try it out and let you know :D

 AriderM says:  Oct 3, 2010. 8:21 PM  REPLYA couple months back I got this working. I used a Parallax basic stamp 2sx. Used an oscilliscope to find the correct pins. From there I connected them to thecomparator (quad comparator in my case) and fed those to the stamp. It took me a few hours, maybe even a full day, but I got it working. I then took theserial out of the stamp and had that spit out to my desktop running virtualdj. Using midiYoke and some other stuff I changed the serial data to virtualdj midicommands. After that I could spin the disk and have the track play. The next step I have planned is to rebuild this setup and introduce a speed controller.This will allow me to set the speed of the disk by hand, press a button and have the speed controller maintain the disk spinning speed.

 Ashiro says:  Aug 22, 2010. 8:31 AM  REPLYMinor correction: "a very simple process". Change to: "a very simple process for an electronics engineering graduate with access to a lab for etching theirown PCB."

 jhakker says:  Jul 14, 2010. 4:40 PM  REPLYI'd pay for one of these !

 swathisanthu says:  Jun 14, 2010. 11:58 PM  REPLYcan u pleas send the HDDJ zip which is working pleazzzzzz

 teinai says:  Jun 14, 2010. 6:14 AM  REPLYVery very cool. I love the cubic fader tool in your paper too. It makes me very happy to be alive at this time when people are sharing brilliant ideasincorporating fun, music and technology. Makes me wish I was more focussed at university! Great work!!!

 T-Hawke says:  Jun 11, 2010. 7:37 AM  REPLYVery Cool. Adding this one to my to do list. I want to adapt or use in windows movie maker for a shuttle knob. Maybe size the platters and the case down tosomething more convenient that does not take as much space. Good instructable. Great idea.

 mattgilbert says:  Aug 30, 2009. 11:26 AM  REPLYThanks for the instructable! I got one working with an Arduino:http://www.youtube.com/watch?v=qaL5syVlae0

I posted the Arduino code here:http://www.arduino.cc/cgi-bin/yabb2/YaBB.pl?num=1251656637/0

Not quite how you did it, but I wouldn't have figured it out without this instructable. I used an old 1st gen iPod HD, and I only needed 2 pulse signals,amplified with LM386 op amps (would have used a LM358 dual opamp if I had one handy.)

It sends usb MIDI commands, routed by this program:http://www.spikenzielabs.com/SpikenzieLabs/Serial_MIDI.html

to a shoddy Max/MSP patch that I threw together.

Page 10: HDDJ Turning an Old Hard Disk Drive Into a Rotary

http://www.instructables.com/id/HDDJ-Turning-an-old-hard-disk-drive-into-a-rotary/

 SinAmos says:  Jun 11, 2010. 1:21 AM  REPLYSweet. What about with different inputs? Like actual tracks?

 kbishop says:  Sep 10, 2009. 3:17 PM  REPLYi got a question though, how do you connect the usb cable to the op-amps, or where does it play it's role on the schematics? i ask this because i'm reallytemped to try but never done usb stuff like this before

 mattgilbert says:  Sep 10, 2009. 5:41 PM  REPLYkbishop, if you mean my Arduino version, the Arduino communicates with the computer over USB, and it also powers and senses the output of theopamps.

http://arduino.cc/

 SinAmos says:  Jun 11, 2010. 1:17 AM  REPLYMy kind of fun-zeyz.

 project dude says:  May 11, 2010. 1:02 PM  REPLY too cool

 dark_angel000 says:  May 2, 2010. 11:22 AM  REPLY this thing is awesome ..................................can i have the parts list too ................i sure am gonna try tp make this thing...................thankx

 bmxlife says:  May 7, 2009. 4:48 PM  REPLYcan I please have a parts list 2

 Wessinc says:  Apr 23, 2010. 7:58 AM  REPLYHi Hope this helps. Parts list:Partlist

Exported from hddj-2.0.sch at 4/23/2010 4:52:42 PM

EAGLE Version 5.3.0 Copyright (c) 1988-2008 CadSoft

Part     Value          Device            Package    Library         Sheet

B1                      RB1A              RB1A       rectifier       1C1                      CPOL-USCT3216     CT3216     rcl             1C2       0.1uF          C_0805            C0805      rc-master       1C3       0.1uF          C_0805            C0805      rc-master       1C4       0.1uF          C_0805            C0805      rc-master       1C5       470nF          C_0805            C0805      rc-master       1C6       0.33uF         CPOL-USB/3528-21R B/3528-21R rcl             1C7       22pF           C_0805            C0805      rc-master       1C8       22pF           C_0805            C0805      rc-master       1C9                      CPOL-USCT3216     CT3216     rcl             1C10                     CPOL-USCT3216     CT3216     rcl             1D1       BAT64_05       DIODE-2AC|CASOT23 SOT23      diode           1D2                      D-SMB             SMB        semicon-smd-ipc 1D3                      D-SMB             SMB        semicon-smd-ipc 1J1                      PN61729           PN61729    con-berg        1J2                      MA04-1            MA04-1     con-lstb        1J3                      MA06-1            MA06-1     con-lstb        1J4                      MA06-1            MA06-1     con-lstb        1J5                      MA05-1            MA05-1     con-lstb        1J6       PINHDR2        PINHDR2           1X02       dongle          1J7       PINHDR2        PINHDR2           1X02       dongle          1J8       PINHDR2        PINHDR2           1X02       dongle          1J9                      MA06-1            MA06-1     con-lstb        1J10      DC21P          DC21P             DCSKTP     dcsocket        1J11                     MA04-1            MA04-1     con-lstb        1L1       FB_0805        FB_0805           L0805      rc-master       1L2       FB_0805        FB_0805           L0805      rc-master       1R1       0R             R_0805            R0805      rc-master       1R2       DNF            R_0805            R0805      rc-master       1R3       22R            R_0805            R0805      rc-master       1R4       22R            R_0805            R0805      rc-master       1R5       470R           R_0805            R0805      rc-master       1R6       470R           R_0805            R0805      rc-master       1R7       470R           R_0805            R0805      rc-master       1R8       470R           R_0805            R0805      rc-master       1R9       470R           R_0805            R0805      rc-master       1

Page 11: HDDJ Turning an Old Hard Disk Drive Into a Rotary

http://www.instructables.com/id/HDDJ-Turning-an-old-hard-disk-drive-into-a-rotary/

R10      470R           R_0805            R0805      rc-master       1R11      1K             R_0805            R0805      rc-master       1R12      1K             R_0805            R0805      rc-master       1R13      1K             R_0805            R0805      rc-master       1R14      10K            R_0805            R0805      rc-master       1R15      10K            R_0805            R0805      rc-master       1R16      10K            R_0805            R0805      rc-master       1R17      4.7K?          R_0805            R0805      rc-master       1R18      10K            R_0805            R0805      rc-master       1R19      10K            R_0805            R0805      rc-master       1R20      10K            R_0805            R0805      rc-master       1R21      10K            R_0805            R0805      rc-master       1R22      10K            R_0805            R0805      rc-master       1R23      10K            R_0805            R0805      rc-master       1R24      10K            R_0805            R0805      rc-master       1R25      0R             R_0805            R0805      rc-master       1R26      DNF            R_0805            R0805      rc-master       1R27      10K            R_0805            R0805      rc-master       1R28      10K            R_0805            R0805      rc-master       1R29      47K            R_0805            R0805      rc-master       1U1       PIC18F4550PT   PIC18F4550PT      PQFP-44    dongle          1U2       LM324D         LM324D            SO14       linear          1U3       L78MXXCDT      L78MXXCDT         DPACK_3    dongle          1U4                      L293E             DIL16      texas           1Y1       4MHz           XTAL/S            QS         special         1

 George1024 says:  Nov 20, 2008. 4:05 PM  REPLYMy attempt at making one has failed...the hard drive I'm using only has 3 wires, therefore only 2 outputs to measure. Regardless of the direction the plattersare spinning in, the sequence of the rising edges will always be A-B-A-B-A-B-A-B. Back to the drawing board...

 pelrun says:  Nov 21, 2008. 5:39 AM  REPLYYou only need two signals, the third is redundant (it's just an inverted copy of one of the others).

Look up "quadrature encoding" for more details, but essentially it doesn't go A-B-A-B, but A-AB-B-None-A-AB-B-None, and *that* pattern lets youdetermine direction. Look at the first two traces in the image in Step 5, you can see the 4 distinct states.

 stefannasehi says:  Apr 11, 2010. 3:03 PM  REPLY@pelrun do i still need to put the op-amp if i have 3 wires? how do i wire it to the usb cable?and what part of the zip file do i need?

 George1024 says:  Apr 11, 2010. 5:05 PM  REPLYI was able to set up the project using three wires and no op-amps. However, you'll need a microcontroller with built in Analog to Digital Converters(ADC), like the ATmegas used in the Arduino boards.As far as I can remember, one of the wires goes into +5V, and the other two go into the analog inputs on the microcontroller. Three wires = sixpossible arrangements, so test them all until you start getting proper signals on both analog inputs.

As for the code, you can either write up your own implementation based on the pattern that the two pins' signals will form (which @pelrundescribes above), or you can be lazy and use someone else's :)My implementation for the Arduino (with lots of comments) is here: http://github.com/George1024/arduino-turntable/blob/master/Turntable/Turntable.pde

 George1024 says:  Nov 21, 2008. 2:21 PM  REPLYThanks, I'll give that a go.

 ruzter says:  Nov 23, 2008. 10:37 AM  REPLYYes, mine only had three wires too, but I can get 2 signals 90 degrees apart, enough to count pulses AND know what direction the platter isturning. i.e use one wire for ground and the other 2 as signals.

 MediocreNinja says:  Mar 11, 2010. 7:53 PM  REPLY Im guessing parts list is:

Old HDD disk drive

Thats it?

 kennethchaco says:  Feb 20, 2010. 7:07 PM  REPLY can i conect that to arduino duemilanove?please help

Page 12: HDDJ Turning an Old Hard Disk Drive Into a Rotary

http://www.instructables.com/id/HDDJ-Turning-an-old-hard-disk-drive-into-a-rotary/

 maxout says:  Sep 10, 2009. 7:13 PM  REPLYnice project can't be done without details on part list yet i still want to build it.. i am itching to scratch lolz.. also is this connected thru USB? i mean whatsoftware u test it with? Virtual Dj, etc? please if you can do this project in detail on WIKI would be great.

 kyle.marsh says:  Apr 14, 2009. 11:44 PM  REPLYCoffee bean: would that be the opposite of defragging?

 ReCreate says:  Sep 2, 2009. 11:54 AM  REPLYJust remove the de, Fragmenting...

 atom heart says:  Aug 12, 2009. 5:37 AM  REPLYSo are there other solutions for creating djing devices such as timecoded turntables?

 chipboy says:  Nov 12, 2008. 6:19 PM  REPLYSO IS THIS TECHNICALLY A CDJ U CAN SCRATCH AND TREAT AS 1

 ReCreate says:  Mar 26, 2009. 5:50 PM  REPLYYA DATS RITE!!!111

 Gamernotnerd says:  Aug 4, 2009. 5:19 PM  REPLYAND YOU CAN USE IT TO TURN CAPS LOCK OFF TOO AND MAYBE IF YOURE LUCKY IT WILL PUNCTUATE YOUR SENTENCES FOR YOU

view all 113 comments