summaryrefslogtreecommitdiff
path: root/templates
diff options
context:
space:
mode:
authorTrygve Laugstøl <trygvis@inamo.no>2017-12-01 13:38:35 +0100
committerTrygve Laugstøl <trygvis@inamo.no>2017-12-01 13:38:35 +0100
commit992c05812ec18b51a2f3368bf4851111950352e7 (patch)
tree42f39b1389369b6a33e81737c202ed9384ff5f82 /templates
parentefa60d73f8912f518a89072653efbceeeac28385 (diff)
downloadIPC-7351-footprints-generator-992c05812ec18b51a2f3368bf4851111950352e7.tar.gz
IPC-7351-footprints-generator-992c05812ec18b51a2f3368bf4851111950352e7.tar.bz2
IPC-7351-footprints-generator-992c05812ec18b51a2f3368bf4851111950352e7.tar.xz
IPC-7351-footprints-generator-992c05812ec18b51a2f3368bf4851111950352e7.zip
o More structure. Moving all data from IPC-782 into its own file.
Diffstat (limited to 'templates')
-rw-r--r--templates/CHIP.j232
1 files changed, 16 insertions, 16 deletions
diff --git a/templates/CHIP.j2 b/templates/CHIP.j2
index 13ee398..11c8789 100644
--- a/templates/CHIP.j2
+++ b/templates/CHIP.j2
@@ -1,31 +1,31 @@
(module {{key}} (layer F.Cu) (tedit 5A2018AF)
(attr smd)
- (fp_text reference REF** (at 0 {{sy/-4 * 0.1}}) (layer F.Fab)
- (effects (font (size {{sy/5 * 0.1}} {{sy/5 * 0.1}}) (thickness {{sy/5 * 0.015}})))
+ (fp_text reference REF** (at 0 {{ lp.size_y / -4 }}) (layer F.Fab)
+ (effects (font (size {{ rnd2(lp.size_y / 5) }} {{ lp.size_y / 5 }}) (thickness {{ lp.size_y / 5 * 0.15 }})))
)
- (fp_text value VAL** (at 0 {{sy/4 * 0.1}}) (layer F.Fab)
- (effects (font (size {{sy/5 * 0.1}} {{sy/5 * 0.1}}) (thickness {{sy/5 * 0.015}})))
+ (fp_text value VAL** (at 0 {{ lp.size_y / 4 }}) (layer F.Fab)
+ (effects (font (size {{ rnd2(lp.size_y / 5) }} {{ lp.size_y / 5 }}) (thickness {{ lp.size_y / 5 * 0.15 }})))
)
- (fp_text user %R (at 0 {{sy/-4 * 0.1}}) (layer "F.SilkS")
+ (fp_text user %R (at 0 {{ lp.size_y / -4 }}) (layer "F.SilkS")
(effects (font (size 0.7 0.7) (thickness 0.1)))
)
- (fp_text user %V (at 0 {{sy/4 * 0.1}}) (layer "F.SilkS")
+ (fp_text user %V (at 0 {{ lp.size_y / 4 }}) (layer "F.SilkS")
(effects (font (size 0.7 0.7) (thickness 0.1)))
)
{# Outline #}
- (fp_line (start {{sx/-20}} {{sy/-20}}) (end {{sx/ 20}} {{sy/-20}}) (layer F.Fab) (width 0.05))
- (fp_line (start {{sx/ 20}} {{sy/-20}}) (end {{sx/ 20}} {{sy/ 20}}) (layer F.Fab) (width 0.05))
- (fp_line (start {{sx/ 20}} {{sy/ 20}}) (end {{sx/-20}} {{sy/ 20}}) (layer F.Fab) (width 0.05))
- (fp_line (start {{sx/-20}} {{sy/ 20}}) (end {{sx/-20}} {{sy/-20}}) (layer F.Fab) (width 0.05))
+ (fp_line (start {{ lp.size_x / -2 }} {{ lp.size_y / -2 }}) (end {{ lp.size_x / 2 }} {{ lp.size_y / -2 }}) (layer F.Fab) (width 0.05))
+ (fp_line (start {{ lp.size_x / 2 }} {{ lp.size_y / -2 }}) (end {{ lp.size_x / 2 }} {{ lp.size_y / 2 }}) (layer F.Fab) (width 0.05))
+ (fp_line (start {{ lp.size_x / 2 }} {{ lp.size_y / 2 }}) (end {{ lp.size_x / -2 }} {{ lp.size_y / 2 }}) (layer F.Fab) (width 0.05))
+ (fp_line (start {{ lp.size_x / -2 }} {{ lp.size_y / 2 }}) (end {{ lp.size_x / -2 }} {{ lp.size_y / -2 }}) (layer F.Fab) (width 0.05))
{# Courtyard #}
- (fp_line (start {{gx/-2}} {{gy/-2}}) (end {{gx/2}} {{gy/-2}}) (layer F.CrtYd) (width 0.05))
- (fp_line (start {{gx/2}} {{gy/-2}}) (end {{gx/2}} {{gy/2}}) (layer F.CrtYd) (width 0.05))
- (fp_line (start {{gx/2}} {{gy/2}}) (end {{gx/-2}} {{gy/2}}) (layer F.CrtYd) (width 0.05))
- (fp_line (start {{gx/-2}} {{gy/2}}) (end {{gx/-2}} {{gy/-2}}) (layer F.CrtYd) (width 0.05))
+ (fp_line (start {{ -lp.courtyard_x }} {{ -lp.courtyard_y }}) (end {{ lp.courtyard_x }} {{ -lp.courtyard_y }}) (layer F.CrtYd) (width 0.05))
+ (fp_line (start {{ lp.courtyard_x }} {{ -lp.courtyard_y }}) (end {{ lp.courtyard_x }} {{ lp.courtyard_y }}) (layer F.CrtYd) (width 0.05))
+ (fp_line (start {{ lp.courtyard_x }} {{ lp.courtyard_y }}) (end {{ -lp.courtyard_x }} {{ lp.courtyard_y }}) (layer F.CrtYd) (width 0.05))
+ (fp_line (start {{ -lp.courtyard_x }} {{ lp.courtyard_y }}) (end {{ -lp.courtyard_x }} {{ -lp.courtyard_y }}) (layer F.CrtYd) (width 0.05))
- (pad 1 smd rect (at {{pcc/-2}} 0) (size {{px}} {{py}}) (layers F.Cu F.Paste F.Mask))
- (pad 2 smd rect (at {{pcc/2}} 0) (size {{px}} {{py}}) (layers F.Cu F.Paste F.Mask))
+ (pad 1 smd rect (at {{ -lp.pad_pos_x }} 0) (size {{ lp.pad_size_x }} {{ lp.pad_size_y }}) (layers F.Cu F.Paste F.Mask))
+ (pad 2 smd rect (at {{ lp.pad_pos_x }} 0) (size {{ lp.pad_size_x }} {{ lp.pad_size_y }}) (layers F.Cu F.Paste F.Mask))
)