| name | prepare-print-model |
| description | Export and optimize 3D models for FDM/SLA printing including STL/3MF export, mesh integrity verification, wall thickness checking, support generation, and slicing. Use when exporting from CAD or modeling software for 3D printing, verifying STL/3MF files are printable before slicing, troubleshooting models that fail to slice correctly, optimizing part orientation for strength or surface finish, or converting between model formats while preserving printability.
|
| license | MIT |
| allowed-tools | Read Write Edit Bash Grep Glob WebFetch |
| metadata | {"author":"Philipp Thoss","version":"1.1","domain":"3d-printing","complexity":"intermediate","language":"multi","tags":"3d-printing, fdm, sla, slicing, mesh-repair, supports"} |
Prepare Print Model
Export and optimize 3D models for additive manufacturing. This skill covers the complete workflow from CAD/modeling software export through mesh repair, printability analysis, support generation, and slicer configuration. Ensures models are manifold, have adequate wall thickness, and are properly oriented for strength and print quality.
When to Use
- Exporting models from CAD software (Fusion 360, SolidWorks, Onshape) or 3D modeling tools (Blender, Maya) for 3D printing
- Verifying that existing STL/3MF files are printable before sending to slicer
- Troubleshooting models that fail to slice or print correctly
- Optimizing part orientation for strength, surface finish, or minimal support material
- Preparing mechanical parts with specific strength or tolerance requirements
- Converting between model formats (STL, 3MF, OBJ) while preserving printability
Inputs
- source_model: Path to CAD file or 3D model file (STEP, F3D, STL, OBJ, 3MF)
- target_process: Printing process type (
fdm, sla, sls)
- material: Intended print material (e.g.,
pla, petg, abs, standard-resin)
- functional_requirements: Load direction, tolerance requirements, surface finish needs
- printer_specs: Build volume, nozzle diameter (FDM), layer height capabilities
- slicer_tool: Target slicer (
cura, prusaslicer, orcaslicer, chitubox)
Procedure
1. Export Model from Source Software
Export the 3D model in a suitable format for printing:
For FDM/SLA:
Expected: Model file exported with appropriate resolution (0.1mm chord tolerance for mechanical parts, 0.05mm for organic shapes).
On failure: Check that model is fully defined (no construction geometry), no missing faces, all components visible.
2. Verify Mesh Integrity
Check that the mesh is manifold and printable:
admesh --check model.stl
Common issues:
- Non-manifold edges: Multiple faces share an edge, or edge has only one face
- Holes: Gaps in mesh surface
- Inverted normals: Inside/outside of model reversed
- Intersecting faces: Self-intersecting geometry
Expected: Report shows 0 errors, or errors are repairable.
On failure: Repair mesh automatically or manually:
admesh --write-binary-stl=model_fixed.stl \
--exact \
--nearby \
--remove-unconnected \
--fill-holes \
--normal-directions \
model.stl
meshlab model.stl
If automatic repair fails, return to source software and fix modeling errors (coincident vertices, open edges, overlapping bodies).
3. Check Wall Thickness
Verify minimum wall thickness for chosen process:
Minimum wall thickness by process:
| Process | Min Wall | Recommended Min | Structural Parts |
|---|
| FDM (0.4mm nozzle) | 0.8mm | 1.2mm | 2.4mm+ |
| FDM (0.6mm nozzle) | 1.2mm | 1.8mm | 3.6mm+ |
| SLA (standard) | 0.4mm | 0.8mm | 2.0mm+ |
| SLA (engineering) | 0.6mm | 1.2mm | 2.5mm+ |
| SLS (nylon) | 0.7mm | 1.0mm | 2.0mm+ |
Expected: All walls meet minimum thickness for chosen process. Thin walls flagged for review.
On failure: Return to CAD and thicken walls, or:
- Switch to smaller nozzle (FDM)
- Use "detect thin walls" slicer setting
- Accept reduced strength for prototypes
4. Determine Print Orientation
Select orientation to optimize strength, surface finish, and support usage:
Orientation decision matrix:
For strength:
- The layer interface is the weak plane, not the material: a part pulled across its stacked layers does not fail by breaking the extruded bead, it delaminates at the bond between layers. This anisotropy — not the filament's rated tensile strength — is what sets the orientation, and it is what lets you reason about load cases no table below covers (torsion, impact, fatigue, hoop stress): ask which surface the load tries to pull apart, and keep layer interfaces off it.
- Orient so the layer stacking direction (build Z) runs perpendicular to the primary load, keeping the load in-plane where continuous extruded beads carry it
- Example: Bracket under tension → lay it flat so the tension axis stays in the X/Y plane; printing it upright stacks layer interfaces across the load axis and invites delamination
For surface finish:
- Orient largest/most visible surface flat on bed (minimal stair-stepping)
- Critical dimensions aligned with X/Y plane (higher precision than Z)
For minimal supports:
- Minimize overhangs >45° (FDM) or >30° (SLA)
- Place flat surfaces on bed when possible
Load direction analysis:
If part experiences:
- Tensile load along axis → stack layers perpendicular to that axis (load stays in-plane)
- Compressive load → stacking direction less critical (layer bonds are pressed together, not pulled apart)
- Bending moment → lay the beam flat so its long axis is in X/Y (the outer fibre is in tension along that axis, and standing it on end puts every layer interface across that tension)
- Shear → avoid layer interfaces parallel to shear direction
Expected: Orientation chosen with explicit rationale for strength, finish, or support tradeoffs.
On failure: If no orientation satisfies all requirements, prioritize in order: functional strength → dimensional accuracy → surface finish → support minimization.
5. Generate Support Structures
Configure automatic or manual supports for overhangs:
Support angle thresholds:
- FDM: 45° from vertical (some bridging up to 60° possible)
- SLA: 30° from vertical (less bridging capability)
- SLS: No supports needed (powder bed support)
Support types:
Tree supports (FDM, recommended):
- Fewer contact points with model
- Easier removal
- Better for organic shapes
- Configure: Branch angle 40-50°, branch density medium
Linear supports (FDM, traditional):
- More stable for large overhangs
- More contact points (harder removal)
- Configure: Pattern grid, density 15-20%, interface layers 2-3
Heavy supports (SLA):
- Thicker contact points for heavy parts
- Risk of marks on surface
- Configure: Contact diameter 0.5-0.8mm, density based on part weight
Interface layers:
- Add 2-3 interface layers between support and model
- Reduces surface marks
- Slightly easier removal
Expected: Supports generated for all overhangs exceeding threshold angle, preview shows no floating geometry.
On failure: If automatic supports inadequate:
- Add manual support enforcers in critical areas
- Increase support density near thin overhangs
- Split model and print in sections if supports infeasible
6. Configure Slicer Profile
Set process-appropriate parameters:
FDM layer heights:
- Draft: 0.28-0.32mm (fast, visible layers)
- Standard: 0.16-0.20mm (balanced quality/speed)
- Fine: 0.08-0.12mm (smooth, slow)
- Rule: Layer height = 25-75% of nozzle diameter
SLA layer heights:
- Standard: 0.05mm (balanced)
- Fine: 0.025mm (miniatures, high detail)
- Fast: 0.1mm (prototypes)
Key parameters by process:
FDM:
layer_height: 0.2mm
line_width: 0.4mm (= nozzle diameter)
perimeters: 3-4 (structural), 2 (cosmetic)
top_bottom_layers: 5 (0.2mm layers = 1mm solid)
infill_percentage: 20% (cosmetic), 40-60% (functional)
infill_pattern: gyroid (FDM), grid (basic)
print_speed: 50mm/s perimeter, 80mm/s infill
temperature: material-specific (see select-print-material skill)
SLA:
layer_height: 0.05mm
bottom_layers: 6-8 (strong bed adhesion)
exposure_time: material-specific (2-8s per layer)
bottom_exposure_time: 30-60s
lift_speed: 60-80mm/min
retract_speed: 150-180mm/min
Expected: Profile configured with process-appropriate defaults, modified for specific material/model requirements.
On failure: If unsure about parameters, start with slicer's default "Standard Quality" profile for chosen material, then iterate.
7. Preview Slice Layer-by-Layer
Inspect sliced G-code for issues:
Red flags in preview:
- White gaps in solid regions: Walls too thin for current line width
- Travels over large distances: Increase retraction or add z-hop
- First layer not squishing: Adjust Z-offset down by 0.05mm
- Sparse top layers: Increase top solid layers to 5+
A clean slice is not a validation: the slicer does not warn about thin-wall gaps or odd infill decisions — it silently emits them — so never skip this preview.
Expected: Preview shows continuous perimeters, proper infill, clean travels, and no obvious defects.
On failure: Adjust slicer settings and re-slice. Common fixes:
- Thin wall gaps → Enable "Detect thin walls" or reduce line width
- Poor bridging → Reduce bridge speed to 30mm/s, increase cooling
- Stringing → Increase retraction distance +1mm, reduce temperature -5°C
8. Export G-code and Verify
Save sliced G-code with descriptive name:
grep "^;PRINT_TIME:" model.gcode
grep "^;Filament used:" model.gcode
head -n 50 model.gcode | grep "^M104\|^M140"
Pre-print checklist:
Expected: G-code file saved with embedded metadata, temperatures verified, print time/material estimate reasonable.
On failure: If print time excessive (>12 hours), consider:
- Increase layer height (0.2 → 0.28mm saves ~30% time)
- Reduce perimeters (4 → 3)
- Reduce infill (40% → 20% for non-structural)
- Scale model down if size not critical
Validation Checklist
Common Pitfalls
- Skipping mesh repair: Non-manifold meshes can slice but fail to print correctly with gaps or malformed layers
- First layer neglect: 90% of print failures occur in first layer—Z-offset and bed adhesion are critical
- Temperature from Internet: Every printer/material combination is unique; always calibrate temperature with tower tests
- Excessive detail for layer height: Fine features smaller than 2× layer height won't resolve properly
- Material hygroscopy: Wet filament (especially Nylon, TPU, PETG) causes poor layer adhesion, stringing, and brittleness
- Overconfidence in supports: Heavy parts with large overhangs can still sag even with supports—test on smaller models first
Related Skills
- select-print-material: Choose appropriate material based on mechanical, thermal, and chemical requirements
- troubleshoot-print-issues: Diagnose and fix print failures if prepared model still fails
- Model with Blender (future skill): Create 3D models optimized for printing from scratch
- Calibrate 3D Printer (future skill): E-steps, flow rate, temperature towers, and retraction tuning