(Howto) Walz a Hard Drive Spindle Motor
| Attachment | Size |
|---|---|
| 3pulses_l293d_big.gif | 24.92 KB |
| 3phase_pulsegenl293d.sch | 92.71 KB |
This is a continuation of my blog on the same subject. Please continue your commenting here.
I am the proud owner of a stack of scavenged hard drives. I hoped to find really fast, torqueless motors inside. But instead I found myself a project for my new found 555 knowledge.
The logic chip 74164 is a "Serial In Parallel Out bit shift register" (datasheet). S1 acts as a reset button. S2 is the little white wire in the video that "boots" the sequence. Once one serial pulse makes it into the 74164, the system will maintain the sequence. When the pulse reaches the third output (red), diode D1 feeds it back to the first (green).

The motor driver is the well known L293D. The circuit with the driver is much simpler:

The EN/able pins apparently do not need pulling down to work. The three diodes D2, D3, D4 only serve to cut a tiny 0.7 V off the voltage. That keeps the current maintainable for the driver chip (rated at max. 1.0 A continues duty). I tried lowering the motor's voltage supply, but the driver would not separate the two supplies very well, when I did. It works OK when V-motor is higher than V-logic. Not the other way around.
The video lasts as long as 10 minutes. Oh, and you'd better take your sea sickness medicine! The video compression kills any details, so here is a closeup of the experiment as demonstrated.


Avenues of improvement
It has been suggested (by oddbot and robologist) that the shape of these square/block wave can be improved upon. Advantages include higher rotational speeds or power efficiency.

Also the control method can be improved a lot. Removing the need for a manual boot up and automatic ramping up of the speed.
Furthermore a decent feedback mechanism could make the driver much more intelligent. Two main alternatives remain to be inestigated: external feedback (e.g. hall effect or optical sensing) telling a processor about the state of the entire system, or internal feedback (e.g. voltage detecting on any of the motor's coils when it is not being fired) which in turn could help the exact firing of the next (round of) pulses. That could even help gradually ramping up (or down) the speed.
Practical issues
Finding the right leads. In this picture, I soldered in the wires shown. I also chose the colour coding to be like the international colour convention of traffic lights. Nothing to do with reggae or rasta.

Just as in a stepper motor, measure the resistance through the coils. In the above diagram any coil from a coloured wire to the "black center" would be a very low resistance: somewhere between 0.5 and 1.5 Ohm. You need a reasonably good multimeter (M-thingey) in order to get an accurate measurement. And some patience.
The resistance through any connection from a colour to a colour would be about twice as much.
The bottom line
You're probably better off using a microcontroller after all!
Watch this space (not the other space) for updates.
8ik




@ Fri, 2010-04-16 21:08
this is pretty old, sorry
this is pretty old, sorry for the bump
my mate sent me that schematic ages ago, but why wont a simple 555, and 4017 combination work?
@ Sat, 2010-04-17 23:04
Bumping is encouraged around here.
Nobody say it won't work, did they?
@ Mon, 2010-04-26 16:56
Electronics is trying, and
Electronics is trying, and trying is learning, and learning is gaining experience, and gaining experience will lead you at last to new ideas. Kudos, Rik, trying to get on the bottom of something is the right way:)
@ Thu, 2010-04-15 16:07
Further thoughts...
Excellent article, it certainly answered my search for what pins to apply voltage to to make the motor turn!
I have 2 memories of things which could help this idea evolve? Many many years ago I built a graphplotter based on 2 stepper motors, my father built the mechanics (he was an engineer) and I messed around with the electronics. My Z80 based microprocessor system had a Parallel IO port so it was easy to generate the the pulse sequences.
A) I think the 5V outputs then went into a power transistor wired as "open collector" which basically meant that a low voltage, low current could switch a higher voltage/current, the transistor behaved like an on/off switch.
B) the Spec Sheet for the stepper motor recommended that the coils be energised singly, and in pairs, alternately: i.e. based on Red/Amber/Green the sequence would be R, RA, A, AG, G, GR. When 2 coils are energised the motor only makes half a step. This makes the stepping twice as granular, so your motor would require 18 steps in the sequence to make one turn. My stepper motors were 180 steps per turn, and designed to turn slowly and precisely, I suspect that with only 9 steps per turn and a motor designed to turn fast then it's only about maintaining the inertia at the correct rate so I doubt this is an improvement. It would also require diodes or AND/OR gates to help generate the pulse sequence.
Anyway, I have 10 or so old drives so I may have a play with this. The immediate advantage of these being step motors is that it would, in theory, be possible to
1) rotate them precisely in sync;
2) wire them in parallel
Of course, I have no idea why I would want to do this, but it seems like a fun engineering objective to spin shafts at 7,000 RPM then have them wind down and still be precisiely aligned...
One last question, on some drives the motor is held in the frame on a large flange, screwed down. On others the motor seems mounted directly in the HDD frame: any idea how to get these motors out of the frame?
Thanks again.
@ Fri, 2010-04-16 17:27
quick reply from Madrid
No I don't know how to ge them out. They might be press fitted. So brute force is authorized. If you destroy them, there is no loss. At any rate you will gain knowledge. Make sure to share. You now know where.
On the the other thing: I never know WHY i do things like making stupid stuff. Or rather: the why the end result has reason to be. It's about doing it, not having it.
@ Sun, 2010-04-04 15:31
need some help
here's what i did:
1)i set the clock around 0.25Hz then i started the 74164 shifting.here i had 47µF and 10nf in parallel.
2)i set R1 around 1K and then and then connected a pot at R2.
3)then i removed the 47µF.then the hard disk motor started squealing at a high freq. then i increased R2 and gradually the freq. decreased and then after some value of r2 the clock suddenly switched off every time i did this.and beyond that value the clock never turned on again.then when i turned back the pot (decreasing value).the clock starts after some value just as earlier.and during which the motor starts and after some value of pot. then gains some RPM and the the motor stops and the squealing takes over and the motor stalls.i tried decreasing the R2 very slowly but still the motor starts and gains some RPM and then halts again.
can you please tell me what's the problem.and can you please tell me if the value of r2 has a max. value beyond which the clock stops.is what i am doing wrong, because i coould'nt get decreasing value of capacitors?
i'm using an SMPS to power up the the circuit is it okay?because even without i sparking the pin2 of 74164 the IC starts automatically as soon as switch on the circuit.
thank you.
@ Sun, 2010-04-04 17:28
Again, you are asking me to guess
You mention resistors by number, but you don't tell which circuit you're discussing. Don't make us guess.
You say your "clock switches off". Do you mean your motor stops running or do you really see the clock pulses die? How do you see that?
By "squealing" you mean "turning really fast", right? Or is it just making high pitched noises?
Did you ever consider that my circuit is not the best way to go? I mentioned this several times across this page....
@ Tue, 2010-03-30 04:27
Motor Speed
Let me try to explain what I want, I think I'm confusing you . I have a spindle motor wired in a "+ configuration" (12 coils) , 3 wires for the coils and 1 common , I trying to obtain the faster rotation, like a hard disk works, but I just obtain this speed in the video that I recorded. http://www.youtube.com/watch?v=6Zp0elG9xP8.
@ Mon, 2010-03-29 19:09
Motor Speed
The graphic is below, the delay is the lenght of the pulse. My problem is the speed, I want the speed around 15.000RPM like is shown in this picture http://www.datarecoverytools.co.uk/wp-content/uploads/2009/08/spindle-speed.jpg
@ Mon, 2010-03-29 20:05
Did you do your math?
Check your numbers: 15000 revolutions per minute. How many per second? How many ms per revolution?
Check your labels: does your hard drive do 15000 RPM? Those are rare. Most modern disks for PCs do 5400 RPM.
Check your coil configuration. My disk has three wires plus a central wire. The three coils are wired in a "Y configuration". Each coil in my disk appeared to be divided into three coils. That's nine coils in total. That takes nine pulses per revolution.
At 1 ms per pulse (and no delay between pulses, as your diagram suggests) those nine pulses would translate to 9 ms per revolution, 111 revolutions per second, 6660 revolution per minute.
Your numbers might be the exact same. Don't count on it.
@ Sun, 2010-03-28 04:29
Motor Speed
I tried to control the motor via parallel port producing the same signal of 74164N and using a L293B, 9V source ,but when I set the delay on 1ms the motor get out of control (stopped rotating ) ,it just rotate with a delay upper 10ms . What is wrong???
@ Sun, 2010-03-28 11:50
I have no idea
I can only make a few guesses. OK, maybe just one.
Your "delay" may be at the wrong moment in the cycle. Is this delay between pulses, or is it the lenght of the pulses? Did you draw yourself a diagram of your pulses?
Is it even realistic to expect a turning motor at 1ms delays? What kind of speeds are we talking about here? 18000 RPM? That's way out of range for these devices.
@ Sat, 2010-03-27 23:50
here's a video
http://www.youtube.com/watch?v=mGleuogJiU0
the quality isn't so good as i captured the video on my cell phone.i used 2 caps. one to start the process and another one to speed it up.
Q; how did you manage to increase the speed?did you use a variable cap from 1F-10pF?
i hope you can properly see the motor spinning.
@ Sat, 2010-03-27 23:59
variable capaciors
I placed several caps in parallel. By removing them, one by one, I reduced the capacitance. And I used a potmeter to vary the resistor.
Good show making it turn! Thanks for the video.
@ Sun, 2010-03-21 18:52
New idea for kick starting this circuit
Instead of booting up the sequence with a "flying lead" touching the right pin at the right time, I came up with a new idea. Perhaps better.
Forget bout looping back the red signal back to the green wire via the diode. ust keep the green wire feeding a pulse every third clock pulse. Use a digital divider.
I am not sure if a "divide by three" chip exists. I doubt it. You may end up hacking a shift register to do it for you. That almost defeats the point. Almost! You still get to eliminate the manual booting, which is good.
@ Sun, 2010-02-14 16:37
problem with clock pulse plz help
@ Sun, 2010-02-14 17:56
The clock
The clock is based on a 555 timer chip. See the post I linked to.
@ Mon, 2010-02-15 08:24
74164 connections
i built the clock input and connected it to the IC74164 but the three LED's after the 74164 didnt glow.Are there any other connections in the circuit other than the ones in the schematic?(i started building circuits very recently and without the complete design it's hard for me to figure out any connection left out)
so,can you please post the remaining connections (if any),and what is the value of v+ that you recommend.(i set V+ to 5v and did'nt give any potential to Vcc of the IC)
@ Mon, 2010-02-15 10:33
I am not sure what to tell you.
Your questions are not very specific. And I could not possibly guess what you're doing different. Also, you must understand that a circuit diagram is never a recipe for success. See it more like a road map where you have to navigate yourself. No road map will ever teach you East from West.
BTW 5V is about right. I can never tell the difference between VCC and VDD. Don't lure me into burning your components as well as mine.
Perhaps you could show us your circuit. In a diagram perhaps. Drawing your own is a very valuable way to learn electronics. Diagramming is the first language of engineers.
My project consists of three major circuits. Each with their own diagram. You can combine them like I did, or replace any of them with your own inventions. I am not sure which connections you left out. An LED not glowing could mean anything. Start with your clock. Replace the values of C and R in the tank circuit to slow it down. Now you should be able to see with the naked eye how the signal is pulsing. Use a voltmeter or an LED or a buzzer. Experiment with different values to speed up or slow down the pulse.
But if this is your very first time with electronics, I can only give you this advice: start small. Smaller even than a 555 timer. Make the LED glow without smoke. And enjoy.
@ Mon, 2010-02-15 17:12
here's the schematic
hope the image is not annoying
@ Mon, 2010-02-15 20:00
Looks fine
Your schematic looks like an exact copy of mine. So I trust it.
The booting "switch" is important. By making a brief contact, you bring the counter loop to life. I used a loose wire from R77 to pin 2 on the 74164.By briefly touching the contact, the sequence would begin. I drew a proper (momentary) switch in my circuit because I do not know the international symbol for "loose wire that touches stuff when I want it to".
I hope you find the patience to try this with a slow clock pulse, so you can follow the results with your own eyes. Two or three pulses per second or slower even.
@ Tue, 2010-02-16 19:40
doing exactly what you said
@ Tue, 2010-02-16 21:33
Sine vs square
My diagram with the Sine waves was just guessing whether a Sine output (directly into the motor) would be an improvement. I did not try it out.
But to entertain your slightly misguided question: I suppose it might work. The bit shifter was not designed to work off a sine, but it's just another chip reading another voltage level. How fast it changes from low to high does not matter (much). Again: I never tried it. I also do not believe that my 555 timer setup produces perfectly square waves either.
The max RPM? I never measured it. I'm sure I never reached the full potential of these motors. In case you missed in the other comments, my circuit sucked. It did not work. The fact that I got any RPM out of it was a small miracle. This is why they sell expensive drivers for brushless motors at hobby RC stores. They're often called "brushless ESC" for Electronic Speed Controller.
@ Sun, 2010-02-28 16:23
circuit still not working
this is what happened:
1)the clock is perfectly working.i could get a very low frequency.
2)i did all the connections to IC74164.i set V=+5v,and grounded the 7th pin(not shown in the diagram).connected an LED to 4th pin and grounded the other end.i switched on the power supply and the LED started glowing.then i gave the clock pulse and exactly after the clock pulse led stopped blinking the LED in IC74164(4th pin) stopped blinking and never turned on again,even after 2 min.
What might be the problem?
@ Sun, 2010-02-28 16:35
difficult debugging like this
I can only guess.
Maybe your circuit only worked once, without looping. The diode provides the closing link in the circle.
Maybe your circuit lit up the LED before it started receiving a clock signal. The the clock switched it off.
Maybe you forgot to "boot up" the sequence. Without that very first "spark" on the register's input, it will not begin to loop.
@ Mon, 2010-03-01 11:33
the problem
"Maybe your circuit lit up the LED before it started receiving a clock signal. The the clock switched it off"
this is what exactly happened,I switched on the power supply and even without the clock being fed the LED was ON and after the clock LED turned ON and OFF and ON the 74164 LED stopped glowing and did'nt turn on even after i did the boot up sequence.(for the boot up sequence i connected a simple switch and clicked it a few times and finally.is it the right way to do it??).i even clicked the other switch but it had no effect.what might be the problem?hope i'm not troubling much.
@ Mon, 2010-03-01 20:36
it somewhat worked.
@ Mon, 2010-03-01 21:11
DIY
I am sorry to say: you will have to figure this out by yourself. You followed all my instructions (I think) and it still does not work as you expected it to work. I just ran out of suggestions. And I don't want to suggest you give up now.
So here's what you need to investigate and study. Start with the bit shift register. Find some good description on-line (always a data-sheet, maybe wikipedia) and study it. Leave out the motor and driver and clock. Just put the 74164 on a breadboard and get to know it. Feed it manual pulses with a "flying lead". Make LEDs light up on its outputs. Use a multimeter. Learn until there is nothing left to learn about the darn thing.
Then apply your knowledge. Or teach me something new. Either way, please report back.
@ Sun, 2010-03-21 17:52
finally it worked
it was a short in the 74164 that created all the problem.but i rectified it and finally it worked.first i set the clock freq. at 0.25 hz and step by step the motor started turning.
the lm32d IC gets hot after a few seconds,how do i over come that?(i gave +5v to all v+) .how do i give the 12v the motor requires?should i give 12v to v+ of lm32d?what is the max freq of clock that i should give?
thank you.please reply.
@ Sun, 2010-03-21 18:28
Congratulations!
Wow! I started to fear for your project. I was running all out of advice for yo. But this is absolutely great news. Please consider posting pictures or even video of a turning motor.
The motor driver chip I used is L293D. It is supposed to get quite hot. Just keep it well ventilated. If I remember correctly, the chip can handle up to 0.7 Ampere or even a full 1.0 A. Put your multimeter to use. Measure the current at the power source, to be sure. At 5 V I never exceeded 1.0 A (again: if I remember correctly). Only when the motor is stalling (not turning while drawing current) will you see it spike above 1.0 A. If your hard drive motor is anything like mine. You know: buyer beware!
Running more than 12V? Hmmm, first of all, check the datasheet for the driver. Check if it will feed on 12V. It has separate V+ pins for the motor power. Then make sure the 12V does not "leak back" to your micro controller. Feel free to post a new question about that in the electronics forum. You will probably get better and more answers there.
Oh, that's right: I used the L293D for just one reason: it was the only "power transistor" I had in stock. Its only function is to amplify the puny signals from the shift register.
Good work jayanth! Keep reporting your successes please.
@ Fri, 2010-03-05 22:24
had some breakthrough
i studied a lot about flipflops and shift registers.Now i understand the circuit pretty well. I understood that the a bit 1 is shifted at every clock pulse to the next flipflop and the output is got at Q.the output at 5 is fed back to 2/1 to get a loop.my circuit is kinda doing the opposite.first all the 8 led's connected to 8 outputs glow without the clock.then when i give the clock pulse.one by one the LED's start switching off.and the loop is not formed even after i spark the 2 with S2.
please tell me what to do next.I studied all about the IC's but could'nt figure out what to do.and as i see 1&2 are grounded and after i spark the 100K to 2 the circuit should give bit1 to the first flip flop and it should shift.but it can be seen from the diagram that the potential is grounded through 10k res.
Please explain that in brief..Thank you..Take your time..
@ Tue, 2010-03-02 05:26
sir yes sir!
@ Tue, 2010-02-16 02:29
Hehe, there is actually an
@ Sat, 2009-11-07 02:13
Ask a question
@ Fri, 2009-10-23 12:26
my crcuit is not working
hello,
i tried the circuit you have shown here but still i am not abel to get the motor to rotate, can you tell me some connections which i missed? i set the timer in astable mode, gave its o/p to pin 8, connected the switches and gave 3 o/p to the l293d driver and from there to the motor, but my 74164 is getting heated up and motor is locked but not rotating!!! can you help me with some clear circuit connection diagram!!!
@ Fri, 2009-10-23 13:23
So many things could go wrong
First of all, this method of mine is NOT a very good one. If your really NEED a turning hard drive motor, look into other drivers. But if you are in it for the fun, keep on trying. Cause fun it is!
Did you measure the resistance between the leads into your motor? Are they the same as I described? There are different models out there.
Did you feed 5V from a battery directly into each coil of the motor? Did it twitch? It should. Did you repeat the twitching for alternating coils? That should make your spindle twitch around and round. My circuit is basically doing just that: give a short pulse to each one of the leads. One after the other and round again. But so much faster.
Does your pulse generator work? Use a very big capacitor to slow it down, so you can follow the pulse with an LED or a piezo buzzer. I used a bank of different capacitors in parallel. By adding and removing caps, I could adjust the total value of the capacitance.
Hook up LEDs to each output of the 74164. Check if they are indeed pulsing in the expected order.
About the LD293: you don't need that one. Any other way of amplifying the pulses would work. I just happened to have the LD293 and wanted to learn more about it. And I sure did. Pick transistors (BJT or FET) if you know more about those.
Did you try to feed manual pulses (just touch wires to the V+ rail) through your amplifier into the motor? Just to check if the amplification is working.
I needed to start my motor real slow and then ramp it up by decreasing capacitors. Or the motor would stall. I often hand started it like an outboard motor on a boat.
When I get home later, I will try and find that LD293 circuit. I must be able to upload a better readable version of it.
Rik
@ Fri, 2009-10-23 20:40
attached
@ Wed, 2009-05-20 14:51
vraag
@ Wed, 2009-05-20 15:38
I am sorry to say: no
No I will not answer forum questions via e-mail. I even answer e-mail questions via the forum.
You asked if a hard drive motor can be simply powered from a battery. The answer (again) is no. Just a simple battery will not make this kind of motor turn. You need a (complex) electronic circuit between the power source and the motor. Even more complex than the one above, as I learned from trying.
See what just happened here? I answered your question for everyone to read. That will save many people (including me!) a lot of effort and time in the future.
I hope my English is clear enough for you to understand.
@ Sat, 2009-04-25 14:18
Parts list
@ Sat, 2009-04-25 15:39
No you don't
If you follow my video carefully, You understand that this is not the right way to drive a brushless motor. It is a lot of fun trying though!
If you really want to give this a try, learn how to read electrical schematics. Mine are all in the post. With values for all components.
@ Sun, 2009-03-22 19:04
Voltage requirements - Waltzing matilda
Gooday Mate - I what to waltz my Drive.............
My Question is what voltage are you sending to the coils - just a rough idea would help me....thanks
(i dont want boil the billy coils)
@ Sun, 2009-03-22 19:28
Billy Coils are safe
I kept it all at 5 Volt. I later understood that the motors expect 12 Volt. Quite a difference. Better not send a continuous 12 V through there, or you'll be desperately jumping in the Billabong.
Please share your thoughts and results.
@ Tue, 2008-12-23 13:20
found a link
Just jotting it down here for later retrieval.
http://www.youtube.com/watch?v=LabMAEdeA48
Rik
@ Fri, 2008-11-14 01:20
Here's something I found to
Here's something I found to do with the old HD.
http://www.instructables.com/id/HDDJ_Turning_an_old_hard_disk_drive_into_a_rotary/
I didn't make it, but I thought you might enjoy it :)
@ Fri, 2008-11-14 09:26
pretty scope traces!
wow thanks for the link
good info in the research from this instructor! pretty scope traces and everything
@ Mon, 2008-11-10 23:42
How can there be so many
How can there be so many cool nerds in one place?
Rik; You know I am your biggest fan!
@ Tue, 2008-11-11 09:00
they all followed the sound of your flute
@ Fri, 2008-11-14 01:19
I would say more like the
@ Tue, 2008-11-11 09:43
Ringing in my ears?