vibe-openscad

bare-think-off/claude-opus-4-7 / tier-2-l-bracket

success tier 2

bare (claude opus 4.7)

render
bare render of tier-2-l-bracket
loading STL…
success 13.9s · 386/1130t · $0.0302
SCAD (76 lines)
// L-bracket with countersunk holes

$fn = 64;

width    = 50;   // X
depth    = 40;   // Y (horizontal flange)
height   = 40;   // Z (vertical flange)
thk      = 3;    // plate thickness

hole_d   = 4.5;  // through hole
csk_d    = 8;    // countersink diameter
csk_h    = 2;    // countersink depth
edge_off = 10;   // distance from edge

// Hole X positions (symmetric on center line)
hx1 = width/2 - 10;
hx2 = width/2 + 10;

module countersunk_hole_z(z_outer_top) {
    // Hole drilled along Z axis. z_outer_top = top surface Z (outer face).
    // Through hole
    translate([0, 0, z_outer_top - thk - 0.1])
        cylinder(d = hole_d, h = thk + 0.2);
    // Countersink from outer (top) face going down
    translate([0, 0, z_outer_top - csk_h])
        cylinder(d = csk_d, h = csk_h + 0.01);
}

module countersunk_hole_y(y_outer_front) {
    // Hole drilled along Y axis. y_outer_front = outer face Y.
    translate([0, y_outer_front - thk - 0.1, 0])
        rotate([-90, 0, 0])
            cylinder(d = hole_d, h = thk + 0.2);
    translate([0, y_outer_front - csk_h, 0])
        rotate([-90, 0, 0])
            cylinder(d = csk_d, h = csk_h + 0.01);
}

difference() {
    union() {
        // Horizontal flange: top surface at Z=0, extends in +Y
        translate([0, 0, -thk])
            cube([width, depth, thk]);
        // Vertical flange: front surface at Y=0, extends in +Z
        translate([0, -thk, 0])
            cube([width, thk, height]);
    }

    // Horizontal flange holes (countersink on bottom = outer face)
    // Outer face is at Z = -thk; bolt head from below.
    // Use countersunk_hole_z with mirrored orientation: drill from bottom.
    for (x = [hx1, hx2]) {
        translate([x, depth - edge_off, 0]) {
            // Through hole
            translate([0, 0, -thk - 0.1])
                cylinder(d = hole_d, h = thk + 0.2);
            // Countersink on bottom (outer) face, opening downward
            translate([0, 0, -thk])
                cylinder(d1 = csk_d, d2 = csk_d, h = csk_h + 0.01);
        }
    }

    // Vertical flange holes (countersink on front = outer face at Y = -thk)
    for (x = [hx1, hx2]) {
        translate([x, 0, height - edge_off]) {
            // Through hole along Y
            translate([0, -thk - 0.1, 0])
                rotate([-90, 0, 0])
                    cylinder(d = hole_d, h = thk + 0.2);
            // Countersink on front face
            translate([0, -thk, 0])
                rotate([-90, 0, 0])
                    cylinder(d = csk_d, h = csk_h + 0.01);
        }
    }
}
パラメータ (8)
スライダを動かすと openscad-wasm で再レンダリング

meta

runIdbare-think-off_claude-opus-4-7-7b78fd3b3432-2026-04-28T18-48-19-579Z
matrixIdbare-think-off/claude-opus-4-7
signature7b78fd3b3432e91e…
provideranthropic
modelclaude-opus-4-7
harnessbare
statussuccess
duration13.94s (wallclock: load + prompt eval + generation + network)
tokens386 in / 1130 out
wallclock tok/s81.1 tok/s (end-to-end)
cost$0.0302
createdAt2026-04-28T18:48:19.579Z
gitCommit781e6c683dda
openscadOpenSCAD version 2026.04.27

prompt

OpenSCAD で、L 字に折れた金具(L-bracket)を作ってください。

形状:
- 水平面と垂直面の 2 つのフランジが直角に繋がっている
- 水平面は 50mm × 40mm(幅 × 奥行き)
- 垂直面は 50mm × 40mm(幅 × 高さ)
- 板厚はどちらも 3mm
- 内側コーナーが原点になるように配置(水平面は +Y 方向、垂直面は +Z 方向に伸びる)

皿穴(countersunk holes):
- 各面に 2 個ずつ、合計 4 個
- M4 ねじ用(貫通穴 Φ4.5mm + 皿座面 Φ8mm × 深さ 2mm)
- 各面の中心線上で、面の縁から 10mm 内側、左右対称に 2 個並べる
- 皿座面は外側(ボルト頭が当たる側)に向ける

完成したコード全体を ```openscad ... ``` のフェンスで囲んで出力してください。コードのみで、追加の説明は不要です。