diff options
author | saurabhb17 | 2020-02-26 15:57:49 +0530 |
---|---|---|
committer | saurabhb17 | 2020-02-26 15:57:49 +0530 |
commit | aa35045840b78d3f48212db45da59a2e5c69b223 (patch) | |
tree | 6acee185a4dc19113fcbf0f9a3d6941085dedaf7 /pcbnew/scripting/tests | |
parent | 0db48f6533517ecebfd9f0693f89deca28408b76 (diff) | |
download | KiCad-eSim-aa35045840b78d3f48212db45da59a2e5c69b223.tar.gz KiCad-eSim-aa35045840b78d3f48212db45da59a2e5c69b223.tar.bz2 KiCad-eSim-aa35045840b78d3f48212db45da59a2e5c69b223.zip |
Added main execs
Diffstat (limited to 'pcbnew/scripting/tests')
-rw-r--r-- | pcbnew/scripting/tests/test1.py | 11 | ||||
-rw-r--r-- | pcbnew/scripting/tests/test2.py | 8 |
2 files changed, 19 insertions, 0 deletions
diff --git a/pcbnew/scripting/tests/test1.py b/pcbnew/scripting/tests/test1.py new file mode 100644 index 0000000..b1f7cff --- /dev/null +++ b/pcbnew/scripting/tests/test1.py @@ -0,0 +1,11 @@ +import pcbnew + +pcb = pcbnew.GetBoard() + +for m in pcb.GetModules(): + print m.GetPosition() + for p in m.Pads(): + print "p=>",p.GetPosition(),p.GetPadName() + print p.GetPosition() + + diff --git a/pcbnew/scripting/tests/test2.py b/pcbnew/scripting/tests/test2.py new file mode 100644 index 0000000..e925f88 --- /dev/null +++ b/pcbnew/scripting/tests/test2.py @@ -0,0 +1,8 @@ +import pcbnew + +pcb = pcbnew.GetBoard() + +for m in pcb.GetModules(): + print m.GetReference(),"(",m.GetValue(),") at ", m.GetPosition() + for p in m.Pads(): + print " pad",p.GetPadName(), "at",p.GetPosition() |