chiark / gitweb /
air-hockey-puck: wip
[reprap-play.git] / treefoil.scad.pl
index 160c175ddda7c8e0a712f75a955b37c62d12be0e..ef9ef2614c83c9f25ad4e79c8080e8dc479ee7a5 100755 (executable)
@@ -1,5 +1,8 @@
 #!/usr/bin/perl -w
 
+# Use:
+#   - support X/Y dist 0.5mm
+
 use strict;
 
 our $shape = <<'END';
@@ -7,6 +10,12 @@ xyyZZYYXYxxyzYYZXzzxyXXYXXXZxxxyyXXZyyyzXXzz
 zxxYYXXZXzzxyXXYZyyzxZZXZZZYzzzxxZZYxxxyZZyy
 yzzXXZZYZyyzxZZXYxxyzYYZYYYXyyyzzYYXzzzxYYxx
 END
+# simple version (unknotted, [0,1,2]^3):
+# YxxyzYYZXzzxyXXYZyyzxZZX
+#
+# New and less symmetric one that also fits in the 2x2x2 box:
+# YXXyzzYxYXZZxzyxYzyyZXZx
+# (email 8.9.2022)
 
 sub o { print @_ or die $!; }
 
@@ -37,8 +46,9 @@ while (<DATA>) { o $_ }
 
 __DATA__
 
-thick = 10;
-edgeu = 20;
+thick = 6;
+edgeu = 10;
+//edgeu = 15;
 
 // calculated
 
@@ -54,6 +64,16 @@ module OctaThing() {
     }
 }
 
-OctaThing();
+module TraceEdge(p,q) {
+    hull(){
+        for (x=[p,q]) {
+            translate(x * edgeu)
+                OctaThing();
+        }
+    }
+}
+
+rotate([0,0,45])
+  Trace();