├── .gitmodules ├── README.md ├── examples.scad └── bottle-clip.scad /.gitmodules: -------------------------------------------------------------------------------- 1 | [submodule "thing-logos"] 2 | path = thing-logos 3 | url = https://github.com/rohieb/thing-logos.git 4 | [submodule "write"] 5 | path = write 6 | url = https://github.com/rohieb/Write.scad.git 7 | -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | Bottle clip with name and logo 2 | ============================== 3 | 4 | This thing is a simple clip with your name on it which can be used to mark your 5 | bottles. 6 | 7 | The clip is customizable and you can tweak the following parameters: 8 | 9 | * name on the clip, font, and optional, logo. 10 | * height and radius on the upper and lower side, for easy adaptation to other 11 | bottle types. The script includes examples for standard 0.5l Club Mate (and 12 | similar) bottles as well as 0.33l longneck bottles and German 0.33l DIN 6199 13 | (“Steinie”) beer bottles. 14 | * wall thickness (though the default should be okay for easy clipping) 15 | 16 | 17 | Instructions 18 | ------------ 19 | 20 | First, get all prerequisites. If you cloned this repository with Git, all you 21 | have to do is `cd` into the repository and do a `git submodule init && git 22 | submodule update`. Otherwise, you need the following: 23 | 24 | * [Write.scad][thing16193] and at least one font, put it into the `write/` 25 | subfolder 26 | * If you want a logo on your name tag, draw a DXF file by yourself, or choose 27 | one out of my collection at rohieb/thing-logos. Your own logos should be no 28 | more than 50mm in height, and centered on point (25,25) for optimal results. 29 | 30 | Then open `example.scad` in OpenSCAD, read it, choose an example that matches 31 | your expectations, comment it out (remove the `//` on the beginning of the 32 | line) and adapt it to your needs, or create your own. The code itself resides 33 | in `bottle-clip.scad` and should be documented sufficiently. 34 | 35 | [thing16193]: http://thingiverse.com/thing:16193 36 | 37 | Ancestry and Licence 38 | --------------- 39 | 40 | The [original design][thing888] was made by Thingiverse user 41 | [wizard23][wizard23] under [CC-BY-NC-3.0][ccbync30]. [daniel][daniel] first put 42 | the [text][thing18978] and then the [logo][thing23817] on it, both his designs 43 | were [CC-BY-SA-3.0][ccbysa30]. In the direct consequence, the design in this 44 | repo is also [CC-BY-SA-3.0][ccbysa30]. 45 | 46 | [thing888]: http://www.thingiverse.com/thing:888 47 | [wizard23]: http://www.thingiverse.com/wizard23 48 | [daniel]: http://www.thingiverse.com/daniel 49 | [thing18978]: http://www.thingiverse.com/thing:18978 50 | [thing23817]: http://www.thingiverse.com/thing:23817 51 | [ccbync30]: https://creativecommons.org/licenses/by-nc/3.0/ 52 | [ccbysa30]: https://creativecommons.org/licenses/by-sa/3.0/ 53 | 54 | // vim: set et ts=2 sw=2 tw=0: 55 | -------------------------------------------------------------------------------- /examples.scad: -------------------------------------------------------------------------------- 1 | /* 2 | * Examples for bottle clip name tags. 3 | * Copyright (C) 2013 Roland Hieber 4 | * 5 | * You can simply comment out one of the examples, adapt it to your needs and 6 | * render it, or use it to build your own variant. 7 | * 8 | * The contents of this file are licenced under CC-BY-SA 3.0 Unported. 9 | * See https://creativecommons.org/licenses/by-sa/3.0/deed for the 10 | * licensing terms. 11 | */ 12 | 13 | /* 14 | * Set the color to render and export. 15 | * ALL will render all colors. 16 | */ 17 | //CURRENT_COLOR = "ALL"; 18 | //CURRENT_COLOR = "black"; 19 | //CURRENT_COLOR = "green"; 20 | 21 | include 22 | 23 | $fn=50; // approximation steps for the cylinders 24 | 25 | // one name tag for 0.5l Club Mate and similar bottles 26 | bottle_clip(name="Zero Cool"); 27 | 28 | // one default name tag with a different logo. 29 | //bottle_clip(name="Acid Burn", logo="thing-logos/glider.dxf"); 30 | 31 | // ...or with a different font: 32 | //bottle_clip(name="Acid Burn", font="write/Letters.dxf"); 33 | // ...or with a differnet logo and a different font... you get it. 34 | 35 | // ...or with a different gap angle of 45 instead of 90 degrees: 36 | //bottle_clip(name="Crash Override", gap=45); 37 | 38 | // Now for something completely different: Longneck bottles. 39 | //bottle_clip_longneck(name="Tom Anderson", logo="thing-logos/glider.dxf"); 40 | 41 | // ...or DIN 6199 ("Steinie") beer bottles. Note that these have no logo. 42 | //bottle_clip_steinie(name="ohbier"); 43 | 44 | // without logo, half the height. this is useable with both 45 | // NRW-bottles and Euro-bottles (shorter 0.5l bottles, 46 | // especially beer bottles in bavaria) 47 | //bottle_clip(name="ohbier", logo="", rl=31/2, ru=27/2, ht=13.1); 48 | 49 | // without logo, half the height, for weissbier glasses 50 | //bottle_clip(name="ohbier", logo="", rl=48/2, ru=48/2, ht=13.1); 51 | 52 | // without logo, for glass "masskrug" handle. 53 | // oval shape: d1=21mm, d2=18mm 54 | //scale([18/21,1,1]) rotate(-45) bottle_clip(name="ohbier", logo="", rl=21/2, ru=21/2, ht=13.1); 55 | 56 | // ...or just do your own variant: Measure the diameter of your bottle at two 57 | // different heights, and pass those as parameters rl (lower radius), ru 58 | // (upper radius) and ht (height) to the bottle_clip() module. You can also 59 | // use the other parameters from above, if you set logo="", then only the text 60 | // is rendered. 61 | //bottle_clip(name="Niobe", rl=15, ru=12, ht=16, logo=""); 62 | 63 | // With color: 64 | //bottle_clip(name="Zero Cool", bg_color="black", text_color="green", logo_color="green"); 65 | 66 | // vim: set noet ts=2 sw=2 tw=80: 67 | -------------------------------------------------------------------------------- /bottle-clip.scad: -------------------------------------------------------------------------------- 1 | /** 2 | * A name tag that can easily be clipped to the neck of your bottle. 3 | * Copyright (C) 2013 Roland Hieber 4 | * 5 | * See examples.scad for examples on how to use this module. 6 | * 7 | * The contents of this file are licenced under CC-BY-SA 3.0 Unported. 8 | * See https://creativecommons.org/licenses/by-sa/3.0/deed for the 9 | * licensing terms. 10 | */ 11 | 12 | include 13 | 14 | /** 15 | * Module for multi colored print. 16 | * All children are the given color. 17 | * Using the global CURRENT_COLOR it is possible to only render and export everything of one color. 18 | * Doing this for all colors the resulting stls can be put together again to a multi filament print in the slicer. 19 | * If CURRENT_COLOR is set to "ALL" all colors are displayed. 20 | * If color is "DEFAULT", it is not colored in the preview. 21 | * Inspired by https://erik.nygren.org/2018-3dprint-multicolor-openscad.html 22 | */ 23 | module multicolor(color) { 24 | if (is_undef(CURRENT_COLOR) || CURRENT_COLOR == "ALL" || CURRENT_COLOR == color) { 25 | if (color != "DEFAULT") { 26 | color(color) children(); 27 | } else { 28 | children(); 29 | } 30 | } 31 | } 32 | 33 | /** 34 | * Creates one instance of a bottle clip name tag. The default values are 35 | * suitable for 0.5l Club Mate bottles (and similar bottles). By default, logo 36 | * and text are placed on the name tag so they both share half the height. If 37 | * there is no logo, the text uses the total height instead. 38 | * Parameters: 39 | * ru: the radius on the upper side of the clip 40 | * rl: the radius on the lower side of the clip 41 | * ht: the height of the clip 42 | * width: the thickness of the wall. Values near 2.5 usually result in a good 43 | * clippiness for PLA prints. 44 | * name: the name that is printed on your name tag. For the default ru/rt/ht 45 | * values, this string should not exceed 18 characters to fit on the name tag. 46 | * gap: width of the opening gap, in degrees. For rigid materials this value 47 | * usually needs to be near 180 (but if you set it to >= 180, you won't have 48 | * anything left for holding the clip on the bottle). For flexible materials 49 | * like Ninjaflex, choose something near 0. For springy materials like PLA or 50 | * ABS, 90 has proven to be a good value. 51 | * logo: the path to a DXF file representing a logo that should be put above 52 | * the name. Logo files should be no larger than 50 units in height and should 53 | * be centered on the point (25,25). Also all units in the DXF file should be 54 | * in mm. This parameter can be empty; in this case, the text uses the total 55 | * height of the name tag. 56 | * font: the path to a font for Write.scad. 57 | * bg_color: The color of the background (the clip itself) 58 | * text_color: The color of the text 59 | * logo_color: The color of the logo 60 | */ 61 | module bottle_clip(ru=13, rl=17.5, ht=26, width=2.5, name="", gap=90, 62 | logo="thing-logos/stratum0-lowres.dxf", font="write/orbitron.dxf", 63 | bg_color="DEFAULT", text_color="DEFAULT", logo_color="DEFAULT") { 64 | 65 | e=100; // should be big enough, used for the outer boundary of the text/logo 66 | difference() { 67 | rotate([0,0,-45]) union() { 68 | // main cylinder 69 | multicolor(bg_color) cylinder(r1=rl+width, r2=ru+width, h=ht); 70 | // text and logo 71 | if(logo == "") { 72 | multicolor(text_color) writecylinder(name, [0,0,3], rl+0.5, ht/13*7, h=ht/13*8, t=max(rl,ru), 73 | font=font); 74 | } else { 75 | multicolor(text_color) writecylinder(name, [0,0,0], rl+0.5, ht/13*7, h=ht/13*4, t=max(rl,ru), 76 | font=font); 77 | multicolor(logo_color) translate([0,0,ht*3/4-0.1]) 78 | rotate([90,0,0]) 79 | scale([ht/100,ht/100,1]) 80 | translate([-25,-25,0.5]) 81 | linear_extrude(height=max(ru,rl)*2) 82 | import(logo); 83 | } 84 | } 85 | // inner cylinder which is substracted 86 | translate([0,0,-1]) 87 | cylinder(r1=rl, r2=ru, h=ht+2); 88 | // outer cylinder which is substracted, so the text and the logo end 89 | // somewhere on the outside ;-) 90 | difference () { 91 | cylinder(r1=rl+e, r2=ru+e, h=ht); 92 | translate([0,0,-1]) 93 | // Note: bottom edges of characters are hard to print when character 94 | // depth is > 0.7 95 | cylinder(r1=rl+width+0.7, r2=ru+width+0.7, h=ht+2); 96 | } 97 | 98 | // finally, substract an equilateral triangle as a gap so we can clip it to 99 | // the bottle 100 | gap_x=50*sin(45-gap/2); 101 | gap_y=50*cos(45-gap/2); 102 | translate([0,0,-1]) 103 | linear_extrude(height=50) 104 | polygon(points=[[0,0], [gap_x, gap_y], [50,50], [gap_y, gap_x]]); 105 | } 106 | } 107 | 108 | /** 109 | * Creates one instance of a bottle clip name tag suitable for 0.33l longneck 110 | * bottles (like fritz cola, etc.). All parameters are passed to the module 111 | * bottle_clip(), see there for their documentation. 112 | */ 113 | module bottle_clip_longneck(name="", width=2.5, gap=90, 114 | logo="thing-logos/stratum0-lowres.dxf", font="write/orbitron.dxf", 115 | bg_color="DEFAULT", text_color="DEFAULT", logo_color="DEFAULT") { 116 | bottle_clip(name=name, ru=13, rl=15, ht=26, width=width, logo=logo, gap=gap, 117 | font=font, bg_color=bg_color, text_color=text_color, logo_color=logo_color); 118 | } 119 | 120 | /** 121 | * Creates one instance of a bottle clip name tag suitable for 0.33l DIN 6199 122 | * beer bottles (also known as "Steinie", "Stubbi", "Knolle", etc.). Because of 123 | * reasons, there is no logo, but all other parameters are passed to the module 124 | * bottle_clip(), see there for their documentation. 125 | */ 126 | module bottle_clip_steinie(name="", width=2.5, gap=90, font="write/orbitron.dxf", 127 | bg_color="DEFAULT", text_color="DEFAULT", logo_color="DEFAULT") { 128 | bottle_clip(name=name, ru=13, rl=17.5, ht=13, width=width, logo="", gap=gap, 129 | font=font, bg_color=bg_color, text_color=text_color, logo_color=logo_color); 130 | } 131 | 132 | /* 133 | * Create one instance of a bottle clip name tag suitable for 0.5l DIN 6198 134 | * bottle (also known as "Euroflasche" or "Euroform 2"). All parameters are 135 | * passed to the module bottle_clip(), see there for their documentation. 136 | */ 137 | module bottle_clip_euro2(name="", width=2.5, gap=90, 138 | logo="thing-logos/stratum0-lowres.dxf", font="write/orbitron.dxf", 139 | bg_color="DEFAULT", text_color="DEFAULT", logo_color="DEFAULT") { 140 | bottle_clip(name=name, ru=13, rl=22.5, ht=26, width=width, logo=logo, gap=gap, 141 | font=font, bg_color=bg_color, text_color=text_color, logo_color=logo_color); 142 | } 143 | 144 | // vim: set noet ts=2 sw=2 tw=80: 145 | --------------------------------------------------------------------------------