I’m trying to create a filled copper pour in pcbnew.
I can’t get AddArea or InsertArea to work because i can’t tell it what net to use.
Looking at http://docs.kicad.org/doxygen-python i need an integer, ideally from board.GetNetcodeFromNetname()
This doesn’t seem to exist in my script window or in my pcbnew.py file.
I don’t have GetNetsByName or GetNetsByNetcode either, not that they would help.
I do have FindNets, but it returns a structure that addarea or insertarea won’t accept and returns a single entry that has no name which is not correct, my named nets show up correctly in the GUI.
This is my first go at scripting but i haven’t had any trouble with moving components around or placing tracks.
I renamed my folder “python2.7\sitepackages” that contains pcbnew.py and reinstalled latest version but i’m still missing these functions.
can/should i just copy the stubs into my pcbnew.py file?
Now i can script an area but it won’t fill unless there is track inside.
If i draw it through the interface it fills without fuss.
There are pads inside the zone on the same net, just not track.
Is there any proper documentation for scripting? i need to learn the pcbnew source really!