Round Stock & Sections#
Turned parts: round stock, circle sections, and the square pommel
Names: shape rect round section interp circle samples axis pommel
When to use#
A lathe-turned part: a table leg, a spindle, a chess piece, a wagon-wheel hub. The blank is
round or square stock, and a section of stations sets the turned profile. Turned parts are a
bench operation in the fabrication pack (no CNC setup spins a spindle).
Syntax#
stock <Material> shape=round diameter=<expr> z=<expr> // no grain argument
section axis=z [interp=linear|spline] [samples=<n>] {
at z=<expr> { circle r=<expr> } // two or more stations
}
shape=isrect(the default for every plainstock <Material> x y z) orround. Round stock takes nameddiameter=andz=(the length along the spindle axis), never a grain word: its grain is lengthwise by definition and naming one is rejected.sectionstations are sorted byzat compile time, whatever the write order. Each isat z=<expr> { circle r=<expr> }.interp=linear(default) makes straight facets between stations;interp=splineresamples a centripetal Catmull-Rom curve through them (samples=, default 64).- The declared
diametermust be at least twice the widestcirclestation, or the build refuses it (the blank is narrower than the part). - A turned part is a stock primitive, not a cutter: ordinary features (
hole, a joint's mortise) still cut it. Anchorstop_center,bottom_center,centerare the spindle axis exactly. The corner anchors stay legal but sit in wood the lathe has removed. - Square pommel (RFC-0127): keep ordinary square
stock(noshape=round) and give asectionwhose stations do not reach the part's top face. Above the topmost station the square stays untouched (the pommel); below it the part is turned. The last station must reach the part's own foot (z = -leg_len) exactly. The topmost radius may be up to half the stock width: equal for a flush transition, a little less for a small shoulder. A tenon goes into the square pommel, never the round part.
Example#
project name="Turned Leg" units=mm schema_version=1 {
params {
leg_dim 45.0
leg_len 700.0
pommel_h 90.0
foot_r 14.0
}
materials { material Ash type=hardwood }
component Leg role=leg {
stock Ash leg_dim leg_dim leg_len
section axis=z interp=linear {
at z="0.0 - pommel_h" { circle r="leg_dim / 2.0" }
at z="0.0 - leg_len" { circle r=foot_r }
}
mark MortiseFace_X x=leg_dim y="leg_dim / 2.0" z="0.0 - pommel_h / 2.0" normal=pos_x
}
component Pawn role=game_piece {
stock Ash shape=round diameter=40.0 z=60.0
section axis=z interp=spline samples=48 {
at z=0.0 { circle r=6.0 }
at z=-30.0 { circle r=10.0 }
at z=-60.0 { circle r=16.0 }
}
mark AxisTop x=20.0 y=20.0 z=0.0 normal=pos_z
}
assembly Root {
part Leg_A instance=Leg { by top_sw; pos x=0.0 y=0.0 z=0.0 }
part Pawn_A instance=Pawn { by top_sw; pos x=200.0 y=0.0 z=0.0 }
}
}
Pitfalls and diagnostics#
- Not built (residual): a
rect-familysection(a non-circular varying profile; onlycirclestations exist), and a mark on the curved turned surface (only the flat axis ends,normal=pos_z/neg_z, are reachable; a mortise cut into a curved face is not modelled). Another file inINDEX.mdmay lift these (faceplate and rectangular sections); the newer file wins. - A grain argument on
shape=roundstock is an error; so is a grain word on atype=sheetmaterial. - A
sectionthat stops short of the foot leaves square material floating under a round run; the build refuses it. Make the last station land onz = -leg_len. - A station radius over half the square stock width is refused (the blank cannot hold it).
- A tenon into the round part cannot be modelled: tenon into the pommel, or use a
round_tenon(seejoinery-tenons) on a turned member's flat end.
See also#
docs/KDL_AUTHORING.md§6 ("Turned stock"); ADR-0018; RFC-0020 (turned round stock), RFC-0127 (pommel).examples/chess_pawn.kdl,examples/spindle.kdl,examples/shaker_side_table.kdl,examples/wagon_wheel.kdl,examples/speaker_ported.kdl.components-and-stock.md,joinery-tenons.md.
Names#
Every name this page declares, how the example library uses it, and the shortest real use.
shape#
word-valued property; property in 66 of 116 examples (133 uses).
Shortest real use, from appalachian_ladder_back_side_chair.kdl:
pin shape=round size=3.0
rect#
stock shape; node in 15 of 116 examples (101 uses).
Shortest real use, from appalachian_ladder_back_side_chair.kdl:
rect x_min=0.0 x_max=pw y_min=0.0 y_max=pd
round#
stock shape, expression function; value in 44 of 116 examples (89 uses).
Shortest real use, from appalachian_ladder_back_side_chair.kdl:
pin shape=round size=3.0
section#
feature, word-valued property; node in 47 of 116 examples (93 uses); property in 18 of 116 examples (36 uses).
Shortest real use, from pop_laminate_stepped_sideboard.kdl:
section axis=z interp=linear {
at z=0.0 { circle r="drum_d / 2.0" }
at z="0.0 - drum_h" { circle r="drum_d / 2.0" }
}
interp#
word-valued property; property in 41 of 116 examples (80 uses).
Shortest real use, from pop_laminate_stepped_sideboard.kdl:
section axis=z interp=linear {
at z=0.0 { circle r="drum_d / 2.0" }
at z="0.0 - drum_h" { circle r="drum_d / 2.0" }
}
circle#
node in 40 of 116 examples (933 uses).
Shortest real use, from windsor_round_stool.kdl:
circle r=rf
samples#
property; property in 23 of 116 examples (35 uses).
Shortest real use, from speaker_ported.kdl:
section axis=z interp=linear samples=2 {
at z=0.0 { circle r=port_outer_radius }
at z="0.0 - port_length" { circle r=port_outer_radius }
}
axis#
word-valued property; property in 72 of 116 examples (173 uses).
Shortest real use, from arched_crest_side_chair.kdl:
centering axis=z
pommel#
not used by any example yet.