pcb_create_fill
Create a PCB fill region from a polygon on a chosen layer, optionally with a net, then read back the board to report any values EasyEDA did not apply.
Instructions
Create a fill region on the PCB. The result is read back from the board, and notApplied lists any requested value EasyEDA did not keep (EasyEDA Pro 3.2.206 stores every fill as solid with a 0.2 outline width, whatever fillMode and lineWidth say). Coordinates are PCB canvas coordinates in mil (1 mil = 0.001 inch), relative to the canvas origin: +X = rightward, +Y = upward. Lengths (widths, diameters) are also in mil. Use pcb_canvas_origin to read/set the origin offset and pcb_convert_coordinates to convert between canvas and data coordinates.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| net | No | Net name | |
| layer | Yes | Layer name (e.g. "TopLayer", "BottomLayer", "Inner1".."Inner30", "Multi") or numeric EPCB_LayerId (1=Top, 2=Bottom, 12=Multi). Names are converted to the numeric id EasyEDA requires. | |
| polygon | Yes | Either an ergonomic point array [{x, y}, ...] (minimum 3 points; the ring is closed automatically and converted to L-mode), or a raw EasyEDA L-mode source array [x1, y1, "L", x2, y2, ..., x1, y1] — coordinates of the first point, then the "L" token, then the remaining points (closed: last point repeats the first) | |
| document | Yes | Target document UUID — auto-switches to this document before executing. Get UUIDs from list_instances or editor_get_open_tabs. | |
| fillMode | No | Fill mode: "solid" (0), "mesh" (1) or "inner_electrical_layer" (2), or the number. Names are converted to the numeric value EasyEDA requires. | |
| lineWidth | No | Line width | |
| instance_id | No | Target EasyEDA instance ID (8-char hex). Required when multiple instances are connected. Omit when only one instance is connected (auto-selected). Use list_instances to see connected instances. |