From d42f99e43747db0aef5ca65ec827b3387c7af2f7 Mon Sep 17 00:00:00 2001 From: Chris Palmer Date: Mon, 6 Apr 2020 10:27:17 +0100 Subject: [PATCH] stl_colour() now used in tests and examples. --- docs/usage.md | 2 +- tests/BOM.scad | 2 +- tests/cable_grommets.scad | 4 ++-- tests/carriers.scad | 6 +++--- tests/fan_guard.scad | 2 +- tests/inserts.scad | 2 +- tests/light_strips.scad | 2 +- tests/polyholes.scad | 4 ++-- tests/printed_box.scad | 4 ++-- tests/teardrops.scad | 2 +- tests/wire.scad | 2 +- 11 files changed, 16 insertions(+), 16 deletions(-) diff --git a/docs/usage.md b/docs/usage.md index fce9ebe..d03f6db 100644 --- a/docs/usage.md +++ b/docs/usage.md @@ -164,7 +164,7 @@ This is achieved by having a pair of modules: - module handle_assembly() pose([225, 0, 150], [0, 0, 14]) //! Printed part with inserts in place assembly("handle") { translate_z(handle_height()) - color(pp1_colour) vflip() handle_stl(); + stl_colour(pp1_colour) vflip() handle_stl(); handle_screw_positions() vflip() diff --git a/tests/BOM.scad b/tests/BOM.scad index 19568c3..99335be 100644 --- a/tests/BOM.scad +++ b/tests/BOM.scad @@ -67,7 +67,7 @@ module widgit_dxf() { //! * Push the insert into the base with a soldering iron heated to 200°C module widgit_base_assembly() assembly("widgit_base") { - color(pp1_colour) + stl_colour(pp1_colour) widgit_stl(); translate_z(height) diff --git a/tests/cable_grommets.scad b/tests/cable_grommets.scad index 6c45d58..14dbe2c 100644 --- a/tests/cable_grommets.scad +++ b/tests/cable_grommets.scad @@ -22,14 +22,14 @@ use <../printed/cable_grommets.scad> module cable_grommets() { rotate(90) - color(pp1_colour) ribbon_grommet(20, 3); + stl_colour(pp1_colour) ribbon_grommet(20, 3); translate([20, 0]) round_grommet_assembly(6, 3); translate([40, 0]) rotate(90) - color(pp1_colour) mouse_grommet(5, 3); + stl_colour(pp1_colour) mouse_grommet(5, 3); } if($preview) diff --git a/tests/carriers.scad b/tests/carriers.scad index faed537..1cebf2b 100644 --- a/tests/carriers.scad +++ b/tests/carriers.scad @@ -20,15 +20,15 @@ include <../utils/core/core.scad> use <../printed/carriers.scad> module carriers() { - color(pp1_colour) ESP12F_carrier_stl(); + stl_colour(pp1_colour) ESP12F_carrier_stl(); translate([0, 15]) rotate(90) - color(pp1_colour) TP4056_carrier_stl(); + stl_colour(pp1_colour) TP4056_carrier_stl(); translate([0, 25]) rotate(90) - color(pp1_colour) MT3608_carrier_stl(); + stl_colour(pp1_colour) MT3608_carrier_stl(); } carriers(); diff --git a/tests/fan_guard.scad b/tests/fan_guard.scad index d9bd342..e35c866 100644 --- a/tests/fan_guard.scad +++ b/tests/fan_guard.scad @@ -24,6 +24,6 @@ use <../utils/layout.scad> module fan_guards() layout([for(f = fans) fan_width(f)], 10) - color(pp1_colour) fan_guard(fans[$i], spokes = fan_width(fans[$i]) > 60 ? 8 : 4); + stl_colour(pp1_colour) fan_guard(fans[$i], spokes = fan_width(fans[$i]) > 60 ? 8 : 4); fan_guards(); diff --git a/tests/inserts.scad b/tests/inserts.scad index f2fdc34..23eb39e 100644 --- a/tests/inserts.scad +++ b/tests/inserts.scad @@ -27,7 +27,7 @@ module inserts() { translate([10 * i, 0]) insert(inserts[i]); - color(pp1_colour) + stl_colour(pp1_colour) translate([len(inserts) * 10, 0]) { insert_lug(inserts[0], 2, 1); diff --git a/tests/light_strips.scad b/tests/light_strips.scad index 58d4e3c..87a8b7c 100644 --- a/tests/light_strips.scad +++ b/tests/light_strips.scad @@ -29,7 +29,7 @@ module light_strips() for(end = [-1, 1]) translate([end * (light_strip_cut_length(light, segs) / 2 - d / 2), 0]) rotate([90, 0, 90]) - color(pp1_colour) render() + stl_colour(pp1_colour) render() translate_z(-d / 2) light_strip_clip(light); } diff --git a/tests/polyholes.scad b/tests/polyholes.scad index a0a7e11..19f66ac 100644 --- a/tests/polyholes.scad +++ b/tests/polyholes.scad @@ -34,7 +34,7 @@ module polyholes() { children(); } - color(pp1_colour) linear_extrude(3, center = true) + stl_colour(pp1_colour) linear_extrude(3, center = true) difference() { square([100, 27]); @@ -52,7 +52,7 @@ module polyholes() { sizes = [1.5, 2, 3, 4]; for(i = [0 : len(sizes) - 1]) translate([i * 10, -10]) { - color(pp1_colour) + stl_colour(pp1_colour) poly_tube(ir = ir, or = cir + sizes[i] * extrusion_width, h = 1); rod(2 * ir, 3); diff --git a/tests/printed_box.scad b/tests/printed_box.scad index a0f63d3..3434b78 100644 --- a/tests/printed_box.scad +++ b/tests/printed_box.scad @@ -93,7 +93,7 @@ module box1_base_stl() module box1_assembly() assembly("box1") { - color(pp1_colour) render() box1_case_stl(); + stl_colour(pp1_colour) render() box1_case_stl(); pbox_inserts(box1); @@ -142,7 +142,7 @@ module box2_base_stl() module box2_assembly() assembly("box2") { - color(pp1_colour) render() box2_case_stl(); + stl_colour(pp1_colour) render() box2_case_stl(); pbox_inserts(box2); diff --git a/tests/teardrops.scad b/tests/teardrops.scad index ffe9d75..211aaf6 100644 --- a/tests/teardrops.scad +++ b/tests/teardrops.scad @@ -20,7 +20,7 @@ include <../utils/core/core.scad> module teardrops() { - color(pp1_colour) + stl_colour(pp1_colour) rotate([90, 0, -45]) difference() { linear_extrude(3) { diff --git a/tests/wire.scad b/tests/wire.scad index da8dbdc..a499710 100644 --- a/tests/wire.scad +++ b/tests/wire.scad @@ -54,7 +54,7 @@ module wires() { %cylinder(r = bundle_r, h = wire_l - 10, center = true); } - color(pp1_colour) { + stl_colour(pp1_colour) { rotate([90, 0, 90]) linear_extrude(thickness) difference() {