
Category: 3D Printing, DIY, Electronics
Apr 16
Auto-Levelling the Hictop Prusa i3
I’ve been having lots of fun with my DIY 3D printer. It’s such an impressive technology demonstration that the school picked up one for my Tech Club to build – which they did in about 6 hours flat. It took me 12 hours to assemble the same kit. I noticed that Hictop have added some improvements such as supplying much higher quality Z threaded rods and new X ends to accommodate them. The Z rods have definitely been the weakest part of the Hictop Prusa design and I’ve already upgraded my machine to use the improved 8mm pitched machined rods.
The other weak part of the design has been bed calibration or levelling. In theory, once you’ve levelled the bed, you should be good to go, however, in practice the bed needs to be re-levelled after almost every print. Bed levelling requires adjusting 4 tiny, hard to reach thumb screws located under the base plate with the aim of adjusting the distance between the extruder tip and bed to be around the thickness of a piece of paper. It’s a complete drag but failure to start a print without a level bed results in either the first layer failing to stick or the extruder getting blocked.
Enter auto-levelling. Marlin, the Arduino based software that runs the printer, supports a clever feature that allows you to print onto an uneven bed by mathematically compensating in software and adjusting the print head to match the bed. It doesn’t actually level the bed at all but rather takes sample points from each corner of the bed prior to printing and then adjusts accordingly on the fly while it prints. A more accurate term for the process would be ‘auto bed compensation’ but I think seeing the terms ‘auto’ and ‘level’ together is enough to compel any DIY 3D printer user.
There are a number of ways to achieve auto-levelling, all of which require some form of switch or probe to sample the bed position prior to printing. A small servo with a contact switch was one of the original methods but inductive, contactless switches seem to be the norm now. My problem with inductive switches is that they require a metal bed to probe and don’t typically work well through glass which is my preferred bed material. I decided to go with a capacitive sensor instead.
First of all, my hat is off to Tom whose Youtube video does an excellent job explaining the process. Although his video is about using an inductive sensor, the exact same process applies. My purpose here is to explain where I deviated with the use of a capacitive sensor and how it applies specifically to the Hictop printer (although this could apply to most Prusa i3 designs).
Before you even begin, you must have a working Marlin configuration and be able to upload to your printer board. Hictop supplied me, upon request, the full Marlin installation but there were errors in their configuration.h (like the X stepper being reversed) and they are using an early version of Marlin which does not support auto-levelling. My first task was to download the latest version of Marlin and transfer all the settings, manually, from the older configuration.h file into the new one. This proved to be slightly more involved than I was expecting due to having also upgraded my control panel to the larger, full screen graphics controller. But in the end, I managed to get it all working. Click here to download my configuration.h file but keep in mind this includes support for the full screen graphics controller which is not standard on the Hictop.
Next up was the hardware. Again, this was not as straightforward as I thought. The sensor I chose is the LJC18A3-H-Z/BX capacitive sensor from Amazon. It’s a big sucker with an 18mm diameter but is quite light for the size. I found this part from thingiverse.com which allows mounting the sensor to the left of the fan duct. I’m not thrilled about adding this extra weight to the head but it remains to be seen what impact this will have on print speed. I did take the effort of printing the new fan duct in ABS. I dislike printing with ABS but the proximity to heated parts makes it a better choice than PLA.
The wiring of the sensor was also a bit of a challenge and I’ve taken a slightly different approach than most people in the reprap forums. There’s a lot of conflicting information out there regarding the wiring of these proximity sensors and this is further confused by different types of sensors that behave electronically in very different ways. The LJC18A3-H-Z/BX is an NPN, normally open type switch which upon triggering clamps the signal pin to ground (unlike the more popular PNP type sensors which output the input voltage to the signal pin upon triggering). Tom’s video deals with PNP type inductive sensors and he explains creating a voltage divider to protect overloading the printer board.
While this shouldn’t apply to the LJC18A3-H-Z/BX NPN type sensor due to the fact it does not deliver voltage when triggered, I found that in its untriggered state, it still produced around 10v across the signal pin when supplied with 12v. There are conflicting reports whether or not the internal pullup resisters on the ramps board are able to regulate this or whether a voltage divider/regulator is required. There was even a guy who powered the sensor via the signal pin! which is a pretty ridiculous shot in the dark.
The LJC18A3-H-Z/BX has a specified input voltage between 6-36v and some report success driving it with 5v meaning it could be hooked up straight to the ramp board’s Z-stop terminal with no other circuit – although I suspect this would affect its stability. Instead, I decided to run the sensor at its supported minimum 6v via a simple DC-DC buck converter (available on eBay for a few quid). This results in an open voltage of around 3.9v on the signal pin when untriggered which is safe for the ramps board and sufficient to trigger its high state for switching. Due to it being a normally open circuit, there was no need to reverse the logic in Marlin and after a little trial and error setting the Z offset, auto-levelling is working great.

I haven’t bothered performing repeatability tests like some people have published in forums. I swear the pixel-peepers exist in pretty much every online community. I’ve also ignored the mindless debates on inductive vs capacitive vs contact vs infrared. What I can tell you is after about a dozen prints, I’m seeing consistent results with a higher level of accuracy across the bed than I ever achieved by manual calibration. Unfortunately, I still can’t swap out different thickness bed materials. Obviously, the capacitance is influenced by the material and layer thickness but I’m sure inductive sensors fluctuate in much the same way. What I can now do is just print and not worry about the first layer adhering properly to the bed and that adds further enjoyment and satisfaction using my DIY machine.
UPDATE: I notice Hictop are now selling an auto-level version of this kit for a little more money. It appears they have mounted a box type proximity sensor (probably inductive?) to the back of the X carriage. This may alleviate extra weight on the head but would park the sensor further away from the extruder tip. Anyway, nice to see Hictop addressing these design deficiencies and I would certainly recommend going for the auto-level function.
UPDATE 2: After weeks of successful printing, the sensor became erratic and failed. Amazon promptly replaced and I’m back up and running.