SnapMount

Snap-in mount for a PCB edge

Category: Case

Using this part

This TurboCase prefab can be directly pasted into your KiCad PCB editor by using the copy button below. The code of the footprint is also shown here for reference. The footprint file can also be downloaded to be added to your own local footprint libraries.

Download footprint
(
  footprint
  "SnapMount"
  (version 20240108)
  (generator turbocaseweb)
  (descr "Snap-in mount for a PCB edge")
  (attr board_only exclude_from_pos_files exclude_from_bom allow_missing_courtyard)
  (zone_connect 0)
  (
    property
    "TurboCaseModule"
    "eJyFUF1vgyAUffdX8KhRV+z2sKbpT9jTHhtjqN6KqQMDmLZb+t93EcS5PYwQuB/nHg7nQzZjD+RdsOFNjsLECfmKCC7dfQI5kOe9y7BfrUuciRYz+vSyjxzGYKoNE408nysOXctNOtSnyvCuvgjQOi08G/8P6XFXxBWLggEUFo5HmtEyI3ghiQ30dYlSqwtTHhohomXpuJQ0zEBsCXAXr7RMprpRTOh+btnv5m5uNuUXKA+2bLYZyW0woQN2fmjnXtr97PWdAKYquBk1NhAHqgVh1yD7eytF7L+feK//qp3MWDm62ZZrrno8Idap9Od6Ao2qQRhQB9QEiTPrET2ib2BNn+Q="
    (at 0 0 0)
    (unlocked yes)
    (layer "F.SilkS")
    (hide yes)
    (uuid "b7948e33-6d17-410d-814f-0f42234dff63")
    (
      effects
      (
        font
        (size 1 1)
        (thickness 0.1)
      )
    )
  )
  (
    property
    "TurboCaseAdd"
    "SnapMount()"
    (at 0 0 0)
    (unlocked yes)
    (layer "F.SilkS")
    (hide yes)
    (uuid "56c35953-5ae8-44fd-9421-cacb906e72dd")
    (
      effects
      (
        font
        (size 1 1)
        (thickness 0.1)
      )
    )
  )
  (
    fp_line
    (start -3 0)
    (end 3 0)
    (
      stroke
      (width 0.2)
      (type default)
    )
    (layer "User.6")
    (uuid "6371b208-2476-4a21-8600-009aaf474d3e")
  )
  (
    fp_rect
    (start -0.5 0)
    (end 0.5 1)
    (
      stroke
      (width 0.2)
      (type default)
    )
    (fill none)
    (layer "User.6")
    (uuid "47488324-c143-4cc3-99c0-da69abcaa10e")
  )
)

The OpenSCAD code

This is the OpenSCAD code that will end up in your final case .scad file:

module SnapMount() {
    size = 3;
    snap_size = 3;
    hang = 0.4;

    st = standoff_height+pcb_thickness+1;
    sh = standoff_height+pcb_thickness;
    sw = 1;
    snapper = [[0,0], [0, st], [sw, st], [sw+hang, sh], [sw, sh], [sw, 0]];
    rotate([0, 0, 180])
    translate([0, size-sw, 0]) {
        translate([-snap_size/2, -size, 0])
        rotate([90, 0, 90])
        linear_extrude(snap_size)
            polygon(snapper);

        translate([0, 0, standoff_height/2])
            cube([size, size, standoff_height], center=true);
    }
}