LidClip

Clip to snap the lid to the case, put this against the inside 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
  "LidClip"
  (version 20240108)
  (generator turbocaseweb)
  (descr "Clip to snap the lid to the case, put this against the inside edge")
  (attr board_only exclude_from_pos_files exclude_from_bom allow_missing_courtyard)
  (zone_connect 0)
  (
    property
    "TurboCaseModule"
    "eJy9U11rgzAUfc+vuPgUN9NZaQdOyh72un8wSrE1rQE/SqLINvrfd5NMUbvWMsYuIXjl3HPvOUnyMqkzDq8iecnEcaPqrapkvKuoC58EMJT44LCC+TwyaRoXB0z92WNEzA+xp5IXCZewWoGzixV32lIdSFaoLK44ffM9wJWJZJOXCc8MXhQFl2wvKgeegaU8TmRZ5veL2RKewF+7F3j0UA+BB6Z8k3JxSCs278FlWRlsaJv2mXTs3jOhZ6aayDOi7O5alSdyIiQfWoODn5niW7g0jixs0pgkDL/96Q3O/FnQjoNE3URDC7HPwMG/dPGci12ycjTBWErj6WI54u78rbcIauxBMSrvAtcD3NduRK7R/nxaNx5qG+qYcsmpnOiFEm5phpDwCqy7ScgmcU0LNJagF/+p8/aev5B7Bmy52ISAwSvsboll7eNOZPilX+cXX0MdHA=="
    (at 0 0 0)
    (unlocked yes)
    (layer "F.SilkS")
    (hide yes)
    (uuid "9f5eafe8-546a-43bd-a10f-946147c5c9b4")
    (
      effects
      (
        font
        (size 1 1)
        (thickness 0.1)
      )
    )
  )
  (
    property
    "TurboCaseSub"
    "LidClip_substract()"
    (at 0 0 0)
    (unlocked yes)
    (layer "F.SilkS")
    (hide yes)
    (uuid "0cd27bd7-b384-4da0-910a-119e16f7639b")
    (
      effects
      (
        font
        (size 1 1)
        (thickness 0.1)
      )
    )
  )
  (
    property
    "TurboCaseLid"
    "LidClip_lid()"
    (at 0 0 0)
    (unlocked yes)
    (layer "F.SilkS")
    (hide yes)
    (uuid "377342de-9604-4f20-aff6-c9339d7f0ae8")
    (
      effects
      (
        font
        (size 1 1)
        (thickness 0.1)
      )
    )
  )
  (
    fp_line
    (start -1 -4.0)
    (end -1 4.0)
    (
      stroke
      (width 0.2)
      (type default)
    )
    (layer "User.6")
    (uuid "225a8984-d494-4cf9-9641-e9ac0e47ad59")
  )
  (
    fp_line
    (start 0 -5.0)
    (end 0 5.0)
    (
      stroke
      (width 0.2)
      (type default)
    )
    (layer "User.6")
    (uuid "5a050ba1-1cd8-4223-8523-f2b85c09b66f")
  )
  (
    fp_line
    (start -1 -4.0)
    (end 0 -5.0)
    (
      stroke
      (width 0.2)
      (type default)
    )
    (layer "User.6")
    (uuid "f3390383-2435-446a-b80e-172117b57b05")
  )
  (
    fp_line
    (start -1 4.0)
    (end 0 5.0)
    (
      stroke
      (width 0.2)
      (type default)
    )
    (layer "User.6")
    (uuid "94d545fd-5866-4b9c-a7ad-d562e185fbdc")
  )
)

The OpenSCAD code

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

module LidClip_substract() {
    size = 11;
    hang = 0.6;

    if(render == "case") {
        translate([0, 0, lid_model == "inner-fit" ? -headroom+4.5 : 0])
        translate([0, size/2, inner_height-1])
        rotate([90, 0, 0])
            cylinder(size, hang, hang);
    }
}

module LidClip_lid() {
    size = 10;
    r = 0.4;
    w = 0.99;

    translate([-0.2, 0, 0]) {

        if(render == "lid") {
            translate([0, 0, lid_model == "inner-fit" ? -headroom+4.5 : 0])
            translate([0, -size/2, inner_height-1]) {
                translate([-w,0, -r])
                    cube([w, size-(r*2), r*2]);

                translate([0, 0, 0])
                    rotate([90, 0, 0])
                    sphere(r);

                translate([-w, 0, 0])
                    rotate([0, 90, 0])
                    cylinder(w, r, r);

                translate([0, size-r*2, 0])
                    rotate([90, 0, 0])
                    sphere(r);

                translate([-w, size-r*2, 0])
                    rotate([0, 90, 0])
                    cylinder(w, r, r);


                rotate([-90, 0, 0])
                    cylinder(size-(r*2), r, r);
            }
        }
    }
}