BLDC motor controlling, the hard way
December 21, 2012
I am going through two processes now...
The first, is removing the spider webs from electronics capabilities of yesterday ; The second, is (during this process) controlling an HDD 3-phase BLDC motor with arduino.
Yes, I know I can simply use an ESC component and save myself the hassle of "figuring it all out", simply plugging in the speed controller to the motor 3 pins, 12V battery and simple signal from my microcontroller (arduino) to set the speed/direction .. and voilla. That's it.
BUT..where's the fun in that??
For the sake of learning the fine details of how a the phased motor is controlled, I rather "do it all" myself. Just rely on my Arduino for feeding the 3 phase lines through three PWM outputs with extra three digital outputs for indicating a "not connected" state (so to have 3 states: +,-,NC),, fed into 6 sets of gate drives and possibly going through another layer of driver... etc..
Basically, I am following http://www.jimfranklin.info/microchipdatasheets/00857a.pdf (see diagrams on pages 29, 30)
So from what I understand.. and I would LOVE your help in knowing where my below description is off:
1. each of the three phase lines (dubbed A, B and C) should be connected in one of three states: VCC, GND, NC ... Those states are set according to a 6 options, creating an always switching flow trough two coils in one direction of the other - info can be seen here: http://bldc.wikidot.com/p-esc-motor
2. cycles should be timed according to the position of the motor, which is referred to sensor enabled control that can be based on hall sensors.. OR can be based on back EMF.
BUT can also be sensorless, by just ignoring things and timing according to a certain preset you set for a desired speed. (less optimal, but should work quite well, especially with some tunning)
3. The speed of the motor, and the torque will be set according to the voltage you feed as well as the timing/frequency of the cycle. Torque is also influenced by the right timing of the state switch.
4. protect the microcontroller by not having it connected directly to the motor, in any way or form. protect things from returning currents from the motor (as motors are "noisy")
Basically, that's it. Now, how is that done? Using which components? For this, I will describe my understanding of the digram in the referred PDF..
Again, corrections are highly appreciated, and actually sought after..
a. The 3 states generation: I have two options. I think..
a.1 : In this Here I am following the diagram on the PDF ::: My microcontroller will generate 3 voltages via PWM, as well as 3 high/low signals allowing switching between GND and NC. overall 6 signals. each pair controls a state of one of the 3 phase pins of the motor. The PWM will range between 255 (5V) and 0 (0V, which is equivalent to NC, depending on the electrical circuit). The second line will be used to basically control the switching between the NC state and GND(-) state. By using two gates (in this case: IRF5305 and IRLI3705, as described in figure B-1 on page 29), I can have a phase line connected either to ground or to the the voltage. Using PWM, that voltage is "basically" variable, ranging between my 12V and 0V. However, in this solution I am not sure why I need the TC4469, and not rely only on the IRF5305 and IRLI3705 gates only? Anyone has any idea? aren;t the gates alone, enough to isolate an arduino from the motor and 12V? Can't they be fed directly by C1,C4?
a.2. Instead of this, I can follow a different guide instead (see soon) ::: I can use a L6234, connect all 6 arduino outputs described above, and skip the need for the TC4469, IRF5305 and IRLI3705, as its all included inside the IC. Right? Though, both where is the fun in that AND its hard (for me) to find L6234. Reading up on it, its basically a triple half-bridge driver. Right? SO, I COULD instead use any other triple half-H or even three seperate half-H ICs. Right?? [http://www.instructables.com/id/BLDC-Motor-Control-with-Arduino-salvaged-HD-motor/step8/The-Power-Electronics/]
How is a.2 different than a.1? Which approach is better? Which approach would isolate my arduino better? and ACTUALLY what is the point, at all, in these TC4469?
b. The positioning of the different capacitors is to protect the circuit from the engine's feedback. Right? When looking at the digram on page 29, I am left with 3 questions:
b.1. Why is the capacitor setup at the top-right of the diagram (where R19 and C6 are located) exist only on the A line? why not on B and C?
b.2. what is exactly that "floating" bit on the middle left, where C1 is connected from the 12V power to GND directly? Why is it not connected to the rest of the diagram? Or is it actually connected, only not specifically indicated as part of the rest of the diagram, since its basically just an "AC protection" of the ENTIRE 12V feed?
b.3. The three resistors R7,R8 and R9 are said (according to note (3)) to be there for controlling the rise/fall of the driver. Here, i'm assuming its for converting a square wave of the phased feeds to something more trapezoid like. However, I can't see how just a resistor would actualy modify the votage in such a way. I would expect that to happen because of a capacitor setup. Not because of a resistor. What am I missing?
Lastly, I want to sneak in another question I have very hard time finding a good answer for...
How can I find what OTHER components might replace an existing component in a given diagram.
For example, in the diagram I linked to and referred to, there are the MOSFET gates: IRF5305 and IRLI3705. However, if my local electronic store does not carry them.. how can I tell which OTHER equivalent components exist which I might use instead? (and how do I know what implications such a switch may have?).. for example, in case of capacitors (in DC digrams), it is almost always fine to replace a capacitor with a different one of higher capacity. Very rarely there is a potential disadvantage or negative implications to it. However, while its easy to do that, as most capacitors are basically 'the same", a specific IC like IRF5305 or IRLI3705 is (at least for me) totally not the same as all others. I am not even sure if IRLI3705 can be replaced by IRLI3705N....
So how do I tell?
Would greatly appreciate any feedback, and would love to post updates about the progress of my process.