fix: B.Cu footprint Flip() in SWIG path + J2-on-B.Cu prompt note + pin-1-at-top schema hint
This commit is contained in:
@@ -125,10 +125,15 @@ class ComponentCommands:
|
||||
angle = pcbnew.EDA_ANGLE(rotation, pcbnew.DEGREES_T)
|
||||
module.SetOrientation(angle)
|
||||
|
||||
# Set layer
|
||||
layer_id = self.board.GetLayerID(layer)
|
||||
if layer_id >= 0:
|
||||
module.SetLayer(layer_id)
|
||||
# Set layer — for B.Cu the footprint must be flipped (mirrored),
|
||||
# not just layer-assigned. Flip() handles layer + mirror in one step.
|
||||
if layer == "B.Cu":
|
||||
if not module.IsFlipped():
|
||||
module.Flip(module.GetPosition(), False)
|
||||
else:
|
||||
layer_id = self.board.GetLayerID(layer)
|
||||
if layer_id >= 0:
|
||||
module.SetLayer(layer_id)
|
||||
|
||||
# Add to board
|
||||
self.board.Add(module)
|
||||
|
||||
@@ -1561,7 +1561,7 @@ SCHEMATIC_TOOLS = [
|
||||
{
|
||||
"name": "connect_passthrough",
|
||||
"title": "Connect Passthrough (Pin-to-Pin)",
|
||||
"description": "Connects all pins of a source connector to the matching pins of a target connector using shared net labels. Ideal for passthrough adapters where J1 pin N connects directly to J2 pin N. Each pair gets a net label '{netPrefix}_{pinNumber}'. Use this instead of calling connect_to_net 15 times for FFC/ribbon cable passthroughs.",
|
||||
"description": "Connects all pins of a source connector to the matching pins of a target connector using shared net labels. Ideal for passthrough adapters where J1 pin N connects directly to J2 pin N. Each pair gets a net label '{netPrefix}_{pinNumber}'. Use this instead of calling connect_to_net 15 times for FFC/ribbon cable passthroughs. NOTE: KiCAD Connector_Generic symbols always have pin 1 at the TOP of the symbol and pin N at the BOTTOM. When assigning named nets (e.g. GND, CAM_SCL) to specific pin numbers, always use the physical pin number as shown in the connector datasheet — pin 1 = top of symbol.",
|
||||
"inputSchema": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
|
||||
Reference in New Issue
Block a user