Skip to content

Instantly share code, notes, and snippets.

@fincham
Created May 26, 2019 05:37
Show Gist options
  • Save fincham/4f3dbb1e08e5fd4de5d75bba24324dda to your computer and use it in GitHub Desktop.
Save fincham/4f3dbb1e08e5fd4de5d75bba24324dda to your computer and use it in GitHub Desktop.
/* iris case drawings extracted from https://github.com/keebio/iris-case/blob/master/iris-middle-layer.ai */
module big_bit()
polygon(
points=
[[-22.994, 69.899], [-23.172, 69.887], [-35.425, 68.14], [-48.485, 65.728], [-62.39, 62.645], [-77.177, 58.885], [-78.362, 58.566], [-79.547, 58.247], [-80.508, 57.808], [-81.258, 57.102], [-81.745, 56.195], [-81.918, 55.154], [-81.918, 11.647], [-81.918, -31.861], [-81.667, -33.107], [-80.98, -34.125], [-79.962, -34.811], [-78.715, -35.063], [-46.701, -35.063], [-14.687, -35.063], [-13.44, -35.315], [-12.423, -36.001], [-11.737, -37.019], [-11.485, -38.265], [-11.485, -45.008], [-11.485, -51.75], [-11.28, -52.88], [-10.711, -53.838], [-9.849, -54.544], [-8.764, -54.917], [-7.402, -55.124], [-6.04, -55.331], [-0.743, -56.045], [4.513, -56.648], [14.599, -57.894], [25.088, -59.913], [30.557, -61.448], [36.215, -63.459], [42.09, -66.041], [48.212, -69.287], [49.599, -70.087], [50.987, -70.888], [51.763, -71.209], [52.588, -71.317], [53.005, -71.29], [53.418, -71.208], [54.538, -70.654], [55.363, -69.715], [68.426, -47.065], [81.489, -24.416], [81.894, -23.21], [81.809, -21.986], [81.27, -20.882], [80.316, -20.041], [78.93, -19.241], [77.544, -18.441], [68.922, -13.297], [62.233, -8.808], [60.955, -8.531], [59.895, -9.3], [58.293, -12.074], [58.111, -13.204], [58.729, -14.167], [65.027, -18.417], [72.5, -22.921], [73.132, -23.483], [73.49, -24.217], [73.547, -25.032], [73.277, -25.833], [62.872, -43.873], [52.468, -61.912], [51.917, -62.54], [51.193, -62.899], [50.388, -62.964], [49.591, -62.711], [42.028, -58.949], [34.824, -56.106], [27.937, -54.02], [21.325, -52.529], [8.755, -50.681], [-3.226, -49.265], [-4.55, -48.553], [-5.079, -47.147], [-5.079, -38.968], [-5.079, -30.789], [-5.247, -29.959], [-5.704, -29.281], [-6.381, -28.825], [-7.211, -28.657], [-40.296, -28.657], [-73.381, -28.657], [-74.211, -28.49], [-74.888, -28.033], [-75.345, -27.355], [-75.513, -26.526], [-75.513, 12.265], [-75.513, 51.055], [-75.07, 52.359], [-73.924, 53.124], [-60.314, 56.558], [-46.981, 59.506], [-34.71, 61.776], [-22.784, 63.491], [-21.775, 64.017], [-21.371, 65.08], [-21.371, 65.976], [-21.371, 68.294], [-21.913, 69.495], [-25.951, 67.335], [-25.216, 67.031], [-24.911, 66.296], [-25.216, 65.561], [-25.951, 65.256], [-26.685, 65.561], [-26.99, 66.296], [-26.685, 67.031], [-77.96, 55.815], [-77.225, 55.511], [-76.92, 54.777], [-77.225, 54.042], [-77.96, 53.737], [-78.694, 54.042], [-78.998, 54.777], [-78.694, 55.511], [62.728, -12.043], [63.463, -12.348], [63.768, -13.083], [63.463, -13.818], [62.728, -14.122], [61.993, -13.818], [61.689, -13.083], [61.993, -12.348], [77.424, -22.135], [78.158, -22.439], [78.463, -23.174], [78.158, -23.909], [77.424, -24.214], [76.689, -23.909], [76.384, -23.174], [76.689, -22.439], [-77.748, -29.895], [-77.013, -30.2], [-76.708, -30.935], [-77.013, -31.669], [-77.748, -31.974], [-78.482, -31.669], [-78.787, -30.935], [-78.482, -30.2], [-7.526, -50.038], [-6.791, -50.343], [-6.487, -51.078], [-6.791, -51.813], [-7.526, -52.117], [-8.261, -51.813], [-8.566, -51.078], [-8.261, -50.343], [52.29, -65.795], [53.025, -66.099], [53.33, -66.834], [53.025, -67.569], [52.29, -67.873], [51.555, -67.569], [51.251, -66.834], [51.555, -66.099]],
paths=
[[0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30, 31, 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 43, 44, 45, 46, 47, 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, 62, 63, 64, 65, 66, 67, 68, 69, 70, 71, 72, 73, 74, 75, 76, 77, 78, 79, 80, 81, 82, 83, 84, 85, 86, 87, 88, 89, 90, 91, 92, 93, 94, 95, 96, 97, 98, 99, 100, 101, 102, 103, 104, 105, 106, 107, 0, 0], [108, 109, 110, 111, 112, 113, 114, 115, 108, 108], [116, 117, 118, 119, 120, 121, 122, 123, 116, 116], [124, 125, 126, 127, 128, 129, 130, 131, 124, 124], [132, 133, 134, 135, 136, 137, 138, 139, 132, 132], [140, 141, 142, 143, 144, 145, 146, 147, 140, 140], [148, 149, 150, 151, 152, 153, 154, 155, 148, 148], [156, 157, 158, 159, 160, 161, 162, 163, 156, 156]]
);
module small_bit()
polygon(
points=
[[24.369, 69.409], [23.294, 68.925], [22.843, 67.812], [22.843, 66.474], [22.843, 64.543], [23.213, 63.524], [24.149, 62.973], [29.498, 61.781], [34.644, 60.294], [40.153, 58.267], [45.385, 55.842], [46.217, 55.06], [46.521, 53.956], [46.521, 29.175], [46.521, 4.394], [46.723, 1.764], [47.32, -0.728], [47.857, -1.499], [48.673, -1.823], [49.539, -1.676], [50.224, -1.034], [52.719, 3.287], [52.932, 4.119], [52.927, 4.394], [52.927, 30.771], [52.927, 57.148], [52.476, 58.787], [51.25, 59.964], [50.412, 60.419], [49.573, 60.873], [43.507, 63.812], [37.042, 66.265], [31.928, 67.787], [26.573, 69.042], [24.732, 69.383], [27.305, 66.662], [28.04, 66.358], [28.344, 65.623], [28.04, 64.888], [27.305, 64.584], [26.57, 64.888], [26.266, 65.623], [26.57, 66.358], [49.253, 57.923], [49.988, 57.618], [50.293, 56.883], [49.988, 56.148], [49.253, 55.844], [48.518, 56.148], [48.214, 56.883], [48.518, 57.618], [49.724, 6.694], [50.459, 6.39], [50.764, 5.655], [50.459, 4.92], [49.724, 4.616], [48.989, 4.92], [48.685, 5.655], [48.989, 6.39]],
paths=
[[0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30, 31, 32, 33, 34, 0, 0], [35, 36, 37, 38, 39, 40, 41, 42, 35, 35], [43, 44, 45, 46, 47, 48, 49, 50, 43, 43], [51, 52, 53, 54, 55, 56, 57, 58, 51, 51]]
);
scale([0.938, 0.938, 0.938]) /* something went wrong somewhere and this global scaling is needed to match the real world :( */
difference() {
translate([0, 0, 2.5])
scale([1, 1, 0.83])
rotate([0, -2.3, 0]) {
linear_extrude(height = 13, center=true) {
big_bit();
small_bit();
}
}
/* slice the bottom off */
translate([-100, -100, -15])
cube([200, 200, 15]);
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment