1
0
mirror of https://github.com/nophead/Mendel90.git synced 2025-08-06 05:17:26 +02:00

Fixed some assembly views so they work for Huxley.

Idler lever added to Huxley extruder.
Extruders now virtual.
views.py now allows camera to be specified using $vpt, $vpr and $vpd.
make_machine.py now does the accessories as well.
This commit is contained in:
Chris Palmer
2016-01-13 10:11:55 +00:00
parent dc154bbe2c
commit ef0406dc29
27 changed files with 2217 additions and 519 deletions

Binary file not shown.

Before

Width:  |  Height:  |  Size: 199 KiB

After

Width:  |  Height:  |  Size: 203 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 138 KiB

After

Width:  |  Height:  |  Size: 146 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 146 KiB

After

Width:  |  Height:  |  Size: 145 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 107 KiB

After

Width:  |  Height:  |  Size: 105 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 120 KiB

After

Width:  |  Height:  |  Size: 138 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 158 KiB

After

Width:  |  Height:  |  Size: 186 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 56 KiB

After

Width:  |  Height:  |  Size: 55 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 120 KiB

After

Width:  |  Height:  |  Size: 120 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 109 KiB

After

Width:  |  Height:  |  Size: 108 KiB

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

View File

@@ -5,11 +5,13 @@ from bom import boms
from sheets import sheets from sheets import sheets
from stls import stls from stls import stls
from plates import plates from plates import plates
from accessories import accessories
def make_machine(machine): def make_machine(machine):
boms(machine) boms(machine)
sheets(machine) sheets(machine)
stls(machine) stls(machine)
accessories(machine)
plates(machine) plates(machine)
if __name__ == '__main__': if __name__ == '__main__':

View File

@@ -304,21 +304,19 @@ module direct_block_stl(include_support = true) {
} }
} }
module extruder_motor_assembly(show_connector = true, exploded = exploded) { module direct_motor_assembly(show_connector = true, exploded = exploded) {
assembly("extruder_motor_assembly"); assembly("extruder_motor_assembly");
// motor and gear // motor and gear
translate([-motor_x, motor_z - width / 2, motor_y]) rotate([0, 0, 180]) {
rotate([90,0,180]) { NEMA(motor);
rotate([0, 0, 180]) {
NEMA(motor); translate([0, 0, filament_z - hobbed_offset(pulley) + exploded * 20])
rotate([0, 0, -90])
hobbed_pulley_assembly(pulley);
}
if(show_connector)
d_motor_bracket_assembly();
translate([0, 0, filament_z - hobbed_offset(pulley)])
rotate([0, 0, -90])
hobbed_pulley_assembly(pulley);
}
if(show_connector)
d_motor_bracket_assembly();
}
end("extruder_motor_assembly"); end("extruder_motor_assembly");
} }
@@ -348,7 +346,7 @@ module direct_idler_lever_stl() {
} }
} }
} }
*linear_extrude(height = h4) // release handle linear_extrude(height = h4) // release handle
hull() { hull() {
translate([idler_x - idler_pivot_x, idler_pivot_y - idler_y]) translate([idler_x - idler_pivot_x, idler_pivot_y - idler_y])
circle(w / 2 - 2); circle(w / 2 - 2);
@@ -360,9 +358,6 @@ module direct_idler_lever_stl() {
translate([0, 0, h2]) translate([0, 0, h2])
poly_cylinder(r = ball_bearing_diameter(idler) / 2 + 0.5, h = 10); // bearing socket poly_cylinder(r = ball_bearing_diameter(idler) / 2 + 0.5, h = 10); // bearing socket
*translate([idler_x - idler_pivot_x - w / 2 - 1, lever_bottom_y - idler_y - 1, h3])
cube([w + 2, 2 * (motor_y - motor_screw_offset - lever_bottom_y) + 1, 10]); // miss the bottom motor screw
rotate([0, 0, 90]) rotate([0, 0, 90])
nut_trap(2, nut_trap_radius(M4_nut, horizontal = false, snug = false), nut_trap_depth(M4_nut), supported = true); // nut trap for axle nut_trap(2, nut_trap_radius(M4_nut, horizontal = false, snug = false), nut_trap_depth(M4_nut), supported = true); // nut trap for axle
@@ -382,15 +377,16 @@ module direct_idler_lever_stl() {
} }
module direct_idler_assembly() { module direct_idler_assembly() {
translate([-idler_x, idler_z - width / 2, idler_y]) { translate([-idler_x, idler_z - width / 2 + exploded * 50, idler_y]) {
rotate([90, 0, 0]) { rotate([90, 0, 0]) {
translate([0, 0, idler_z - width]) translate([0, 0, idler_z - width])
color("lime") render() direct_idler_lever_stl(); color("lime") render() direct_idler_lever_stl();
ball_bearing(idler) explode([0, 0, 20])
screw(M4_hex_screw, 16); ball_bearing(idler)
screw(M4_hex_screw, 16);
translate([0, 0, -ball_bearing_width(idler) / 2]) translate([0, 0, -ball_bearing_width(idler) / 2 + exploded * 10])
rotate([180, 0, 0]) rotate([180, 0, 0])
washer(M4_washer); washer(M4_washer);
@@ -399,7 +395,6 @@ module direct_idler_assembly() {
nut(M4_nut, true); nut(M4_nut, true);
} }
} }
translate([-spring_x, spring_z - width / 2, spring_y]) translate([-spring_x, spring_z - width / 2, spring_y])
rotate([0, 90, 0]) rotate([0, 90, 0])
washer(M4_washer) washer(M4_washer)
@@ -429,22 +424,32 @@ module direct_assembly(show_connector = true, show_drive = true) {
screw(M4_hex_screw, 20); screw(M4_hex_screw, 20);
// motor // motor
translate([0, 0, 50 * exploded]) translate([0, -40 * exploded, 0])
extruder_motor_assembly(show_connector, 0); translate([-motor_x, motor_z - width / 2, motor_y])
rotate([90,0,180])
direct_motor_assembly(show_connector, 0);
translate([-motor_x, -width / 2 + motor_thickness, motor_y]) { // motor screws
translate([-motor_x, -width / 2 + motor_thickness, motor_y])
rotate([-90, 0, 0]) rotate([-90, 0, 0])
NEMA_screws(motor, 3, 8, M3_pan_screw); NEMA_screws(motor, 3, 8, M3_pan_screw);
}
// idler axle
translate([-idler_pivot_x, width / 2, idler_pivot_y]) translate([-idler_pivot_x, width / 2, idler_pivot_y])
rotate([-90, 0, 0]) { rotate([-90, 0, 0]) {
screw_and_washer(M3_cap_screw, 25); explode([0, 0, 50])
translate([0, 0, -(width - motor_thickness)]) screw_and_washer(M3_cap_screw, 25);
translate([0, 0, -width + motor_thickness])
explode([0, 0, 5])
washer(M3_washer) washer(M3_washer)
star_washer(M3_washer) explode([0, 0, 2])
nut(M3_nut) star_washer(M3_washer)
washer(M3_washer); explode([0, 0, 2])
} nut(M3_nut)
explode([0, 0, 2])
washer(M3_washer);
}
// //
// Filament // Filament
// //
@@ -456,10 +461,9 @@ module direct_assembly(show_connector = true, show_drive = true) {
translate([-bulkhead_x - bulkhead_depth, spring_z - width / 2, spring_y]) translate([-bulkhead_x - bulkhead_depth, spring_z - width / 2, spring_y])
rotate([0, 90, 0]) rotate([0, 90, 0])
nut(M4_nut); explode([0, 0, -5])
nut(M4_nut);
} }
// //
// Hot end // Hot end
// //
@@ -487,10 +491,8 @@ module direct_assembly(show_connector = true, show_drive = true) {
screw_and_washer(jhead_screw, jhead_screw_length, true); screw_and_washer(jhead_screw, jhead_screw_length, true);
translate([jhead_screw_pitch, 0, jhead_nut_pos - jhead_nut_slot / 2 + nut_thickness(screw_nut(jhead_screw)) / 2]) translate([jhead_screw_pitch, 0, jhead_nut_pos - jhead_nut_slot / 2 + nut_thickness(screw_nut(jhead_screw)) / 2])
explode([ [ 10 * cos(a), 10 * sin(a), 0], explode( [ 15 * sin(-a), 15 * cos(-a), 0] * [-1,1,-1,1][i])
[ 10 * sin(a), -10 * cos(a), 0], rotate([180, 0, -a + 90])
[-10 * sin(a), 10 * cos(a), 0] ][i])
rotate([180, 0, -a + 90])
nut(screw_nut(jhead_screw)); nut(screw_nut(jhead_screw));
} }
} }
@@ -508,6 +510,6 @@ module direct_extruder_stl() {
if(1) if(1)
direct_assembly(true); direct_assembly(true, true);
else else
direct_extruder_stl(); direct_extruder_stl();

26
scad/extruder.scad Normal file
View File

@@ -0,0 +1,26 @@
//
// Mendel90
//
// GNU GPL v2
// nop.head@gmail.com
// hydraraptor.blogspot.com
//
// Virual extruder
//
include <conf/config.scad>
use <wade.scad>
use <direct.scad>
function extruder_connector_offset() = extruder == Wades ? wades_extruder_connector_offset() : direct_extruder_connector_offset();
module extruder_motor_assembly(show_connector = true, exploded = exploded)
if(extruder == Wades)
wades_motor_assembly(show_connector, exploded);
else
direct_motor_assembly(show_connector, exploded);
module extruder_assembly(show_connector = true, show_drive = true)
if(extruder == Wades)
wades_assembly(show_connector, show_drive);
else
direct_assembly(show_connector, show_drive);

View File

@@ -19,7 +19,7 @@ use <z-coupling.scad>
use <z-motor-bracket.scad> use <z-motor-bracket.scad>
use <z-limit-switch-bracket.scad> use <z-limit-switch-bracket.scad>
use <fan-guard.scad> use <fan-guard.scad>
use <wade.scad> use <extruder.scad>
use <cable_clip.scad> use <cable_clip.scad>
use <pcb_spacer.scad> use <pcb_spacer.scad>
use <ATX_PSU_brackets.scad> use <ATX_PSU_brackets.scad>

View File

@@ -9,7 +9,6 @@
// //
include <conf/config.scad> include <conf/config.scad>
include <positions.scad> include <positions.scad>
use <wade.scad>
small_bearing = false; small_bearing = false;

View File

@@ -17,6 +17,7 @@ spring = false; // use two nuts or one nut and a spring
screw_depth = 5; screw_depth = 5;
motor = extruder_motor(extruder);
motor_y = 28; motor_y = 28;
driven_y = 31.5; driven_y = 31.5;
motor_min = 26 + 5; motor_min = 26 + 5;
@@ -171,10 +172,10 @@ module wades_block_stl() {
// holes for motor // holes for motor
// //
translate([motor_x, motor_y, -1]) { translate([motor_x, motor_y, -1]) {
slot(r = NEMA_big_hole(NEMA17), l = motor_leeway, h = 10, center = false); // motor hub slot slot(r = NEMA_big_hole(motor), l = motor_leeway, h = 10, center = false); // motor hub slot
for(x = NEMA_holes(NEMA17)) // motor screw slots for(x = NEMA_holes(motor)) // motor screw slots
for(y = NEMA_holes(NEMA17)) for(y = NEMA_holes(motor))
translate([x,y,0]) translate([x,y,0])
slot(r = M3_clearance_radius, l = motor_leeway, h = 10, center = false); slot(r = M3_clearance_radius, l = motor_leeway, h = 10, center = false);
} }
@@ -182,7 +183,7 @@ module wades_block_stl() {
// //
// remove fourth motor slot // remove fourth motor slot
// //
translate([motor_x - 40 + motor_leeway / 2, motor_y - NEMA_big_hole(NEMA17), -1]) translate([motor_x - 40 + motor_leeway / 2, motor_y - NEMA_big_hole(motor), -1])
cube([40, 32, 7]); cube([40, 32, 7]);
translate([motor_x - 40 + motor_leeway / 2 + 6, motor_y, -1]) translate([motor_x - 40 + motor_leeway / 2 + 6, motor_y, -1])
@@ -193,7 +194,7 @@ module wades_block_stl() {
translate([11, 0, -1]) translate([11, 0, -1])
fillet(4, 30); fillet(4, 30);
translate([11, motor_y - NEMA_big_hole(NEMA17), -1]) translate([11, motor_y - NEMA_big_hole(motor), -1])
rotate([0, 0, -90]) rotate([0, 0, -90])
fillet(4, 30); fillet(4, 30);
@@ -361,21 +362,19 @@ module wade_idler_assembly() {
} }
} }
module extruder_motor_assembly(show_connector = true, exploded = exploded) { module wades_motor_assembly(show_connector = true, exploded = exploded) {
assembly("extruder_motor_assembly"); assembly("extruder_motor_assembly");
// motor and gear // motor and gear
translate([motor_x, motor_y, thickness + eta]) rotate([0, 0, 180])
rotate([0,180,0]) { NEMA(motor);
rotate([0, 0, 180])
NEMA(NEMA17);
translate([0,0, 2.5 + 30 * exploded]) translate([0,0, 2.5 + 30 * exploded])
rotate([0, 0, 11]) rotate([0, 0, 11])
small_gear_assembly(); small_gear_assembly();
if(show_connector)
d_motor_bracket_assembly();
if(show_connector)
d_motor_bracket_assembly();
}
end("extruder_motor_assembly"); end("extruder_motor_assembly");
} }
@@ -385,133 +384,138 @@ module wades_assembly(show_connector = true, show_drive = true) {
assembly("extruder_assembly"); assembly("extruder_assembly");
color(wades_block_color) render() translate([-filament_x, width / 2, eta])
difference() { rotate([90,0,0]) {
wades_block_stl();
*translate([-1,-10, filament_z]) // cross section
cube([200,100,100]);
}
if(show_drive) { color(wades_block_color) render()
// idler screws, washers and springs difference() {
for(i = [0,1]) wades_block_stl();
translate([pscrew_x, pscrew_y[i], pscrew_z[i]]) *translate([-1,-10, filament_z]) // cross section
rotate([90, 90, 90]) { cube([200,100,100]);
screw(M4_hex_screw, pscrew_length);
translate([0,0, -pscrew_length + nut_inset])
explode([12 - 24 * i, 0, 0])
nut(M4_nut);
translate([0, 0, -spring_total + 53 * exploded]) {
washer(M4_washer)
comp_spring(extruder_spring, spring_length)
washer(M4_washer);
}
} }
// mounting screws if(show_drive) {
for(side = [-1, 1]) // idler screws, washers and springs
translate([filament_x + mount_pitch * side, base_thickness - 3, filament_z]) for(i = [0,1])
rotate([-90,0,0]) translate([pscrew_x, pscrew_y[i], pscrew_z[i]])
screw(M4_hex_screw, 20); rotate([90, 90, 90]) {
screw(M4_hex_screw, pscrew_length);
//idler translate([0,0, -pscrew_length + nut_inset])
translate([filament_x + 22 + 39 * exploded, driven_y, filament_z]) explode([12 - 24 * i, 0, 0])
rotate([90, 0, -90]) nut(M4_nut);
wade_idler_assembly();
// motor translate([0, 0, -spring_total + 53 * exploded]) {
translate([0, 0, 50 * exploded]) washer(M4_washer)
extruder_motor_assembly(show_connector, 0); comp_spring(extruder_spring, spring_length)
washer(M4_washer);
}
}
translate([motor_x, motor_y, 0]) // mounting screws
rotate([0, 180, -90]) for(side = [-1, 1])
NEMA_screws(NEMA17, 3, 10, M3_hex_screw); translate([filament_x + mount_pitch * side, base_thickness - 3, filament_z])
} rotate([-90,0,0])
screw(M4_hex_screw, 20);
// hobbed bolt and gear //idler
translate([driven_x, driven_y, 0]) { translate([filament_x + 22 + 39 * exploded, driven_y, filament_z])
translate([0, 0, width - ball_bearing_width(bearing) / 2 + (!show_drive ? exploded * 20 : 0)]) rotate([90, 0, -90])
ball_bearing(bearing); wade_idler_assembly();
translate([0, 0, ball_bearing_width(bearing) / 2 - (!show_drive ? exploded * 20 : 0)]) // motor
ball_bearing(bearing); translate([0, 0, 50 * exploded])
translate([motor_x, motor_y, thickness + eta])
rotate([0,180,0])
wades_motor_assembly(show_connector, 0);
translate([motor_x, motor_y, 0])
rotate([0, 180, -90])
NEMA_screws(motor, 3, 10, M3_hex_screw);
}
// hobbed bolt and gear
translate([driven_x, driven_y, 0]) {
translate([0, 0, width - ball_bearing_width(bearing) / 2 + (!show_drive ? exploded * 20 : 0)])
ball_bearing(bearing);
translate([0, 0, ball_bearing_width(bearing) / 2 - (!show_drive ? exploded * 20 : 0)])
ball_bearing(bearing);
if(show_drive) { if(show_drive) {
translate([0, 0, - 30 * exploded]) translate([0, 0, - 30 * exploded])
rotate([180, 0, 0]) rotate([180, 0, 0])
color(wades_gear_spacer_color) render() wades_gear_spacer_stl(); color(wades_gear_spacer_color) render() wades_gear_spacer_stl();
translate([0, 0, -spacer_length - 50 * exploded]) translate([0, 0, -spacer_length - 50 * exploded])
rotate([180, 0, 0]) rotate([180, 0, 0])
wades_big_gear_stl(); wades_big_gear_stl();
translate([0,0, -spacer_length - gear_thickness]) translate([0,0, -spacer_length - gear_thickness])
rotate([180, 0, 0]) rotate([180, 0, 0])
screw(M8_hex_screw, 60, spacer_length + gear_thickness + filament_z); screw(M8_hex_screw, 60, spacer_length + gear_thickness + filament_z);
translate([0,0, width]) { translate([0,0, width]) {
if(spring) { if(spring) {
comp_spring(hob_spring, 8); comp_spring(hob_spring, 8);
translate([0, 0, 8]) translate([0, 0, 8])
nut(M8_nut); nut(M8_nut);
} }
else explode([0, 0, 35]) group() { else explode([0, 0, 35]) group() {
translate([0, 0, -15 * exploded]) translate([0, 0, -15 * exploded])
nut(M8_nut); nut(M8_nut);
translate([0, 0, nut_thickness(M8_nut) - 10 * exploded]) { translate([0, 0, nut_thickness(M8_nut) - 10 * exploded]) {
star_washer(M8_washer); star_washer(M8_washer);
translate([0, 0, washer_thickness(M8_washer) + 5 * exploded]) translate([0, 0, washer_thickness(M8_washer) + 5 * exploded])
nut(M8_nut); nut(M8_nut);
}
}
} }
} }
} }
}
//
// Hot end
//
assembly("hot_end_assembly");
translate([filament_x, -extension, filament_z])
rotate([-90, 0, 0]) {
if(hot_end_style(hot_end) == m90)
m90_hot_end(hot_end);
if(hot_end_style(hot_end) == Stoffel)
stoffel_hot_end(hot_end);
if(hot_end_style(hot_end) == jhead)
jhead_hot_end(hot_end, exploded = 0);
}
end("hot_end_assembly");
if(!hot_end_groove_mount(hot_end))
for(side = [-1, 1])
translate([filament_x + hot_end_screw_pitch(hot_end) * side, screw_depth - extension, width])
screw(M3_cap_screw, 30);
else
translate([filament_x, -extension, filament_z])
for(i = [0:2]) {
a = i * 120 - jhead_screw_angle;
rotate([90, a, 0]) {
translate([jhead_screw_pitch, 0, 0])
washer(jhead_washer)
star_washer(screw_washer(jhead_screw))
screw(jhead_screw, jhead_screw_length);
translate([jhead_screw_pitch, 0, -extension - base_thickness - jhead_nut_slot / 2 - nut_thickness(screw_nut(jhead_screw)) / 2])
explode([ [ 10 * cos(a), 10 * sin(a), 0],
[ 10 * sin(a), -10 * cos(a), 0],
[-10 * sin(a), 10 * cos(a), 0] ][i])
rotate([0, 0, [0, 30, 30][i]])
nut(screw_nut(jhead_screw));
}
}
} }
//
// Hot end
//
assembly("hot_end_assembly");
translate([filament_x, -extension, filament_z])
rotate([-90, 0, 0]) {
if(hot_end_style(hot_end) == m90)
m90_hot_end(hot_end);
if(hot_end_style(hot_end) == Stoffel)
stoffel_hot_end(hot_end);
if(hot_end_style(hot_end) == jhead)
jhead_hot_end(hot_end, exploded = 0);
}
end("hot_end_assembly");
if(!hot_end_groove_mount(hot_end))
for(side = [-1, 1])
translate([filament_x + hot_end_screw_pitch(hot_end) * side, screw_depth - extension, width])
screw(M3_cap_screw, 30);
else
translate([filament_x, -extension, filament_z])
for(i = [0:2]) {
a = i * 120 - jhead_screw_angle;
rotate([90, a, 0]) {
translate([jhead_screw_pitch, 0, 0])
washer(jhead_washer)
star_washer(screw_washer(jhead_screw))
screw(jhead_screw, jhead_screw_length);
translate([jhead_screw_pitch, 0, -extension - base_thickness - jhead_nut_slot / 2 - nut_thickness(screw_nut(jhead_screw)) / 2])
explode([ [ 10 * cos(a), 10 * sin(a), 0],
[ 10 * sin(a), -10 * cos(a), 0],
[-10 * sin(a), 10 * cos(a), 0] ][i])
rotate([0, 0, [0, 30, 30][i]])
nut(screw_nut(jhead_screw));
}
}
end("extruder_assembly"); end("extruder_assembly");
} }
@@ -537,8 +541,7 @@ module wades_big_gear_x5_stl(){
if(1) if(1)
rotate([90, 0, 0]) wades_assembly(true);
wades_assembly(true);
else else
if(1) if(1)
wades_extruder_stl(); wades_extruder_stl();

View File

@@ -10,10 +10,7 @@
include <conf/config.scad> include <conf/config.scad>
use <bearing-holder.scad> use <bearing-holder.scad>
use <wade.scad> use <extruder.scad>
use <direct.scad>
function extruder_connector_offset() = extruder == Wades ? wades_extruder_connector_offset() : direct_extruder_connector_offset();
hole = extruder_hole(extruder); hole = extruder_hole(extruder);
width = hole[1] + 2 * bearing_holder_width(X_bearings); width = hole[1] + 2 * bearing_holder_width(X_bearings);

View File

@@ -7,19 +7,12 @@
// //
// X carriage, carries the extruder // X carriage, carries the extruder
// //
include <x-carriage.scad> include <x-carriage.scad>
module x_carriage_assembly(show_extruder = true, show_fan = true) { module x_carriage_assembly(show_extruder = true, show_fan = true) {
if(show_extruder) { if(show_extruder) {
if(extruder == Wades) rotate([0, 180, 0])
translate([75, extruder_width / 2, eta]) extruder_assembly();
rotate([-90,0,180])
wades_assembly();
if(extruder == Direct14)
rotate([180, 0, 180])
direct_assembly();
for(end = [-1, 1]) for(end = [-1, 1])
translate([extruder_mount_pitch / 2 * end, 0, nut_trap_thickness]) translate([extruder_mount_pitch / 2 * end, 0, nut_trap_thickness])

View File

@@ -12,7 +12,6 @@ include <conf/config.scad>
use <x-carriage.scad> use <x-carriage.scad>
use <pulley.scad> use <pulley.scad>
use <ribbon_clamp.scad> use <ribbon_clamp.scad>
use <wade.scad>
bwall = 2.3; bwall = 2.3;

View File

@@ -4,6 +4,7 @@ import os
import sys import sys
import shutil import shutil
import openscad import openscad
import re
from set_machine import * from set_machine import *
@@ -28,23 +29,45 @@ def views(machine):
scad_name = scad_dir + os.sep + scad scad_name = scad_dir + os.sep + scad
png_name = render_dir + os.sep + scad[:-4] + "png" png_name = render_dir + os.sep + scad[:-4] + "png"
dx = None
rx = None
d = None
for line in open(scad_name, "r").readlines(): for line in open(scad_name, "r").readlines():
m = re.match(r'\$vpt *= *\[ *(.*) *, *(.*) *, *(.*) *\].*', line[:-1])
if m:
dx = float(m.group(1))
dy = float(m.group(2))
dz = float(m.group(3))
m = re.match(r'\$vpr *= *\[ *(.*) *, *(.*) *, *(.*) *\].*', line[:-1])
if m:
rx = float(m.group(1))
ry = float(m.group(2))
rz = float(m.group(3))
m = re.match(r'\$vpd *= * *(.*) *;.*', line[:-1])
if m:
d = float(m.group(1))
words = line.split() words = line.split()
if len(words) > 10 and words[0] == "//": if len(words) > 3 and words[0] == "//":
cmd = words[1] cmd = words[1]
if cmd == "view" or cmd == "assembled" or cmd == "assembly": if cmd == "view" or cmd == "assembled" or cmd == "assembly":
w = int(words[2]) * 2 w = int(words[2]) * 2
h = int(words[3]) * 2 h = int(words[3]) * 2
dx = float(words[4]) if len(words) > 10:
dy = float(words[5]) dx = float(words[4])
dz = float(words[6]) dy = float(words[5])
dz = float(words[6])
rx = float(words[7]) rx = float(words[7])
ry = float(words[8]) ry = float(words[8])
rz = float(words[9]) rz = float(words[9])
d = float(words[10])
if dx == None or rx == None or d == None:
print "Missing camera data in " + scad_name
sys.exit(1)
d = float(words[10])
camera = "%.2f,%.2f,%.2f,%.2f,%.2f,%.2f,%.2f" % (dx, dy, dz, rx, ry, rz, d) camera = "%.2f,%.2f,%.2f,%.2f,%.2f,%.2f,%.2f" % (dx, dy, dz, rx, ry, rz, d)
exploded = "0" exploded = "0"

View File

@@ -7,9 +7,18 @@
// //
// Bed fan assembly view // Bed fan assembly view
// //
// assembly 958 958 -175 101 85 62 0 214 326 $vpt = [-99, 147, 85];
$vpr = [63, 0, 215];
$vpd = 115;
// //
// assembly 958 958
//
include <../scad/conf/config.scad>
include <../scad/positions.scad>
use <../scad/main.scad> use <../scad/main.scad>
bed_fan_assembly(show_fan = true); translate([-left_stay_x, -fan_y, -fan_z])
bed_fan_assembly(show_fan = true);
$exploded = 1; $exploded = 1;

View File

@@ -7,8 +7,14 @@
// //
// Wade's assembly view // Wade's assembly view
// //
// view 929 904 51.73 40.12 18.31 55.00 0.00 26.40 425 $vpt = [-21, 23, 11];
$vpr = [55, 0, 26];
$vpd = 380;
// //
use <../scad/wade.scad> // view 929 904
//
include <../scad/conf/config.scad>
use <../scad/extruder.scad>
wades_assembly(show_connector = true); rotate(extruder == Wades ? [-90, 0, 0] : [0, 0, 180])
extruder_assembly(show_connector = true);

View File

@@ -7,9 +7,12 @@
// //
// Wade's assembly view // Wade's assembly view
// //
// assembly 929 904 66 39 -6 241 0 38 450 // assembly 929 904 -9 39 -19 241 0 38 450
// //
use <../scad/wade.scad> include <../scad/conf/config.scad>
use <../scad/extruder.scad>
rotate(extruder == Wades ? [-90, 0, 0] : [0, 180, 0])
extruder_assembly(show_connector = false);
wades_assembly(show_connector = false);
$exploded = 1; $exploded = 1;

View File

@@ -7,9 +7,13 @@
// //
// Wade's assembly view // Wade's assembly view
// //
// assembly 910 904 61.89 7.66 0.30 13.70 25.90 348.60 300 $vpt = [-10, 6, 3];
$vpr = [107, 12, 24];
$vpd = 300;
// //
use <../scad/wade.scad> // assembly 910 904
//
use <../scad/extruder.scad>
include <../scad/conf/config.scad> include <../scad/conf/config.scad>
wades_assembly(show_connector = !exploded, show_drive = false); extruder_assembly(show_connector = !exploded, show_drive = false);

View File

@@ -7,12 +7,12 @@
// //
// Wade's motor assembly view // Wade's motor assembly view
// //
// assembly 1141 965 51.27 13.11 -39.31 57.80 2.10 5.40 350 // assembly 1141 965 -24 26 13 226 0 108 350
// assembled 1141 965 51.27 13.11 -39.31 57.80 2.10 5.40 250 // assembled 1141 965 -24 26 13 226 0 108 250
// //
$exploded = 1; $exploded = 1;
use <../scad/wade.scad> use <../scad/extruder.scad>
rotate([0, 90, -30]) rotate([0, 90, -30])
extruder_motor_assembly(); extruder_motor_assembly();

View File

@@ -7,10 +7,18 @@
// //
// Frame front bar detail // Frame front bar detail
// //
// assembly 958 842 171 -154 -26 65.5 0 314 290 $vpt = [18, 13, -11];
$vpr = [65.5, 0, 314];
$vpd = 261;
// //
// assembly 958 842
//
include <../scad/conf/config.scad>
include <../scad/positions.scad>
use <../scad/main.scad> use <../scad/main.scad>
frame_assembly(); translate([-right_stay_x + fixing_block_height() / 2 + sheet_thickness(frame) / 2, (base_depth / 2 - fixing_block_width() / 2 - base_clearance), 0])
frame_assembly();
$exploded = 1; $exploded = 1;