kicad10-mcp
Provides comprehensive control over KiCad 10 for PCB and schematic design, including editing, routing, net management, layer control, project settings, and export to manufacturing outputs.
Click on "Deploy Server".
Wait a few minutes for the server to deploy. Once ready, it will show a "Started" state.
In the chat, type
@followed by the MCP server name and your instructions, e.g., "@kicad10-mcp export gerbers for the current board"
That's it! The server will respond to your query, and you can continue using it as needed.
Here is a step-by-step guide with screenshots.
kicad10-mcp
Bir MCP sunucusu — KiCad 10 üzerinde tam kontrol sağlar. KiCad'in IPC
API'sini (kicad-python / kipy) ve kicad-cli'yi sararak PCB editörü,
şematik editörü, proje ayarları, ağlar (nets), katmanlar, tasarım verisi,
üretim çıktıları ve ham bir betik çalıştırma kapısını MCP araçları olarak sunar.
102 araç, 14 modülde gruplanmıştır. İngilizce araç adları ve açıklamaları modelin doğru aracı bulması için tutulmuştur.
Yenilikler (v1.1.0)
Pad bazlı yerleşim:
place_near_pad,place_on_edge,place_relative,arrange_row,flip_footprint,check_placementPad bazlı routing:
route_padsiki pad'i adıyla bağlar; genişlik netclass'tan gelir, ince pinlerde yol otomatik incelir. Her sonuçta kısa devre ve clearance uyarıları döner.Freerouting ile otomatik routing:
autoroutemevcut yolları kilitler, istenen netclass'ları atlar, sonunda zone'ları doldurup DRC çalıştırır.Güç bütçesi:
analyze_power_budgetşemadan her besleme netinin akımını hesaplar; regülatör ve sürücü sınırları aşılınca uyarır, netclass önerir.Akıma göre yol genişliği:
calc_track_width(IPC-2221) veconfigure_netclassesParça veritabanı: 16 yaygın parça; 13'ü üretici datasheet'lerinden doğrulandı.
Kartı görme:
snapshot_boardkartın PNG görüntüsünü verir.Kurulum: tek komutla
uvx(eski.exeartık sunulmuyor).
Test: KiCad 10.0.5 üzerinde Arduino Nano + TB6612FNG kartı baştan sona çizildi
(0 DRC hatası, 0 çizilmemiş bağlantı); temiz bir uvx kurulumu canlı KiCad'e
karşı 13/13 kontrolü geçti.
Related MCP server: KiCad MCP Server
Gereksinimler
KiCad 10 kurulu
uv (Python ve paketleri kendisi hazırlar)
autorouteiçin Java 21+ (Java 25 önerilir); Freerouting'iinstall_freeroutingkurarKiCad açık ve API sunucusu etkin:
Preferences > Plugins > "Enable the KiCad API server"Çoğu araç o anda AÇIK olan kart (
.kicad_pcb) veya şema (.kicad_sch) üzerinde çalışır — önce ilgili dökümanı açın.
Kurulum
Sunucu KiCad'e yerel IPC ile bağlandığı için bilgisayarda çalışır; Windows'ta Docker container'ından açık KiCad'e bağlanamaz. Claude Code'a kaydetmek için:
claude mcp add kicad --scope user -- uvx --from https://github.com/tureruygar-glitch/Kicad-mcp/archive/refs/tags/v1.1.1.zip kicad10-mcpclaude komutu yoksa (yalnızca masaüstü uygulaması kuruluysa) aynı kaydı
~/.claude.json içine mcpServers.kicad olarak elle ekleyin:
"mcpServers": {
"kicad": {
"type": "stdio",
"command": "uvx",
"args": ["--from", "https://github.com/tureruygar-glitch/Kicad-mcp/archive/refs/tags/v1.1.1.zip", "kicad10-mcp"]
}
}Kayıttan sonra Claude Code oturumunu yeniden başlatın. Test: kicad_status
aracı "no handler available" derse KiCad'e bağlanılmıştır ama PCB Editor açık
değildir.
Komut v1.1.1 sürümünü kurar. Geliştirme sürümü için adresteki
refs/tags/v1.1.1.zip yerine refs/heads/main.zip yazın; uv indirdiğini
önbellekte tuttuğu için main'i güncellerken komutu bir kez --refresh ile çalıştırın.
Geliştirme için:
python -m venv .venv
.venv\Scripts\python.exe -m pip install -e .
.venv\Scripts\python.exe run_server.pyBirimler / kurallar
Tüm konum, boyut ve genişlikler milimetre; açılar derece.
Katman adları:
F.Cu,B.Cu,In1.Cu,Edge.Cuts,F.SilkS,F.Mask,F.Paste,F.Fab… Geçerli set içinlist_board_layers.Kart düzenlemeleri tek bir geri-al (undo) adımına gruplanır. Diske yazmak için
save_board. Export araçları aksi belirtilmedikçe önce kaydeder.
Araç grupları
Sistem / bağlantı — kicad_status, get_version, ping,
list_open_documents, save_board, save_board_as, revert_board,
run_action, get_kicad_binary_path
PCB okuma — get_board_summary, list_footprints, get_footprint,
list_pads, list_tracks, list_vias, list_zones, list_shapes,
get_board_outline, list_text, list_dimensions, list_groups,
get_bounding_box
PCB düzenleme — move_footprint, rotate_footprint,
set_footprint_locked, set_footprint_value, batch_move_footprints,
set_items_locked, delete_items, select_items, clear_selection,
get_selection
Yerleşim (parça/pad/kenar bazlı) — get_footprint_geometry,
place_near_pad (dekuplaj vb.; aynı netteki pad hedefe bakacak şekilde gerekirse
180° döndürür), place_relative, place_on_edge, arrange_row,
flip_footprint, check_placement (courtyard çakışması, kart dışı parça,
toplam airwire uzunluğu). move_footprint / batch_move_footprints da artık
çakışma uyarısı döndürür.
Routing (pad bazlı) — route_pads (iki pad'i adıyla bağlar: net ve genişlik
netclass'tan, 45°/90° yol, gerekirse via), add_track_path (çok parçalı yol),
check_clearance. Her sonuçta warnings alanı kısa devre, clearance ihlali ve
boşta kalan uçları bildirir; rollback_on_conflict ile hatalı çizim geri alınır.
route_pads geniş bir güç yolunu ince aralıklı bir pine (ör. SSOP) girerken
komşu pinlere değmeyecek genişliğe daraltır (necks), yol tam genişliğe hiç
sığmıyorsa tamamını sığan en geniş değerle çizer; sürücülerin çift pinli
çıkışlarında (TB6612 AO1 = 1+2) izi iki pinin ortasına getirip ikisini birden bağlar.
Netclass / track genişliği — calc_track_width (akıma göre IPC-2221 genişliği,
istenirse direnç ve gerilim düşümü), configure_netclasses (sınıfları ve net atamalarını
.kicad_pro'ya yazar; genişlik sabit sayı yerine current_a ile verilebilir; proje
KiCad'de kapalıyken çalışır — sadece proje yöneticisinde açık olsa bile kilit
dosyasından anlayıp reddeder), get_netclass_config.
Otomatik routing (Freerouting) — autoroute: kalan bağlantıları
Freerouting ile çizer. Mevcut yollar
kilitlenir (elle/Claude'un çizdiği güç yolları yerinde kalır), skip_netclasses
ile istenen sınıflar (ör. HighCurrent) hiç rotalanmaz. Açık kart kaydedilir,
<kart>.pre-autoroute.kicad_pcb yedeği alınır, rotalanıp KiCad'e yeniden
yüklenir; ardından zone'lar doldurulup DRC çalıştırılır (drc_after).
Freerouting'in pin çıkışlarında sınıf genişliğinin %75'ine inceltip kartın asgari
iz genişliğinin altına düşürdüğü izler içe aktarımda asgari genişliğe çıkarılır
(widened_to_min_width).
freerouting_status hazırlığı kontrol eder, install_freerouting resmi jar'ı
GitHub'dan indirir. Freerouting GPL-3.0'dır ve yalnızca ayrı bir program olarak
çağrılır; kodu bu pakete dahil değildir. Gereksinim: Java 21+ (Java 25 önerilir:
Freerouting 2.4 saniyeler içinde biter ve limitlere uyar; Java 21'de 2.1.0 çalışır,
limitleri yok sayar ve dakikalar sürer). DSN/SES dönüşümü KiCad'in kendi Python'u
(pcbnew) ile yapılır, çünkü kicad-cli DSN dışa aktaramaz. Not: bakır
katmandaki yazılar Freerouting'e engel olarak gitmez; DRC raporunu okuyun.
Güç bütçesi (akım analizi) — analyze_power_budget: şematikten (kicad-cli
netlist; KiCad açık olmak zorunda değil) her besleme netinin normal ve en kötü
durum akımını hesaplar; regülatör, sürücü ve seri elemanlar (sigorta, diyot,
anahtar, bobin, 0 Ω) üzerinden akımı kaynağa kadar taşır, sürücü/regülatör
sınır aşımlarını uyarır ve configure_netclasses'a verilecek netclass önerisi
üretir. Bilinmeyen parçaları ve ucunda ne olduğu bilinmeyen konnektörleri tahmin
etmez, soru olarak döndürür. set_part_current datasheet değerlerini kaynağıyla
kaydeder, list_part_database bilinen parçaları listeler.
Parça verisi sırası: kullanıcının kendi kayıtları (~/.kicad10_mcp/parts.json)
→ yerleşik veritabanı. Yerleşik 16 parçanın 13'ü üretici datasheet'lerinden
alınmıştır (her kayıtta kaynak URL ve sayfa); datasheet'i alınamayan MCP1700,
L7805 ve WS2812B verified: false olarak işaretlidir.
Görünüm — snapshot_board: kartın üstten PNG görüntüsü (kart sınırı,
courtyard'lar, pad'ler, track/via'lar, zone dolguları, vurgulanan net). Kart
dışındaki parçalar da kadraja girer; airwire'lar KiCad'in bağlantı bilgisiyle
yalnızca bakırın henüz bağlamadığı bağlantılar için çizilir. Model yerleşimi ve
routing'i görerek kontrol edebilir.
Oluşturma (routing/grafik) — add_track, add_arc_track, add_via,
add_zone, add_zone_rect, refill_zones, add_line, add_rectangle,
add_circle, add_arc, add_polygon, add_board_outline_rect, add_text
(add_track genişliği ve add_via ölçüleri verilmezse netclass'tan alınır;
bilinmeyen net adı artık hata verir ve benzer adları önerir.)
Ağlar / katmanlar — list_nets, list_netclasses, get_items_by_net,
get_connected_items, list_board_layers, set_active_layer,
set_visible_layers, set_copper_layer_count, get_stackup,
get_design_rules
Proje — get_project_info, get_text_variables, set_text_variable,
expand_text, get_title_block, set_title_block
Şema — get_schematic_summary, list_symbols, list_labels,
list_schematic_text, get_schematic_hierarchy, add_schematic_text,
add_local_label, save_schematic
(Not: sembol/hiyerarşi okuma KiCad 11 özelliğidir; KiCad 10'da bu araçlar
açıklayıcı bir hata döndürebilir — bu durumda execute_kipy kullanın.)
Üretim çıktıları (kicad-cli) — run_kicad_cli, export_gerbers,
export_drill, export_step, export_pdf, export_svg, export_pos,
render_3d, run_drc, export_bom, export_netlist, run_erc
(run_drc önce zone'ları doldurur — eski dolgu sahte clearance hatası verir — ve
ihlalleri türe göre sayıp örnekleriyle özetler.)
Tam kontrol kapısı — execute_kipy: canlı KiCad'e karşı rastgele Python
çalıştırır. kicad, board, schematic, kipy, commit, Vector2, Angle,
BoardLayer, KiCadObjectType adları önceden bağlıdır. result değişkenine
atadığınız şey geri döner; print çıktısı da yakalanır.
# execute_kipy örnek
from kipy.board_types import Track
t = Track()
t.start = Vector2.from_xy_mm(10, 10)
t.end = Vector2.from_xy_mm(20, 10)
t.width = 250000 # 0.25 mm (nanometre)
t.layer = BoardLayer.BL_F_Cu
with commit(board, "api track"):
created = board.create_items(t)
result = [c.id.value for c in created]Bilinen sınırlamalar
Bakır katmandaki yazılar Freerouting'e engel olarak gitmez;
autoroutesonrası DRC raporunu okuyun.KiCad 10.0.5'te şema editöründe ERC çalıştırmak KiCad'i çökertebiliyor (KiCad hatası).
configure_netclassesproje KiCad'de kapalıyken çalışır.PCB Editor'de bir araç aktifken API "meşgul" yanıtı verir; Esc'ye basın.
Ortam değişkenleri
KICAD_API_TIMEOUT_MS— IPC istek zaman aşımı (varsayılan 10000)KICAD_API_BUSY_WAIT_S— KiCad "meşgul" dediğinde (ör. otomatik kayıt sırasında) isteği yeniden deneme süresi (varsayılan 5); açık diyalog/aktif araç gibi kalıcı durumlarda sonra anlaşılır bir hata döner. KiCad yeniden başlarsa bağlantı kendiliğinden yenilenir.KICAD_API_SOCKET/KICAD_API_TOKEN— KiCad otomatik ayarlar; genelde gerekmezKICAD10_MCP_JAVA— Freerouting için kullanılacakjava(varsayılan: bulunan en yeni sürüm)KICAD10_MCP_FREEROUTING_JAR— belirli bir Freerouting jar dosyasıKICAD10_MCP_KICAD_PYTHON— KiCad'in Python'u (DSN/SES dönüşümü için; genelde otomatik bulunur)
Proje yapısı
kicad10_mcp/
server.py FastMCP uygulaması, tüm modülleri kaydeder
connection.py Önbellekli KiCad istemcisi + commit context manager
helpers.py mm<->nm, katman ad<->enum, serileştiriciler
board_query.py parça/pad bulma, courtyard, netclass değerleri, geometri, ratsnest
system_tools.py sistem / döküman yaşam döngüsü
read_tools.py PCB okuma
edit_tools.py PCB düzenleme
placement_tools.py parça/pad/kenar bazlı yerleşim + yerleşim kontrolü
routing_tools.py pad bazlı routing + clearance / bağlantı kontrolü
view_tools.py snapshot_board (PNG görüntü)
netclass_tools.py IPC-2221 hesabı + .kicad_pro netclass/atama düzenleme
power_tools.py güç bütçesi analizi (netlist → net akımları → netclass önerisi)
parts_db.py parça akım veritabanı (yerleşik + kullanıcı)
sexpr.py KiCad S-expression okuyucu/yazıcı
autoroute_tools.py Freerouting entegrasyonu (DSN → Freerouting → SES)
kicad_py/ KiCad'in Python'u ile çalışan yardımcılar (DSN/SES)
create_tools.py routing + grafik + metin oluşturma
net_layer_tools.py ağlar, ağ sınıfları, katmanlar, stackup, tasarım kuralları
project_tools.py metin değişkenleri, başlık bloğu
schematic_tools.py şema okuma/yazma
export_tools.py kicad-cli sarmalayıcıları
exec_tools.py execute_kipy
run_server.py başlatıcı
pyproject.tomlAvailable Tools
102 toolsadd_arcA
Add a graphic arc defined by start, mid, and end points.
Args: start_x_mm, start_y_mm: Arc start in mm. mid_x_mm, mid_y_mm: Point on the arc, in mm. end_x_mm, end_y_mm: Arc end in mm. layer: Layer name. width_mm: Outline width in mm.
Inputs: end_x_mm (required), end_y_mm (required), mid_x_mm (required), mid_y_mm (required), +4 more. Returns: object
add_arc_trackA
Add a curved (arc) copper track defined by start, mid, and end points.
Args: start_x_mm, start_y_mm: Arc start in mm. mid_x_mm, mid_y_mm: A point on the arc between start and end, in mm. end_x_mm, end_y_mm: Arc end in mm. width_mm: Track width in mm. layer: Copper layer name. net_name: Optional net to assign.
Inputs: end_x_mm (required), end_y_mm (required), mid_x_mm (required), mid_y_mm (required), +5 more. Returns: object
add_board_outline_rectB
Add a rectangular board outline on the Edge.Cuts layer.
Args: x_min_mm, y_min_mm: Top-left corner in mm. x_max_mm, y_max_mm: Bottom-right corner in mm. width_mm: Outline width in mm.
Inputs: x_max_mm (required), x_min_mm (required), y_max_mm (required), y_min_mm (required), +1 more. Returns: object
add_circleB
Add a graphic circle.
Args: center_x_mm, center_y_mm: Centre in mm. radius_mm: Radius in mm. layer: Layer name. width_mm: Outline width in mm. filled: Whether the circle is solid-filled.
Inputs: radius_mm (required), center_x_mm (required), center_y_mm (required), layer, +2 more. Returns: object
add_lineB
Add a graphic line segment (silkscreen, fab, Edge.Cuts, etc.).
Args: start_x_mm, start_y_mm: Start point in mm. end_x_mm, end_y_mm: End point in mm. layer: Layer name, e.g. 'F.SilkS' or 'Edge.Cuts'. width_mm: Line width in mm.
Inputs: end_x_mm (required), end_y_mm (required), start_x_mm (required), start_y_mm (required), +2 more. Returns: object
add_local_labelC
Add a local net label to the open schematic.
Args: text: Label text (the net name). x_mm, y_mm: Position in mm.
Inputs: text (required), x_mm (required), y_mm (required). Returns: object
add_polygonB
Add a graphic polygon.
Args: points: Vertices, each {"x_mm": .., "y_mm": ..} or [x, y]. >= 3 points. layer: Layer name. width_mm: Outline width in mm. filled: Whether the polygon is solid-filled.
Inputs: points (required), layer, filled, width_mm. Returns: object
add_rectangleB
Add a graphic rectangle.
Args: x_min_mm, y_min_mm: Top-left corner in mm. x_max_mm, y_max_mm: Bottom-right corner in mm. layer: Layer name. width_mm: Outline width in mm. filled: Whether the rectangle is solid-filled.
Inputs: x_max_mm (required), x_min_mm (required), y_max_mm (required), y_min_mm (required), +3 more. Returns: object
add_schematic_textC
Add a free text object to the open schematic.
Args: text: Text string. x_mm, y_mm: Position in mm.
Inputs: text (required), x_mm (required), y_mm (required). Returns: object
add_textB
Add free text to the board.
Args: text: The text string. x_mm, y_mm: Anchor position in mm. layer: Layer name, e.g. 'F.SilkS'. size_mm: Glyph height (and width) in mm. thickness_mm: Stroke thickness in mm. angle_deg: Rotation in degrees.
Inputs: text (required), x_mm (required), y_mm (required), layer, +3 more. Returns: object
add_trackA
Add a straight copper track segment. Prefer route_pads (connect pads by name) or add_track_path (multi-segment) - they avoid hand-copied coordinates.
Args: start_x_mm, start_y_mm: Start point in mm. end_x_mm, end_y_mm: End point in mm. width_mm: Track width in mm; default is the net's netclass width. layer: Copper layer name, e.g. 'F.Cu' or 'B.Cu'. net_name: Net to assign (must exist on the board).
Inputs: end_x_mm (required), end_y_mm (required), start_x_mm (required), start_y_mm (required), +3 more. Returns: object
add_track_pathA
Draw a connected multi-segment track through a list of points in one step, then check both ends are connected and nothing is too close.
Args: points: Vertices, each [x, y] or {"x_mm":.., "y_mm":..}; at least 2. net_name: Net to assign (must exist; e.g. 'GND', '/MOTOR_A'). layer: Copper layer name. width_mm: Track width; default is the net's netclass width. rollback_on_conflict: Undo the path if any clearance problem is found.
Inputs: points (required), net_name (required), layer, width_mm, +1 more. Returns: object
add_viaA
Add a through via at a position, sized from the net's netclass by default, and report clearance problems with other nets on the outer layers.
Args: x_mm, y_mm: Via centre in mm. diameter_mm: Copper diameter in mm; default from netclass. drill_mm: Drill diameter in mm; default from netclass. net_name: Net to assign (must exist on the board).
Inputs: x_mm (required), y_mm (required), drill_mm, net_name, +1 more. Returns: object
add_zoneA
Add a copper zone (filled pour) bounded by a polygon outline.
Args: points: Outline vertices, each {"x_mm": .., "y_mm": ..} or [x, y]. >= 3 points. layers: Layer names the zone exists on, e.g. ['F.Cu']. net_name: Net to connect the pour to (e.g. 'GND'). Empty for no net. name: Optional zone name. priority: Fill priority (higher fills first). refill: Refill all zones after creating (slower, reflects in editor).
Inputs: layers (required), points (required), name, refill, +2 more. Returns: object
add_zone_rectA
Add a rectangular copper zone (convenience wrapper around add_zone).
Args: x_min_mm, y_min_mm: Top-left corner in mm. x_max_mm, y_max_mm: Bottom-right corner in mm. layers: Layer names, e.g. ['F.Cu']. net_name: Net to connect (e.g. 'GND'). name: Optional zone name. priority: Fill priority. refill: Refill zones after creating.
Inputs: layers (required), x_max_mm (required), x_min_mm (required), y_max_mm (required), +5 more. Returns: object
analyze_power_budgetA
Estimate how much current every supply net carries, from the schematic, and suggest track widths / net classes. Works for any kind of board.
Reads the saved schematic via kicad-cli (save it first). Parts are looked up in the current database; regulators, drivers, and series parts (fuse, diode, switch, inductor, 0-ohm) propagate current from loads back to the source.
Returns 'questions' when information is missing - answer them and run again:
unknown_parts: open the part's 'datasheet' link (taken from the KiCad symbol; about half of vendor sites allow automated download - if it fails, search the web for " datasheet"), read the supply/output current figures, then call set_part_current with the URL as source. 'rating_hint' is only a pointer from the symbol description.
unknown_connectors: ask the user what is plugged in (and its worst-case current, e.g. motor stall), then pass it in external_loads. Values from the built-in database are flagged in 'unverified_parts' until checked against a datasheet.
Args: schematic_path: .kicad_sch / .kicad_pro / project folder; default = project of the open board. external_loads: What hangs off connectors (or any part), by reference: {"J2": 2.5} or {"J2": {"typ_a": 0.4, "max_a": 2.5, "note": "motor stall"}}. Current is charged to every non-ground net the part touches; restrict with "pins": ["1"] (e.g. only the supply pin of a 3-pin servo header). sources: References of the supply inputs (battery/power connectors). Default: batteries, USB/barrel jacks, and connectors named like BAT/PWR/SUPPLY. net_voltages: Voltages for nets whose name doesn't say it, e.g. {"/VMOT": 7.4}; used for switching regulators and linear-regulator dissipation. temp_rise_c: Temperature rise for the width suggestions. copper_oz: Copper weight for the width suggestions.
Inputs: sources, copper_oz, temp_rise_c, net_voltages, +2 more. Returns: object
arrange_rowA
Line several parts up in a row or column in one undo step.
Args:
references: Parts in order, e.g. ['R1', 'R2', 'R3'].
start_x_mm, start_y_mm: Origin of the first part.
pitch_mm: Fixed origin-to-origin spacing. If omitted, parts are packed
courtyard-to-courtyard with gap_mm between them.
direction: 'x' (row, left to right) or 'y' (column, top to bottom).
gap_mm: Gap used when pitch_mm is omitted.
angle_deg: Optional absolute rotation applied to every part.
Inputs: references (required), start_x_mm (required), start_y_mm (required), gap_mm, +3 more. Returns: object
autorouteA
Route the remaining connections with Freerouting.
Typical flow: set net classes (configure_netclasses), route or pour the high-current nets yourself, then autoroute the rest with those classes in skip_netclasses. Existing tracks are locked so they are not moved.
With the board open in KiCad it is saved, backed up (.pre-autoroute.kicad_pcb), routed on disk, and reloaded into the editor - that replaces the editor's undo history, so the backup is the way back. Afterwards zones are refilled and DRC runs; always read 'drc_after' (copper text and some keepouts are invisible to Freerouting).
Args: max_passes: Autorouter pass limit (honoured by Freerouting 2.2+). timeout_s: Hard limit for the Freerouting run, in seconds. lock_existing: Keep existing tracks exactly where they are. skip_netclasses: Net classes Freerouting must not route, e.g. ['HighCurrent']. board_file: Route this .kicad_pcb on disk instead of the open board.
Inputs: timeout_s, board_file, max_passes, lock_existing, +1 more. Returns: object
batch_move_footprintsA
Move/rotate several footprints in a single undo step.
Args: moves: List of objects with keys 'reference', 'x_mm', 'y_mm', and optional 'angle_deg'. Example: [{"reference": "R1", "x_mm": 100, "y_mm": 95}, {"reference": "C1", "x_mm": 102, "y_mm": 95, "angle_deg": 90}]
Inputs: moves (required). Returns: object
calc_track_widthA
IPC-2221 minimum track width for a current, plus resistance and voltage drop when a length is given.
Args: current_a: Continuous (or worst-case, e.g. motor stall) current in amps. temp_rise_c: Allowed temperature rise above ambient (10 C is conservative). copper_oz: Copper weight (1 oz = 35 um is the usual default). internal_layer: True for inner layers (they cool worse, need ~2.5x width). length_mm: Optional track length to report resistance, drop, and loss.
Inputs: current_a (required), copper_oz, length_mm, temp_rise_c, +1 more. Returns: object
check_clearanceA
Quick clearance check of tracks against other nets' copper (tracks, vias, pads), using each net's netclass clearance. Pass track IDs to check just those, or nothing to check every track. Approximate - run_drc is authoritative.
Args: item_ids: Track KIIDs to check; empty = all tracks on the board.
Inputs: item_ids. Returns: object
check_placementA
Score the current placement: courtyard overlaps, parts off the board, and total airwire (ratsnest) length. Lower airwire length usually means easier routing; compare before/after when moving parts.
Args: exclude_nets: Nets to ignore in the airwire total, typically ['GND'] when a ground pour will connect it. top_airwires: How many of the longest airwires to list.
Inputs: exclude_nets, top_airwires. Returns: object
clear_selectionB
Clear the current selection in the PCB editor.
Inputs: no named parameters. Returns: result
configure_netclassesA
Create/update net classes and assign nets to them in the .kicad_pro file. Widths can be derived from current (IPC-2221) instead of fixed numbers.
The project must be CLOSED in KiCad (both editors): KiCad keeps project settings in memory and would overwrite this change on its next save. Reopen it afterwards and the nets pick up their classes.
Args: classes: One object per class, e.g. [{"name": "Power", "current_a": 1.5, "nets": ["+5V", "VMOT"]}, {"name": "Motor", "current_a": 2.5, "nets": ["AO1", "AO2"]}, {"name": "Signal", "track_width_mm": 0.25, "nets": ["/*"]}] Keys: name (required); nets (names or KiCad wildcard patterns - plain names also match their '/NAME' root-sheet form); current_a (sizes the track via IPC-2221) or track_width_mm; clearance_mm; via_diameter_mm; via_drill_mm; priority (lower wins when patterns overlap). project_path: .kicad_pro file or its folder; default = project of the open board. temp_rise_c: Temperature rise used for current-based widths. copper_oz: Copper weight used for current-based widths. replace_patterns: Drop all existing net-class patterns first.
Inputs: classes (required), copper_oz, temp_rise_c, project_path, +1 more. Returns: object
delete_itemsA
Delete board items by their KIID strings (single undo step).
Args: item_ids: Item KIID strings from any list_* tool.
Inputs: item_ids (required). Returns: result
execute_kipyA
Run arbitrary Python against the live KiCad session (FULL-CONTROL escape hatch).
Use this for anything not covered by a dedicated tool. The code runs in-process with these names pre-bound:
kicad: connected kipy.KiCad instance
board: the open Board, or None if no PCB is open
schematic: the open Schematic, or None
kipy, board_types, geometry, commit
Vector2, Angle, BoardLayer, KiCadObjectType
Conventions:
Internal units are nanometres; build points with Vector2.from_xy_mm(x, y).
Group board edits in a single undo step: with commit(board, "my change"): board.create_items(item)
Assign a variable named
resultto return structured data; anything printed to stdout is also captured.
Args: code: Python source to execute. autosave: If True and a board is open, save it after the code runs.
Example: code = ''' from kipy.board_types import Track from kipy.geometry import Vector2 t = Track() t.start = Vector2.from_xy_mm(10, 10) t.end = Vector2.from_xy_mm(20, 10) t.width = 250000 # 0.25 mm in nm t.layer = BoardLayer.BL_F_Cu with commit(board, "api track"): created = board.create_items(t) result = [c.id.value for c in created] '''
Inputs: code (required), autosave. Returns: object
expand_textA
Expand ${...} text variables in a string using the project's values.
Args: text: Text possibly containing ${VAR} references.
Inputs: text (required). Returns: result
export_bomA
Export a bill of materials (CSV) from the open schematic.
Args: output_path: Destination .csv file. schematic_path: Explicit .kicad_sch path (defaults to the open project's). save_first: Save the schematic before exporting.
Inputs: output_path (required), save_first, schematic_path. Returns: object
export_drillA
Export drill files (Excellon) for the open PCB into a directory.
Args: output_dir: Destination directory (created if needed). save_first: Save the board before exporting.
Inputs: output_dir (required), save_first. Returns: object
export_gerbersA
Export Gerber files for the open PCB into a directory.
Args: output_dir: Destination directory (created if needed). layers: Optional comma-separated layer list, e.g. 'F.Cu,B.Cu,Edge.Cuts'. Empty exports all enabled plottable layers. save_first: Save the board before exporting.
Inputs: output_dir (required), layers, save_first. Returns: object
export_netlistB
Export a netlist from the open schematic.
Args: output_path: Destination netlist file (e.g. .net). schematic_path: Explicit .kicad_sch path (defaults to the open project's). save_first: Save the schematic before exporting.
Inputs: output_path (required), save_first, schematic_path. Returns: object
export_pdfB
Export a PDF plot of selected PCB layers.
Args: output_path: Destination .pdf file. layers: Comma-separated layers to plot. save_first: Save the board before exporting.
Inputs: output_path (required), layers, save_first. Returns: object
export_posA
Export a component placement (pick-and-place) file.
Args: output_path: Destination file. fmt: 'csv', 'ascii', or 'gerber'. side: 'front', 'back', or 'both'. save_first: Save the board before exporting.
Inputs: output_path (required), fmt, side, save_first. Returns: object
export_stepA
Export a 3D STEP model of the open PCB.
Args: output_path: Destination .step/.stp file. save_first: Save the board before exporting.
Inputs: output_path (required), save_first. Returns: object
export_svgB
Export an SVG plot of selected PCB layers.
Args: output_path: Destination .svg file. layers: Comma-separated layers to plot. save_first: Save the board before exporting.
Inputs: output_path (required), layers, save_first. Returns: object
flip_footprintA
Move a footprint to the other side of the board (front <-> back), mirrored in place.
Args: reference: Footprint to flip.
Inputs: reference (required). Returns: object
freerouting_statusA
Report whether autorouting can run: Java version, installed Freerouting jars, and KiCad's Python (needed for DSN/SES conversion).
Inputs: no named parameters. Returns: object
get_board_outlineA
Return all graphic shapes on the Edge.Cuts layer (the board outline).
Inputs: no named parameters. Returns: result
get_board_summaryA
Return counts and basic metadata for the open PCB.
Includes element counts, copper layer count, board file name, and bounding box extents in millimetres.
Inputs: no named parameters. Returns: object
get_bounding_boxA
Return KiCad-computed bounding boxes for the given item IDs.
Args: item_ids: Item KIID strings (from any list_* tool). include_text: Include child reference/value text in footprint boxes.
Inputs: item_ids (required), include_text. Returns: result
get_connected_itemsB
Find items copper-connected to a given item (by KIID).
Args: item_id_str: KIID string of the source track/via/pad.
Inputs: item_id_str (required). Returns: object
get_design_rulesA
Return the board's minimum design-rule constraints in mm (best effort).
Falls back to an explanatory message if the running KiCad build does not expose design rules over the API.
Inputs: no named parameters. Returns: object
get_footprintC
Return full detail for a single footprint by reference designator.
Args: reference: Reference designator, e.g. 'U1'. include_pads: Include the footprint's pads.
Inputs: reference (required), include_pads. Returns: object
get_footprint_geometryA
Position, rotation, side, courtyard box, and every pad (number, net, position, size) of one footprint. Use this before placing or routing around a part.
Args: reference: Reference designator, e.g. 'U1'.
Inputs: reference (required). Returns: object
get_items_by_netB
Summarise every board item belonging to a net (counts by type + IDs).
Args: net_name: The net name, e.g. 'GND'.
Inputs: net_name (required). Returns: object
get_kicad_binary_pathA
Return the full path to a bundled KiCad binary (e.g. 'kicad-cli').
Args: binary_name: Short binary name; '.exe' is assumed on Windows.
Inputs: binary_name. Returns: result
get_netclass_configA
Read net classes and net-to-class patterns from the project file (works with KiCad closed). list_netclasses reads the live values from a running KiCad.
Args: project_path: .kicad_pro file or its folder; default = project of the open board.
Inputs: project_path. Returns: object
get_project_infoA
Return the open project's name and path.
Inputs: no named parameters. Returns: object
get_schematic_hierarchyA
Return the sheet hierarchy of the open schematic (KiCad 11+ feature).
Inputs: no named parameters. Returns: result
get_schematic_summaryA
Return counts of symbols, labels, text, lines, and sheets in the open schematic.
Inputs: no named parameters. Returns: object
get_selectionA
Return the items currently selected in the PCB editor (id + type).
Inputs: no named parameters. Returns: result
get_stackupA
Return the board stackup: ordered layers with type, thickness, material.
Inputs: no named parameters. Returns: result
get_text_variablesA
Return the project's text variables (used in ${VAR} substitutions).
Inputs: no named parameters. Returns: object
get_title_blockA
Return the board's title block fields (title, date, revision, company, comments).
Inputs: no named parameters. Returns: object
get_versionA
Return the connected KiCad version and the kicad-python API version.
Inputs: no named parameters. Returns: object
install_freeroutingA
Download the official Freerouting release jar from GitHub into ~/.kicad10_mcp/freerouting. 'auto' picks the newest release the installed Java can run (2.4.1 on Java 25+, 2.1.0 on Java 21-24). Freerouting is GPL-3.0 and runs as a separate program.
Args: version: 'auto' or an explicit release such as '2.1.0'.
Inputs: version. Returns: object
kicad_statusA
Report whether KiCad is reachable, its version, and which documents are open.
Use this first to confirm connectivity before other operations.
Inputs: no named parameters. Returns: object
list_board_layersB
Report copper layer count plus enabled, visible, and active layers (names).
Inputs: no named parameters. Returns: object
list_dimensionsB
List dimension annotations on the board.
Inputs: no named parameters. Returns: result
list_footprintsB
List footprints on the open PCB.
Args: reference_filter: Case-insensitive substring match on the reference (e.g. 'R', 'U1'). value_filter: Case-insensitive substring match on the component value. include_pads: Include each footprint's pads (number, net, position).
Inputs: include_pads, value_filter, reference_filter. Returns: result
list_groupsA
List item groups on the board with their member item IDs.
Inputs: no named parameters. Returns: result
list_labelsA
List labels (local/global/hierarchical) in the open schematic.
Inputs: no named parameters. Returns: result
list_netclassesA
List the project's net classes and their key parameters (mm).
Inputs: no named parameters. Returns: result
list_netsA
List all nets on the board, optionally filtered by net class name.
Args: netclass_filter: Restrict to nets belonging to this net class.
Inputs: netclass_filter. Returns: result
list_open_documentsA
List all documents currently open in KiCad, grouped by type.
Inputs: no named parameters. Returns: object
list_padsB
List pads on the board, optionally filtered by footprint reference or net.
Args: reference: Only pads belonging to this footprint reference. net_filter: Case-insensitive substring match on the pad's net name.
Inputs: reference, net_filter. Returns: result
list_part_databaseB
List parts the power budget knows about (built-in and user-added).
Args: filter: Optional case-insensitive substring to filter part names.
Inputs: filter. Returns: object
list_schematic_textA
List free text objects in the open schematic.
Inputs: no named parameters. Returns: result
list_shapesA
List graphic shapes (lines, arcs, circles, rectangles, polygons) on the board.
Args: layer: Restrict to a layer name, e.g. 'Edge.Cuts' for the board outline.
Inputs: layer. Returns: result
list_symbolsA
List symbol instances in the open schematic (reference, value, position).
Note: requires KiCad's schematic symbol API (KiCad 11+); on KiCad 10 this may return an error — fall back to execute_kipy or read the .kicad_sch file.
Inputs: no named parameters. Returns: result
list_textA
List free text and text-box objects on the board.
Inputs: no named parameters. Returns: result
list_tracksA
List copper tracks and arc tracks on the board.
Args: layer: Restrict to a layer name, e.g. 'F.Cu'. net_filter: Case-insensitive substring match on the net name.
Inputs: layer, net_filter. Returns: result
list_viasA
List vias on the board, optionally filtered by net.
Inputs: net_filter. Returns: result
list_zonesA
List copper zones, rule areas, and graphic zones on the board.
Inputs: no named parameters. Returns: result
move_footprintB
Move a footprint to an absolute position, optionally setting its rotation.
Args: reference: Reference designator, e.g. 'R1'. x_mm: Target X in millimetres. y_mm: Target Y in millimetres. angle_deg: Optional absolute rotation in degrees.
Inputs: x_mm (required), y_mm (required), reference (required), angle_deg. Returns: result
pingA
Ping the KiCad API server. Returns 'pong' on success.
Inputs: no named parameters. Returns: result
place_near_padA
Place a part right next to a specific pad, just outside the target part's courtyard and aligned with the pad. Ideal for decoupling capacitors, pull-ups, and series resistors.
Args: reference: Footprint to move, e.g. 'C3'. target_reference: Part that owns the pad, e.g. 'U2'. target_pad: Pad number on the target, e.g. '13'. side: 'left', 'right', 'up', 'down', or 'auto' (the courtyard edge nearest the pad). gap_mm: Courtyard-to-courtyard gap in mm. angle_deg: Optional absolute rotation for the moved part (applied first). auto_orient: If the moved part has a pad on the target pad's net, turn it 180 degrees when that makes the same-net pad face the target (so the connecting track doesn't cross the part's other pad).
Inputs: reference (required), target_pad (required), target_reference (required), side, +3 more. Returns: object
place_on_edgeA
Place a part against a board edge (connectors, sensors, switches).
Args: reference: Footprint to move. edge: 'left', 'right', 'top', or 'bottom' edge of the board outline. inset_mm: Distance from the board edge to the part's courtyard. along_mm: Absolute coordinate along the edge (X for top/bottom, Y for left/right). Defaults to the middle of that edge. angle_deg: Optional absolute rotation (applied first).
Inputs: edge (required), reference (required), along_mm, inset_mm, +1 more. Returns: object
place_relativeB
Place a footprint at an offset from another footprint's origin.
Args: reference: Footprint to move. anchor_reference: Footprint to measure from. dx_mm, dy_mm: Offset in mm (Y grows downward). angle_deg: Optional absolute rotation for the moved part.
Inputs: dx_mm (required), dy_mm (required), reference (required), anchor_reference (required), +1 more. Returns: object
refill_zonesA
Refill (recompute) all copper zones on the board. May take a few seconds.
Inputs: no named parameters. Returns: result
render_3dB
Render a 3D image (PNG) of the open PCB.
Args: output_path: Destination .png file. side: 'top', 'bottom', 'left', 'right', 'front', 'back'. width, height: Image dimensions in pixels. save_first: Save the board before rendering.
Inputs: output_path (required), side, width, height, +1 more. Returns: object
revert_boardA
Discard unsaved changes and reload the open PCB from disk.
Inputs: no named parameters. Returns: result
rotate_footprintB
Set a footprint's absolute rotation in degrees.
Args: reference: Reference designator, e.g. 'U1'. angle_deg: Absolute angle in degrees (0, 90, 180, 270, ...).
Inputs: angle_deg (required), reference (required). Returns: result
route_padsA
Route a track between two pads by name - no coordinates needed.
Looks up both pads, takes the net from them, uses the netclass track width unless overridden, draws a 45-degree (or orthogonal) path, and then reports clearance conflicts with other nets. A power track wider than a fine-pitch pad is necked down where it leaves the pad (see 'necks' in the result).
Args: from_reference, from_pad: Start pad, e.g. 'U2', '7'. to_reference, to_pad: End pad, e.g. 'J3', '1'. layer: Copper layer. Empty = a layer both pads share (F.Cu preferred). width_mm: Track width; default is the net's netclass width. style: '45' (default), 'manhattan' (90-degree), or 'direct' (straight line). bend: 'straight_first' or 'diagonal_first' - which end gets the bend. via_at: [x_mm, y_mm] to change layer through a via on the way. Required when the pads have no copper layer in common (e.g. one SMD on each side); if omitted in that case the via goes at the midpoint. to_layer: Layer after the via (default: the other outer layer). rollback_on_conflict: Undo the whole route if any clearance problem is found. neck_down: Where the full width would hit the part's other pins, run the stretch next to the pad at the widest width that fits (at most the pad's size) and widen once clear.
Inputs: to_pad (required), from_pad (required), to_reference (required), from_reference (required), +8 more. Returns: object
run_actionA
Run an arbitrary KiCad tool action by name (power user / unstable API).
Example actions: 'pcbnew.InteractiveRouter.routeSingleTrack', 'pcbnew.EditTool.Rotate', 'common.Control.zoomFitScreen'. Action names are not guaranteed stable across KiCad versions and may have side effects.
Args: action: The KiCad TOOL_ACTION name to invoke.
Inputs: action (required). Returns: object
run_drcA
Run Design Rule Check on the open PCB and summarise the results.
Args: output_path: Optional .json report path (a temp file is used if empty). save_first: Save the board before checking. refill_zones: Refill zones first (in the editor too when saving) - stale fills after routing show up as false clearance errors.
Inputs: save_first, output_path, refill_zones. Returns: object
run_ercA
Run Electrical Rule Check on the open schematic and summarise the results.
Args: output_path: Optional .json report path (a temp file is used if empty). schematic_path: Explicit .kicad_sch path (defaults to the open project's). save_first: Save the schematic before checking.
Inputs: save_first, output_path, schematic_path. Returns: object
run_kicad_cliB
Run an arbitrary kicad-cli command (escape hatch for any export).
Args: args: Argument list after the binary, e.g. ["pcb", "export", "gerbers", "board.kicad_pcb", "-o", "out/"] or ["version"]. Use the currently open board's path from get_board_summary.
Inputs: args (required). Returns: object
save_boardB
Save the currently open PCB to disk.
Inputs: no named parameters. Returns: result
save_board_asB
Save a copy of the open PCB to a new path.
Args: file_path: Destination .kicad_pcb path. overwrite: Overwrite if the file already exists. include_project: Also write the associated project file.
Inputs: file_path (required), overwrite, include_project. Returns: result
save_schematicB
Save the open schematic to disk.
Inputs: no named parameters. Returns: result
select_itemsB
Select board items by ID in the PCB editor.
Args: item_ids: Item KIID strings. add_to_existing: Keep the current selection and add to it.
Inputs: item_ids (required), add_to_existing. Returns: object
set_active_layerB
Set the active drawing layer in the PCB editor.
Args: layer: Layer name, e.g. 'B.Cu'.
Inputs: layer (required). Returns: result
set_copper_layer_countA
Set the number of copper layers (must be even, >= 2).
WARNING: removing layers deletes any content on them and cannot be undone. Pass confirm=True to proceed.
Args: count: New copper layer count. confirm: Must be True to apply the change.
Inputs: count (required), confirm. Returns: result
set_footprint_lockedB
Lock or unlock a footprint.
Args: reference: Reference designator. locked: True to lock, False to unlock.
Inputs: locked (required), reference (required). Returns: result
set_footprint_valueC
Set the value field text of a footprint (e.g. '10k', '100nF').
Args: reference: Reference designator. value: New value string.
Inputs: value (required), reference (required). Returns: result
set_items_lockedC
Lock or unlock arbitrary board items by ID.
Args: item_ids: Item KIID strings. locked: True to lock, False to unlock.
Inputs: locked (required), item_ids (required). Returns: object
set_part_currentA
Save a part's current data (from its datasheet) to the user part database so analyze_power_budget can use it. Always cite where the numbers came from.
Args: part: Symbol name as in KiCad (e.g. 'TB6612FNG'); also used as the match pattern unless entry has "match": [...] (wildcards allowed). entry: Behaviour description; any of: "supply": [{"pins": ["VCC"], "typ_a": 0.0015, "max_a": 0.0022}] "regulators": [{"in_pins": ["VIN"], "out_pins": ["VOUT"], "type": "linear"|"buck", "vout": 3.3, "efficiency": 0.9, "max_out_a": 1.0}] "drivers": [{"supply_pins": ["VM"], "channels": [["OUT1", "OUT2"]], "max_continuous_a": 1.2, "max_peak_a": 3.2}] Pin names must match the KiCad symbol's pin names. source: Datasheet URL (and page/table) the numbers came from. verified: False if the numbers are estimates rather than datasheet values.
Inputs: part (required), entry (required), source (required), verified. Returns: object
set_text_variableA
Set (or add) one project text variable, merging with existing variables.
Args: name: Variable name (referenced as ${name}). value: Variable value.
Inputs: name (required), value (required). Returns: object
set_title_blockB
Update title block string fields on the board.
Args: fields: Map of field name to value, e.g. {"title": "My Board", "revision": "B", "company": "Acme", "date": "2026-05-23"}. Valid field names are returned by get_title_block.
Inputs: fields (required). Returns: object
set_visible_layersA
Set exactly which layers are visible in the editor.
Args: layers: Full list of layer names to make visible (others are hidden).
Inputs: layers (required). Returns: result
snapshot_boardA
Return a PNG picture of the open board (top view) to check placement and routing visually. Front copper is red, back copper blue, zone fills are tinted in their layer's colour, courtyards are grey (front) / purple (back) boxes labelled with references, airwires are yellow.
Args: side: 'both', 'front', or 'back' - which side's parts and copper to draw. show_ratsnest: Draw airwires for connections that copper (tracks, vias, zone fills) does not make yet. ratsnest_exclude_nets: Nets to leave out of the airwires, e.g. ['GND']. highlight_net: Draw this net's pads, tracks, and airwires in green. width_px: Image width in pixels (height follows the board's aspect ratio). show_zones: Draw copper zone fills (refill_zones first if they are stale).
Inputs: side, width_px, show_zones, highlight_net, +2 more.
Tool Schema Changelog
Recent tool additions, removals, and schema changes observed during successful MCP inspections.
Loading tool schema changelog…
TDQS
Scored across 102 tools
The set spans many distinct PCB and project resources, but with 102 tools there are overlapping boundaries among list/get/summary tools, multiple placement/routing helpers, and three general escape hatches (run_action, run_kicad_cli, execute_kipy). Detailed descriptions mitigate most confusion, but an agent can still misselect among near-duplicate inspection, export, and low-level execution tools.
Nearly all names use snake_case and follow a verb_noun or noun_verb convention such as save_board, list_footprints, add_track, and export_gerbers. A few outliers like ping, autoroute, kicad_status, and freerouting_status deviate from the dominant pattern, but the set remains readable and broadly consistent.
102 tools is far beyond the 3-15 range for a coherent MCP server and exceeds the 50+ extreme-mismatch threshold. Even for a complex EDA domain, this volume creates a heavy selection burden and many capabilities could be consolidated.
Coverage is extensive for PCB work: placement, routing, zones, DRC/ERC, autoroute, netclasses, power analysis, visualization, and many export formats are present. Schematic editing is thinner (no symbol/wire creation or deletion), but execute_kipy and run_kicad_cli provide workarounds for gaps.
Maintenance
Related MCP Connectors
MCP server unifying ERPs, CRMs, APIs and knowledge base for Claude, ChatGPT and Gemini.
MCP server for generating rough-draft project plans from natural-language prompts.
MCP server that lets your AI assistant build and deploy apps, hosting each one at a live URL.
One MCP server for the services your AI needs: memory, files, Microsoft 365, kanban and more.
Related MCP Servers
- AlicenseNot gradedqualityDmaintenanceMCP server for creating, modifying, and analyzing KiCAD schematic files using natural language.22MIT
- AlicenseBqualityBmaintenanceAn MCP server that enables AI assistants to analyze schematics, inspect PCBs, trace connections, validate designs, and generate embedded code for KiCad projects.39188MIT
- AlicenseNot gradedqualityDmaintenanceAn MCP server that gives AI agents end-to-end control of KiCad 9+ for rule checks, manufacturing exports, production-readiness certification, and live PCB editor control.MIT
- AlicenseNot gradedqualityCmaintenanceAn MCP server for controlling KiCad EDA software, enabling schematics, PCB design, manufacturing outputs, design checks, and library management through any MCP-compatible AI assistant.MIT