A => +95 -0
@@ 0,0 1,95 @@
module.exports = {
nets: {
neg: undefined,
pos: undefined,
},
body: p => `
(module BatteryPads
(layer "F.Cu")
${p.at /* parametric position */}
${'' /* TODO: Does not yet support rotation */}
(fp_text reference "BT1" (at 0 0.5) (layer "F.SilkS") hide (effects (font (size 1 1) (thickness 0.15))))
(fp_text value "Battery_Cell" (at 0 -0.5) (layer "F.Fab") (effects (font (size 1 1) (thickness 0.15))))
(fp_text user "Battery_Cell" (at 0 -0.5) (layer "B.Fab") (effects (font (size 1 1) (thickness 0.15)) (justify mirror)))
(fp_text user "BT01" (at 0 0.5) (layer "B.SilkS") hide (effects (font (size 1 1) (thickness 0.15)) (justify mirror)))
(fp_text user "Battery" (at 3.175 0.79375 90) (layer "F.SilkS") hide (effects (font (size 0.8 0.8) (thickness 0.1))))
(fp_text user "Battery" (at 3.175 0.79375 90) (layer "B.SilkS") hide (effects (font (size 0.8 0.8) (thickness 0.1)) (justify mirror)))
(fp_text user "(+)" (at -1.1 -2.286) (layer "F.SilkS") (effects (font (size 0.8 0.8) (thickness 0.1))))
(fp_text user "(+)" (at -1.1 -2.286) (layer "B.SilkS") (effects (font (size 0.8 0.8) (thickness 0.1)) (justify mirror)))
(fp_text user "(-)" (at 1.1 -2.286) (layer "F.SilkS") (effects (font (size 0.8 0.8) (thickness 0.1))))
(fp_text user "(-)" (at 1.1 -2.286) (layer "B.SilkS") (effects (font (size 0.8 0.8) (thickness 0.1)) (justify mirror)))
(fp_poly (pts
(xy 0.4 -1)
(xy 0.4 1)
(xy 1.8 1)
(xy 1.8 -1)
) (layer "B.Mask") (width 0.1) (fill solid))
(fp_poly (pts
(xy -1.8 -1)
(xy -1.8 1)
(xy -0.4 1)
(xy -0.4 -1)
) (layer "B.Mask") (width 0.1) (fill solid))
(fp_poly (pts
(xy -0.401442 -1)
(xy -0.401442 1)
(xy -1.801442 1)
(xy -1.801442 -1)
) (layer "F.Mask") (width 0.1) (fill solid))
(fp_poly (pts
(xy 1.8 -1)
(xy 1.8 1)
(xy 0.4 1)
(xy 0.4 -1)
) (layer "F.Mask") (width 0.1) (fill solid))
(pad "1" thru_hole circle (at -1.1004 -1.3416) (size 0.4572 0.4572) (drill 0.3048) (layers *.Cu) ${p.net.pos.str})
(pad "1" smd custom (at -1.1 0 180) (size 1.5 2.1) (layers "F.Cu")
(options (clearance outline) (anchor rect))
(primitives
(gr_poly (pts
(xy 0.179 1.3352)
(xy -0.1766 1.3352)
(xy -0.1766 0.762)
(xy 0.179 0.762)
) (width 0.1) (fill yes))
))
(pad "1" smd custom (at -1.1 0) (size 1.5 2.1) (layers "B.Cu")
(options (clearance outline) (anchor rect))
(primitives
(gr_poly (pts
(xy 0.176556 -0.7618)
(xy -0.179044 -0.7618)
(xy -0.179044 -1.335)
(xy 0.176556 -1.335)
) (width 0.1) (fill yes))
))
(pad "2" thru_hole circle (at 1.1 -1.3416) (size 0.4572 0.4572) (drill 0.3048) (layers *.Cu) ${p.net.neg.str})
(pad "2" smd custom (at 1.1 0 180) (size 1.5 2.1) (layers "F.Cu")
(options (clearance outline) (anchor rect))
(primitives
(gr_poly (pts
(xy 0.1786 1.3352)
(xy -0.177 1.3352)
(xy -0.177 0.762)
(xy 0.1786 0.762)
) (width 0.1) (fill yes))
))
(pad "2" smd custom (at 1.1 0) (size 1.5 2.1) (layers "B.Cu")
(options (clearance outline) (anchor rect))
(primitives
(gr_poly (pts
(xy 0.1766 -0.7618)
(xy -0.179 -0.7618)
(xy -0.179 -1.335)
(xy 0.1766 -1.335)
) (width 0.1) (fill yes))
))
)
`
}
A => +19 -0
@@ 0,0 1,19 @@
module.exports = {
nets: {
from: undefined,
to: undefined,
},
body: p => `
(module TwoLeadButton
(layer "F.Cu")
${p.at /* parametric position */}
(fp_text reference "B1" (at 0 0 unlocked) (layer "F.SilkS") (effects (font (size 1 1) (thickness 0.15))))
(fp_text value "Button" (at 0 2.54 unlocked) (layer "F.Fab") (effects (font (size 1 1) (thickness 0.15))))
(fp_text user "Button" (at 0 0 unlocked) (layer "F.Fab") (effects (font (size 1 1) (thickness 0.15))))
(pad "1" smd roundrect (at -2.2 0) (size 1 2) (layers "F.Cu" "F.Paste" "F.Mask") (roundrect_rratio 0.25) ${p.net.from.str})
(pad "2" smd roundrect (at 2.2 0) (size 1 2) (layers "F.Cu" "F.Paste" "F.Mask") (roundrect_rratio 0.25) ${p.net.to.str})
)
`
}
M pseudacris/pseudacris.yaml => pseudacris/pseudacris.yaml +12 -69
@@ 1,10 1,3 @@
-#
-# NOTES:
-#
-# - The thumb key nets are inverted compared to rest
-# - The right half column nets are in a strange order
-#
-
units:
cx: 18 # Keycap is 17.5mm wide
cy: 17 # Keycap is 16.5mm tall
@@ 27,9 20,12 @@ points:
zones:
matrix:
key:
+ padding: 18
footprints:
- chocmini:
- type: chocmini_with_diode
+ choc:
+ type: choc
+ params:
+ hotswap: true
nets:
from: "=row_net"
to: "=column_net"
@@ 114,11 110,13 @@ points:
shift: [-(kx/2), -(ky + 2)]
key:
footprints:
- chocmini:
- type: chocmini_with_diode
+ choc:
+ type: choc
+ params:
+ hotswap: true
nets:
- from: "=column_net"
- to: "=row_net"
+ from: "=row_net"
+ to: "=column_net"
columns:
near:
rows:
@@ 170,18 168,6 @@ outlines:
shift:
- -batt_length/2
- -mcu_height - batt_width - 6 # Below the MCU and bat pads
- _battery_cutout:
- - type: rectangle
- size:
- - batt_length + 2 batt_padding
- - batt_width + 2 batt_padding
- anchor:
- ref:
- - matrix_inner_top
- - mirror_matrix_inner_top
- shift:
- - -(batt_length + 2 batt_padding)/2 # Half the width
- - -mcu_height - batt_width - 6 - batt_padding # Below the MCU and bat pads
_key_outline:
- type: keys
side: both
@@ 241,23 227,6 @@ outlines:
side: both
size: [cx, cy]
bound: false
- _top_plate_mounting_holes:
- - type: circle
- anchor:
- ref:
- - thumbfan_home_thumb
- - thumbfan_far_thumb
- shift: [0, 3.8 cy]
- mirror: true
- radius: mounting_hole_radius
- - type: circle
- anchor:
- ref:
- - thumbfan_home_thumb
- - thumbfan_far_thumb
- shift: [0, cy]
- mirror: true
- radius: mounting_hole_radius
_battery_mounting_holes:
- type: circle
anchor:
@@ 277,35 246,10 @@ outlines:
- _key_outline
- +_center
- +_bottom_arc
- - -_battery_cutout
panel:
- name: _panel
fillet: 1.5
- - -_top_plate_mounting_holes
- -_battery_mounting_holes
- top_plate:
- - type: polygon
- points:
- - ref: matrix_inner_top
- shift: [cx/2 + plate_padding, cy/2-1]
- - ref: mirror_matrix_inner_top
- shift: [cx/2 + plate_padding, cy/2-1]
- - ref: mirror_matrix_inner_bottom
- shift: [cx/2 + plate_padding, -cy/2]
- - ref: mirror_thumbfan_far_thumb
- shift: [-cx/2, cy/2 + plate_padding]
- - ref: thumbfan_far_thumb
- shift: [-cx/2, cy/2 + plate_padding]
- - ref: matrix_inner_bottom
- shift: [cx/2 + plate_padding, -cy/2]
- - type: circle # Match the top center arc
- operation: subtract
- anchor:
- ref:
- - matrix_inner_top
- - mirror_matrix_inner_top
- shift: [0, 32]
- radius: 31
demo_keycaps:
- panel
- ^_keycaps
@@ 316,10 260,9 @@ outlines:
- panel
- ^_mcu
- ^_keycaps
- - ^top_plate
- ^_battery
pcbs:
- chrysemeys:
+ pseudacris:
outlines:
main:
outline: panel