Atlas / Skills / matlab / Matlab Assemble Pcb Layout

Matlab Assemble Pcb LayoutSAFE

skills/matlab/matlab-assemble-pcb-layout

The MATLAB Agentic Toolkit brings proven MATLAB capabilities to AI agents, making engineering and scientific workflows agent-ready.

Verdict
SAFE
Grade
B
Trust score
89 /100
Version
1.0
Hosts
—
License
NOASSERTION
Stars
1,164
01

Overview

The MATLAB Agentic Toolkit brings proven MATLAB capabilities to AI agents, making engineering and scientific workflows agent-ready.

Read from source at commit 58967e6f32b5OBSERVED · 2026-10-14
02

What it tells the agent

The instruction file, verbatim from the audited commit — this is the text the model reads, and the surface the audit's instruction layer examines. Quoted here so you can judge it without cloning anything.

---
name: matlab-assemble-pcb-layout
description: "Build custom PCB structures with pcbComponent, shapes, Boolean ops, feeds, and multi-layer stackups for non-catalog geometries. TRIGGER: user asks to build, modify, or customize a pcbComponent — add/remove shapes, edit polygons, place feeds, add metal layers, cut slots, or create non-catalog RF structures. Also when modifying geometry of an existing catalog-designed component (e.g., adding pads, removing elements, editing vertices). Invoke BEFORE writing pcbComponent code — layer/shape/feed API is non-obvious. SKIP: designing catalog components like filters/couplers/txlines (use the specific matlab-design-pcb-* skill), material/stackup definition only (use matlab-manage-pcb-material), EM analysis (use matlab-analyze-em), importing PCB files (use matlab-read-pcb-layout)."
license: https://www.mathworks.com/content/dam/mathworks/license/pmrl/license.md
metadata:
  author: MathWorks
  version: "1.0"
---

# Assembling Custom PCB Components

## When to Use

- Building custom PCB structures that aren't covered by catalog objects (microstripLine, coupledMicrostripLine, etc.)
- Constructing multi-layer stackups with custom metal shapes on each layer
- Combining shape primitives with Boolean operations (union, subtract, intersect)
- Creating defected ground structures (DGS) by etching patterns into ground planes
- Placing feed ports, vias, or using advanced FeedDefinitions (coaxial, edge, delta-gap)
- Assembling stripline or shielded enclosure structures

## When NOT to Use

- Designing standard transmission lines — use `matlab-design-pcb-transmission-line`
- Importing layouts from Gerber, ODB++, or Allegro — use `matlab-read-pcb-layout`
- Defining dielectric or metal materials — use `matlab-manage-pcb-material`
- Running EM analysis after assembly — use `matlab-analyze-em`
- Cascading or connecting multiple pcbComponents — use `matlab-integrate-pcb-circuit`

## Typical Workflow

1. **Before:** `matlab-manage-pcb-material` — set up substrate and conductor
2. **This skill:** Build the custom PCB structure using pcbComponent, shapes, and feeds
3. **After:** `matlab-analyze-em` — validate S-parameters → `matlab-optimize-pcb-design` — tune dimensions → `matlab-write-pcb-layout` — export Gerber

## Quick Reference

| Task | Code |
|------|------|
| Create pcbComponent | `pcb = pcbComponent` |
| Assign layers | `pcb.Layers = {signal, substrate, ground}` |
| Set board shape | `pcb.BoardShape = ground` |
| Set thickness | `pcb.BoardThickness = 1.6e-3` |
| Place feeds | `pcb.FeedLocations = [x1 y1 1 3; x2 y2 1 3]` |
| Feed diameter | `pcb.FeedDiameter = W/2` |
| Set conductor | `pcb.Conductor = metal("Copper")` |
| Add vias | `pcb.ViaLocations = [x y topLayer botLayer]` |
| Visualize | `show(pcb)` |
| Layout view | `layout(pcb)` |
| Boolean union | `shape = s1 + s2` |
| Boolean subtract | `shape = s1 - s2` |
| Boolean intersect | `shape = s1 & s2` |

## pcbComponent Anatomy

`pcbComponent` is the universal container for custom RF PCB structures.

### Minimal 2-Layer Microstrip

```matlab
pcb = pcbComponent;
substrate = dielectric("FR4");
substrate.Thickness = 1.6e-3;

signal = traceRectangular(Length=20e-3, Width=3e-3);
ground = traceRectangular(Length=30e-3, Width=20e-3);

pcb.Layers = {signal, substrate, ground};
pcb.BoardShape = ground;
pcb.BoardThickness = substrate.Thickness;
pcb.Conductor = metal("Copper");
pcb.FeedDiameter = 1.5e-3;
pcb.FeedLocations = [-10e-3 0 1 3; 10e-3 0 1 3];
show(pcb);
```

### 5-Layer Stripline Structure

```matlab
pcb = pcbComponent;
sub = dielectric(Name="FR4", EpsilonR=4.4, LossTangent=0.02, Thickness=0.8e-3);

topGnd = traceRectangular(Length=40e-3, Width=20e-3);
signal = traceRectangular(Length=30e-3, Width=2e-3);
botGnd = traceRectangular(Length=40e-3, Width=20e-3);

pcb.BoardThickness = 2 * sub.Thickness;          % Set BEFORE Layers
pcb.Layers = {topGnd, sub, signal, sub, botGnd};
pcb.BoardShape = topGnd;
pcb.Conductor = metal("Copper");
pcb.FeedLocations = [-15e-3 0 3 1; 15e-3 0 3 5];
pcb.FeedDiameter = 1e-3;
show(pcb);
```

### Key Properties

| Property | Format | Description |
|----------|--------|-------------|
| `Layers` | Cell array | Alternating: metal shape, dielectric, metal shape, ... |
| `BoardShape` | Shape object | Outer boundary of the PCB |
| `BoardThickness` | Scalar (m) | Must equal sum of dielectric thicknesses |
| `FeedLocations` | N×4 matrix | `[x, y, signalLayer, groundLayer]` per port |
| `FeedDiameter` | Scalar (m) | Diameter of feed via/probe |
| `ViaLocations` | M×4 matrix | `[x, y, topLayer, bottomLayer]` per via |
| `ViaDiameter` | Scalar (m) | Via barrel diameter |
| `FeedViaModel` | String | `'strip'`, `'square'`, `'octagon'`, `'hexagon'` |
| `Conductor` | metal object | Conductor for all metal layers |
| `SolverType` | String | `'MoM'` or `'FEM'` |

## Shape Primitives

### Rectangular Traces

```matlab
rect = traceRectangular(Length=20e-3, Width=5e-3, Center=[0 0]);
```

### Line Traces (multi-segment with bends)

```matlab
tl = traceLine;
tl.Length = [10 5*sqrt(2) 10]*1e-3;
tl.Angle = [0 45 0];
tl.Width = 3e-3;
tl.Corner = 1;          % 1 = Miter, 2 = Smooth (default: Sharp)
show(tl);
```

### Point-Defined Traces

```matlab
tp = tracePoint;
tp.TracePoints = [0 0; 10e-3 0; 15e-3 5e-3; 25e-3 5e-3];
tp.Width = 2e-3;
tp.Corner = 2;          % 2 = Smooth
```

### Spiral Traces

```matlab
sp = traceSpiral;
sp.NumTurns = 3;
sp.InnerDiameter = 4e-3;
sp.Spacing = 0.5e-3;
sp.TraceWidth = 0.5e-3;
show(sp);
```

### Tapered Traces

```matlab
tt = traceTapered;
tt.Length = 10e-3;
tt.InputWidth = 1e-3;
tt.OutputWidth = 3e-3;
```

### Bends

Bend `Width` is a 2-element vector `[w1 w2]` for the two arms:

```matlab
bc = bendCurved;
bc.Width = [2e-3 2e-3];
bc.CurveRadius = 5e-3;

bm = bendMitered;
bm.Width = [2e-3 2e-3];

br = bendRightAngle;
br.Width = [2e-3 2e-3];
```

### U-Bends

U-bend `Width` is a 3-element vector `[arm1 bottom arm2]`:

```matlab
uc = ubendCurved;
uc.Width = [2e-3 2e-3 2e-3];
u
03

Trust audit

SAFEgrade B · trust 89/100 Nothing in the source contradicts what it says it does. Grade A is reserved for packages that have also passed the behavioural sandbox.

LayerWhat it checksResult
L0Provenance & inventoryPASS
L1Static analysis of the codeNA
L2Instruction surface (what it tells the agent)PASS
L3Class-specific surfacePASS
L4Behavioural (sandbox)SKIPPED

What the source does

Filesystem
none-observed
Network
none-observed
Shell
none-observed
Dependencies
pinned
Secrets in source
none-found

Findings (0)

No findings outside the package's declared scope.

Gates applied: no_behavioural_pass.

Audited 2026-10-14 · audit v0.4.1 · source sha 58967e6f32b5full audit observations/trust-audit/skill/matlab__matlab-assemble-pcb-layout.json · Report an issue / request a re-scan
04

Audit history

Every audit this skill has had.

DateSourceVerdictGradeScoreChange
2026-10-1458967e6f32b5SAFEB89first audit
05

Questions

What does the Matlab Assemble Pcb Layout skill do?

The MATLAB Agentic Toolkit brings proven MATLAB capabilities to AI agents, making engineering and scientific workflows agent-ready.

Is Matlab Assemble Pcb Layout safe to install?

The audit found nothing in the source that contradicts what it says it does, and graded it B (89/100). Grade A is held back for packages that have also passed a sandboxed behavioural run, which is why a clean skill reads B.

What can Matlab Assemble Pcb Layout access on my machine?

The audit observed no filesystem, network or shell use at all in its source.

How current is this page?

The grade is for one exact copy of the source (58967e6f32b5), read on 2026-10-14. The repository is watched, and a new audit runs when it changes — this is the first audit.

Advertisement