@@engineerbo What do you think about adapting your servo design for diy cnc minimill like what "I'm no expert, but" built? I'm in the middle of building one similar to his and the Milo minimill and was planning on picking up a set of SERVO57Ds with 1.9Nm steppers with this next paycheck. You seriously just saved me a lot of headaches!
I'd absolutely love to have a CNC milling machine (and also lathe), and have thought about making one myself. It's definitely on my bucket list to either make or buy one.
I haven't published any details about my servo schematics, since I'm not quite satisfied with it. I'll probably make a few videos about the design and its problems, which I think is better than releasing an incomplete schematic into the wild.
For stepper motor, acceleration and max speed are affected by voltage. That's why most of 3d printer use 24v, rather than 12v. Hope to see tests at 24v later as you get replacement.
@@engineerbo BTW, I subscribed. A long time ago when stepper motors and drive electronics were insalely expensive, they used to apply scary voltages to stepper motors... I have seen 3 or 5 volt stepper motors conected to the voltage equivilent of the rectified AC line. Due to the "L/R" characteristics of the stepper motrs, a simple series resistor and a high voltage transistor was all that was used to drive the stepper coils. VERY VERY inefficient but inexpensive and totally usable. A good example of a system like this was the Bridgeport Boss CNC. Servo motors and modern Chopper style stepper drives brought true CNC capability to the small shop and home shop. Thank you for this video, I am an electrical engineer and I see and appreciate your contribution to those of us who go to bed thinking about this stuff.
@8:40, an objective measure for the motor not being able to keep is seeing the current clip at the limit set in your drive. You don’t need to interpret the overshoot to say it is out of current. Great video!!
Thank you! The overshoot doesn't seem to coincide with an overcurrent condition. The servo's internal current limit would trip, leading to a servo fault, before the power supply's current limit is hit. The amount of overshoot can also be increased/decreased by changing the controller parameters, which is why I'm inclined to think it's a problem related to controller tuning.
I kept notes on the calculations and algorithms when I was developing the firmware. The focus was the auto commissioning process and it's pretty technical. I haven't published anything though.
The problem with the MKS Servo42D is quiet simple. If you bought the RS485 Version you can use the Makerbase USB to RS485 adapter with their software, to set the start and stop acceleration.😉
You stopped me in my tracks! I am currently doing a klipper install on an older machine that has the S42B from BTT which has the same acceleration of 1000rpm. I’m going to swap those out for TMC2209 if I want to have the speeds that I’m hoping to achieve. Glad I stumbled upon this video.
Yep I have the S42Bs too, nice and reliable little drivers/motors, but they do have their limits. I would suggest you something else entirely tho: go for TMC5160s instead, the high voltage variant, and run them at 48v or so (of course you'll need the board that supports or an adapter for that). It's what I've done with an enormous machine I built at work, that CoreXY system with a 500x500 bed (tho I'm moving 450x450 on it because of the rails) can reach 1000mm/s with 50m/s² accelerations (yep I'm cutting out that milli out, straight out meters per second square). At high voltages it does slam current into the motors quite hard. You DO need a powerful enough power supply to run their peak power tho.
The drive voltage has a direct impact on the maximum speed, though the torque is still limited by the motor construction (current limit). One of my good-to-have features for the next iteration of my servo controller is 48+V support!
I also had countless issues with MKS servos, I think the uC code for the serial interface is broken, with step and direction you can use much higher speeds, but once you overshoot the error window the motor will actually slow down to 100rpm and never catch up. It's also not capable of NPN/PNP (i forget which one was broken), the schematic and documentation suggests that it'll work in either direction but the actual implementation doesn't work, all you get is a big self induced oscillation loop. Anyway for my project I ended up switching to delta AC servos, several orders of magnitude more money but man the performance is scary good 👀
I had some difficulties getting the serial interface to work at the start, but eventually polling for the position and error worked. I haven't tested the other serial commands though. With my own servo implementation, it's also very possible to get oscillations if the control loop isn't tuned correctly. How did you induce oscillations with the MKS implementation? I'm thinking it'll be fun to try and reproduce it.
@@engineerbo I was using a PLC's GPIO which are 24VDC sink or source, I believe when the servo is in sinking mode this saturates the input transistor arrangement, so all of the inputs get stuck on except when the direction signal is low, which causes the step to leak through to the direction channel and it goes nuts trying to run both ways at once.
I had a quick look at the schematics, the optocoupler part number doesn't seem to match what I find online. But besides that, it looks like the step/dir/en pins need to be push-pulled, or there'll be a leak through the resistors on the COM net, affecting high-Z inputs.
Is your BLDC servo board available for purchase? Something ive been looking for for a very long time. Great video and a subscriber earned. I look forward to more.
Thank you for subscribing! The servo controller isn't quite ready for prime time. I made it mostly as a learning exercise, and there are still many improvements to be made, for example reducing the phase current measurement noise.
I’d love to see how the closed loop compares to the open loop in terms of stall torque. I want to make a lathe with nema 17s that are gear reduced. I’m wondering if the closed loop can handle more force at say 0-300rpm than the open loop
That'll be very useful information indeed. I've been thinking of building a Prony brake setup which will allow me to create speed torque plots. I might do that for a future video. Thanks for the suggestion!
but why ? why messing with this DIY-style contraptions with bare pcb on the back when there is a lot of cheep industrial grade closed loop steppers with optical encoders.
@@vasyapupken I’m designing a machine with covers and a positive air pressure system to keep coolant/dust away from all of the components including the motors. I want to do OD/ID carbide grinding as well. A bare backed pcb motor wouldn’t be a liability really. I’m curious can you point me to closed loop systems that can be purchased motor and driver for a similar price of around $26 shipped? I’d love to hear about your suggestions
Could you do a more in depth video on how you set up servos in Klipper? Im wanting to build a small voron printer with servos instead of steppers and you honestly seem like THE guy to make a video on it. There is surprising little info on servos with klipper right now.
I have the BTT S42Bs on my printer, and got the S42C as an "upgrade" (board only had the motors already anyway), and the upgrade part was just plain terrible. The older ones worked quite reliably and solved my issues I had with lost steps in my lead screw based machine, the new ones stuttered ridiculously at different speeds. The old ones do have a bit of issues at the start and end of movements tho. My bet on this is that since they do use PID to control the system, it might just be factory tuned badly, better on the B version than C ones, but still kinda off, then again I don't have the time now to test new PID values on the motors, hope I can get around this soon enough.
Yes it's quite possible it's a controller or tuning problem. It looks like it could be something like an integral anti-windup limit, but I don't think there was such a parameter even using the configuration software.
Hmm... I'm probably not telling you anything new with this, but steppers like higher supply voltages in order to get good RPMs out of them. When the replacement parts arrive for the MKS board; it would be interesting to see how much performance the closed-loop stepper picks up when powered closer to the drive's max rated voltage.
You're right, higher voltages usually the steppers can spin faster, since the top speed is when the motor's back EMF, which is proportional to angular velocity, cancels out the supply voltage. It's definitely worth a test, but I'm not optimistic, considering the huge difference between the open-loop and closed-loop stepper speeds when both are running on 12 V.
I believe with the tmc2209 that it does not face such high current draw during holding torque/no movement situations depending upon settings. Doing UART control with an esp32 I've had it successfully vary in current/power draw between different parts of operation. Just a heads up. This is amazing though and I beyond appreciate such
Your servo design looks very interesting, I would love to learn more about it. Closed loop stepper motors and hybrid stepper motors are often presented as good 'middle of the road' alternatives for people who don't want to mess with servo's. But as this video shows the gap can be quite large. I had no idea a closed loop stepper could be so slow, but I guess it makes sense as steppers aren't really designed for high speed/high torque applications. Adding the baggage of a closed loop system on top of that makes the whole motion system slow and unwieldy. I wonder if a hybrid stepper would do much better in a closed loop system. In the end well tuned (Field Oriented Control) servo's are really the golden standard.
Thank you! I'm planning a series on the design of the servo right now, is there any particular aspect of it you're interested in? Given the open loop stepper is able to move much faster than the closed loop stepper, I'm inclined to believe that it's primarily a controller problem in this case.
@@engineerbo Mainly the electronics and the software. The calibration procedure you showed in this video is quite extensive. It looks like you put quite a bit of effort into the software side of the servo driver ☺
👌 Starting the series with the electronics/schematics probably makes sense. You're quite right about the calibration procedure. Easily more than half the time went into implementing the self-commissioning algorithms!
I wish this was something that could be added to klipper, I think it could be very useful for finding max acc and speed with any given printer :D I'd love to see this turned into a macro
I initially wanted to implement it as a Klipper macro since it's a little hacky to pipe gcode using the pseudo serial port, but implementing loops and conditions in Python is just so much simpler.
@@engineerbo With Klipper being C and KlipPy (Klippy) being Python, it's already halfway there. The critical parts, though, are still C. But if you can make a working Python implementation for closed loop, I'm sure there's C nerds out there that can help you get it into C/C++
I'm reasonably comfortable with C/C++, but haven't figured out how Klipper is structured. I enjoy using Klipper, and even tried to get it to control my pick and place machine (worked used macros, but poorly), but still never figured out how to write custom modules for it.
I'm currently using OpenPnP and Marlin. I actually started off using Klipper with manual_stepper and many hacky macros, to limited success. Would have loved to have stayed with Klipper because it's so much easier to reconfigure. If you're making a 3D printer, servos that support step/dir should work.
Nice video i use the closeloop driver on my 3d printer and i also noticed some small issues but it gives a great result. but i see now on the github they give parameter suggenstions. "disable MPlyer" and set "ACC to 412 or 538" i'm going to try that.
Amazing video! Thank you! It would be great to see if the D version of the MKS controller also behaves the same way. Also, are you planning on making the BLDC servo controller open source? It seems like a great controller!
There is software you can use, by connecting a computer the mks servo's serial port I believe. You might find the RPM limit setting in there. However the slow CPU might not be able to do full speed.
Yes I tried the application, it's called "MKS SERVO42C CONTROL V1.1". I used it to verify that the serial communications were working when I had problems polling the position/error from Python. There are a few extra settings compared to the OLED menu e.g. PID parameters, but I don't think there's a speed limit setting.
great video. Your testing setup is amazing and I found the video very interesting to watch since I am working on open loop steppermotors right now myself:)
I would've loved to see a comparison where you use a higher voltage. Like 24v and 48v for especially the stepper motors, since this helps tremendously with speed and torque. However, I do believe the TMC2209 has a max rating of 36v.
Yep, I ran some tests at 24V until the SKR V1.4 blew up. I've fixed the board now, and also gotten a new power supply that can handle 48V, so I'll run some new tests soon!
Hello, I'm building a delta and I'm not sure whether to use Nema 23 or a Brushells motor, which one do you recommend because I want greater speed on the printer?
Seems to me that if youre attempting to fix layer shift, its easier and more effective to go to a longer stepper motor. I went from 40mm long to 80mm long. .32nm of torque to 1.09nm and bumped the run current to 1a and installed 40x10 fan to help cool the drives. Throws the bed around just fine now without layer shifts @ 2x the accel (4k was max on stock, now i print @ 8k with 14k travels)
I was just curious about the performance of a cheap closed-loop stepper. But I agree, it's probably not a good first choice for fixing layer shift problems.
How do they compare in price? UA-cam algorithm send me here. I am a Software engineer for embedded Devices and i would like to see your sourcecode and schematic for my diy cnc. You mentionet bigger ones as well, i would like to see avideo about those as well
The closed-loop stepper motor was surprisingly affordable, and only cost a slight bit more than a generic open-loop stepper and a TMC2209 driver. The difficulty with price comparison in this case is the servo, which I hand built in tiny quantities.
1:32 I've tried to search about your DIY C4260 servo design project and PnP project which uses the C4260 BLDC in your channel but I've not found them. Do you have the videos for those?
Hello, I haven't gotten around to making videos about these older projects, but it's in my to-do list to build a new iteration of the servo and make a video about it.
@@engineerbo I will wait for your those videos. BTW: I've seen your videos "MKS SERVO42C Closed-Loop Stepper: Tests vs Servo with Field-Oriented Control and TMC2209 Open-Loop" and "Finding the Best NEMA17 Stepper Motor: LDO Motors, STEPPERONLINE and more tested with a dynamometer". They are very impressive. You have high engineering skill, good technic and very well presentation. I appreciate for your videos and how you tested and mesaured all thoses staff. Thank you.
Since the odrive went closed source, the only open source servo system I've found is the mjbots / moteus I'd be interested to see how the design / firmware compares
Ah yes the recent odrives are no longer open. It's a shame, but understandable given the numerous clones. I've seen the moteus controllers, and they use much more recent components than mine (e.g. newer microcontroller, newer gate driver). I designed my servo hardware several years ago, so the hardware is more similar to the original odrives. The firmware's really where there'll be major differences. I've written my algorithms in a more academic way, forcing myself to follow the math and not to use hacks. This probably has a performance cost. I'll make a series on the design of the servo in due time, subscribe if you're interested!
Hi! excellent work on the comparison, i have a question on the MKS SERVO42C, is it possible to have a torque variation depending on the severity of error i introduce? (for example i introduce 10° angle error -> torque 30% of maximun, then the error gets to 20° angle -> torque increments at 60% of maximun). I've been tryng to create a 3 DOF imput system like the old Novint Falcon for personal use and i was curious if these little boards are up to the task without going to BLDC motors where i have little experience.
That sounds like a proportional controller, but are you sure that's the behaviour you want? The SERVO42C's PID controller can be configured using the provided software they named "MKS SERVO42C CONTROL V1.1", but I don't know what the control scheme is exactly, and it's unlikely it'll give you exactly what you described.
Are you referring to the step/dir signals from the motion controller? The setpoint plot seems to show the steps being counted properly, and on re-homing, the closed-loop stepper didn't lose any steps.
beautiful work on servos for 3D printers, I've been wanting to implement them on mine printer for a while but I can't find much info about them, I think they have numerous points in favor compared to an open loop system with stepper motor... which board do you use to manage the servos? Thanks a lot I'm definitely signing up, I'm really curious about any news on servomotors in this environment
The theory is explained in "Anticogging: Torque Ripple Suppression, Modeling, and Parameter Selection" by Piccoli et. al. In summary, the servo driver positions the rotor at various (many) positions during calibration, and measures the current required to hold the rotor position. The holding current is indicative of the cogging torque. The current values are then stored in a look-up table and are used with the motion controller as feedforward terms.
First of all, congrats on the video, it's really good and technical! I would like to know more about your test setup, i want to make some tests in different models of stepper and your setup can help me a lot, can we talk about how you make it, components, etc?
Thank you! The mechanical components of the test setup are either common off-the-shelf parts like GT2 pulleys, idlers, belts, or designed for the purposes of this test and 3D printed. I didn't talk about the accelerometer in the video, but it's an 3-axis analog output device (ADXL335). It's only rated to 3G per axis, so I mounted it 45 degrees to combine X and Y for ~4.2G range.
Very nice video! I see in your comments that you did not post any files, but would it be possible to show how you connected the servo to the MCU? And did you make your own board or is it a pomade one? Thanks
Thank you! The servo is completely custom made. It's connected to the SKR V1.4 using the step/dir interface like the other two motors, using a custom adapter board that plugs into where the stepper driver goes.
how about the other options? HBS57 with closed-loop nema17 and the usual iHSV servos like iHSS42-24-05 bought a mks servo long time ago when it was all the hype but in the end never used it, way too slow and unreliable. went with hbs57 driven nema23 closed loop steppers instead for my project that required the necessary beef.
Cool and informative Video, thanks! I am looking for a motor to use in a robot arm project right now, is there any documentation or production files available for you custom servo and the corresponding PCB?
The closed-loop is only within the motor control system. The position error etc aren't fed back to Klipper because like you said, Klipper doesn't support it.
@@engineerbo I’ve built a few 3D printers and a CNC machine with Nema 17’s, you get a lot more torque and acceleration when the drivers get 24v to play with.
Yes a higher voltage allows a higher drive current and higher speed (I talk about this in my video on regenerative braking). But I'm guessing the servo42c's being limited by something else like the microcontroller or the firmware, so it wouldn't be able to take advantage of the higher voltage.
@@engineerbo that is a good point - the tmc2209 should have a way to configure the max current for the stepper. The LDO motors I use are good for up to 2.5A. So I typically run them @ ~1.77 A RMS (2.5x0.707) for longevity, or full beans for max performance (they get fairly hot then).
For the TMC2209 tests in this video, I've actually set the RMS current to 2A, which is the max. rated current this driver board supports. That's probably how it gets so hot so fast. I've seen LDO motors mentioned a lot, particularly their speedy power and super power motors. The super power motor's speed-torque curves look interesting, so I've been sourcing some for testing!
great work .I am usnig 5 of these Servo42c on my pnp Machine. What is the firmware vesrion for Servo42c V1.1 or V1.0? Also can you check with MPlayer setting disabled once and see if that improves the performance. I have seen emi issue with these where they stall and start oscilating on one place pretty scary :). Also please share some videos on the PnP machine would love to see the machine in action :P .I hear lot of issues with the smoothieboard clones especially the SKR V1.4 where 24V can mess up the board, I have a MKS Sbase V1.3 with its one set of issues but i am running things on 12V and can power the servo with 24v in future if required
The firmware version's V1.1.2, and the MPlyer is enabled (by default). As far as I can tell, this seems like additional internal microstepping, so it's quite possible that could affect the performance. I took a look at the schematics for the SKR V1.4 after I blew mine up, and found that the DC-DC converter is rated to 28.5V, so the regenerative braking spike probably exceeded that. It's probably a good idea to run the SKR V1.4 on separate power rail to be extra safe.
Not yet! I recently decided to make videos so I'd be more diligent with documenting my projects. The pick and place machine is in the queue to be featured, hopefully soon.
Given how the 42C performed, I'm a little hesitant to purchase the 42D. I might still do it purely for testing purposes if there's sufficient interest.
Yes the acceleration data is coming from the pico, but the position/error information comes from the servo or closed-loop stepper, and they're all plotted live using matplotlib in Python.
Hey No I'de love to see some tests against cln17 v2 drivers. Not sure if anyone would send you one for testing as you can't buy them yet, they need to be self made from PCB fan. Check it out if you have time.
A great test, I'd love to know if there's something in the configuration of the closed loop motor which could fix the linearity problems because even with the speed issues it would be a good alternative.
Thanks for this test. Would you be willing to post your design for your custom servo motor? How easy is it to add those servos to a klipper 3D printer?
I'm not sure I'll publish them quite like a few other motor controller projects, but I'm planning on doing a deep dive video series on it, since there seems to be sufficient interest. The servos in this test are configured to use the step/dir interface, so Klipper doesn't even know it's not a stepper motor.
Thanks for the suggestion! It might take a series of videos to cover the whole design. Is there some aspect of the servo you're particularly interested in?
Thank you! Yes the live plots are using Python, specifically matplotlib. I use daemon threads for the serial interface, and multiprocessing for the actual live matplotlib animation.
The open-loop stepper performance is largely a function of the driver! From the motor, looking back into the driver (specifically the resistance seen) will affect top-speed, ringing and stability.
The driver definitely has a major impact on the performance. I can imagine resistance and wire inductance can have an impact, but I wonder how significant it is for reasonable cable lengths.
I have used the servo 42c's on my 3d printer and it does not give my input shaper higher than 8k acceleration's. Using a LDO Speedy power gave more than double the accelerations.
That servo looks extremely interesting. I would love to build a high speed 3D printer with it. Have you found any weird behaviours from using a servo vs traditional open loop stepper? From the vid it looks like your servo just out performs everything with no downsides
There are some tradeoffs to using the servo, for example the controller needs to be properly tuned, and in the current design there's still significant servo noise. The servo's low speed and stall torque is also lower than a stepper, so it wouldn't be as good with holding position or slow moves under load.
@@engineerbo thanks for the reply. I meant actually to make it available as an open source design. I saw an open source design for a nema 17 closed loop controller. I was hoping you would share your controller design also available. Thanks
I'm open to sharing the designs in some form or another. At this point, I'm leaning towards doing it in video form, so these (incomplete and imperfect) designs are accompanied with commentary and explanations.
I tested serve42c vs standard stepped with TMC. I think: serv42c is stronger, and quickly than standard stepper. I don't really understand why the video shows that servo42 is slower. (setup is siliminar: microstep 16)
That's interesting, I don't think the serial connection would have changed anything though. How did you compare the performance between the servo42c and the normal stepper?
The script checks if the number of steps to the destination and back (home) are the same. If it took fewer steps to home (compared to the fast move) then steps were skipped.
Great video!! I'm starting on servos and motors and an another great video could be differences about NEMA, digital servos and others. I noticed that you didn't mentioned torque, it's possible that a nema17 or 24 have more torque than a 30kg digital servo? Thank you!
I actually did mention torque, specifically the speed-torque curves. But since the tests are with a linear system, whenever I say acceleration, it's really equivalent to torque. When you say 30kg digital servo, do you mean a hobby servo with gear reduction? The easiest way to tell is if these systems come with the speed-torque curves, so you'd have a direct comparison of the torque at the speed you need for your application.
@@engineerbo I'm sorry, i rewached the video and saw the post about the speed-torque curves and the more i'm reading it the less i understand :rofl: I'm no engi so in your opinion for a project with a really low rpm but really high torque requirement what is better to use, i have a 30kg hobby digital servo (with the gear reduction, yes) i might need to add a gearbox if needed XD
Hobby servos are pretty different compared to either a servo or stepper, so it really depends on your specific application. Steppers and servos can also have gearboxes which gives you even more options. My experience with hobby servos is that they aren't usually great for highly precise positioning, and are usually noisy because of the tiny gears. They usually also use potentiometers for feedback, so precision and resolution aren't their strong suits.
There are also affordable steppers with built-in gearboxes that would have more torque than hobby servos. Essentially, a hobby servo is unlikely to be a top performer if torque is the only concern. Of course, there are still benefits to the hobby servo, like availability, cost and ease-of-use.
Hello, the C3548 is just the brushless motor, the control board is custom made by me, and isn't for sale. If you want to buy the motor though, I've added a link in the description to the one I bought, which is the 790KV model.
Hmm. The main problem I found with both closed loop steppers like the MKS and the BLDC servo's is that they lag behind on the real motion, because they use the encoder to "fix" their positional mistake. That means that there's no "precision coordinated motion" anymore; you tell is where to go and it will just eventually get there.. tell it to go some place else, and it will go there instead. If your motor can keep up that's not a problem; if it lags behind (for example because there's load involved) it's a huge issue. For open loop systems, you have no guarantee either, but at least it's coordinated - because you need to tune it at a certain max speed and acceleration (torque). So it comes to me like no surprise that you get these results for the bldc servo: the test is just flawed. What you want to use here is a glass scale to measure where the thing *actually goes* which is different from where you *want it to go*.
I agree partially, I mentioned the caveat in the video as well. Neither open-loop nor closed-loop systems shown can make any guarantees on the position error. Both systems necessarily lag behind on the commanded position. The stepper doesn't teleport after you command a step. Within reason, both systems can achieve coordinated motion. This shouldn't be a surprise since it's not uncommon for high precision industrial machines to use servos. Perhaps you're suggesting hobby-grade controllers don't meet the positional control bandwidth you're expecting?
@@engineerbo Actually, open loop keeps coordinated when you use the same drivers for all axis (which is common). Especially the good drivers tend to have guarantees about times. No, they don't teleport, they continue due to inertia and the firmware makes assumptions about accelerations. I know I tinkered with that in our firmware anyways... Industrial servo's is another thing... basically they tune them so that the torque under load is more than the requirement, and use PID to compensate for a target setpoint. They can only guarantee that when you follow the manual to the letter, which basically implies the set point will be reachable before the next one is set... These AC Servo's are also usually not made with low end BLDC's, they are not running on SimpleFOC, have a differential optical encoder and so forth... Very importantly: they use set points with acceleration profiles, which a PID loop attempts to meet. Closed loop steppers also use set points, and loose torque when they are not powered (of course). The closed loop fixes the position to the set point. The main difference is the number of poles. If you change the set point before the target, the set point will change, even though you will still reach the second set point. Anyways, I try to explain here that there's a key difference between using set points and (traditional) stepping because of the distance, time and acceleration profiles involved here... but perhaps it's just too hard to explain in just a few paragraphs.
Servo control loops and tuning are certainly non-trivial topics. Perhaps at some point I'll make a video to compare coordinated movements between steppers and servos. Thank you for the comments!
My experience with the Servo42b is that it is relatively slow .. so I don't expect the 42c to be much better and I'll probably also go with a homebrew stepper rather than BLDC (since I need a little bit torque and the smallest possible design)
The makerbase docs specify the servo42b to have a max speed of 600 RPM, compared to the servo42c which is listed as 1000 RPM. This is actually one of the upgrades featured in their comparison table!
@@engineerbo how about the acceleration? I use the Servo42b on a pick and place machine for the Z axis certainly I can command rotate to a certain angle and then start commanding rotate back --- but then the servo won't reach the actual target/requested setpoint. The 42b is a bottleneck for me, I'd just add a beefy stm32f4 and implement the controller there accordingly. For my setup speed is very important. Let's say I pick/place 10.000 components that results in an overhead of over one hour just with a 0.5 sec delay per pick. but yes as you mentioned the 42c might be different but I don't want to spend my time with that and rather dig into implementing it myself.
If the servo42b isn't going to the commanded position i.e. skipping steps, then it's quite likely a different problem. Mine hasn't skipped a step, it just doesn't move the way it's supposed to.
@@engineerbo no it's not skipping it's just counting it up and back. 1 - 100 - 200 - 100 - 1 but if you start to decrease too early it might not go to 200. That's just my observation because I need to add some delay before retracting (then the components will stick on the machine).
Oh alright I see what you mean. In my tests I intentionally put a 200ms dwell so it doesn't start reversing immediately. Without the dwell, I expect the servo42c wouldn't get to the destination either.
i have problems with my nema 17 stepper motors - they run reallly SLOOOOOW could you help me out with picking electronics and - drivers for them to - be able to speed them up ? I am using arduino mega board for my cnc ... but it works just bad
It's quite a project to be building a CNC. As much as I'd like to help, I'm probably not the best person to recommend products (especially if I've not tested them myself).
The MKS stepper surprised, in the wrong way. I have seen people use it for 3d printers, where they seem to be pretty fast, can it be because they run them at higher voltage? Also, have you seen the Makerbase BLDC motor and TLE5012 encoders? It seems to be similar to the one you made.
It's possible the voltage might make a difference, yet the 12V performance is so much poorer than the open-loop stepper, it seems unlikely. It's still worth a try after I've fixed my SKR V1.4 board. It could also be a configuration problem e.g. the 256 internal microstepping. I haven't really paid too much attention to the other BLDC servos, but yes my component choices are somewhat similar to a couple other designs e.g. using the ultra popular DRV830x series.
If you try changing the microstepping or higher voltage on the closed loop stepper, please share. Its so interesting. Thanks for making such a nice video, Im subbed now@@engineerbo
I put it in my pick and place machine, but that doesn't need perfect coordinated motion since it's point-to-point only. Still manages to pick and place 0402 components reasonably well.
I'm not certain if there's a strict definition. As long as the motor has closed-loop positional control, it could technically be called a servo. It's still useful to distinguish systems based on motor type (e.g. steppers) because there can be significant performance differences (see speed torque curves).
Would love to see more about your own servo design!
Thank you, I'll see what I can do!
@@engineerbo What do you think about adapting your servo design for diy cnc minimill like what "I'm no expert, but" built? I'm in the middle of building one similar to his and the Milo minimill and was planning on picking up a set of SERVO57Ds with 1.9Nm steppers with this next paycheck. You seriously just saved me a lot of headaches!
Do you have a repo to look at the schematics for it ?
I'd absolutely love to have a CNC milling machine (and also lathe), and have thought about making one myself. It's definitely on my bucket list to either make or buy one.
I haven't published any details about my servo schematics, since I'm not quite satisfied with it. I'll probably make a few videos about the design and its problems, which I think is better than releasing an incomplete schematic into the wild.
This is not only amazing , but also informational.
I struggle to install steppers, bro builds his own servo!
Subscribed
Thank you!
I appreciate how thorough you are in your documentation. Your presentation is really good too. Thanks :)
Thank you!
For stepper motor, acceleration and max speed are affected by voltage. That's why most of 3d printer use 24v, rather than 12v. Hope to see tests at 24v later as you get replacement.
Yes they are. I'll do a follow-up video before long!
@@engineerbo BTW, I subscribed. A long time ago when stepper motors and drive electronics were insalely expensive, they used to apply scary voltages to stepper motors... I have seen 3 or 5 volt stepper motors conected to the voltage equivilent of the rectified AC line. Due to the "L/R" characteristics of the stepper motrs, a simple series resistor and a high voltage transistor was all that was used to drive the stepper coils. VERY VERY inefficient but inexpensive and totally usable. A good example of a system like this was the Bridgeport Boss CNC.
Servo motors and modern Chopper style stepper drives brought true CNC capability to the small shop and home shop.
Thank you for this video, I am an electrical engineer and I see and appreciate your contribution to those of us who go to bed thinking about this stuff.
Thank you for subscribing!
@8:40, an objective measure for the motor not being able to keep is seeing the current clip at the limit set in your drive. You don’t need to interpret the overshoot to say it is out of current. Great video!!
Thank you! The overshoot doesn't seem to coincide with an overcurrent condition. The servo's internal current limit would trip, leading to a servo fault, before the power supply's current limit is hit.
The amount of overshoot can also be increased/decreased by changing the controller parameters, which is why I'm inclined to think it's a problem related to controller tuning.
@@engineerbo Are you using any feed forward in the servo controller?
do you have documentation on your servo design? would love to see more about it.
I kept notes on the calculations and algorithms when I was developing the firmware. The focus was the auto commissioning process and it's pretty technical. I haven't published anything though.
The problem with the MKS Servo42D is quiet simple. If you bought the RS485 Version you can use the Makerbase USB to RS485 adapter with their software, to set the start and stop acceleration.😉
The open-loop stepper isn't a low-cost solution when you end-up making scrap parts. I am closed-loop servo, all the way. Great vid, very clear 👍
Thank you!
people seem to really like your servo, hope it gets the noise removed and published soon 🤩🤩
Thank you! I'll be making a video series about the servo's design, flaws and all, sometime in the future.
You stopped me in my tracks! I am currently doing a klipper install on an older machine that has the S42B from BTT which has the same acceleration of 1000rpm. I’m going to swap those out for TMC2209 if I want to have the speeds that I’m hoping to achieve. Glad I stumbled upon this video.
Yep I have the S42Bs too, nice and reliable little drivers/motors, but they do have their limits.
I would suggest you something else entirely tho: go for TMC5160s instead, the high voltage variant, and run them at 48v or so (of course you'll need the board that supports or an adapter for that). It's what I've done with an enormous machine I built at work, that CoreXY system with a 500x500 bed (tho I'm moving 450x450 on it because of the rails) can reach 1000mm/s with 50m/s² accelerations (yep I'm cutting out that milli out, straight out meters per second square). At high voltages it does slam current into the motors quite hard. You DO need a powerful enough power supply to run their peak power tho.
Glad you found it useful!
The drive voltage has a direct impact on the maximum speed, though the torque is still limited by the motor construction (current limit). One of my good-to-have features for the next iteration of my servo controller is 48+V support!
Awesome video Bo, looking forward to see more content about motors & servos!
Thank you!
I also had countless issues with MKS servos, I think the uC code for the serial interface is broken, with step and direction you can use much higher speeds, but once you overshoot the error window the motor will actually slow down to 100rpm and never catch up. It's also not capable of NPN/PNP (i forget which one was broken), the schematic and documentation suggests that it'll work in either direction but the actual implementation doesn't work, all you get is a big self induced oscillation loop. Anyway for my project I ended up switching to delta AC servos, several orders of magnitude more money but man the performance is scary good 👀
I had some difficulties getting the serial interface to work at the start, but eventually polling for the position and error worked. I haven't tested the other serial commands though.
With my own servo implementation, it's also very possible to get oscillations if the control loop isn't tuned correctly.
How did you induce oscillations with the MKS implementation? I'm thinking it'll be fun to try and reproduce it.
@@engineerbo I was using a PLC's GPIO which are 24VDC sink or source, I believe when the servo is in sinking mode this saturates the input transistor arrangement, so all of the inputs get stuck on except when the direction signal is low, which causes the step to leak through to the direction channel and it goes nuts trying to run both ways at once.
I had a quick look at the schematics, the optocoupler part number doesn't seem to match what I find online. But besides that, it looks like the step/dir/en pins need to be push-pulled, or there'll be a leak through the resistors on the COM net, affecting high-Z inputs.
cool video, would love to hear more about how you designed your servo
Thank you! I'll see what I can do.
You should really make a video on that amazing servo of yours! Even though if you arent fully satisfied with it yet:D
I intend to!
Very impressive! I like your servo model very much! Btw, I have a facination for motors too, so I understand your devotion very well!
Thank you, fellow motor enthusiast!
🎶 Drive gear keep on turnin 🛞
Hope this board don't start burnin ❤️🔥
And we rollin 🛼, rollin 🎲
Rolling data ona test bed 🎺🎷🎹🥁
Is your BLDC servo board available for purchase? Something ive been looking for for a very long time. Great video and a subscriber earned. I look forward to more.
Thank you for subscribing!
The servo controller isn't quite ready for prime time. I made it mostly as a learning exercise, and there are still many improvements to be made, for example reducing the phase current measurement noise.
@@engineerboPerfect topic for a video showing how your design currently was created, current problems and how you are working through them.
I’d love to see how the closed loop compares to the open loop in terms of stall torque. I want to make a lathe with nema 17s that are gear reduced. I’m wondering if the closed loop can handle more force at say 0-300rpm than the open loop
That'll be very useful information indeed. I've been thinking of building a Prony brake setup which will allow me to create speed torque plots. I might do that for a future video. Thanks for the suggestion!
but why ? why messing with this DIY-style contraptions with bare pcb on the back when there is a lot of cheep industrial grade closed loop steppers with optical encoders.
@@vasyapupken I’m designing a machine with covers and a positive air pressure system to keep coolant/dust away from all of the components including the motors. I want to do OD/ID carbide grinding as well. A bare backed pcb motor wouldn’t be a liability really.
I’m curious can you point me to closed loop systems that can be purchased motor and driver for a similar price of around $26 shipped? I’d love to hear about your suggestions
Could you do a more in depth video on how you set up servos in Klipper? Im wanting to build a small voron printer with servos instead of steppers and you honestly seem like THE guy to make a video on it. There is surprising little info on servos with klipper right now.
I've set my servos to use step/dir mode, so they function just like stepper motors as far as Klipper is concerned.
this is cool where can i get your servo design BOM? is the nua size the same as nema17 only longer?
I have the BTT S42Bs on my printer, and got the S42C as an "upgrade" (board only had the motors already anyway), and the upgrade part was just plain terrible. The older ones worked quite reliably and solved my issues I had with lost steps in my lead screw based machine, the new ones stuttered ridiculously at different speeds. The old ones do have a bit of issues at the start and end of movements tho.
My bet on this is that since they do use PID to control the system, it might just be factory tuned badly, better on the B version than C ones, but still kinda off, then again I don't have the time now to test new PID values on the motors, hope I can get around this soon enough.
Yes it's quite possible it's a controller or tuning problem. It looks like it could be something like an integral anti-windup limit, but I don't think there was such a parameter even using the configuration software.
Very interesting. I often buy some small components on Aliexpress that I don't have a use for, but might use someday on a project.
Sounds familiar, I've a sizeable collection of components and spares accumulated over the years that has come in handy numerous times.
Hmm... I'm probably not telling you anything new with this, but steppers like higher supply voltages in order to get good RPMs out of them. When the replacement parts arrive for the MKS board; it would be interesting to see how much performance the closed-loop stepper picks up when powered closer to the drive's max rated voltage.
You're right, higher voltages usually the steppers can spin faster, since the top speed is when the motor's back EMF, which is proportional to angular velocity, cancels out the supply voltage.
It's definitely worth a test, but I'm not optimistic, considering the huge difference between the open-loop and closed-loop stepper speeds when both are running on 12 V.
Great video mate! I was tempted to buy some of these closed loop steppers. I'm glad I didnt!
Thank you! Glad you found the video useful!
I believe with the tmc2209 that it does not face such high current draw during holding torque/no movement situations depending upon settings. Doing UART control with an esp32 I've had it successfully vary in current/power draw between different parts of operation. Just a heads up. This is amazing though and I beyond appreciate such
Yes the TMC2299 can be configured to have different running and holding torques, and that's supported in Klipper too.
that self made servo is very juicy!!!!!If you would ever release it, open source or pay for schematics please post a video! you got my subscription!
Thank you!
Your servo design looks very interesting, I would love to learn more about it.
Closed loop stepper motors and hybrid stepper motors are often presented as good 'middle of the road' alternatives for people who don't want to mess with servo's. But as this video shows the gap can be quite large. I had no idea a closed loop stepper could be so slow, but I guess it makes sense as steppers aren't really designed for high speed/high torque applications. Adding the baggage of a closed loop system on top of that makes the whole motion system slow and unwieldy. I wonder if a hybrid stepper would do much better in a closed loop system. In the end well tuned (Field Oriented Control) servo's are really the golden standard.
Thank you! I'm planning a series on the design of the servo right now, is there any particular aspect of it you're interested in?
Given the open loop stepper is able to move much faster than the closed loop stepper, I'm inclined to believe that it's primarily a controller problem in this case.
@@engineerbo Mainly the electronics and the software. The calibration procedure you showed in this video is quite extensive. It looks like you put quite a bit of effort into the software side of the servo driver ☺
👌 Starting the series with the electronics/schematics probably makes sense.
You're quite right about the calibration procedure. Easily more than half the time went into implementing the self-commissioning algorithms!
I wish this was something that could be added to klipper, I think it could be very useful for finding max acc and speed with any given printer :D
I'd love to see this turned into a macro
I initially wanted to implement it as a Klipper macro since it's a little hacky to pipe gcode using the pseudo serial port, but implementing loops and conditions in Python is just so much simpler.
@@engineerbo With Klipper being C and KlipPy (Klippy) being Python, it's already halfway there. The critical parts, though, are still C. But if you can make a working Python implementation for closed loop, I'm sure there's C nerds out there that can help you get it into C/C++
I'm reasonably comfortable with C/C++, but haven't figured out how Klipper is structured. I enjoy using Klipper, and even tried to get it to control my pick and place machine (worked used macros, but poorly), but still never figured out how to write custom modules for it.
@@engineerbo What do you use to control your PNP? Would love to see servos on klipper
I'm currently using OpenPnP and Marlin.
I actually started off using Klipper with manual_stepper and many hacky macros, to limited success. Would have loved to have stayed with Klipper because it's so much easier to reconfigure.
If you're making a 3D printer, servos that support step/dir should work.
Very good testing and real comparison
You deserve so much more views and abos with your quality
Thank you very much!
Nice video i use the closeloop driver on my 3d printer and i also noticed some small issues but it gives a great result.
but i see now on the github they give parameter suggenstions. "disable MPlyer" and set "ACC to 412 or 538" i'm going to try that.
Nice, thanks for the tip. I'll try this out when I revisit the tests!
Link to the servo hardware setup?
Amazing video! Thank you! It would be great to see if the D version of the MKS controller also behaves the same way. Also, are you planning on making the BLDC servo controller open source? It seems like a great controller!
Thank you! The servo's still very much a prototype and a little outdated now. I'm planning to build a new version sometime.
There is software you can use, by connecting a computer the mks servo's serial port I believe.
You might find the RPM limit setting in there.
However the slow CPU might not be able to do full speed.
Yes I tried the application, it's called "MKS SERVO42C CONTROL V1.1". I used it to verify that the serial communications were working when I had problems polling the position/error from Python. There are a few extra settings compared to the OLED menu e.g. PID parameters, but I don't think there's a speed limit setting.
greatly appreciate seeing this video :-)
Thank you!
great video. Your testing setup is amazing and I found the video very interesting to watch
since I am working on open loop steppermotors right now myself:)
Thank you! Glad you enjoyed the video!
id love to see a test with the newer mks servo 42d closed loop stepper
I'm working on new testing methods, I'll eventually come back to closed-loop servos and test a bunch of them!
Really awesome to see. I come from the 3d printer world so seeing this type of stuff is fascinating to me!
Thank you!
No! thank you@@engineerbo
!Great!, Glad I checked this before switching my ratrig.
Can you do a MKS SERVO42D vs SERVO57D vs SERVO42C comparison?
I can't seem to find anything.
Thank you! I might have a look at the 42D to see if they've improved things.
@@engineerbo Looking forward to is and also wonder how these compare to the AS5600.
I would've loved to see a comparison where you use a higher voltage. Like 24v and 48v for especially the stepper motors, since this helps tremendously with speed and torque. However, I do believe the TMC2209 has a max rating of 36v.
Yep, I ran some tests at 24V until the SKR V1.4 blew up. I've fixed the board now, and also gotten a new power supply that can handle 48V, so I'll run some new tests soon!
@@engineerbo Cool! Very curious to see the new results :) Have fun testing :)
Excellent comparison, thankyou
Thank you for watching!
Hello, I'm building a delta and I'm not sure whether to use Nema 23 or a Brushells motor, which one do you recommend because I want greater speed on the printer?
Your servo looks neat, I'd be interested in knowing more about it!
Thank you! I'll be making videos about servo's design, so check back in a bit!
The servo overshoot can be eliminated with proper tuning, no?
Setting the dammping ratio to 1 and back calculating the gains?
Yes the overshoot is a tuning issue. I've been tuning the loops by hand though, so in this case it just wasn't done well enough.
We tried to use them in a robot. Nice, but fragile as anything. Output stage blows up on ESD, backdriving etc
Interesting, maybe the devices have low maximum rated voltages. I've blown my fair share of servo prototypes too!
Please release the BLDC code. I would love to play with that.
Seems to me that if youre attempting to fix layer shift, its easier and more effective to go to a longer stepper motor. I went from 40mm long to 80mm long. .32nm of torque to 1.09nm and bumped the run current to 1a and installed 40x10 fan to help cool the drives. Throws the bed around just fine now without layer shifts @ 2x the accel (4k was max on stock, now i print @ 8k with 14k travels)
I was just curious about the performance of a cheap closed-loop stepper. But I agree, it's probably not a good first choice for fixing layer shift problems.
How do they compare in price? UA-cam algorithm send me here. I am a Software engineer for embedded Devices and i would like to see your sourcecode and schematic for my diy cnc. You mentionet bigger ones as well, i would like to see avideo about those as well
The closed-loop stepper motor was surprisingly affordable, and only cost a slight bit more than a generic open-loop stepper and a TMC2209 driver. The difficulty with price comparison in this case is the servo, which I hand built in tiny quantities.
1:32 I've tried to search about your DIY C4260 servo design project and PnP project which uses the C4260 BLDC in your channel but I've not found them.
Do you have the videos for those?
Hello, I haven't gotten around to making videos about these older projects, but it's in my to-do list to build a new iteration of the servo and make a video about it.
@@engineerbo I will wait for your those videos.
BTW: I've seen your videos "MKS SERVO42C Closed-Loop Stepper: Tests vs Servo with Field-Oriented Control and TMC2209 Open-Loop" and "Finding the Best NEMA17 Stepper Motor: LDO Motors, STEPPERONLINE and more tested with a dynamometer". They are very impressive. You have high engineering skill, good technic and very well presentation.
I appreciate for your videos and how you tested and mesaured all thoses staff. Thank you.
Since the odrive went closed source, the only open source servo system I've found is the mjbots / moteus
I'd be interested to see how the design / firmware compares
Ah yes the recent odrives are no longer open. It's a shame, but understandable given the numerous clones.
I've seen the moteus controllers, and they use much more recent components than mine (e.g. newer microcontroller, newer gate driver). I designed my servo hardware several years ago, so the hardware is more similar to the original odrives.
The firmware's really where there'll be major differences. I've written my algorithms in a more academic way, forcing myself to follow the math and not to use hacks. This probably has a performance cost.
I'll make a series on the design of the servo in due time, subscribe if you're interested!
Hi! excellent work on the comparison, i have a question on the MKS SERVO42C, is it possible to have a torque variation depending on the severity of error i introduce? (for example i introduce 10° angle error -> torque 30% of maximun, then the error gets to 20° angle -> torque increments at 60% of maximun). I've been tryng to create a 3 DOF imput system like the old Novint Falcon for personal use and i was curious if these little boards are up to the task without going to BLDC motors where i have little experience.
That sounds like a proportional controller, but are you sure that's the behaviour you want?
The SERVO42C's PID controller can be configured using the provided software they named "MKS SERVO42C CONTROL V1.1", but I don't know what the control scheme is exactly, and it's unlikely it'll give you exactly what you described.
@@engineerbo thank you for the advice, i'll try and research a more suitable controller
Is the closed loop stepper motor have saturated input control signals, it should be that slow ...
Are you referring to the step/dir signals from the motion controller? The setpoint plot seems to show the steps being counted properly, and on re-homing, the closed-loop stepper didn't lose any steps.
beautiful work on servos for 3D printers, I've been wanting to implement them on mine printer for a while but I can't find much info about them, I think they have numerous points in favor compared to an open loop system with stepper motor... which board do you use to manage the servos? Thanks a lot
I'm definitely signing up, I'm really curious about any news on servomotors in this environment
Thank you! The servo here is controlled by the SKR V1.4 board using the step/dir interface.
Excellent video
Thank you!
I'd love to see a video about your Custom Designed Servo design.
Thanks! I'll work on a deep dive series in the near future.
this video is so well done. thank you!
Thank you, I'm glad you liked it!
Interesting video, but how's your anti-cogging or compensation steps, could shed some light or point to some reference? Thanks!
The theory is explained in "Anticogging: Torque Ripple Suppression, Modeling, and Parameter Selection" by Piccoli et. al.
In summary, the servo driver positions the rotor at various (many) positions during calibration, and measures the current required to hold the rotor position. The holding current is indicative of the cogging torque. The current values are then stored in a look-up table and are used with the motion controller as feedforward terms.
First of all, congrats on the video, it's really good and technical!
I would like to know more about your test setup, i want to make some tests in different models of stepper and your setup can help me a lot, can we talk about how you make it, components, etc?
Thank you! The mechanical components of the test setup are either common off-the-shelf parts like GT2 pulleys, idlers, belts, or designed for the purposes of this test and 3D printed.
I didn't talk about the accelerometer in the video, but it's an 3-axis analog output device (ADXL335). It's only rated to 3G per axis, so I mounted it 45 degrees to combine X and Y for ~4.2G range.
Whow! Neither here nor in you profile is any hint about that DIY servo. This looks groundbreaking to me. Could this be a DIY Servo?
Yes it's a DIY servo! It's a pretty involved project, but nothing groundbreaking.
Great PCB design for your own servo driver. May I know what thermal camera you're using? The thermal footage looks clear.
Thank you! The thermal camera is actually a phone called DOOGEE V20 Pro. It's not the best, but it's pretty decent for its price.
Very nice video! I see in your comments that you did not post any files, but would it be possible to show how you connected the servo to the MCU? And did you make your own board or is it a pomade one? Thanks
Thank you! The servo is completely custom made. It's connected to the SKR V1.4 using the step/dir interface like the other two motors, using a custom adapter board that plugs into where the stepper driver goes.
really liked this video! thanks i would love to try and make a servo motor like you did.
Thank you! Designing a servo is a fun rabbit hole of a project!
how about the other options?
HBS57 with closed-loop nema17
and the usual iHSV servos like iHSS42-24-05
bought a mks servo long time ago when it was all the hype but in the end never used it, way too slow and unreliable.
went with hbs57 driven nema23 closed loop steppers instead for my project that required the necessary beef.
It'll be pretty fun to test a whole bunch of different options, I just need to find an excuse to buy them!
OMG, so many valuable details! I would review it again and again!
Glad you enjoyed the video!
Cool and informative Video, thanks! I am looking for a motor to use in a robot arm project right now, is there any documentation or production files available for you custom servo and the corresponding PCB?
Thank you! I haven't published any details about the servo, since I've been treating it like an exercise and changing things all the time.
In the meantime SERVO42D got released with up to 3000rpm. i would be very interested in a retest.
I'll look into it!
Can you post your Klipper config for the motor when using closed loop? I was under impression that Klipper does not support closed loop.
The closed-loop is only within the motor control system. The position error etc aren't fed back to Klipper because like you said, Klipper doesn't support it.
Interesting video, thank you. I’d like to see the closed loop stepper retested at 24v - 12v is half of the ideal voltage for most Nema 17 steppers.
Thank you! I've had some comments suggesting the same thing. I have my doubts that it'll make a difference, but I'll revisit it in due time.
@@engineerbo I’ve built a few 3D printers and a CNC machine with Nema 17’s, you get a lot more torque and acceleration when the drivers get 24v to play with.
Yes a higher voltage allows a higher drive current and higher speed (I talk about this in my video on regenerative braking). But I'm guessing the servo42c's being limited by something else like the microcontroller or the firmware, so it wouldn't be able to take advantage of the higher voltage.
@@engineerbo that is a good point - the tmc2209 should have a way to configure the max current for the stepper. The LDO motors I use are good for up to 2.5A. So I typically run them @ ~1.77 A RMS (2.5x0.707) for longevity, or full beans for max performance (they get fairly hot then).
For the TMC2209 tests in this video, I've actually set the RMS current to 2A, which is the max. rated current this driver board supports. That's probably how it gets so hot so fast.
I've seen LDO motors mentioned a lot, particularly their speedy power and super power motors. The super power motor's speed-torque curves look interesting, so I've been sourcing some for testing!
great work .I am usnig 5 of these Servo42c on my pnp Machine. What is the firmware vesrion for Servo42c V1.1 or V1.0? Also can you check with MPlayer setting disabled once and see if that improves the performance. I have seen emi issue with these where they stall and start oscilating on one place pretty scary :). Also please share some videos on the PnP machine would love to see the machine in action :P .I hear lot of issues with the smoothieboard clones especially the SKR V1.4 where 24V can mess up the board, I have a MKS Sbase V1.3 with its one set of issues but i am running things on 12V and can power the servo with 24v in future if required
The firmware version's V1.1.2, and the MPlyer is enabled (by default). As far as I can tell, this seems like additional internal microstepping, so it's quite possible that could affect the performance.
I took a look at the schematics for the SKR V1.4 after I blew mine up, and found that the DC-DC converter is rated to 28.5V, so the regenerative braking spike probably exceeded that. It's probably a good idea to run the SKR V1.4 on separate power rail to be extra safe.
Do you have any details posted anywhere on your custom pick and place?
Not yet! I recently decided to make videos so I'd be more diligent with documenting my projects. The pick and place machine is in the queue to be featured, hopefully soon.
Id love to see how the new 42d fairs in comparison.
Given how the 42C performed, I'm a little hesitant to purchase the 42D. I might still do it purely for testing purposes if there's sufficient interest.
@@engineerbo i got just the pcb for it on order. Apparently the newer revisions should be fine even above 3000 rpm, but we'll see once it gets here.
nice work, those graphs bottom screen are from the pico right? they are live plotted with python?
Yes the acceleration data is coming from the pico, but the position/error information comes from the servo or closed-loop stepper, and they're all plotted live using matplotlib in Python.
Hey No I'de love to see some tests against cln17 v2 drivers. Not sure if anyone would send you one for testing as you can't buy them yet, they need to be self made from PCB fan. Check it out if you have time.
Thanks for the tip! I've added it to my list for when I revisit closed-loop steppers.
@@engineerbo thanks a bunch! Next month they are releasing designs for larger stepper motors too it should be good.
Will you share your servo plans ever?
I'll certainly make videos on the servo, which should include details about the schematics and firmware like in my other videos.
A great test, I'd love to know if there's something in the configuration of the closed loop motor which could fix the linearity problems because even with the speed issues it would be a good alternative.
Thank you! I agree there are applications for the closed-loop stepper even with the low speed. What linearity problems are you referring to?
@@engineerbo the inconsistent velocity you reported as it ran along the rail.
Oh yes the wobbly velocity. It's possible it's a PID tuning problem, could be worth investigating.
Thanks for this test. Would you be willing to post your design for your custom servo motor? How easy is it to add those servos to a klipper 3D printer?
I'm not sure I'll publish them quite like a few other motor controller projects, but I'm planning on doing a deep dive video series on it, since there seems to be sufficient interest.
The servos in this test are configured to use the step/dir interface, so Klipper doesn't even know it's not a stepper motor.
would love to see a vid on your cutom servo!
Thanks for the suggestion! It might take a series of videos to cover the whole design. Is there some aspect of the servo you're particularly interested in?
Great video! do you draw your live plots in python? what library? Or what do you use?
Thank you! Yes the live plots are using Python, specifically matplotlib. I use daemon threads for the serial interface, and multiprocessing for the actual live matplotlib animation.
Nice video! Would you make one about your pick and place machine? Thanks in advance.
Thanks for the suggestion! Building the pick and place was an fun project, so I'll definitely make a video on it some time.
hey did he mention he has a fasination with motors
The open-loop stepper performance is largely a function of the driver! From the motor, looking back into the driver (specifically the resistance seen) will affect top-speed, ringing and stability.
The driver definitely has a major impact on the performance. I can imagine resistance and wire inductance can have an impact, but I wonder how significant it is for reasonable cable lengths.
I have used the servo 42c's on my 3d printer and it does not give my input shaper higher than 8k acceleration's. Using a LDO Speedy power gave more than double the accelerations.
I've been hearing a lot about LDO motors, I'll have to get some for testing!
That servo looks extremely interesting. I would love to build a high speed 3D printer with it.
Have you found any weird behaviours from using a servo vs traditional open loop stepper? From the vid it looks like your servo just out performs everything with no downsides
There are some tradeoffs to using the servo, for example the controller needs to be properly tuned, and in the current design there's still significant servo noise. The servo's low speed and stall torque is also lower than a stepper, so it wouldn't be as good with holding position or slow moves under load.
nice video bro, which controller have you used for the bldc servo?
Thanks! The servo controller is a fully custom design.
Did you make the t slot mounts for the motors/ pulley? Awesome design
Yes I did, thank you!
@@engineerbo would you be willing to share? I just started designing something similar after seeing your video
Sure, I can send you a STEP file of the design for reference. Please note it's not exactly a perfect design!
@@engineerbo that would be great! How can i reach out
Send me an email, you can find the email address in the channel info.
Great video, thanks. Do you plan to make your Servo controller available?
Thank you! I've no plans to sell the servos. My intention is to make a video series about its design, if there's sufficient interest.
@@engineerbo thanks for the reply. I meant actually to make it available as an open source design. I saw an open source design for a nema 17 closed loop controller. I was hoping you would share your controller design also available.
Thanks
I'm open to sharing the designs in some form or another. At this point, I'm leaning towards doing it in video form, so these (incomplete and imperfect) designs are accompanied with commentary and explanations.
I tested serve42c vs standard stepped with TMC. I think: serv42c is stronger, and quickly than standard stepper. I don't really understand why the video shows that servo42 is slower. (setup is siliminar: microstep 16)
Did you change any of the servo42c settings? I left everything on default which might not have been the ideal configuration.
@@engineerbo Hi, all settings is default. But, i enable serial connection with 38kbaud.
That's interesting, I don't think the serial connection would have changed anything though. How did you compare the performance between the servo42c and the normal stepper?
How are you measuring how far it travelled? How to you know its not skipping steps?
The script checks if the number of steps to the destination and back (home) are the same. If it took fewer steps to home (compared to the fast move) then steps were skipped.
Great video!! I'm starting on servos and motors and an another great video could be differences about NEMA, digital servos and others. I noticed that you didn't mentioned torque, it's possible that a nema17 or 24 have more torque than a 30kg digital servo? Thank you!
I actually did mention torque, specifically the speed-torque curves. But since the tests are with a linear system, whenever I say acceleration, it's really equivalent to torque.
When you say 30kg digital servo, do you mean a hobby servo with gear reduction? The easiest way to tell is if these systems come with the speed-torque curves, so you'd have a direct comparison of the torque at the speed you need for your application.
@@engineerbo I'm sorry, i rewached the video and saw the post about the speed-torque curves and the more i'm reading it the less i understand :rofl: I'm no engi so in your opinion for a project with a really low rpm but really high torque requirement what is better to use, i have a 30kg hobby digital servo (with the gear reduction, yes) i might need to add a gearbox if needed XD
Hobby servos are pretty different compared to either a servo or stepper, so it really depends on your specific application. Steppers and servos can also have gearboxes which gives you even more options.
My experience with hobby servos is that they aren't usually great for highly precise positioning, and are usually noisy because of the tiny gears.
They usually also use potentiometers for feedback, so precision and resolution aren't their strong suits.
@@engineerbo This project also doesn't have to have precission, just enough torque and be 360º Thank you for all the info!!
There are also affordable steppers with built-in gearboxes that would have more torque than hobby servos. Essentially, a hobby servo is unlikely to be a top performer if torque is the only concern.
Of course, there are still benefits to the hobby servo, like availability, cost and ease-of-use.
Hi! what is the c3548 controller board order link?
Hello, the C3548 is just the brushless motor, the control board is custom made by me, and isn't for sale.
If you want to buy the motor though, I've added a link in the description to the one I bought, which is the 790KV model.
@@engineerbo Thank you, please share the BLDC motor controller design and program (if possible). I want to try it.
Hmm. The main problem I found with both closed loop steppers like the MKS and the BLDC servo's is that they lag behind on the real motion, because they use the encoder to "fix" their positional mistake. That means that there's no "precision coordinated motion" anymore; you tell is where to go and it will just eventually get there.. tell it to go some place else, and it will go there instead. If your motor can keep up that's not a problem; if it lags behind (for example because there's load involved) it's a huge issue. For open loop systems, you have no guarantee either, but at least it's coordinated - because you need to tune it at a certain max speed and acceleration (torque).
So it comes to me like no surprise that you get these results for the bldc servo: the test is just flawed. What you want to use here is a glass scale to measure where the thing *actually goes* which is different from where you *want it to go*.
I agree partially, I mentioned the caveat in the video as well. Neither open-loop nor closed-loop systems shown can make any guarantees on the position error.
Both systems necessarily lag behind on the commanded position. The stepper doesn't teleport after you command a step. Within reason, both systems can achieve coordinated motion. This shouldn't be a surprise since it's not uncommon for high precision industrial machines to use servos.
Perhaps you're suggesting hobby-grade controllers don't meet the positional control bandwidth you're expecting?
@@engineerbo Actually, open loop keeps coordinated when you use the same drivers for all axis (which is common). Especially the good drivers tend to have guarantees about times. No, they don't teleport, they continue due to inertia and the firmware makes assumptions about accelerations. I know I tinkered with that in our firmware anyways...
Industrial servo's is another thing... basically they tune them so that the torque under load is more than the requirement, and use PID to compensate for a target setpoint. They can only guarantee that when you follow the manual to the letter, which basically implies the set point will be reachable before the next one is set... These AC Servo's are also usually not made with low end BLDC's, they are not running on SimpleFOC, have a differential optical encoder and so forth... Very importantly: they use set points with acceleration profiles, which a PID loop attempts to meet.
Closed loop steppers also use set points, and loose torque when they are not powered (of course). The closed loop fixes the position to the set point. The main difference is the number of poles.
If you change the set point before the target, the set point will change, even though you will still reach the second set point.
Anyways, I try to explain here that there's a key difference between using set points and (traditional) stepping because of the distance, time and acceleration profiles involved here... but perhaps it's just too hard to explain in just a few paragraphs.
Servo control loops and tuning are certainly non-trivial topics. Perhaps at some point I'll make a video to compare coordinated movements between steppers and servos. Thank you for the comments!
My experience with the Servo42b is that it is relatively slow .. so I don't expect the 42c to be much better and I'll probably also go with a homebrew stepper rather than BLDC (since I need a little bit torque and the smallest possible design)
The makerbase docs specify the servo42b to have a max speed of 600 RPM, compared to the servo42c which is listed as 1000 RPM. This is actually one of the upgrades featured in their comparison table!
@@engineerbo how about the acceleration? I use the Servo42b on a pick and place machine for the Z axis certainly I can command rotate to a certain angle and then start commanding rotate back --- but then the servo won't reach the actual target/requested setpoint.
The 42b is a bottleneck for me, I'd just add a beefy stm32f4 and implement the controller there accordingly. For my setup speed is very important.
Let's say I pick/place 10.000 components that results in an overhead of over one hour just with a 0.5 sec delay per pick.
but yes as you mentioned the 42c might be different but I don't want to spend my time with that and rather dig into implementing it myself.
If the servo42b isn't going to the commanded position i.e. skipping steps, then it's quite likely a different problem. Mine hasn't skipped a step, it just doesn't move the way it's supposed to.
@@engineerbo no it's not skipping it's just counting it up and back.
1 - 100 - 200 - 100 - 1 but if you start to decrease too early it might not go to 200. That's just my observation because I need to add some delay before retracting (then the components will stick on the machine).
Oh alright I see what you mean. In my tests I intentionally put a 200ms dwell so it doesn't start reversing immediately. Without the dwell, I expect the servo42c wouldn't get to the destination either.
where you micro-stepping the steppers?
Yes, all of them were using 3200 steps per revolution (16 microsteps).
i have problems with my nema 17 stepper motors - they run reallly SLOOOOOW could you help me out with picking electronics and - drivers for them to - be able to speed them up ? I am using arduino mega board for my cnc ... but it works just bad
It's quite a project to be building a CNC. As much as I'd like to help, I'm probably not the best person to recommend products (especially if I've not tested them myself).
The MKS stepper surprised, in the wrong way. I have seen people use it for 3d printers, where they seem to be pretty fast, can it be because they run them at higher voltage?
Also, have you seen the Makerbase BLDC motor and TLE5012 encoders? It seems to be similar to the one you made.
It's possible the voltage might make a difference, yet the 12V performance is so much poorer than the open-loop stepper, it seems unlikely. It's still worth a try after I've fixed my SKR V1.4 board. It could also be a configuration problem e.g. the 256 internal microstepping.
I haven't really paid too much attention to the other BLDC servos, but yes my component choices are somewhat similar to a couple other designs e.g. using the ultra popular DRV830x series.
If you try changing the microstepping or higher voltage on the closed loop stepper, please share. Its so interesting. Thanks for making such a nice video, Im subbed now@@engineerbo
Thank you for the sub!
Excellent video!
Thank you!
Instructive, great work!
Glad you enjoyed it!
Looking forward to seeing your servo design being used in an actual machine like a 3D printer or mill!
I put it in my pick and place machine, but that doesn't need perfect coordinated motion since it's point-to-point only. Still manages to pick and place 0402 components reasonably well.
@@engineerbo I'm no engineer (yet), but being able to manage 0402 components sounds like the repeatability of the motor is really good
It's pretty decent, honestly could have been better if I went for a more conventional motion configuration instead of core XY!
Is a servo basically a closed loop motor of any kind (stepper, bldc, dc)?
I'm not certain if there's a strict definition. As long as the motor has closed-loop positional control, it could technically be called a servo.
It's still useful to distinguish systems based on motor type (e.g. steppers) because there can be significant performance differences (see speed torque curves).
if you interested in closed loop steppers then try some ihss42 one.
A couple of viewers have mentioned this, I might have a look! Thank you!
Is the test code at 4:30 available?
Hello, I've just made the repo public. You can find the link in the video description.