Sign in with STEVE

Compare versions

2 files changed, +8 −3 1.1.0: Materials and finishes: each part is made of its standard's engineering material, with its usual finish.

part.py +5 −1
@@ -1,5 +1,7 @@
11"""ISO 4762 (DIN 912) socket head cap screw. Envelope: head, hex socket and plain shank (no modelled thread).
2The head sits on the XY plane at the origin; the shank points down -Z. `length` is measured under the head."""
2The head sits on the XY plane at the origin; the shank points down -Z. `length` is measured under the head.
3
4Material: property class 12.9 alloy steel, quenched and tempered (34CrNiMo6 from the material library), black oxide."""
35from steve import Model
46
57size = "M3" # Thread size
@@ -42,5 +44,7 @@
4244with model.sketch("socket_sketch", on="head_top", name="Hex socket") as sk:
4345 sk.polygon("hex", (0, 0), s / 2, 6, inscribed=False)
4446model.extrude("socket", "socket_sketch", distance=-0.55 * k, op="cut")
47model.material("steel-34crnimo6") # class 12.9 alloy steel
48model.appearance(color="#2e3034", metalness=0.75, roughness=0.38) # black oxide finish
4549result = model.result()
4650
pypart.toml +3 −2
@@ -1,10 +1,11 @@
11name = "steve/socket-head-cap-screw"
2version = "1.0.0"
2version = "1.1.0"
33runtime = "steve"
44license = "MIT"
55summary = "Socket head cap screw, ISO 4762 / DIN 912, M2 to M12, any length."
6description = "ISO 4762 (DIN 912) socket head cap screw. Envelope: head, hex socket and plain shank (no modelled thread).\nThe head sits on the XY plane at the origin; the shank points down -Z. `length` is measured under the head.\n\nDimensions from STEVE's standard-part tables (nominal values of the standard). Envelope geometry: no modelled thread."
6description = "ISO 4762 (DIN 912) socket head cap screw. Envelope: head, hex socket and plain shank (no modelled thread).\nThe head sits on the XY plane at the origin; the shank points down -Z. `length` is measured under the head.\n\nMaterial: property class 12.9 alloy steel, quenched and tempered (34CrNiMo6 from the material library), black oxide.\n\nDimensions from STEVE's standard-part tables (nominal values of the standard). Envelope geometry: no modelled thread."
77tags = ["fastener", "screw", "iso-4762", "din-912", "metric"]
8changes = "Materials and finishes: each part is made of its standard's engineering material, with its usual finish."
89
910[parameters.size]
1011type = "choice"