Packages & Landpatterns¶
Package name: jsl/landpatterns/packages
Interface definitions for Landpatterns
This package contains the definition of some abstract types for defining the landpatterns of various components.
The goal of these definitions is to provide a consistent interface across all landpattern definitions. This promotes re-use and correctness.
All of the entities in this package use millimeters as their standard unit.
TODO - Diagram here discussing the concept for landpatterns & component packages. We should include examples of various packages and use the right nomenclature to describe things.
Summary¶
Package¶
Every component has a representation for a
Multis¶
Function | Description |
---|---|
make-silkscreen | Generator for creating the silkscreen of a landpattern |
build-silkscreen | Create silkscreen content in virtual landpattern |
build-all | Apply all Package builder functions |
make-all | Generator for applying all Package generators |
make-cut-out | Generator for creating cutout regions in the landpattern. |
build-cut-out | Create cut-out regions in a virtual landpattern |
build-keep-out | Create keep-out regions in a virtual landpattern |
make-keep-out | Generator for creating keep-out constraints for a landpattern |
make-courtyard | Generator for creating courtyard for a landpattern |
build-courtyard | Create courtyard content in a virtual landpattern |
build-conformal-mask | Create conformal coat mask regions in a virtual landpattern |
make-conformal-mask | Generator for creating conformal coat masks for a landpattern |
lead-numbering | Lead Numbering Scheme for this Package |
package-body | Package Body provides the physical envelope for |
name | IPC7351 compliant name for the package generated |
num-leads | Number of Total Lead Mounts on this Package |
create-landpattern | Create a LandPattern definition |
pad-planner | Pad Planner for this Package |
courtyard-excess | |
build-pads | Build the pad/copper in a virtual landpattern |
density-level | Density Level for this Package |
make-pads | Generator for creating the copper pad landpattern |
Methods¶
Function | Description |
---|---|
make-silkscreen | Default Silkscreen Implementation - No Silkscreen Artwork Created |
build-silkscreen | Default silkscreen creator - No Silkscreen Content |
build-all | Default build-all implementation |
make-all | Default make-all generator implementation |
make-cut-out | Default Generator make-cut-out - Constructs the cutouts only. |
build-cut-out | Default build-cut-out - No cut-out regions created. |
build-keep-out | Default build-keep-out - No Keep-out Regions Applied. |
make-keep-out | Default make-keep-out - Constructs the Keepouts Only. |
build-courtyard | Default courtyard creator |
build-conformal-mask | Default build-conformal-mask - No Conformal Mask Regions Applied. |
make-conformal-mask | Default Conformal Coat Generator |
create-landpattern | Default Implementation of create-landpattern |
density-level | Default Density Level Setting |
make-pads | Default Implementation of the Landpattern Copper Generator |
Functions¶
Function | Description |
---|---|
package-build-all-order | Externally Defined Build All Order |
General Definitions¶
Variable | Description |
---|---|
DEF_LP_POSE | Default Landpattern Generator Pose |
Definitions¶
Package¶
Every component has a representation for a
public deftype Package <: Hashable
package
Multis¶
make-silkscreen¶
Generator for creating the silkscreen of a landpattern
public defmulti make-silkscreen (pkg:Package -- pose:Pose = ?)
pkg: Package
- IC Package for which we are creating silkscreen artworkpose: Pose
- Offset to apply to all of the geometry generated by this generator function. By default, no offset is applied.
This generator is typically called within a pcb-landpattern
definition to create the silkscreen outline, pin-1 indicator, or
any other silkscreen artwork.
build-silkscreen¶
Create silkscreen content in virtual landpattern
public defmulti build-silkscreen (pkg:Package, vp:VirtualLP) -> False
pkg: Package
- Package definition to buildvp: VirtualLP
- Virtual Landpattern Container- Returns
False
This function is used to build the landpattern's
silkscreen artwork in a virtual landpattern environment.
That virtual environment can then be written out to a
pcb-landpattern
definition.
build-all¶
Apply all Package
builder functions
public defmulti build-all (pkg:Package, vp:VirtualLP) -> False
pkg: Package
- IC Package for which we are creating silkscreen artworkvp: VirtualLP
- Virtual Landpattern Container to which content will be written- Returns
False
This function applies all of the build-*
functions
associated with the Package
type to a virtual landpattern container.
make-all¶
Generator for applying all Package
generators
public defmulti make-all (pkg:Package -- pose:Pose = ?)
pkg: Package
- IC Package for which we are creating silkscreen artworkpose: Pose
- Offset to apply to all of the geometry generated by this generator function. By default, no offset is applied.
This function applies all of the make-*
generators
associated with the Package
type.
make-cut-out¶
Generator for creating cutout regions in the landpattern.
public defmulti make-cut-out (pkg:Package -- pose:Pose = ?)
pkg: Package
- IC Package for which we are creating silkscreen artworkpose: Pose
- Offset to apply to all of the geometry generated by this generator function. By default, no offset is applied.
This generator is typically called within a pcb-landpattern
definition to create the Cutout()
layer regions for this component.
build-cut-out¶
Create cut-out
regions in a virtual landpattern
public defmulti build-cut-out (pkg:Package, vp:VirtualLP) -> False
pkg: Package
- Package definition to buildvp: VirtualLP
- Virtual Landpattern Container- Returns
False
This function is used to build the landpattern's cut-out regions in a virtual landpattern environment.
The cut-outs are routed areas where the board is completely removed. Sharp corners (zero radius) are difficult to manufacturer so filleted edges should be used where appropriate.
The VirtualLP environment will be written out to a
pcb-landpattern
definition by the make-cut-out
function.
build-keep-out¶
Create keep-out
regions in a virtual landpattern
public defmulti build-keep-out (pkg:Package, vp:VirtualLP) -> False
pkg: Package
- Package definition to buildvp: VirtualLP
- Virtual Landpattern Container- Returns
False
This function is used to build the landpattern's
keep-out regions in a virtual landpattern environment.
This may include keep-outs for copper, vias, etc.
That virtual environment can then be written out to a
pcb-landpattern
definition.
make-keep-out¶
Generator for creating keep-out constraints for a landpattern
public defmulti make-keep-out (pkg:Package -- pose:Pose = ?)
pkg: Package
- IC Package for which we are creating silkscreen artworkpose: Pose
- Offset to apply to all of the geometry generated by this generator function. By default, no offset is applied.
This generator is typically called within a pcb-landpattern
definition to create the keep-out regions for this component.
make-courtyard¶
Generator for creating courtyard for a landpattern
public defmulti make-courtyard (pkg:Package -- pose:Pose = ?)
pkg: Package
- IC Package for which we are creating silkscreen artworkpose: Pose
- Offset to apply to all of the geometry generated by this generator function. By default, no offset is applied.
This generator is typically called within a pcb-landpattern
definition to create the courtyard outline for this component.
build-courtyard¶
Create courtyard content in a virtual landpattern
public defmulti build-courtyard (pkg:Package, vp:VirtualLP) -> False
pkg: Package
- Package definition to buildvp: VirtualLP
- Virtual Landpattern Container- Returns
False
This function is used to build the landpattern's
courtyard region in a virtual landpattern environment.
That virtual environment can then be written out to a
pcb-landpattern
definition.
build-conformal-mask¶
Create conformal coat mask regions in a virtual landpattern
public defmulti build-conformal-mask (pkg:Package, vp:VirtualLP) -> False
pkg: Package
- Package definition to buildvp: VirtualLP
- Virtual Landpattern Container- Returns
False
This function is used to build the landpattern's
conformal coat mask regions in a virtual landpattern environment.
Typically this is used to mark where on this component conformal
coating should not be applied - like for connector openings, etc.
That virtual environment can then be written out to a
pcb-landpattern
definition.
make-conformal-mask¶
Generator for creating conformal coat masks for a landpattern
public defmulti make-conformal-mask (pkg:Package -- pose:Pose = ?)
pkg: Package
- IC Package for which we are creating silkscreen artworkpose: Pose
- Offset to apply to all of the geometry generated by this generator function. By default, no offset is applied.
This generator is typically called within a pcb-landpattern
definition to create the conformal coat mask regions. This is
typically useful for connectors or thermal interfaces.
lead-numbering¶
Lead Numbering Scheme for this Package
public defmulti lead-numbering (x:Package) -> Numbering
- Returns
Numbering
package-body¶
Package Body provides the physical envelope for
public defmulti package-body (x:Package) -> PackageBody
- Returns
PackageBody
the package's body.
name¶
IPC7351 compliant name for the package generated
public defmulti name (x:Package) -> String
- Returns
String
by this instance.
num-leads¶
Number of Total Lead Mounts on this Package
public defmulti num-leads (x:Package) -> Int
- Returns
Int
This number should include all possible standard lead locations on this package.
- The user should not subtract the pins that are marked absent.
- The user should not include the thermal lead if any.
create-landpattern¶
Create a LandPattern
definition
public defmulti create-landpattern (pkg:Package -- pose:Pose = ?, description:String = ?) -> LandPattern
pkg: Package
- Package to create a landpattern for.pose: Pose
- Geometry gets created with an offset from the origin bypose
.description: String
- Description of the landpattern.
Example:
val lp = create-landpattern(pkg)
; Is equivalent to:
pcb-landpattern lp:
name = "lp"
description = ""
make-landpattern(pkg)
LandPattern
This function is used to create a complete landpattern definition
for this Package
. Typically this function would use the make-*
generators for this type to construct a pcb-landpattern
definition
and return it.
pad-planner¶
Pad Planner for this Package
public defmulti pad-planner (x:Package) -> PadPlanner
- Returns
PadPlanner
courtyard-excess¶
public defmulti courtyard-excess (x:Package) -> Double
- Returns
Double
build-pads¶
Build the pad/copper in a virtual landpattern
public defmulti build-pads (pkg:Package, vp:VirtualLP) -> False
pkg: Package
- Package definition to buildvp: VirtualLP
- Virtual Landpattern Container- Returns
False
This function is used to build the landpattern's
pad definitions in a virtual landpattern environment.
That virtual environment can then be written out to a
pcb-landpattern
definition.
density-level¶
Density Level for this Package
public defmulti density-level (x:Package) -> DensityLevel
- Returns
DensityLevel
make-pads¶
Generator for creating the copper pad landpattern
public defmulti make-pads (pkg:Package -- pose:Pose = ?)
pkg: Package
- IC Package for which we are creating a landpatternpose: Pose
- Offset to apply to all of the geometry generated by this generator function. By default, no offset is applied.
This generator is typically called within a pcb-landpattern
definition to create the necessary pads and copper geometry associated
with that component's landpattern.
Methods¶
make-silkscreen¶
Default Silkscreen Implementation - No Silkscreen Artwork Created
defmethod make-silkscreen (pkg:Package -- pose:Pose = ?)
build-silkscreen¶
Default silkscreen creator - No Silkscreen Content
defmethod build-silkscreen (pkg:Package, vp:VirtualLP) -> False
- Returns
False
build-all¶
Default build-all
implementation
defmethod build-all (pkg:Package, virt:VirtualLP) -> False
- Returns
False
Builders are applied in the following order:
make-all¶
Default make-all
generator implementation
defmethod make-all (pkg:Package -- pose:Pose = ?)
pkg: Package
- IC Package for which we are creating silkscreen artworkpose: Pose
- Offset to apply to all of the geometry generated by this generator function. By default, no offset is applied.
make-cut-out¶
Default Generator make-cut-out
- Constructs the cutouts only.
defmethod make-cut-out (pkg:Package -- pose:Pose = ?)
build-cut-out¶
Default build-cut-out
- No cut-out regions created.
defmethod build-cut-out (pkg:Package, vp:VirtualLP) -> False
- Returns
False
build-keep-out¶
Default build-keep-out
- No Keep-out Regions Applied.
defmethod build-keep-out (pkg:Package, vp:VirtualLP) -> False
- Returns
False
make-keep-out¶
Default make-keep-out
- Constructs the Keepouts Only.
defmethod make-keep-out (pkg:Package -- pose:Pose = ?)
build-courtyard¶
Default courtyard creator
defmethod build-courtyard (pkg:Package, vp:VirtualLP) -> False
- Returns
False
This function creates the default courtyard for the component
by introducing a center mark at the origin and a bounding
rectangle on the Courtyard(Top)
layer.
build-conformal-mask¶
Default build-conformal-mask
- No Conformal Mask Regions Applied.
defmethod build-conformal-mask (pkg:Package, vp:VirtualLP) -> False
- Returns
False
make-conformal-mask¶
Default Conformal Coat Generator
defmethod make-conformal-mask (pkg:Package -- pose:Pose = ?)
create-landpattern¶
Default Implementation of create-landpattern
defmethod create-landpattern (pkg:Package -- pose:Pose = ?, description:String = ?) -> LandPattern
pkg: Package
- Package to create a landpattern for.pose: Pose
- Offset of the geometry in the landpattern. Default is no offset, ieloc(0.0, 0.0)
description: String
- Description of the landpattern.- Returns
LandPattern
The default landpattern creator combines all of the
defined generators for a Package
(ie, make-*
functions)
to generate the complete landpattern for a package.
In more complex packages, you may need to define your own
pcb-landpattern
definition with multiple packages
density-level¶
Default Density Level Setting
defmethod density-level (x:Package) -> DensityLevel
- Returns
DensityLevel
If the package doesn't provide an implementation for
density-level - then this function will serve the DENSITY-LEVEL
from the design settings file as the default level.
make-pads¶
Default Implementation of the Landpattern Copper Generator
defmethod make-pads (pkg:Package -- pose:Pose = ?)
Functions¶
package-build-all-order¶
Externally Defined Build All Order
public defn package-build-all-order (pkg:Package, virt:VirtualLP) -> False
- Returns
False
This function can be used when you want to override the
default behavior of default build-all
defmethod.
General Definitions¶
DEF_LP_POSE¶
Default Landpattern Generator Pose
public val DEF_LP_POSE
This value should be the default value used for the
pose
argument in all make-landpattern
invocations.
Related Packages¶
Forwards packages: jsl/landpatterns/package-body, jsl/landpatterns/package-body, jsl/landpatterns/package-body Forwarded by packages: jsl/landpatterns/framework, jsl/landpatterns