Fix more constant names

This commit is contained in:
Martin Frost 2024-09-05 15:09:17 +02:00
parent 1cd946e2fd
commit e9423dbcf0
1 changed files with 13 additions and 14 deletions

View File

@ -1058,11 +1058,10 @@ def screw_insert_all_shapes(shape):
) )
trrs_holder_size = [6.0, 11.0, 7.0] TRRS_HOLDER_SIZE = [6.0, 11.0, 7.0]
trrs_hole_size = [2.6, 10.0] TRRS_HOLE_SIZE = [2.6, 10.0]
trrs_holder_thickness = 2.5 TRRS_HOLDER_THICKNESS = 2.5
TRRS_FRONT_THICKNESS = 1.8
trrs_front_thickness = 1.8
def trrs_key_holder_position(): def trrs_key_holder_position():
@ -1072,27 +1071,27 @@ def trrs_key_holder_position():
def trrs_holder(): def trrs_holder():
shape = cube( shape = cube(
trrs_holder_size[0] + trrs_holder_thickness, TRRS_HOLDER_SIZE[0] + TRRS_HOLDER_THICKNESS,
trrs_holder_size[1] + trrs_front_thickness, TRRS_HOLDER_SIZE[1] + TRRS_FRONT_THICKNESS,
trrs_holder_size[2] + trrs_holder_thickness * 2, TRRS_HOLDER_SIZE[2] + TRRS_HOLDER_THICKNESS * 2,
) )
placed_shape = translate( placed_shape = translate(
-trrs_holder_size[0] / 2, -TRRS_HOLDER_SIZE[0] / 2,
-trrs_holder_size[1], -TRRS_HOLDER_SIZE[1],
-(trrs_holder_size[2] / 2 + trrs_holder_thickness), -(TRRS_HOLDER_SIZE[2] / 2 + TRRS_HOLDER_THICKNESS),
)(shape) )(shape)
return translate(*trrs_key_holder_position())(placed_shape) return translate(*trrs_key_holder_position())(placed_shape)
def trrs_holder_hole(): def trrs_holder_hole():
rect_hole = cube(*trrs_holder_size) rect_hole = cube(*TRRS_HOLDER_SIZE)
rect_hole = translate( rect_hole = translate(
-trrs_holder_size[0] / 2, -trrs_holder_size[1], -trrs_holder_size[2] / 2, -TRRS_HOLDER_SIZE[0] / 2, -TRRS_HOLDER_SIZE[1], -TRRS_HOLDER_SIZE[2] / 2,
)(rect_hole) )(rect_hole)
cylinder_hole = cylinder(*trrs_hole_size, segments=30) cylinder_hole = cylinder(*TRRS_HOLE_SIZE, segments=30)
cylinder_hole = rotate_x(90)(cylinder_hole) cylinder_hole = rotate_x(90)(cylinder_hole)
cylinder_hole = translate(0, 5, 0)(cylinder_hole) cylinder_hole = translate(0, 5, 0)(cylinder_hole)