Feeler Gauge
A set of thickness leaves for checking gaps, from 0.2 to 1.0 mm in 0.1 mm steps by default. Every leaf is a thin blade with a rounded tip and a thick tab at the pivot end that carries its thickness engraved, so even the thinnest leaf can be read, and the leaves fan out on a printed split snap pin through the tabs. The series is set by the thinnest and thickest leaf and the step; the number of leaves and the pin length follow from it. The default nine leaves lay out as 92 x 150 mm. Print flat with no supports, with a layer height that divides the step and a first layer of the same height, since a 0.2 mm leaf is only two layers; the leaves are nominal, so check them with a caliper before trusting them. Parameters: thinnest and thickest leaf, step, blade length and width.
# Feeler Gauge - a fan of leaves from 0.2 to 1.0 mm on a snap pin, each thickness on its tab
#
# A set of thickness leaves for checking gaps: every leaf is a thin blade with a rounded
# tip and a thick tab at the pivot end that carries its thickness, engraved, so a 0.1 mm
# leaf can still be read. The leaves fan out on a printed split snap pin through the tabs.
# The thicknesses are a series from the smallest to the largest in a chosen step; the
# number of leaves and the pin length follow from it.
# Printing: lay flat, no supports. Print with a layer height that divides the step
# (0.1 mm for a 0.1 step) and a first layer of the same height, because a 0.2 mm leaf is
# only two layers. The leaves are nominal: check them with a caliper before trusting them.
@param 0.1..1 step:0.1 desc:"Thinnest leaf (mm)"
$t_min = 0.2
@param 0.5..3 step:0.1 desc:"Thickest leaf (mm)"
$t_max = 1.0
@param 0.1..0.5 step:0.1 desc:"Step between leaves (mm)"
$t_step = 0.1
@param 40..100 desc:"Blade length (mm)"
$blade_l = 60
@param 6..14 desc:"Blade width (mm)"
$blade_w = 10
$n = floor(($t_max - $t_min) / $t_step + 1.001)
assert $n >= 2
def th($i) = $t_min + $i * $t_step
# --- One leaf: tab with the pivot hole and the engraved thickness, blade with a round tip
$tab_l = 16
$tab_t = 2.4
$tab_w = $blade_w + 4
$pin_d = 6
$hole_r = $pin_d / 2 + 0.25
def leaf($i) = union [box $tab_l $tab_w $tab_t center:(false, true, false),
box ($blade_l - $blade_w / 2) $blade_w th($i) center:(false, true, false) | translate ($tab_l - 1) 0 0,
cylinder ($blade_w / 2) th($i) center:(true, true, false) | translate ($tab_l - 1 + $blade_l - $blade_w / 2) 0 0]
$hole = cylinder $hole_r ($tab_t + 2) center:(true, true, false) | translate 6 0 -1
def label($i) = text ("" + th($i)) 3 | extrude 1 | translate 11.5 (-1.5) ($tab_t - 0.5)
def leaf_cut($i) = leaf($i) - $hole
def leaf_done($i) = leaf_cut($i) - label($i)
# --- Layout: leaves side by side along Y, tabs aligned, pin at the end ------------------
$pitch = $tab_w + 3
def ly($i) = ($i - ($n - 1) / 2) * $pitch
$leaves = union [leaf_done(i) | translate 0 ly(i) 0 for i in range($n)]
# snap pin long enough for the stack of tabs
$stack = $n * $tab_t
$shaft_l = $stack + 0.4
$pin0 = union [cylinder 5 2 center:(true, true, false),
cylinder ($pin_d / 2) $shaft_l center:(true, true, false) | translate 0 0 2,
cone ($pin_d / 2 + 0.5) ($pin_d / 2 - 0.6) 1.6 center:(true, true, false) | translate 0 0 (2 + $shaft_l)]
$slot = box 1.2 ($pin_d + 4) ($shaft_l + 1.6 + 1) center:(true, true, false) | translate 0 0 3
$pin = $pin0 - $slot
$pin_p = $pin | translate (-12) 0 0
$out = $leaves + $pin_p
# --- Checks: one solid per leaf plus the pin, and the stack volume matches the series ------
assert $out.solids == $n + 1
assert clear($leaves, $pin_p)
$blade_area = ($blade_l - $blade_w / 2) * $blade_w + 3.14159 * ($blade_w / 2) * ($blade_w / 2) / 2
$blades_vol = $blade_area * $n * ($t_min + $t_max) / 2 - 1 * $blade_w * $n * ($t_min + $t_max) / 2 # minus the 1 mm overlap into the tab
$tabs_vol = $n * ($tab_l * $tab_w * $tab_t - 3.14159 * $hole_r * $hole_r * $tab_t)
assert $leaves.volume ~ ($blades_vol + $tabs_vol) # within 1 %: the engraved labels are the difference
assert $pin.solids == 1
print "leaves" $n
print "pin shaft (mm)" $shaft_l
$out