BatteryHolder_18650_Protected

3D Printed 18650 button-top cell holder for slightly longer protected cells

Category: Batteryholder

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
  "BatteryHolder_18650_Protected"
  (version 20240108)
  (generator turbocaseweb)
  (descr "3D Printed 18650 button-top cell holder for slightly longer protected cells")
  (attr board_only exclude_from_pos_files exclude_from_bom allow_missing_courtyard)
  (zone_connect 0)
  (
    property
    "TurboCaseModule"
    "eJy9ld1ugyAUx+99Ci5RxIJL1yxNb7abvcPSLH7QzsTignixLH33HVFWndXapRvxggOc//kBh+OhSKtcoMdIa6E+nos8Fer16SPPZKqyJMpxmkUHAXM+yoXc6zcXfToIWmOhTdtZcIYI4mszFxcKZGDuLli2IyVY7exeZe8bHjZGmu12QgmZCGyV61bJrJC9kYnFtiVVLPCLBSY49OLStdzGNFwwZNcswq27dgZCqtCRBin6wHxUf1t3sEarSJa5WXZSI3HpI4pPAxCrCXpGITGnLBRuALtU3b677nke+7jjGKy/zZ7XpQ1+ozXwE2gzYdo7GMr9GdiZ8+rggTRlAWPLk5fHgtXyZ7iZGUVAi4+m1fixNO5d9kkAg3jOy+PBauujREgwNlpV4rr4ZOR+/peGzbkMbiNeiHdlTnrhLYPPjl4bg0ymfDoNrUcjQXFdUL2wU9Z+nwrEiMEDgtdxfwWTb6o65UF4CwpqKQgIwm9lWCBvgVO7HZ2j8wXD6QFo"
    (at 0 0 0)
    (unlocked yes)
    (layer "F.SilkS")
    (hide yes)
    (uuid "29ec9c1b-662d-4259-a612-6ded437be0b8")
    (
      effects
      (
        font
        (size 1 1)
        (thickness 0.1)
      )
    )
  )
  (
    property
    "TurboCaseAdd"
    "BatteryHolder_Cylindrical(diameter=18, length=700)"
    (at 0 0 0)
    (unlocked yes)
    (layer "F.SilkS")
    (hide yes)
    (uuid "2813e530-b095-4e70-8abb-1c1e96e787e8")
    (
      effects
      (
        font
        (size 1 1)
        (thickness 0.1)
      )
    )
  )
  (
    property
    "TurboCaseHeight"
    "18.5"
    (at 0 0 0)
    (unlocked yes)
    (layer "F.SilkS")
    (hide yes)
    (uuid "aa5fb3ff-0e16-4dc9-b53c-832c0991c010")
    (
      effects
      (
        font
        (size 1 1)
        (thickness 0.1)
      )
    )
  )
  (
    fp_rect
    (start 0 0)
    (end 20 78.0)
    (
      stroke
      (width 0.2)
      (type default)
    )
    (fill none)
    (layer "User.6")
    (uuid "8b2fbc47-9969-454b-9a1b-e877cc5751fc")
  )
  (
    fp_rect
    (start 1 3.5)
    (end 19 74.5)
    (
      stroke
      (width 0.2)
      (type default)
    )
    (fill none)
    (layer "User.6")
    (uuid "6c8dfab3-1078-421c-b4bb-08ac3d49bf06")
  )
  (
    fp_text
    user
    "18650"
    (at 8.0 39.0 90)
    (
      effects
      (
        font
        (size 3 3)
        (thickness 0.1)
      )
      (justify bottom)
    )
    (layer "User.6")
    (uuid "5d58ac6d-61f3-4cd3-8ea6-7a1e7368063c")
  )
  (
    fp_text
    user
    "Protected"
    (at 10.0 39.0 90)
    (
      effects
      (
        font
        (size 2 2)
        (thickness 0.1)
      )
      (justify top)
    )
    (layer "User.6")
    (uuid "56d896f6-0923-4ee7-b316-08a98d891e7b")
  )
)

The OpenSCAD code

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

module BatteryHolder_Cylindrical(diameter, length) {
    length = length/10 + 1;
    border = 3.5;
    bs = 1;
    grip=12;
    difference() {
        union() {
            difference() {
                cube([diameter+(2*bs), length+(2*border), diameter/2]);

                rotate([-90, 0, 0])
                translate([diameter/2+bs, -(diameter/2), border])
                cylinder(length, diameter/2, diameter/2);
            }

            translate([diameter/2+bs, 0, diameter/2])
            rotate([-90, 0, 0])
            cylinder(border, diameter/2, diameter/2);

            translate([diameter/2+bs, length+border, diameter/2])
            rotate([-90, 0, 0])
            cylinder(border, diameter/2, diameter/2);
        }

        translate([0, -0.005, diameter*0.75])
            cube([diameter+(2*bs), length+(2*border)+0.01, diameter/2]);

        translate([diameter/2+bs, border/2, diameter])
            cube([diameter*0.75, border/2, diameter*1.7], center=true);

        translate([diameter/2+bs, border/2+length+border, diameter])
            cube([diameter*0.75, border/2, diameter*1.7], center=true);

        translate([diameter/2+bs, 0, diameter*0.75])
            cube([1, border, diameter*1.7], center=true);
        translate([diameter/2+bs, length+border*2, diameter*0.75])
            cube([1, border, diameter*1.7], center=true);

        translate([diameter/2+bs, length/2+border, diameter/2-1])
            cube([diameter+border, length-(grip*2), diameter], center=true);

        translate([diameter/2+bs, border+(grip/2)-0.6, diameter/2-1])
            cube([diameter, grip-1.2, diameter], center=true);

        translate([diameter/2+bs, border-(grip/2)+1.2 + length, diameter/2-1])
            cube([diameter, grip-1.2, diameter], center=true);
    }
}