Skip to content

Commit

Permalink
fixup! chip: Generate 3D models for chip resistors
Browse files Browse the repository at this point in the history
  • Loading branch information
dbrgn committed Sep 3, 2023
1 parent 54fd42a commit 8b7ad45
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion generate_chip.py
Original file line number Diff line number Diff line change
Expand Up @@ -618,7 +618,10 @@ def generate_3d(
fillet = width * 0.05
if fillet * 2 >= height:
fillet = height * 0.2
edge = (length - config.gap) / 2
gap = config.gap or config.body.gap
if gap is None:
raise RuntimeError('Generating 3D models not supported for configs without gap')
edge = (length - gap) / 2
translation = (0, 0, height / 2)
edge_offset = length / 2 - edge

Expand Down

0 comments on commit 8b7ad45

Please sign in to comment.