Currently reading:
About Stepper Motors

Discuss About Stepper Motors in the UK Electrical Forum area at ElectriciansForums.net

_q12x_

DIY
Reaction score
212
Actually there is another forum discussion until reaching this cct here. It was an entire evolution of it.
This cct is working ok but in certain parameters. It is limited to power and heat over the Tr's.
Is working fine in the 5V range for 2 of my stepper motors that I tested with it. But if Im bringing up the voltage, to 10V, I get 140dgrC on one Tr and about 60dgrC on a few others. At 5V, everything stays at a constant 50dgrC which I call it normal and safe.
One of the test motor is a Nema17 17HS4401. The other one is a scrapped stepper. Both work fine at 5V and even at 10V, no one was heating. Over 5V, especially at 10V, only the driver's Tr's were cooked to (almost)death. I stopped the power after smelling hot metal in the air.
I am also receiving a couple of L298N IC's. They are coming in the mail, not arrived yet. But I dont expect much difference from them, compared to what I have here. It would be nice to be better ! I hope so.
- My question:
- How to make this cct more powerful? To drive more power through the coils of the stepper motor? (and not blow up it's Tr's!)
I already have 2 answers to this question in my mind, but I dont want to influence your answer. I expect to be pleasantly surprised. Haha.
4wire 2phase2coil Stepper Motor logic circuit v3.jpg
Thank you !
 
I am waiting with my wife at addenbrookes hospital Cambridge. The hospital is very large. Not had chance to watch your last video.
You will, when you will be bored out of your ears. Waiting in hospital, I know that story, I actually waited for days at some point in my life. I hope is not something serious, but a routine check, right? I wish you and your wife good luck. Good luck from Romania is a precious thing, you get it very rarely in your life. So use it well.
The motor eh? Haha. Well... not really-really a plan per say... but I do have something in mind. Its a very simple thing, but we will get there. Trust me. For now, I want a very serious and stable and reliable stepper motor driver/controller. That is capable (most importantly) to drive at full potential these motors ! Not like my dinky driver that is able to spin them but not really put them to serious work. You get the idea.
Another important thing is accessibility ! We, humans, in these modern days, we got used to already made boards that are performing very well, no doubt about that. But it should be correct to have the proper circuits to build those well performing boards they sell so expensive as well. Dont you think? I very much do. So from that aspect of things, I am very ----ed off and I want to correct it. I want a (very) good performant cct for driving these motors, available, online, on internet, and not hunt for help. That's important ! In my mind. I hope I transmitted to you the same feeling I have. And you should transmit it as well further.
 
I doubt my circuit will be the acme of what is possible. To do that requires considerable testing and real life trials to discover and fix problems which may at first be hidden. That is why in my view some of the best technology is often years old. But my breadboard may work reasonably well as a technology demonstrator which with your patience you can perfect.
 
Stepper and mosfets arrived. And I thought I would do some reading up since the last time I made any circuitry for stepper motors was 40 years ago at college:

https://www.ti.com/lit/ml/slua618a/slua618a.pdf?ts=1666798524312

If you dip into this reference you will see there is more to a good driver circuit than at first blush*. Maybe too mathematical for you but the text is reasonably understandable.

*
at first blush

phrase of blush

  1. at the first glimpse or impression.
    "his next decision was at first blush disconcerting"
 

Attachments

  • 790B47E7-7DA3-40CE-BF3C-E7F608CD3728.jpeg
    381.6 KB · Views: 37
Last edited:
WOW- it must cost you a small fortune.
I have a success ! With the mosfets !
I managed to install a primary external PSU of 12V to drive all the gates and the voltage regulator and the logic circuit.
And a secondary PSU, my variable PSU that I can monitor the Amps and Volts on the motor itself.
Here is what I tried:
4wire v5 - N-ch Mosfets - separate power -.jpg

The 4wire NEMA17 - the new one, worked excellent at the lowest fv to the highest. I didnt reach 5V, but up to it, like 4.5, 4.8V. But the amperage was considerable high, at 1A, 1,2, 1.5. I keep it running most of the time somewhere at 300mA-to-600mA.
Some of the Tr were hot and some were Very-Hot.

1666884526015.png


I am very happy that nothing burned out.
Well... in my first try I actually forget a link wire in the breadboard and that got extremely hot and the plastic got in thick smoke and I thought it was a Tr. But the Tr was fine. Haha. But that was the only incident and at relatively low power.
No motors , no Tr and no important components were damaged.
The Voltage regulator started to heat up quite high with a heat sink on it. BIGGER is BETTER was always my motto. Haha. But that can wait.
The only failure I have so far, with this current circuit that I just tested, is the second 4wire scrapped motor. It only trembled and never rotated. I switched its connection wires a lot and the motor could NOT start rotating. Only vibrating. I noticed the new NEMA17 was trembling until 4V but after 4V started rotating. So, I increased the Amps and Volts for the scrapped one, I reached 5.5V but at a very high Amp of ~2A, so I dialed down for safety. The Tr's got extremly hot at that point. I did all this experimentation as quickly as I could, in a couple of seconds, no more than 10s per high level of power. Usually I keep everything working at a very safe temperature and power of 300mA and somewhere at 2V. At this level Ican see trembling in the motors and also no heat on the Mosfets or the VoltageRegulator.
Like the BJT version, this mosfet version has the Voltage dependent to the Amps. But is a lot better because is not limited like the BJT was. I couldnt reach 1A with the BJT. If I remember right. At 600mA everything was starting to get extremely hot. So usually if I remember right I was keeping at 300mA or less. Back then the scrapped motor worked perfectly for the tiniest impulses. But now.....????
Now that I have 2 functional circuits, its a stage completed at this point.
I will try to build the BJT that give me the best results, as a stand alone board. As weak as it was, it did served very well for testing the motors. This more powerful mosfet circuit.... hmmm, I will come to it when I will finish the BJT one. If the scrapped motor worked with this mosfet circuit, I would have been very happy. So far im only 50% happy.
1666884573881.png
 
Last edited:
comments from the other forum:
I only look at the top Transistors. All the bottom ones are drive at 5V ! So 4 mosfets in the lower side. Hmmm. I didnt notice it. But it worked like that, haha.
Someone noticed 2 of the mosfets are still working at 5V, and I looked more closely and 4 of them , the bottom ones, are at 5V but I notice after all the thing worked as described. Hahaha
It worked fine....
 
Good morning. I have been studying your latest driver circuit, the one with some mosfets circled in red. I think you have made a wiring error between the cd4017 and the two H bridges. If you think of each of each H bridge as being made up of diagonal pairs of mosfets ie \ and /, then for wave switching the pairs are switched on as in my attachment to #7.

The sequence, looking at my #7 table is 1, 4, 2, 3, 1, 4, 2, 3, 1……..where these numbers refer to the pairs of Q transistors read left to right 1, 2, 3, 4.

Your pairs of diagonal transistor are being switched 1, 3, 2, 4, 1, 3, 2, 4, 1…….

If you study your diagrams at #1 and #36 in the way the 4017 is connected to the two H bridges you should see what I mean.
 
Thank you for your last comment.
My friend mister @marconi ... check this out, what I received today !
20221101_134314.jpg
20221101_134326.jpg

The far right IC that almost has no marking left on it is the one from you. I notice mine are bigger. I didnt realized it when I buy them. Eh...
Cool, yes ?
 
Thank you for your last comment.
My friend mister @marconi ... check this out, what I received today !
View attachment 103229View attachment 103231
The far right IC that almost has no marking left on it is the one from you. I notice mine are bigger. I didnt realized it when I buy them. Eh...
Cool, yes ?
Your chips At28c64 have 64k of memory whereas the At28c16 I sent you had 16k. Otherwise they have the same technology inside. There are two more pins for the address on yours A11 and A12.
 
Last edited:
There are two more pins for the address on yours A11 and A12 to address 64k rather than 16k since 2exp2 is 4.
Im not sure how your math works but here is my math:
2^16 = 65536 bit combinations (your chip)
2^64 = 1.8446744e+19 which is 2 quatrilions probably of bit combinations. And not 4 like you calculated. Haha.
 
Im not sure how your math works but here is my math:
2^16 = 65536 bit combinations (your chip)
2^64 = 1.8446744e+19 which is 2 quatrilions probably of bit combinations. And not 4 like you calculated. Haha.
16k memory locations is organised as 2048 x 8 bit memory locations shortened to 2k x 8 bits = 16k. 2exp11 = 2048. Address word A0 to A10.

64k is 4 x 2048 x 8 bit = 8192 x 8 bits = 8k x 8 bits. 2exp13 = 8192. Address word A0 to A12.
 
Aha... I believe this number 2048 and 8192 are referring to the Addresses/or/MemoryRegisters of the IC.
I think I get your point. Im not used to think in these terms, I still lack some experience but im not far away. Thanks for your kind explanation !
 
- I open it before I buy it. Im always reading the datasheet, I got used to it and is a routine now for me.
Good thought but im doing it all the time. I didnt read it corner to corner, I only fly over it, I smell it. Haha. Probably I will, in the future.
- For now I showed you that your influence grow with me. I liked the IC especially after that HARD circuit I made, also with your help, I realized it is a very good chip to have. And it was quite cheap anyway so I made the step and took them. How I will use them... we'll see in time.
 
Actually there is another forum discussion until reaching this cct here. It was an entire evolution of it.
This cct is working ok but in certain parameters. It is limited to power and heat over the Tr's.
Is working fine in the 5V range for 2 of my stepper motors that I tested with it. But if Im bringing up the voltage, to 10V, I get 140dgrC on one Tr and about 60dgrC on a few others. At 5V, everything stays at a constant 50dgrC which I call it normal and safe.
One of the test motor is a Nema17 17HS4401. The other one is a scrapped stepper. Both work fine at 5V and even at 10V, no one was heating. Over 5V, especially at 10V, only the driver's Tr's were cooked to (almost)death. I stopped the power after smelling hot metal in the air.
I am also receiving a couple of L298N IC's. They are coming in the mail, not arrived yet. But I dont expect much difference from them, compared to what I have here. It would be nice to be better ! I hope so.
- My question:
- How to make this cct more powerful? To drive more power through the coils of the stepper motor? (and not blow up it's Tr's!)
I already have 2 answers to this question in my mind, but I dont want to influence your answer. I expect to be pleasantly surprised. Haha.
View attachment 102851Thank you !
Pondering the circuit at your #1, I am doubtful whether when the CD4017 output is logic 0 that the inputs to the base of the upper transistor and the input to the NOT gate are pulled down to 0V because those 4 diodes, one on top of the other, are reversed biased so no sinking current can flow through them. The diode path can only source current which raises the potential at the base and input to the NOT gate - not lower it. I would insert four 10kR resistors as I have indicated in the attachment to provide a current path to the 0V rail when the input to the diode is logic 0.
 

Attachments

  • 4wire 2phase2coil Stepper Motor logic circuit v3.jpg
    166.2 KB · Views: 10
Last edited:
I would insert four 10kR resistors as I have indicated in the attachment to provide a current path to the 0V rail when the input to the diode is logic 0.
-I actually did that in my experiments. Here are my results: In the simulator, I got a very small performance boost in the motor spinning. Almost negligible. In reality, nothing really looked different. With or without those resistors, the motor(s) were driven the same. I put 100k indeed there, in all my experiments. But I put 10k and 1k and the result was the same so I decided to go quite up in the resistor value since the performance and the result was equal in any circumstance.
-Your explanation is very pertinent and I like it. I may try it again and see if indeed something improves.
Well done with figuring how to draw over an image ! I know it is hard to do it for you. But it pays off, doesnt it? Heh. I cna teach you some advanced image editing stuff, since you know me, Im actually a digital artist and not someone who aspire to be one. Anytime, my doors are open to you.
 
I was just demystifying L298N Motor Driver Module for 4 wires cct right now. It turns out it is having only a fixed 7805 VReg at 5V @500mA and 2 filter capacitors, one for the variable Input and another for the constant 5V output.
I also find this cct online, that is the exact same cct from this module datasheet, but is much more clear to me:
1667502447103.png

Then, I was also paying attention to the recommended current controller IC L6506 recommended to be used with L298 . It is a new chip for me, and I really have no idea what really does... although I read its datasheet, Im still loking stupid at it.
1667502482119.png


...further in time...
- I believe I may understand the practical reason for this L6506 IC. I believe, it is using some sort of feedback from the motor and it is --maintaining-- the same speed and torque of the motor, by automatically regulating the current.
The text selection I made is telling me what --might-- be. And I think I'm right.
1667502558910.png

- I strongly believe it is pretty much like my lathe, when I apply force on the motor spindle, when Im cutting into metal, the speed and force is maintained and not decreased as long as I press into the axe.

The simple way....
I believe...(I dont know for sure) the simplest way of driving this L298 IC is to use an arduino.
1667502596698.png
1667502608009.png


The complicated way...
Is using this L6506 IC internal cct logic. Since I dont have the chip and no one told me about it to take it in time. I didn't look very hard either in the datasheet as well.
1667502637113.png

Ive already read the entire description of this L6506 chip and I decided is a very cool function to have with my stepper motors.
I believe is a moderately 'simple' logic circuit to build. I looked at the prices already for the L6506 IC and is a bit expensive for the moment. I will live without it for awhile, and build myself its internal logic cct.
  • I think is best to do the simple way first, to get it running and familiarize with the L298 chip itself. And after that, add this new layer of cool but more complicated cct. That's the plan. Wish me luck.
  • Any helpful comments are welcome. My first time with this L298 chip. Very virgin right now. Haha.
 
Last edited:
Hello. Editing while my wife shops😕

The first thing to think about is how to provide a 35V Vcc supply of say 2 to 3 A dc for the 298 driver. Whereas the H bridge driver circuits were constant voltage drivers and the current through the coils rose and decayed as in a series resistor inductor circuit in response to an on and off voltage waveform, the 298 cleverly uses a higher voltage to increase the initial rate of rise of current through the coils which enables the stepper to operate at faster rotation rate with less reduction of torque as speed increases. The other chip has two external resistors placed in series with the two coils to sense the current through them. When the sensed voltage exceeds a threshold voltage the second chip knows the coil current I is greater than Iy the desired current through the coil and it tells the 289 to turn off the energising voltage Vx to the stepper coil. When current decays - the inductance of the coil will act to try and maintain current flow - and I is less then Iy, the threshold voltage is sensed as low and the chip turn on Vy again. For each coil, the energising voltage is being turned on and off - 'chopped' - but because of the coil's inductance the current is maintained largely constant. See my electrical art which was scribbled in the shop while I was waiting and is largely right. Obviously the full Vcc voltage across the coil would cause too much current to flow for too long and is likely to cause overheating. But the chopped waveform and the sensing of the coil current means that the average current is not greater than the specified maximum current for the coil. This quick explanation tells you why the chip is a constant current driver.
 

Attachments

  • 68B39962-1765-46C7-B69B-368D9960B01D.jpeg
    446.2 KB · Views: 11
Last edited:
Good morning. Just watched your progress report video. Two comments if I may?

1. Put a heat sink on the L289N;

2. The L289N will not operate the best it can in voltage drive mode as you have it now because the voltage is too low and the current flowing is too high for too long so it overheats. You need to control it using the L6506 so that using the voltage chopping technique inside the 6506 the 289 will drive the coils of the stepper motor with constant current albeit the value of this constant current can be varied by varying threshold voltages values at which the higher voltage motor supply is turned on and off ie chopped.

Here is a clearer diagram of chopped voltage waveform and resulting coil current waveform than my earlier electrical art - but not too dissimilar than my drawing I think you will agree😎 :

Chopper Drive
Relationship between voltage and current in a constant current (chopper) drive.
Image credit: Oriental Motor USA Corp.
 
Last edited:
1. Put a heat sink on the L289N;
It is Under-Powered/Voltage. No need at this testing stage. I was aiming for its safe zone of operation.
And I find it to be at 3.3V. Over that, will heat up. But also depends on the motor used as well. For the scrapped motor will be a bit higher, 4V running cold. ;)
2. The L289N will not operate the best it can in voltage drive mode as you have it now because the voltage is too low and the current flowing is too high for too long so it overheats.
Not correct. It is Under-Powered Under-Voltage. It is as I tell you, running cold a these safe values. What you dont know is that the voltage and current are proportional. Meaning, as long as I increase the voltage, the current will increase as well. And vice-versa(but I don't have this capability). I tested at 3.3V and 4V for about 10minutes and all this time, run cold. No current too high as you say.
Heating occurs over a certain voltage but everything remains constant beyond 10 seconds of running.
You need to control it using the L6506
Yah... thats the next thing in plan. I do not have this chip and it adds too much to my budget expenses. And also will be used sporadically. So my plan is to actually make it's internal cct that consists of 2 opamps, a FF and a clock. Easy to make, but a bit spacey. I can live with that.
 
I leave you with somethings to ponder - why does your current project spin the motor slowly and smoothly albeit in steps but when you increase the pulse rate it stops rotating? And you may notice that over the range the motor spins as the rotational speed rises the torque the motor is producing decreases - why?
 
I leave you with somethings to ponder - why does your current project spin the motor slowly and smoothly albeit in steps but when you increase the pulse rate it stops rotating? And you may notice that over the range the motor spins as the rotational speed rises the torque the motor is producing decreases - why?
That is the nature of a stepper motor. The higher the frequency the smaller the torque. And vice-versa, the smaller the speed, the higher the torque. Is nothing to wonder about. Is like looking at the sky and ask me why the clouds are moving. Because thats the way sky works. The same as with the stepper. And the faster the fv applied to the coils, the faster it runs. But in a certain limit. After that limit, or certain fv, the stepper is unable to spin anymore, and losses its rithm. I already establish these limits.
 

Reply to About Stepper Motors in the UK Electrical Forum area at ElectriciansForums.net

OFFICIAL SPONSORS

Electrical Goods - Electrical Tools - Brand Names Electrician Courses Green Electrical Goods PCB Way Electrical Goods - Electrical Tools - Brand Names Pushfit Wire Connectors Electric Underfloor Heating Electrician Courses
These Official Forum Sponsors May Provide Discounts to Regular Forum Members - If you would like to sponsor us then CLICK HERE and post a thread with who you are, and we'll send you some stats etc

YOUR Unread Posts

This website was designed, optimised and is hosted by untold.media Operating under the name Untold Media since 2001.
Back
Top