Skip to content

Next Gen STEP AP242 Native-ish BREP Geometric Modeling Kernel

2.0 KB
Raw Blame
Model LampBaseIntent {
    units: mm

    // The large opening is the XY datum. Source XY is translated by (-38, 0) mm.
    Concept Struct BaseSketch on XY {
        Point2 Nose { position: [-144.9mm, 0mm] }
        Point2 UpperNoseHandle { position: [-144.9mm, 53.96mm] }
        Point2 UpperShoulderHandle { position: [-47.32mm, 74.4mm] }
        Point2 UpperShoulder { position: [-5.5mm, 74.4mm] }
        Point2 LowerShoulder { position: [-5.5mm, -74.4mm] }
        Point2 LowerShoulderHandle { position: [-47.32mm, -74.4mm] }
        Point2 LowerNoseHandle { position: [-144.9mm, -53.96mm] }
        Point2 RoundCenter { position: [-5.5mm, 0mm] }
        Point2 OpeningCenter { position: [0mm, 0mm] }
        Point2 PostMountCenter { position: [-116mm, 0mm] }
        Point2 AuxiliaryMountCenter { position: [-82mm, -25mm] }

        CubicBezier2 UpperFlank { from: UpperShoulder; control1: UpperShoulderHandle; control2: UpperNoseHandle; to: Nose }
        Circle2 RoundEnd { center: RoundCenter; radius: 74.4mm }
        CubicBezier2 LowerFlank { from: Nose; control1: LowerNoseHandle; control2: LowerShoulderHandle; to: LowerShoulder }
        Circle2 LargeOpening { center: OpeningCenter; radius: 61.6mm }
        Circle2 PostMount { center: PostMountCenter; radius: 7mm }
        Circle2 AuxiliaryMount { center: AuxiliaryMountCenter; radius: 3.5mm }
    }

    Profile PlateSection using BaseSketch {
        Loop Outer {
            Segment Lower { trace: LowerFlank; from: Nose; to: LowerShoulder }
            Segment Round { trace: RoundEnd; from: LowerShoulder; to: UpperShoulder; sweep: CounterClockwise }
            Segment Upper { trace: UpperFlank; from: UpperShoulder; to: Nose }
        }
        Loop Inner { LargeOpening as OpeningBoundary |> TraceLoop }
        Loop Inner { PostMount as PostBoundary |> TraceLoop }
        Loop Inner { AuxiliaryMount as AuxiliaryBoundary |> TraceLoop }
    }

    Struct Base { Extrude PrimaryPlate { profile: PlateSection; from: 0mm; to: 12mm } }
}