# Wiring Z-stop directly to hot end and aluminum bed / spacers

So I am really fed up with inductive probes. The one I am using keeps getting shifted slightly every time I switch nozzles or run an oozy print. That means I have to autolevel again, then manually set a Z-offset (as I would have anyway if I didn't have an inductive probe).

On my Lulzbot Mini there is a different scenario. There are four washers at each part of the bed. The nozzle is "grounded" so that when the Mini touches the washers, a current is created that seems to act as the Z-stop. Surprisingly there isn't much out there for a DIY implementation of this.

Since I have an aluminum bed (and aluminum is conductive), I am thinking of doing the following:

1) Put one wire from the Z-stop ground pin to the aluminum bed. Make sure it is away from the wires for the heater / thermister (?)

2) Put one wire from the Z-stop 5V into the heating block of my nozzle.

When the nozzle probes the bed, a current will be created from the 5V heating block, through the conductive nozzle, into the conductive bed, to the Z-stop ground.

I'm always unsure when it comes to circuitry. Will there be any dangerous interference from this technique from, say, the bed heating circuit? I'm not sure what kind of protection circuitry are on each of the Arduino's pins, and I'd rather not fry my board if this sounds like a bad idea to someone.

I figure most people don't do this because they have sheets of PEI or some other non-conductive material on their bed. I can use PET tape but still leave holes in the tape for this autobed leveling probe. It would be really great if it worked and wasn't dangerous.

I shouldn't even need the third pin?

• You mean the method that is used in some mills and CNC to find the corners and top of a workpiece? – Trish Jul 14 '19 at 13:20
• ^ Not sure. But just to add to my complaints: Inductive probes take up space that could be used for extruders, my one in particular required a 3D printed piece that was getting warped, and in fact they shrink the overrall bed size because you can't always move an extruder to a spot on the axis that is blocked by the inductive probe – K Mmmm Jul 14 '19 at 22:50
• even a conductive probe (what you want to do!) takes space. – Trish Jul 15 '19 at 8:50
• ^ Yes I know what you mean now. In my case it takes significantly less space though – K Mmmm Jul 15 '19 at 13:33
• I'm reading this question after a month published and using the nozzle as trigger for Z stop can be used if this nozzle is grounded; the main problem is if the nozzle are not complete clean at the time of touching the aluminum bed might fail, but could be realable. I'm using inductive probes and each print the Gcode calls G29 to auto level; this is not a mess but each print is granted to be perfectly aligned and sticky. – Fernando Baltazar Sep 12 '19 at 4:14

Aluminium is conductive, but aluminium oxide is not, which is just so what there (unavoidably, since aluminium rapidly oxidises in air) happens to be a thin layer of on top of your bed. The coating is very thin, but it might foul your plans. It would work better with a sharp probe (that can puncture the layer) than with a 3D printer nozzle. You should be careful, because your probing method might be unreliable (which could cause the nozzle to crash into the bed).

Wiring the endstop 5V directly to ground will create a short circuit which will damage your printer. You should use the third (signal) pin and ground instead.

Edit: i recommend using some conductive felt

The top of the aluminum bed is not conductive, but the sides of it are. You can re-create the Lulzbot Mini endstop set-up by connecting the Z-stop ground to the side of the aluminum bed, then using binder clips and nickels as the "washers". In my case I had to use quarters because my bed was really big and the extruder came down far from its edges.

To do this, you'll need:

1. A multimeter and a >100 Ohm resistor for safety
2. Some nickels (or any conductive coin)
3. Some binder clips (with steel insides)
4. Some aluminum foil (increases reliability of setup)
5. A Z end-stop

Building conductive washer perimeter

Create a conductive washer system along the sides of your aluminum bed by:

1. Wrapping a nickel-sized amount of aluminum foil on the bottom, side, and top of the bed

2. Placing a nickel on top of that aluminum foil on the bedttop

3. Placing a steel-inside binder clip to hold down the nickel

Do this multiple times along the perimeter of the bed. It seems you are limited to an evenly-spaced grid structure by the software. In my case I placed the washers at:

X = 0, Y = 0
X = 0.5 * Max_X, Y=0
X = Max_X, Y = 0
X = 0, Y = Max_Y
X = 0.5*Max_X, Y = 0.5 * Max_Y
X = Max_X, Y = Max_X


The aluminum foil provides a contact between the side of the bed and the top and bottom of it. The binder clip can be pressed inwards against the aluminum foil to ensure high reliability. However, the binder clip can get loose. So, using aluminum foil helps make the bottom of the bed conductive too, increasing the surface area of the contact for the binder clip.

Attaching red wire to hot end

Attach the red part of the Z-endstop to your heatblock. It must be in the heatblock somewhere. The thermister hole might work. For me, I was able to slide it in a small space that's used to tighten the screw that holds the heat rod.

Now we want to attach the Z-stop ground (black wire) to the conductive perimeter.

Before attaching Z-stop ground underneath one of the binder clips, a word of caution...

The first time I did this, I stupidly placed a binder clip on top of the 12V heat rod attached to the bottom of the aluminum bed. This put all sides of the aluminum bed (and my conductive washers) at 12V, which created a short into the Z-stop ground pin when I connected it. This resulted in my Z-stop ground pin SMOKING up from the heat going through it. As a word of precaution, you should attach a resistor between the Z-stop ground pin and the side of the aluminum bed should something go wrong in the future. I used a 2.1 kOhm resistor I had laying around. This will limit the current going into the Z-stop ground pin. Since everyone's aluminum bed will be different (for e.g. the bottom of my bed is non-conductive, but yours might be conductive), it is really important to be careful here.

Before powering on, test to see that all of the nickels have low resistance between them. Test to see that the hot end nozzle is connected to the Z-stop red wire. Use a multimeter for this.

If you don't have a resistor, wait to attach the Z-stop ground before powering on. This will let you check the voltage to tell if your aluinum bed sides are connected to the 12V heat rod. After that, you can power off and attach the Z-stop ground and power on again.

Setting up the software

If you've flashed your firmware before, setting up the software is easy. Go to the "AUTO_BED" section of Configuration.h. First thing to do is to set your Z-offset to about 2.0mm and remove any existing offsets you might've had for a Z-probe (for e.g. X_PROBE_OFFSET... = -40 was set for me). The Z-offset should be set to a positive value this time. Don't forget to change this setting in EEPROM if you set itas well!

Since I'm only probing the perimeter, I use BILINEAR bed leveling for this one. Bilinear calculates points automatically for me, so I had to set up my perimeter according to an evenly spaced grid like I listed in "Building conductive washer perimeter".

First I activated AUTO_BED_LEVELING_BILINEAR

And my IF tree looks like:

#if ENABLED(AUTO_BED_LEVELING_LINEAR) || ENABLED(AUTO_BED_LEVELING_BILINEAR)

// Set the number of grid points per dimension.
#define GRID_MAX_POINTS_X 3
#define GRID_MAX_POINTS_Y 2

// Set the boundaries for probing (where the probe can reach).
#define LEFT_PROBE_BED_POSITION 1
#define RIGHT_PROBE_BED_POSITION 264
#define FRONT_PROBE_BED_POSITION 1
#define BACK_PROBE_BED_POSITION 264

// The Z probe minimum outer margin (to validate G29 parameters).
#define MIN_PROBE_EDGE 0

// Probe along the Y axis, advancing X after each column
//#define PROBE_Y_FIRST

#if ENABLED(AUTO_BED_LEVELING_BILINEAR)

// Beyond the probed grid, continue the implied tilt?
// Default is to maintain the height of the nearest edge.

#define EXTRAPOLATE_BEYOND_GRID
//
// Experimental Subdivision of the grid by Catmull-Rom method.
// Synthesizes intermediate points to produce a more detailed mesh.
//
#define ABL_BILINEAR_SUBDIVISION
#if ENABLED(ABL_BILINEAR_SUBDIVISION)
// Number of subdivisions between probe points
#define BILINEAR_SUBDIVISIONS 3
#endif

#endif
#elif // other bed leveling trees


Feel free to disable EXTRAPOLATE_BEYOND_GRID and BILINEAR_SUBDIVISIONS because they might not be necessary for you.

Time to autobed level

Of course, even with all that work, you're still going to want to be able to power off your 3D printer if it doesn't recognize even one of the nickels. So stay close to your power source and be sure to power it off safely if it doesn't recognize one of your contacts or if something comes loose. For example one of my coins was very dirty and yea, it made a huge difference in that corner, so I had to swap it out.

Last but not least, if you have some extra binder clips, you can enable the "Nozzle cleaning" feature in Configuration.h, just by binder-clipping the dark-green layer of a sponge to the board. Then just set the X-Y coordinates of that layer in the nozzle_clean feature in Configuration.h and make your life a lot easier. These two features working well together basically mean you don't have to do anything between multiple prints except remove the prints from the bed.

• I really wanted to add two more perimeter points at: (0, 0.5*MAX_Y) and (MAX_X, 0.5*MAX_Y). But I couldn't do this using Bilinear bed leveling. There is also something called Unified bed leveling, but I couldn't tell if that would be useful. The reason this is a headache is that you obviously don't want to continue the grid, as it would require putting a nickel right in the center of the bed (disrupting prints where the bed temperature is most accurate). If anyone has any advice on how to add just these two points it would be much appreciated – K Mmmm Jul 14 '19 at 22:48
• Update: Printing very consistently, but you will want to include the sponge like I suggested at the end and do an autoclean ("G12") after killed prints. Repetier-Host makes this easy. Also add it to your start code. It really only works reliably when you G12 before going home – K Mmmm Jul 15 '19 at 22:56

This will not work reliably.

I know, I have tried it, for a couple of years, with poor consistency.

Now, I will tell you that it worked better than the parallax IR sensors. It worked better than trying to slam the head into the bed and listen for the click.

I used the brass nozzle and the aluminum bed as a switch to detect the bed position.

I used ABS slurry on the bed. With a 100°C bed the ABS was soft enough for the nozzle to make contact. Elmer's Glue for PLA also was soft enough.

But, with the elasticity I had in the synthetic Z-axis of the delta machine, the time delay to much the bed adhesive out of the way, and the general problem of trying to conduct electricity through an aluminum oxide layer, I had variability of about 0.1 mm, which was far to much to give a reliable first layer.

To "level" the delta bed, I would touch each point several times (with a clean bed) and fit my leveling function to the noisy data. For finding my zero reference at the beginning of a print, I would touch off three time and only use the third one. This helped, but it was still super noisy.

I have subsequently incorporated a strain gauge in the triangular delta-bit. It gives much more accurate contact information and is not effected by the bed glue not does the aluminum oxide layer cause problems.

• The uncertainty and variance I found was less from the bed glue and more from the aluminum oxide breakdown. The brass nozzle had to contact the bed hard enough to scrub a break in the oxide. – cmm Jul 16 '19 at 0:45