While I think this is quite clear from the perspective of communicating the schematic intent, it obviously can’t be directly transferred to the layout like this.
So what’s the best way to proceed? I see three options at the moment:
Draw the N LEDs (64 in my current plans, but lets imagine it were more) in the schematic
Create a script to process the schematic (which I believe is in XML format), to produce a new schematic with the individual LEDs materialised
Import the single LED into the layout and create the N LEDs there.
Option 1 is out of the question. As a computer scientist I can’t accept a manual solution like that, even if it takes me 10x longer to write the script
Option 2 seems quite possible? I see KiCad has a python interface, but maybe just processing the XML file externally would be simplest. I think I can create such a script.
But - don’t options 1 or 2 then mean that when I do the layout I will have N LEDs and N caps to individually drag into place and connect?
Option 3, it seems to me, would have the advantage that I could layout the 1 LED with its cap and incoming/outgoing wires in a suitable pattern, and then use the create array function to lay that pattern out in a grid. Then I would only have to route power lines across all the dangling wires, and connect up the “ends” of each row in the array. Sounds a lot more accurate and a lot faster…
But for Option 3, it seems to me that there will then be problems with DRC and Net-checks, since the original duplicated LED wasn’t connected in the schematic the way it now is in the layout…
So, my question is, are there any good options that I missed? I’m not that experienced with KiCad yet…
Is there any way to maybe combine approaches 2&3, so that I end up with a verifiable layout that matches the schematic, but don’t have to lay each led out individually?
Has anyone has a similar type situation, that they solved well?
On your root page put the two resistors biasing the driver circuit signal and the final termination resistor.
Then place a hierarchical sheet object and create a new schematic name (take note of the filename).
In the hierarchical schematic place one LED, it’s bypass cap, an input hierarchical label and an output hierarchical label.
Return to the root schematic and right-click on the hierarchical sheet object to add the connections, place them where they make sense to you (for me input on the left and output on the right).
Duplicate that sheet 63 times and wire them all in series from the driver signal biasing resistors through to the termination resistor.
Annotate, ERC, and push to the PCB.
In PCBNew layout and place traces for the first sheet’s worth of LED and bypass cap.
Use the ReplicateLayout plugin from here (you’ll need to install it, see the instructions on @MitjaN’s repository page) to duplicate the work you did for the components of the one sheet 63 more times. I haven’t used that tool, but it is for exactly what you want.
Place the LEDs where you want them if the automated placement tools of the plugin don’t provide the flexibility you need.
Then place the traces to connect the LEDs together and to power.
(Edited to change format from wall of text to bullet points.)
A thread I wrote recently has much overlapping info:
But for this, I would simply draw a few footprints (for example 4) then copy them to make 8 in a row, connect them with wires, and then use block copy operations to double the row to 2, 4, and 8.
Is this a linear or an X/Y array?
Not that it matters too much, this is a case for hierachical schematics.
A main one with all drivers and all LEDs as blocks, and then you drill down. A schematic for the drivers showing all of them in a block as small blocks, and then the detailed schematic of each driver in each small block.
Same with the LEDs.
Copy/duplicate the blocks. Incrementing the component references I’m not certain how to do.
EDIT: scratch this, @SembazuruCDE beat me to it and explained it much better
Question about your curciut… The final resistor (R14 in your screenshot)… Is that really a termination resistor like I guessed? If so, it probably shouldn’t be floating. I would expect a termination resistor to be either tied to +V or GND. Check your SK6812 datasheet for the manufacturer’s suggestion.
Keep in mind that Replicate layout plugin works well with Place footprints plugin. And for placement (linear, circular, matrix) I imagine you could use this.
A bit of a background: the placement functionality used to be a part of the Replicate layout plugin, but it was separated into it’s own plugin. So there might be references to placement with replicate layout plugin still on the forum and on the web.