Skip to content

Latest commit

 

History

History
43 lines (26 loc) · 1.25 KB

File metadata and controls

43 lines (26 loc) · 1.25 KB

OpenCAD Examples

These examples show how to use the in-process OpenCAD API to model parts that commonly appear in collaborative device-development work across hardware, software, and firmware teams.

Included scripts

Hardware

  • hardware/hardware_mounting_bracket.py — mechanical mounting bracket with fastener holes
  • hardware/hardware_pcb_carrier.py — carrier plate for a controller or sensor PCB

Software

  • software/software_hmi_panel.py — front panel for a software-driven operator interface

Firmware

  • firmware/firmware_programmer_fixture.py — fixture plate for firmware flashing or debug access

Full device

  • device/full_device_cable_grommet.py — cable-management part built from primitive booleans

Agents

  • agents/generate_mounting_bracket_code.py — agent-driven example-style code generation

Running an example

From the repository root:

python -m opencad.cli run examples/hardware/hardware_mounting_bracket.py \
  --export bracket.step \
  --tree-output bracket-tree.json

Each script leaves the final part in the default runtime context, so the CLI can export both a STEP file and a serialized feature tree.

For agent-focused examples, see examples/agents/README.md.