fix: Update schematic format to KiCAD 9 and fix invalid UUIDs (#37)

- Update schematic version from 20230121 (KiCAD 7) to 20240101 (KiCAD 9)
- Replace invalid all-zeros UUIDs in template files with valid UUIDs
- Add post-copy UUID regeneration to ensure each project gets unique UUID
- Add UTF-8 encoding and Unix line endings for cross-platform compatibility

Fixes the root cause where templates were copied with invalid UUIDs and
outdated version format, causing KiCAD 9.0.x to reject the schematic files.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
KiCAD MCP Bot
2026-03-01 07:56:32 -05:00
parent b98c94be42
commit 2b38796409
5 changed files with 295 additions and 32 deletions

View File

@@ -1,11 +1,11 @@
(kicad_sch (version 20250114) (generator "KiCAD-MCP-Server")
(kicad_sch (version 20240101) (generator "KiCAD-MCP-Server")
(uuid 00000000-0000-0000-0000-000000000000)
(uuid c3d4e5f6-a7b8-4c9d-0e1f-2a3b4c5d6e7f)
(paper "A4")
(lib_symbols
;; PASSIVES
(symbol "Device:R" (pin_numbers hide) (pin_names (offset 0)) (in_bom yes) (on_board yes)
(property "Reference" "R" (at 2.032 0 90)
(effects (font (size 1.27 1.27)))
@@ -182,7 +182,7 @@
)
)
)
;; SEMICONDUCTORS
(symbol "Device:D" (pin_numbers hide) (pin_names (offset 1.016) hide) (in_bom yes) (on_board yes)
(property "Reference" "D" (at 0 2.54 0)
(effects (font (size 1.27 1.27)))
@@ -497,7 +497,7 @@
)
)
)
;; INTEGRATED CIRCUITS
(symbol "Amplifier_Operational:LM358" (pin_names (offset 0.127)) (in_bom yes) (on_board yes)
(property "Reference" "U" (at 0 5.08 0)
(effects (font (size 1.27 1.27)) (justify left))
@@ -546,7 +546,7 @@
)
)
)
;; CONNECTORS
(symbol "Connector_Generic:Conn_01x02" (pin_names (offset 1.016) hide) (in_bom yes) (on_board yes)
(property "Reference" "J" (at 0 2.54 0)
(effects (font (size 1.27 1.27)))
@@ -635,7 +635,7 @@
)
)
)
;; POWER/REGULATORS
(symbol "Regulator_Linear:AMS1117-3.3" (pin_names (offset 0.254)) (in_bom yes) (on_board yes)
(property "Reference" "U" (at -3.81 3.175 0)
(effects (font (size 1.27 1.27)))
@@ -670,7 +670,7 @@
)
)
)
;; MISC
(symbol "Switch:SW_Push" (pin_numbers hide) (pin_names (offset 1.016) hide) (in_bom yes) (on_board yes)
(property "Reference" "SW" (at 1.27 2.54 0)
(effects (font (size 1.27 1.27)) (justify left))
@@ -721,19 +721,261 @@
)
)
;; TEMPLATE INSTANCES (placed offscreen at -100, -110, etc.)
(symbol (lib_id "Device:R") (at -100 -100 0) (unit 1)
(in_bom no) (on_board no) (dnp yes)
(uuid 00000000-0000-0000-0000-000000000001)
(property "Reference" "_TEMPLATE_R" (at -100 -102.54 0)
(effects (font (size 1.27 1.27)))
)
(property "Value" "R" (at -100 -100 90)
(effects (font (size 1.27 1.27)))
)
(property "Footprint" "" (at -100 -100 90)
(effects (font (size 1.27 1.27)) hide)
)
(property "Datasheet" "~" (at -100 -100 0)
(effects (font (size 1.27 1.27)) hide)
)
(pin "1" (uuid 10000000-0000-0000-0000-000000000001))
(pin "2" (uuid 10000000-0000-0000-0000-000000000002))
)
(symbol (lib_id "Device:C") (at -100 -110 0) (unit 1)
(in_bom no) (on_board no) (dnp yes)
(uuid 00000000-0000-0000-0000-000000000002)
(property "Reference" "_TEMPLATE_C" (at -100 -107.46 0)
(effects (font (size 1.27 1.27)))
)
(property "Value" "C" (at -100 -112.54 0)
(effects (font (size 1.27 1.27)))
)
(property "Footprint" "" (at -100 -110 0)
(effects (font (size 1.27 1.27)) hide)
)
(property "Datasheet" "~" (at -100 -110 0)
(effects (font (size 1.27 1.27)) hide)
)
(pin "1" (uuid 20000000-0000-0000-0000-000000000001))
(pin "2" (uuid 20000000-0000-0000-0000-000000000002))
)
(symbol (lib_id "Device:L") (at -100 -120 0) (unit 1)
(in_bom no) (on_board no) (dnp yes)
(uuid 00000000-0000-0000-0000-000000000003)
(property "Reference" "_TEMPLATE_L" (at -100 -117.46 0)
(effects (font (size 1.27 1.27)))
)
(property "Value" "L" (at -100 -122.54 0)
(effects (font (size 1.27 1.27)))
)
(property "Footprint" "" (at -100 -120 0)
(effects (font (size 1.27 1.27)) hide)
)
(property "Datasheet" "~" (at -100 -120 0)
(effects (font (size 1.27 1.27)) hide)
)
(pin "1" (uuid 30000000-0000-0000-0000-000000000001))
(pin "2" (uuid 30000000-0000-0000-0000-000000000002))
)
(symbol (lib_id "Device:Crystal") (at -100 -130 0) (unit 1)
(in_bom no) (on_board no) (dnp yes)
(uuid 00000000-0000-0000-0000-000000000004)
(property "Reference" "_TEMPLATE_Y" (at -100 -127.46 0)
(effects (font (size 1.27 1.27)))
)
(property "Value" "Crystal" (at -100 -132.54 0)
(effects (font (size 1.27 1.27)))
)
(property "Footprint" "" (at -100 -130 0)
(effects (font (size 1.27 1.27)) hide)
)
(property "Datasheet" "~" (at -100 -130 0)
(effects (font (size 1.27 1.27)) hide)
)
(pin "1" (uuid 40000000-0000-0000-0000-000000000001))
(pin "2" (uuid 40000000-0000-0000-0000-000000000002))
)
(symbol (lib_id "Device:D") (at -100 -140 0) (unit 1)
(in_bom no) (on_board no) (dnp yes)
(uuid 00000000-0000-0000-0000-000000000005)
(property "Reference" "_TEMPLATE_D" (at -100 -137.46 0)
(effects (font (size 1.27 1.27)))
)
(property "Value" "D" (at -100 -142.54 0)
(effects (font (size 1.27 1.27)))
)
(property "Footprint" "" (at -100 -140 0)
(effects (font (size 1.27 1.27)) hide)
)
(property "Datasheet" "~" (at -100 -140 0)
(effects (font (size 1.27 1.27)) hide)
)
(pin "1" (uuid 50000000-0000-0000-0000-000000000001))
(pin "2" (uuid 50000000-0000-0000-0000-000000000002))
)
(symbol (lib_id "Device:LED") (at -100 -150 0) (unit 1)
(in_bom no) (on_board no) (dnp yes)
(uuid 00000000-0000-0000-0000-000000000006)
(property "Reference" "_TEMPLATE_LED" (at -100 -147.46 0)
(effects (font (size 1.27 1.27)))
)
(property "Value" "LED" (at -100 -152.54 0)
(effects (font (size 1.27 1.27)))
)
(property "Footprint" "" (at -100 -150 0)
(effects (font (size 1.27 1.27)) hide)
)
(property "Datasheet" "~" (at -100 -150 0)
(effects (font (size 1.27 1.27)) hide)
)
(pin "1" (uuid 60000000-0000-0000-0000-000000000001))
(pin "2" (uuid 60000000-0000-0000-0000-000000000002))
)
(symbol (lib_id "Device:Q_NPN_BCE") (at -100 -160 0) (unit 1)
(in_bom no) (on_board no) (dnp yes)
(uuid 00000000-0000-0000-0000-000000000007)
(property "Reference" "_TEMPLATE_Q_NPN" (at -100 -157.46 0)
(effects (font (size 1.27 1.27)))
)
(property "Value" "Q_NPN" (at -100 -162.54 0)
(effects (font (size 1.27 1.27)))
)
(property "Footprint" "" (at -100 -160 0)
(effects (font (size 1.27 1.27)) hide)
)
(property "Datasheet" "~" (at -100 -160 0)
(effects (font (size 1.27 1.27)) hide)
)
(pin "1" (uuid 70000000-0000-0000-0000-000000000001))
(pin "2" (uuid 70000000-0000-0000-0000-000000000002))
(pin "3" (uuid 70000000-0000-0000-0000-000000000003))
)
(symbol (lib_id "Device:Q_NMOS_GSD") (at -100 -170 0) (unit 1)
(in_bom no) (on_board no) (dnp yes)
(uuid 00000000-0000-0000-0000-000000000008)
(property "Reference" "_TEMPLATE_Q_NMOS" (at -100 -167.46 0)
(effects (font (size 1.27 1.27)))
)
(property "Value" "Q_NMOS" (at -100 -172.54 0)
(effects (font (size 1.27 1.27)))
)
(property "Footprint" "" (at -100 -170 0)
(effects (font (size 1.27 1.27)) hide)
)
(property "Datasheet" "~" (at -100 -170 0)
(effects (font (size 1.27 1.27)) hide)
)
(pin "1" (uuid 80000000-0000-0000-0000-000000000001))
(pin "2" (uuid 80000000-0000-0000-0000-000000000002))
(pin "3" (uuid 80000000-0000-0000-0000-000000000003))
)
(symbol (lib_id "Amplifier_Operational:LM358") (at -100 -180 0) (unit 1)
(in_bom no) (on_board no) (dnp yes)
(uuid 00000000-0000-0000-0000-000000000009)
(property "Reference" "_TEMPLATE_U_OPAMP" (at -100 -177.46 0)
(effects (font (size 1.27 1.27)))
)
(property "Value" "OpAmp" (at -100 -182.54 0)
(effects (font (size 1.27 1.27)))
)
(property "Footprint" "" (at -100 -180 0)
(effects (font (size 1.27 1.27)) hide)
)
(property "Datasheet" "" (at -100 -180 0)
(effects (font (size 1.27 1.27)) hide)
)
(pin "1" (uuid 90000000-0000-0000-0000-000000000001))
(pin "2" (uuid 90000000-0000-0000-0000-000000000002))
(pin "3" (uuid 90000000-0000-0000-0000-000000000003))
(pin "4" (uuid 90000000-0000-0000-0000-000000000004))
(pin "8" (uuid 90000000-0000-0000-0000-000000000005))
)
(symbol (lib_id "Connector_Generic:Conn_01x02") (at -100 -190 0) (unit 1)
(in_bom no) (on_board no) (dnp yes)
(uuid 00000000-0000-0000-0000-00000000000A)
(property "Reference" "_TEMPLATE_J2" (at -100 -187.46 0)
(effects (font (size 1.27 1.27)))
)
(property "Value" "Conn_2" (at -100 -192.54 0)
(effects (font (size 1.27 1.27)))
)
(property "Footprint" "" (at -100 -190 0)
(effects (font (size 1.27 1.27)) hide)
)
(property "Datasheet" "~" (at -100 -190 0)
(effects (font (size 1.27 1.27)) hide)
)
(pin "1" (uuid A0000000-0000-0000-0000-000000000001))
(pin "2" (uuid A0000000-0000-0000-0000-000000000002))
)
(symbol (lib_id "Connector_Generic:Conn_01x04") (at -100 -200 0) (unit 1)
(in_bom no) (on_board no) (dnp yes)
(uuid 00000000-0000-0000-0000-00000000000B)
(property "Reference" "_TEMPLATE_J4" (at -100 -197.46 0)
(effects (font (size 1.27 1.27)))
)
(property "Value" "Conn_4" (at -100 -202.54 0)
(effects (font (size 1.27 1.27)))
)
(property "Footprint" "" (at -100 -200 0)
(effects (font (size 1.27 1.27)) hide)
)
(property "Datasheet" "~" (at -100 -200 0)
(effects (font (size 1.27 1.27)) hide)
)
(pin "1" (uuid B0000000-0000-0000-0000-000000000001))
(pin "2" (uuid B0000000-0000-0000-0000-000000000002))
(pin "3" (uuid B0000000-0000-0000-0000-000000000003))
(pin "4" (uuid B0000000-0000-0000-0000-000000000004))
)
(symbol (lib_id "Regulator_Linear:AMS1117-3.3") (at -100 -210 0) (unit 1)
(in_bom no) (on_board no) (dnp yes)
(uuid 00000000-0000-0000-0000-00000000000C)
(property "Reference" "_TEMPLATE_U_REG" (at -100 -207.46 0)
(effects (font (size 1.27 1.27)))
)
(property "Value" "Regulator" (at -100 -212.54 0)
(effects (font (size 1.27 1.27)))
)
(property "Footprint" "" (at -100 -210 0)
(effects (font (size 1.27 1.27)) hide)
)
(property "Datasheet" "" (at -100 -210 0)
(effects (font (size 1.27 1.27)) hide)
)
(pin "1" (uuid C0000000-0000-0000-0000-000000000001))
(pin "2" (uuid C0000000-0000-0000-0000-000000000002))
(pin "3" (uuid C0000000-0000-0000-0000-000000000003))
)
(symbol (lib_id "Switch:SW_Push") (at -100 -220 0) (unit 1)
(in_bom no) (on_board no) (dnp yes)
(uuid 00000000-0000-0000-0000-00000000000D)
(property "Reference" "_TEMPLATE_SW" (at -100 -217.46 0)
(effects (font (size 1.27 1.27)))
)
(property "Value" "Switch" (at -100 -222.54 0)
(effects (font (size 1.27 1.27)))
)
(property "Footprint" "" (at -100 -220 0)
(effects (font (size 1.27 1.27)) hide)
)
(property "Datasheet" "~" (at -100 -220 0)
(effects (font (size 1.27 1.27)) hide)
)
(pin "1" (uuid D0000000-0000-0000-0000-000000000001))
(pin "2" (uuid D0000000-0000-0000-0000-000000000002))
)
(sheet_instances
(path "/" (page "1"))