Wireless Charger Stand
A desk stand that holds a round wireless charging puck upright, so a phone that sticks to it magnetically charges at a comfortable viewing angle. The cradle is a flat plate with a press-fit pocket sized from the puck diameter and thickness, a ledge with a lip for the bottom edge of the phone, a cable slot under the pocket that is long enough to pass the plug, and a push-out hole behind the puck; the puck face stands 0.3 mm proud so the phone lies on the charger. The cradle plugs into a slot in the base that leans back 20 deg, and the puck height above the ledge is set from where the charging coil sits in your phone. The file checks the fit with puck, plug and phone probe solids and keeps the phone's centre of mass over the base. Assembled it is 82 x 72 x 128 mm; the print plate is 162 x 131 x 22 mm, cradle on its back and base on its underside, no supports. Parameters: puck diameter and thickness, pocket fit, cable and plug size, coil height, phone thickness and recline.
# Charger Stand - holds a round wireless charging puck upright so the phone charges at a viewing angle
#
# Two parts. The cradle is a flat plate with a round pocket for the charging puck, a ledge
# for the bottom edge of the phone and a tongue; the base is a plate with a housing whose
# slot leans back at `recline`. Push the tongue into the slot, thread the cable plug through
# the slot under the pocket and press the puck in: its face stands 0.3 mm proud, so the
# phone lies on the puck, not on the plastic. The height of the puck above the ledge is
# `coil_h`, the distance from the bottom edge of the phone to the centre of its charging
# coil. A hole behind the pocket lets you push the puck out again.
# The cable leaves through the plate and runs away behind the stand.
# The file drops a puck, a cable plug and a phone into place as probe solids and checks that
# they fit, and that the phone's centre of mass stays over the base.
# Printing: view = "print" lays both parts flat - the cradle on its back with the pocket up,
# the base on its underside. No supports: the lip of the ledge grows at 45 deg.
@param 40..70 step:0.5 group:"Puck" desc:"Diameter of the charging puck (mm)"
$puck_d = 56
@param 4..12 step:0.1 group:"Puck" desc:"Thickness of the charging puck (mm)"
$puck_t = 5.5
@param 0.05..0.5 step:0.05 group:"Puck" desc:"Radial clearance of the pocket (mm): small for a press fit"
$fit = 0.15
@param 3..9 step:0.5 group:"Cable" desc:"Thickness of the cable where it leaves the puck, or of its plug if thicker (mm)"
$cable_d = 6.5
@param 8..20 step:0.5 group:"Cable" desc:"Width of the plug at the far end of the cable (mm)"
$plug_w = 13
@param 55..110 step:1 group:"Phone" desc:"Bottom edge of the phone to the centre of its charging coil (mm)"
$coil_h = 75
@param 6..16 step:0.5 group:"Phone" desc:"Phone thickness, with its case (mm)"
$phone_t = 10
@param 10..35 step:1 group:"Phone" desc:"Recline of the phone from vertical (deg)"
$recline = 20
@param choices:["print", "assembled"] group:"View" desc:"Print plate or assembled stand"
$view = "print"
# --- Cradle, in print coordinates: back on the bed, Y up the plate, Z out of its front face -----
$proud = 0.3 # the puck face stands this far above the plate
$back = 2 # plate left behind the puck
$pd = $puck_t - $proud # pocket depth
$t = $pd + $back # plate thickness
$rp = $puck_d / 2 + $fit # pocket radius
$margin = 8
$Wp = $puck_d + 2 * $margin # plate width
$ledge_t = 4
$sc = $ledge_t + $coil_h # puck centre above the bottom of the ledge
$s_top = $sc + $puck_d / 2 + $margin
$Lt = 16 # tongue length
$d = $proud + $phone_t + 0.8 # room on the ledge for the phone
$lip = 2.5
$slab = box $Wp ($sc + $Lt) $t center:(true, false, false) | translate 0 (-$Lt) 0
$head = cylinder ($Wp / 2) $t | floor | translate 0 $sc 0
$ledge = workplane YZ | polyline [(0, $t - 0.5), ($ledge_t, $t - 0.5), ($ledge_t, $t + $d), ($ledge_t + $lip, $t + $d + $lip),
($ledge_t + $lip, $t + $d + $lip + 1.5), (0, $t + $d + $lip + 1.5)] | extrude $Wp | translate (-$Wp / 2) 0 0
$pocket = cylinder $rp (2 * $pd) | translate 0 $sc $t
$push = cylinder 6 (4 * $t) | translate 0 $sc 0
# cable slot: through the plate under the pocket, long enough to pass the plug
$slot_w = $cable_d + 0.6
$slot_len = $plug_w + 3
$slot_s0 = $sc - $rp - $slot_len
assert $slot_s0 >= $ledge_t + 3 # the slot ends above the ledge: raise coil_h or shrink the plug
$cable_slot = box $slot_w ($slot_len + 4) (4 * $t) center:(true, false, true) | translate 0 $slot_s0 0
$cradle = $slab + $head + $ledge - $pocket - $push - $cable_slot
# probes in the same coordinates
$puck = cylinder ($puck_d / 2) $puck_t | floor | translate 0 $sc $back
$plug = box ($cable_d) $plug_w 30 center:(true, false, true) | translate 0 ($slot_s0 + 1) 0
$phone_w = min($Wp, 72)
$phone_h = 2 * $coil_h
$phone = box $phone_w $phone_h $phone_t center:(true, false, false) | translate 0 $ledge_t ($t + $proud)
# --- Assembled coordinates: Z up, the phone faces -Y --------------------------------------------
$floor_z = 2
$zO = $floor_z + $Lt * cos($recline) + $t * sin($recline) # height of the front foot line of the plate
def asm($s) = $s | translate 0 0 (-$t) | rotate (90 - $recline) 0 0 | translate 0 0 $zO
$c = 0.2 # slot clearance per side
$Wb = $Wp + 10
$hb = $zO - 0.6 # housing height
$hy0 = -$Lt * sin($recline) - 3.5
$hy1 = $t * cos($recline) + 3.5
$y_front = -($d + $lip + 1.5) * cos($recline) - 12
$y_back = $s_top * sin($recline) + 6
$base_t = 4
$foot_blank = box $Wb ($y_back - $y_front) $base_t center:(true, false, false) | translate 0 $y_front 0
$foot = $foot_blank | edges =Z | fillet 6
$housing = box $Wb ($hy1 - $hy0) $hb center:(true, false, false) | translate 0 $hy0 0
$socket_raw = box ($Wp + 2 * $c) ($Lt + 0.2 + 20) ($t + 2 * $c) center:(true, false, false) | translate 0 (-$Lt - 0.2) (-$c)
$socket = asm($socket_raw)
$base = $foot + $housing - $socket
$cradle_up = asm($cradle)
$phone_up = asm($phone)
# --- Layout -------------------------------------------------------------------------------------
$cradle_flat = $cradle | translate ($Wb / 2 + $Wp / 2 + 8) ($y_front + $Lt) 0
$plate = union [$base, $cradle_flat]
$stand = union [$base, $cradle_up]
$out = if $view == "print" then $plate else $stand
# --- Checks -------------------------------------------------------------------------------------
assert $cradle.solids == 1
assert $base.solids == 1
assert $cradle.bbox.min[2] ~ 0 tol:0.001
assert $base.bbox.min[2] ~ 0 tol:0.001
assert $cradle.bbox.x ~ $Wp tol:0.01
assert $cradle.bbox.y ~ $s_top + $Lt tol:0.01
assert $cradle.bbox.z ~ $t + $d + $lip + 1.5 tol:0.01
# the puck drops into the pocket, sits on its floor and stands proud of the plate
assert clear($cradle, $puck)
assert $puck.bbox.max[2] ~ $t + $proud tol:0.001
assert ($cradle * ($puck | translate 0 0 (-0.5))).volume > 0.3 * pi * $puck_d * $puck_d / 4 * 0.5 # there is a floor under it
assert ($cradle * (cylinder ($puck_d / 2 + $fit + 0.6) $puck_t | floor | translate 0 $sc $back)).volume > 0 # and a wall around it
# the plug passes the cable slot, the phone lies on the puck between plate and lip
assert clear($cradle, $plug)
assert clear($cradle, $phone)
assert $phone.bbox.min[2] ~ $puck.bbox.max[2] tol:0.001
assert $phone.bbox.center[1] ~ $sc tol:0.01 # coil over the puck centre
# assembled: tongue in the socket with a real gap, phone clear of the base
assert clear($base, $cradle_up)
assert clear($base, $phone_up)
assert clear($base, $cradle_flat)
assert $stand.solids == 2
assert $plate.solids == 2
assert $cradle_up.bbox.min[2] >= $floor_z - 0.01
assert ($base * asm($slab)).volume ~ 0 tol:0.001
$tongue_in = asm($slab) * (box 400 400 $hb center:(true, true, false))
assert $tongue_in.volume >= 0.8 * $Wp * $t * $Lt # most of the tongue is inside the housing
# tipping: the phone's centre of mass is over the base plate with 10 mm to spare
$com_y = $phone_up.bbox.center[1]
assert $com_y >= $y_front + 10
assert $com_y <= $y_back - 10
print "pocket (mm)" (2 * $rp) "deep" $pd "plate" $t
print "cradle" $cradle.bbox
print "base" $base.bbox
print "assembled" $stand.bbox
print "phone centre of mass y" $com_y "base from" $y_front "to" $y_back
$out