pacman-ghost: initial upstream version
authorClinton Ebadi <clinton@unknownlamer.org>
Sun, 20 Oct 2019 20:55:53 +0000 (16:55 -0400)
committerClinton Ebadi <clinton@unknownlamer.org>
Sun, 20 Oct 2019 21:01:44 +0000 (17:01 -0400)
Code is Copyright (c) 2015 Joao Alves, licensed under Creative Commons
Attribute-ShareAlike 3.0 Unported

pacman-ghost/pacman-ghost.scad [new file with mode: 0644]
pacman-ghost/pacman-ghost_attribution_card.html [new file with mode: 0644]

diff --git a/pacman-ghost/pacman-ghost.scad b/pacman-ghost/pacman-ghost.scad
new file mode 100644 (file)
index 0000000..5c17fd9
--- /dev/null
@@ -0,0 +1,53 @@
+//
+// Pacman Ghost
+// ------------
+//
+// Created by Joao Alves (jpralves@gmail.com)
+// ------------------------------------------
+//
+// Parameters:
+
+
+// Figure diameter
+diameter = 25; // [25:5:100]
+
+height = diameter*0.65; 
+// Add keychain
+key_chain = 0; // [1:On, 0:Off]
+// Add LED hole
+led_Hole = 0; // [0:Off, 5:5mm, 8:8mm, 10:10mm]
+
+// Detail
+$fn=100; // [20:Low Res, 50:Normal Res, 100:Hi Res]
+
+rotate([0,0,-90])
+difference() {
+  union() {
+    cylinder(d = diameter, h = height);
+    translate([0, 0, height]) sphere(d = diameter);
+    if (key_chain == 1) {
+      translate([0, 0, height+diameter/2])
+        rotate([0, 90, 0])
+          rotate_extrude()
+            translate([4, 0, 0])
+              circle(r = 1.5);
+    }
+  }
+  translate([diameter/2, -diameter/4, height])
+    sphere(d = diameter/3.5);
+  translate([diameter/2, diameter/4, height])
+    sphere(d = diameter/3.5);
+  translate([0, 0, -0.1]) 
+    for(a = [0:11]) {
+      rotate([a/12*360,-90,0]) 
+        scale([1.5,1,1])
+          translate([0,0,diameter/12.5]) 
+            cylinder(diameter, 0,diameter/25*6.5, $fn=4);
+    }
+  if (led_Hole > 0) {
+    union() {
+      cylinder(d = led_Hole+2, h = height-(led_Hole+2));
+      translate([0, 0, height-(led_Hole+2)]) sphere(d = led_Hole+2);
+    }
+  }
+}
\ No newline at end of file
diff --git a/pacman-ghost/pacman-ghost_attribution_card.html b/pacman-ghost/pacman-ghost_attribution_card.html
new file mode 100644 (file)
index 0000000..94db1ef
--- /dev/null
@@ -0,0 +1,42 @@
+<!-- from http://www.thingiverse.com/thing:8174 by whosawhatsis, used with permission -->
+<style type="text/css">
+#tagback {padding: 50px;background: white;}
+.tag {position: relative;border: 1px solid #eeeeee;width: 450px;height: 150px;margin: 0px;padding: 10px 10px 10px 120px;}
+.tag .qrcode-sidebar {float: right;margin: 0px;padding: 0px;}
+.tag a {color: black;text-decoration: none;}
+.tag h1 {font: bold 18px Arial,sans-serif;margin: 0px;padding: 0px; word-wrap: break-word; max-height: 2.25em; overflow: hidden;}
+.tag h2 {font: 14px Arial,sans-serif;margin: 0px;padding: 0px;}
+.tag h3 {font: 12px Courier,monospace;margin: 0px;padding: 0px;}
+.tag h4 {font: 9px Arial,sans-serif;position: absolute;bottom: 0px;left: 0px;margin: 0px 150px 0px 0px;padding: 0px;}
+.tag h4 div {float: left;margin: 0px 5px 15px 125px;height: 40px;}
+.tag h4 div img {height: 40px;}
+</style>
+
+<div id="tagback"><div class="tag">
+        <div class="qrcode-sidebar">
+            <img src="//chart.apis.google.com/chart?chs=150x150&cht=qr&chl=thingiverse.com/thing:1073112&choe=UTF-8&chld=Q|1">
+        </div>
+        <h1>Customizable Pacman Ghost by jpralves</h1>
+        <h2>Published on October 15, 2015</h2>
+        <h3>www.thingiverse.com/thing:1073112</h3>
+        <h4>
+                                                                                                                                                <div class="row-fluid cc-licenses">
+                                            <span class="span4">
+                            <img src="https://cdn.thingiverse.com/site/img/cc/chooser_cc.png" />
+                        </span>
+                                            <span class="span4">
+                            <img src="https://cdn.thingiverse.com/site/img/cc/chooser_by.png" />
+                        </span>
+                                            <span class="span4">
+                            <img src="https://cdn.thingiverse.com/site/img/cc/chooser_sa.png" />
+                        </span>
+                                    </div>
+                    Creative Commons - Attribution - Share Alike<br /></h4>
+</div></div>
+
+<script>
+// TODO
+window.onload = function(){
+    document.getElementById('tagback').appendChild(document.getElementById('tagback').firstChild.cloneNode(true));
+};
+</script>