Autoleveling on 3D printers: 9 myths and 12 sensors tested!

Autoleveling on 3D printers: 9 myths and 12 sensors tested!

Twelve options to sense the surface of a 3D
printer’s bed. Twelve solutions to the same problem. Twelve sensors that are all different.
But there can only be one! Well, actually, each one of these has an upside, so let’s
see what they can and can’t do. Myth busting 3D-printer style!
Essentially these should all do the same thing: When using autoleveling on a 3D printer or
even on other machines that need their tool to be at a perfect distance from a workpiece,
like a PCB router, these sensors probe a few different points on the surface and then compensate
for any misalignment of the bed or workpiece. Since the sensor itself is the only input
the machine gets about how the surface is aligned or deformed, it’s kinda critical
that it senses stuff reliably and can even detect your surface. The easiest option are
inductive sensors, but those only detect metals and are useless for glass, then you’ve got
optical ones, which can detect any surface as long as it’s not totally transparent,
mechanical ones that physically extend to the surface and touch it, and lastly capacitive
sensors that will detect every surface and then some. To test their repeatability, I
built this assembly that should provide a near-perfect linear motion for testing the
sensors. Essentially, it’s an IGUS W rail, which as a sliding mate, should have a better
repeatablity than ball bearings, and the backlash these typically have doesn’t matter much
since gravitiy is essentially pre-tensioning things here, then we’ve got another IGUS
part, a 2mm pitch trapezoid spindle attached to a 0.9° stepper motor the two shafts here
are touching inside the coupling, so we’re not getting any springiness. Again, to take
care of any tipping effects on the rail, it’s mounted off-center. The entire thing is driven
with an MKS Gen board that was literally sitting in the “scraps” bin, and a few lines of
Arduino code. And yes, you can still run standard Arduino code by itself on any 3D printer board
that would otherwise run the Marlin firmware or similar. All it does is to run the sensor
into the surface, backs up by a bit and then does that again 41 more times. In the end,
it reports the standard deviation of all measurements, which essentially tells us what sort of precision
we can expect from each sensor. To check that this construction even worked as intended,
I mounted a steel rod to the carriage and let it close a circuit as it touched the aluminum
block, and that came in with a repeatability much better than one micron, and basically,
it was never further off than a single microstep. Yes, the microstepping might not be perfect,
but it’s still an indicator that this apparatus works pretty well for these measurements.
So the units I’ve got lined up here are four different industrial inductive sensors,
the smaller 2mm trigger distance, 5V type, a 4 and 8mm type and the Prusa PINDA probe,
and yes, Prusa definitely has the smallest and shortest one of them all. Also in the
category of inductive sensors is the one from the BQ Hephestos 2, but that one turned out
to be defective, so I couldn’t include it. The capacitive ones are also industrial types,
with 8 and 20mm sensing distances, this huge guy was actually pretty expensive in comparison
at around 8 bucks, and even worse, it also didn’t work. Bummer. Mechanical probes are
the BLTouch and a standard microswitch with and without the lever, the BLTouch retracts
on its own, while a switch like this will need some sort of servo to lift it up, which
will introduce inaccuracies on top of what the sensor itself can do. And lastly, the
optical sensors are David Crocker’s infrared probe I got from Think3DPrint3D and a Sharp
sensor that outputs an analog voltage according to how far away it senses an object, which
is really cool, but needs a comparator to generate that on/off signal the board requires.
So that’s how we’re going to do it, let’s get to mythbusting! #1 Optical Sensors can sense plain glass.
That’s actually one that’s a bit more complex than it might look like at first sight.
Glass is transparent, obviously, at least to the naked eye. But because these sensors
work with infrared light, what they see could be completely different to what we see. These
sensors work based on reflected light, so having a surface that is glossy like this
could throw them off as well. Now, the simple answer is yes, both the optical sensors can
detect that sheet of glass. David Crocker’s sensor easily detects the glass, but the Sharp
sensor gets thrown off track quite a bit. First off all, it requires a much larger distance
to trigger at all, and even then it started drifting and eventually smashed into the glass.
The custom sensor did trigger reliably against glass, but still came with a huge penalty
in precision: The readings onto glass had a tolerance fifteen times as large as the
ones onto an opaque block. So while it works, it’s not something that is really advisable. #2 You can just run a standard 6 to 36V probe
from 5V Ok, this one is actually easy to test. Out
of all the 6 to 36V probes, none worked on 5V except the 8mm capacitive one. And even
then, it was much less sensitive than on 12V and only triggered against metal parts, while
with the higher supply voltage and a voltage divider on the output, it reliably also triggered
against printed parts and had a larger trigger distance than on 5V.
So that one is busted. #3 Capacitive probes are unreliable
So the theory with capacitive probes is that they sense pretty much anything – Plastic,
glass, wood, metal, humans, etc. The problem is, things like moisture in the air also influence
the readings – in theory. So as a really simple test, I let the system do 21 measurements
and then just started breathing over the sensor. And oh boy, did that throw it off. Almost
instantly, it started triggering about 200µm earlier – that’s 0.2mm, so basically a full
layer height off target. So even if you had a less extreme humidity change, it would still
throw the sensor off by a significant amount. I also did the same with the inductive sensors
and while they did show a marginal change, it was always in the single-digit micron range,
which might as well have been from thermal expansion. Speaking of the topic, the capacitive
sensor also showed, by far, the greatest deviation when blasted with a hairdryer on low.
So are capacitive sensor unreliable and unprecise? Well, if you look at the base reading in a
consistent environment, they aren’t that bad, but as soon as anything changes, you
will run into issues. #4 Probing slower gets you better readings
There are a few things that go into this – first off, some sensors, like the Sharp optical
one only take a reading a few times per second, so by the time they trigger, you might already
be past the point that would be the perfect spot. The same thing might be true for the
printer’s firmware, which only reads values every now and then. The code I’m using is
checking the sensor after every microstep, so that shouldn’t be an issue. But still,
sensor delay etc still are. So every sensor was tested at two different speeds – 1.35mm/s
and twice as fast, so 2.7mm/s, which is about the range you would expect a normal Z-axis
to move at. And basically every single sensor was less precise when run at the faster speed.
They all showed about 20% better repeatiability at the slower speed, some a bit less, some
a bit more, so while that’s not going turn a great sensor into an unusable one, or vice-versa,
it’s still a considerable improvement if you just need that extra bit of precision. #5 Sensors drift with heat
So you might have noticed the effect that when you run the autoleveling cycle with the
bed cold, the nozzle height will end up slightly different than when probed hot. And this is
very real effect, but after testing all the relevant sensors, I’m not quite sure that
the sensors themselves are actually the problem there. It looks like the larger the trigger
distance is, the larger the temperature drift is going to be.The inductive and optical ones
were all decent, maybe not the 8mm inductive one, but the others are all at least usable
when heated up. Though what also played into this was the apparatus simply heated and expanded,
too, so the measured trigger point unavoidably moved back, too. What could also play into
this is that at higher temperatures, copper and aluminum are less conductive, so for the
sensor, it’s as if there was a thinner sheet of material, which shortens the trigger distance. #6 Just use aluminum tape for inductive sensors
So the myth is that if you want the advantages of an inductive sensor, you can simply use
some aluminum tape, even on the bottom of a glass sheet and the sensor will still trigger.
So I used some standard aluminum tape, and the 4 and 8mm inductive sensors do trigger
against just the roll of material, but none of the inductive sensors actually triggered
against a layer of tape, even on the top surface of a glass sheet. So while multiple layers
might work, they are going to add some thickness, and even then, you’re only going to get
a fraction of the nominal trigger distance. And that leads us into #7 Larger trigger distance
sensors are less precise While none of the industrial sensors are actually
made to detect a set distance precisely each time, they can still be incredibly good at
it. For the inductive sensors, I had 2, 4 and 8mm types, and they all performed virtually
identical. They all achieved sub-micron repeatibilities, except for the 5V, 2mm type, and even that
one was better than 2µm. So that’s busted. #8 Inductive sensors trigger much closer when
sensing aluminum Before I try and explain why this is the case
and end up with half the viewers and getting bored and the other half getting ready to
roast me, let’s just stick to the facts: Yes, inductive sensors do lose quite a bit
of their trigger distance, even against a solid block of aluminum. The distance the
sensor says is against iron or steel, and with aluminum, you get about half of that.
Capacitive sensors aren’t affected by this. and last, #9 Anything sensor with a standard
deviation better than 50µ is probably good enough
And this one is from the BLTouch kickstarter campaign – the sensor measured in with a standard
deviation of about 2.5µ. Let’s take a step back and look at what the standard deviation
means. Say you have a bunch of measurements and you plot out how many of them are how
far off. Typically, noisy sensors like show a normal distribution, which looks like this.
All the standard deviation says is that about ⅔ of the measurements are better than that
standard deviation range. So with a bed leveling approach that uses just three points, on average,
two of them will be measured more precisely than the standard deviation, and one of them
will be worse. In turn, this point then, again, has about a ⅔ chance of falling within the
range of two standard deviations, which means that, statistically, every three prints, that
50µ sensor is going to have be off by more than + – 100µ or 0.1mm. And if you’ve ever
played around and experienced the difference 100µ can make to the first layer of a print,
you’ll probably agree that that’s too much.
Now, of course, a more precise sensor can still have those measurements that are far
off, but it’s much less likely to happen. So if you look at the measured standard deviations
of the sensors I’ve tested, i’d say they are all very usable, maybe with the exception
of the SHARP optical sensor and the capacitive one, everything else is, like, really good.
Out of those, the BLTouch performed the worst, but if you take it a bit slower, it’s still
way more than good enough. So yeah, that’s the story behind all the
different sensor options. What surprised me was how precise the inductive sensors turned
out to be, I was expecting them to be much noisier. What I’d also like to retest is
the Sharp sensor, this one is the analog type, but they are also making ones just trigger
at a set distance, and I think that might make it a bit less noisy. This video is sponsored by Aleph Objects,
Inc., a Free Software, Libre Innovation, and Open Source Hardware company headquartered
in Loveland, Colorado, USA and makers of LulzBot desktop 3D printers.
Watch my reviews of both LulzBot 3D printers here and check the links in video description
for more info on the machines straight from Aleph Objects. So I if this video so if this video was helpful
to you, give it a thumbs up, if not, leave a comment on what I can improve. Also consider
subscribing to the channel, and click that bell or YouTube might not show you updates
as new videos come out and livestreams go live.
If you’re going to be shopping on Amazon or other shops, check out the affiliate links
from the video description or head over to Patreon to support the channel directly and
get access to monthly Q&A hangouts and more. And that’s it for today, thanks for watching,
and I’ll see you in the next one.

100 thoughts on “Autoleveling on 3D printers: 9 myths and 12 sensors tested!

  1. I am looking for someone who has a custom configuration.h file that they are already using, and configured for the BLTouch Sensor, and SKYNET3D that they could put a link in for dropbox or somewhere for my CooCheer 3d Printer. The file needs to be configured for an Anet board with LCD 12864 graphic display. Print Bed Size configuration is W 220 L 270 H 230 mm. If someone would put a link in a reply, I would appreciate it. I'm sure there are other people who could use the file also.

  2. If you ever re-run this test I'd love to see the piezo sensors be included. I'm about to give one a try myself but curious to see your experience vs mine/others

  3. Hello. Where can we read the results please? I am very interested by mecanical switch results (with and without lever)
    As I understand, at 7:24; mecanical without lever is more precise than BLTouch ? cool!!

  4. So which one was the winner?? I need decent bed leveling desperately, I just can't get a truly flat surface on my CR-10, even after trying multiple mirror tiles.

  5. Lots of great information which in the end was overwhelmingly confusing. Your scripted, rapid fire delivery, in the end just left me confused and without a clear direction as to which sensor I should use. There was no wrap up or recommendation as to which sensor was the best one to use. It seems that you were trying to keep the video as short as possible rather than delivering useable information. I just want a good sensor at a descent price and I still don't know which one to use.

  6. Technically speaking the whole process shouldn't even be called "auto levelling" as the printer doesn't make anything more level after probing. It just compensated with stepper motor movements for the uneven bed.

  7. I never thought about using such sensors for measuring the bed level. At work I use mostly inductive ones but just for checking if there is an object or not. When I saw your video about the Prusa i3MK3 and its autoleveling I had doubts about the precision, but your video here has told me better. Thank you.

  8. Assuming the data collected is accurate, in order to make probe comparisons, large tolerances must be added to inductive probes that include the build plate tolerance stack for non-conductive top sheets (adhesive, PEI, etc…) . Also the BL Touch is intended to operate vertically, more friction is introduced horizontally. Once all this is considered and included, the BL Touch will compare MUCH better, if not the best. Also, if tossing on a thick G10 build plate for printing Nylon … only the BL Touch or a micro switch can accommodate that, without having to change the probe z offset value.

  9. hy all, i have a bltouch on ramps 1.4, i have a isue that the right side of the bed is always lower as the left side, any explication?

  10. Any chances of doing a review of Piezo-electric sensors? Been reading up on them, but most of the hype I've found seems to come from people who work for the company selling commercial versions, so getting third-party reviews would be interesting.

  11. Almost 2 years later now and I still adore my BLTouch. Even if it statistically or scientifically isn't the most accurate out there, as you say, it's 'more than good enough'. It's so rare to have a calibration fail.

  12. Here's a question, with the inductive sensor, does the voltage range matter? ie does the sensor (say, a 6-36v sensor) work the same at 6v, as it does at 36v?

  13. Hmm, as detailed your video was, and I consider myself as a reasonably intelligent bloke, I still haven't determined which sensor is the best. Apart from the two that were obviosly way out on the last chart you showed, all the rest performed similarly. So, be brave, which one would YOU choose to use regularly?

  14. I got a 8mm "orange" inductive sensor. It detects from 5mm away at 5V, perfect for my mirror covered bed. Too bad I have deviation between the Z homing distance and the probing distance. Then nozzle homes about 1mm lower than it actually prints at. Same with endstop, that's not the sensor's fault.

  15. Mal ne Frage…Kann ich mein Bed ohne Glassplatte leveln, danach zum ersten Mal den Sensor einbauen und dann wieder die Platte aufs Heatbed drauf machen? Oder muss ich irgendetwas verstellen nachdem ich die Platte wieder drauf habe?

  16. You are talking about 50µm (0.05 millimeters) If your 3d printer i high end maby and i say may your 3d printer has a tolerens of 0.1mm , maby better with out belts, and using ball spindels. 0.05 millimeters is just so unreal.

  17. So, there is no clear winner? I was hoping that the BLtouch was. But like others mentioned, you tested it horizontally and BLTouch clearly says that readings will be inaccurate that way.

  18. The only reason I moved from an inductive sensor to David Crocker's IR sensor is because of the bed. If the thickness of the bed varies, or there are holes in it to reduce weight, the induction sensor will trigger at a different height to more/less material being on the bed in one location.

  19. I would love to see this video updated to include Ultrasonic sensors, and name brand inductance sensors like those made by Osram up to say 16mm sensing distance. That being said, this video is so helpful. Thank you for making it.

  20. So…. which one is the best? More accurate, reliable and worth to buy?
    Great video but without conclusion is quite useless, still have no idea what to buy as an upgrade to my printer :/

  21. I know this video is over a year old at this point so I hope this is still relevant.

    He tested all of these sensors horizontally. The BLTouch specifically states NOT to use it that way. It needs to be hung vertically as it would be mounted on a printer.

    I've used a mechanical switch with manual leveling, a mechanical switch that flips up with a servo, capacitive sensors, inductive sensors, glass beds, PEI sheets, Zebra Plate from PRINTinZ, aluminum beds, and even tool steel beds. I've tried a total of 15 different sensors and 11 different beds in my few years of 3D printing. NONE of them were as accurate as simply using the BLTouch. When it is installed correctly, it just works flawlessly. Best of all it doesn't care one bit what surface you have, it will work on anything.

    I think it deserves a re-test.

  22. When I look at your sheet and go to buy one I noticed that your links are not named at your data sheet. Could you please rename them correspondingly and provide a link for the PINDA

  23. would it be possible to use the z end stop as an auto level, for example moving the z end stop to the extrude instead of the side and have auto level turned on in firmware

  24. may be a bit late, but someone might see this and find it useful. copper tape can be used on the bottom of glass beds, and an inductive sensor will work in my experience.

  25. Hello Tom. May I first congratulate you on your clear, informative videos and have now subscribed to you. I am new to 3D printing and Arduino world in general. I have just bought the Ender 3 and having watched various autolevelling videos also purchased the BLtouch sensor. I have added the bootloader to the Ender 3 and now want to download the relevant sketch to control the BLtouch. Can you direct me to any video/information that will help as I am a little confused with what I have seen so far. Many Thanks. Rob

  26. Another one to try is the piezo force sensor. Mount it in your bed support or (as I did) in your hot-end mount on the carriage and it registers contact of the nozzle to the bed. Zero probe offsets in X, Y and Z, change nozzle and all you have to do is run the auto-level. Super convenient. Precision Piezo do a good rig.

  27. So, would I be correct is assuming the LJ12A3-4-Z/BX is incredibly accurate and the 1 to get, at a fraction of the cost of some of the others?

  28. If I have a capacitive sensor. and a aluminium bed. what is the best height the sensor should be at? Somebody must know. have searched. cant find any good answers. =) thank you.

  29. The BLTouch manual specifically states the sensor must be run vertically. Since your test rig is horizontal, the results are suspect. It would be good to rerun the BLTouch test with it held vertically.

  30. Hello Tom,

    I wonder if you can help me with a couple of queries.

    I have bought a LJ12A3-4-Z/BY inductive sensor. It is the 12mm diameter version as I did not have room to fit the larger 18mm version. The problem is that the detection distance is halved to just 4mm. I was wondering if I could power the sensor directly from the power supply and possibly fit either a voltage regulator or resistor voltage divider to reduce the signal back at the board? I also have some 0.1mm stainless steel foil that I am intending to place under the 2mm glass. Will this increase the ability for the sensor to pick up the magnetic field?

    One last point, do you know if it is possible to devise a method of using a k type thermocouple instead instead of a thermistor? I know that a thermistor decreases voltage as it heats and a thermocouple works in the opposite direction but i would like to use a PID to control hot end temperature as it better controls better without overrun once heating temperature is achieved.

  31. Why only 5 volt? Are they powered by USB? Since most USB ports are 5 volts? Great video! But you didn't show us stepper motors that have all this stuff built in. Is this just a cheaper method using an external sensor?

  32. You measured mostly repeatability, and mostly ignored system accuracy due to heating/cooling.
    Excellent video, great charts.

    Should have had an external digital DTI measure the setups actual position, logging, and dwelled (paused) after contact on the probe.
    Then the DTI log would show where the moving piece actually was at probe contact, vs the start position when all was cold.

    Likewise, the triggering circuit for probe hit is critical.
    I did a lot of work on this, 8 years ago, on testing for lathe spindle index sensors, and we proved conclusively that sensors will give very fuzzy signals, that vary with temp/speed/luck.
    A sharp triggering circuit, and a sensor tuned to give a crisp response, will be about 100x more accurate on a range of speeds vs a typical probe "hit".

    I also saw that optical sensors will repeat to about 2 microns, with very simple basic cheap sensors.

  33. Thanks for your work! But one question:

    Is it possible, that a electical heatbed can get a bad influence on these probes?
    For e.g. eletric magnetic behaviours? On your test is a "perfect" metal block without heatbed wires etc.

  34. Thanks for your videos. I have experienced difficulties with sensors. After a few consecutive prints, the levelling of the bed was not accurate, but was accurate again the day after. I now make the levelling when the bed is hot, but the problem still exists. I believe that the sensor close to the bed and the head warms up little by little, and the temperature of the sensor may have some effect of the measurement.

  35. HELP !!! my new 3D printing (A10M geeetech) does't work petty well..
    the Y sensor stop to work but the sensor is not broken I'm sure.. no problem on the cables.. but.. where is the problem ??

  36. Incredible experimental design, helped me so much in making an informed choice. Earned my subscription and then some!

  37. I want to address something I've been seeing floating around the internet regarding the inductive/capacitive probes. People keep saying you need a 12 V to 5V voltage divider on the output. This is partially wrong, and may, in fact, introduce more errors in your bed leveling. The sensors do absolutely need to be run from 12 volts to achieve their rated specs, but if you are careful to buy an NPN type sensor, you can simply plug the output directly into the Ramps input pin. This sensors are what is called "open collector drain" output. It means that it doesn't provide an output voltage when trigged, rather it pulls the signal provided to it to ground. The Arduino/Ramps board has internal 20 kohm pull up resistors on all of its pins (enabled in Configurations.h). This pull up provides 5 volts to the output pin of the sensor, when the sensor triggers, it pulls that 5 volt signal to ground. If you use a voltage divider, you might reduce the 5 volts enough to cause unreliable switching in the Arduino. PNP type = needs voltage divider. NPN type = do not use voltage divider.

  38. 2 years further, are there newer sensors on the market that do a better job, or is this video still relevant?

  39. So what the best for practical use? All that for no practical results. ………… PRUSA Knows how to work it.

  40. I thought you needed an PNP sensor? (at least for a ender 3) Can you use either and set the high/low trigger in marlin firmware?

    Also, what voltage divider did you use?

  41. So, I've been thinking about these results, and I don't believe they can be conclusive for which sensor is actually best for "bed leveling" since that involves sensing at several different places on the bed. This test setup, though certainly useful and helpful, may not be telling the whole story since it continuously tests only one spot on the big aluminum block. A better more conclusive test would test how accurately each sensor can sense the actual flatness of a bed; i.e., at multiple points. Since an aluminum bed, for instance, may not be perfectly uniform across its entirety with respect to its inductive properties, would an inductive sensor actually perform worse than or only as good as a physical touch/contact type sensor in an actual "leveling" application?

  42. It is a nice video and I learned something,
    but I my expectation was, you would have tested more different types.
    Besides, most printers use an optical sensor, which block the light.
    For bed leveling, it is often the touch sensor, which you did quicly glance over.
    I kinda missed the hal sensor and the piezoelectric sensor.

  43. Microswitch is more accurate but is there any practical way to use one as a bed leveler since it would always be below the nozzle height?

  44. Why does searching Tom's channel for "Piezo" list this video (and only this video) as the result?
    I'm saying I want a piezo sensor underbed mount review by Tom please. 🙂

  45. Tom. You pretty much nailed this one….also you mentioned that capacitive sensors are thrown off by humidity…they are actually the instrument they use to sense humidity.

  46. If the tests were conducted as in the video , what do you make of Antcap's instructions regarding how the BLTouch must be mounted ?

    The manufacturer's website for the BLTouch clearly states this: if the sensor is mounted horizontally it WILL give wrong results.
    They don't equivocate. It is a crystal clear stipulation. It is underlined even . Would you care to comment ?

  47. Very informative video that highlights the differences in sensor types. Just what I was looking for to help decide what sensors to look at.

  48. I've got a creality textured glass bed so can someone recommend me a type of probe please? (I have an ender 3)

  49. Hi there, i have a LJ18A3-8-Z / BX 8mm and cannot detect the alluminum bed behind the glass build plate, not even the glass, but detects metal, any ideia?

  50. I am gonna buy an inductive and put foil on the glass and throw out the touch. The touch almost destroyed my extruder and bed when it suddenly jammed the needle.

  51. Cool comparison. I was looking for a sensor to measure distance for my research project. So this helped me to understand the basics of the sensors. Thank you for that. Also is it possible to have the part list for your test setup? It will be really useful.

  52. I don't use autolevel for couple reasons – I print on glass, and I can't afford (or justify the expense of) ball screws. I use an inductive sensor (LJ8A3-2-Z/BX-5V), as a fixed Z end stop switch, sensing a mild steel bolt head. Using a digital 'dial' gauge, I get repeatabilty of ~3µm delta (not standard deviation). That's with T8 lead screws and DRV8825 drivers, 32 microsteps, so 1.25µm per step. Not bad I think, for a modest outlay, and plenty good enough for 3d printing.

  53. Название ролика и его описание на русском языке , это Ютуб перевел или автор в оригинале на русском написал ?

Leave a Reply

Your email address will not be published. Required fields are marked *