Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

add enum variant docs to jsl #188

Merged
merged 1 commit into from
Oct 4, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
17 changes: 17 additions & 0 deletions src/bundles/comms.stanza
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,8 @@ doc: \<DOC>
SMBus Bundle
System Management Bus (SMBus) is a two wire serial communication protocol
@see http://smbus.org/specs/
@member SMBALERT#
@member SMBSUS#
<DOC>
public pcb-enum jsl/bundles/comms/SMBUSPins :
SMBALERT#
Expand Down Expand Up @@ -113,6 +115,9 @@ SPI Bundle Pin Names
A list of possible names for the SPI interface. Note that in order to connect
SPI interfaces automatically, the constituent pins need to be present on all
objects to be connected.
@member SPI-CS
@member SPI-COPI
@member SPI-CIPO
<DOC>

public pcb-enum jsl/bundles/comms/SPIPins :
Expand Down Expand Up @@ -250,6 +255,18 @@ public pcb-bundle octal-spi-with-cs-dqs :
; UART - Univeral Asynchronous Receiver/Transmitter
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;

doc: \<DOC>
@member UART-DTR
@member UART-CTS
@member UART-DCD
@member UART-RI
@member UART-DSR
@member UART-RTS
@member UART-CK
@member UART-DE
@member UART-RX
@member UART-TX
<DOC>
public pcb-enum jsl/bundles/comms/UARTPins :
UART-DTR
UART-CTS
Expand Down
3 changes: 3 additions & 0 deletions src/bundles/debug.stanza
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,9 @@ public pcb-bundle jtag :
port tdo
port tms

doc: \<DOC>
@member SWD-SWO
<DOC>
public pcb-enum jsl/bundles/debug/SWDPins :
SWD-SWO ; Trace Output for Serial Wire Debug

Expand Down
5 changes: 5 additions & 0 deletions src/design/settings.stanza
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,11 @@ defpackage jsl/design/settings:
import jitx
import jitx/commands

doc: \<DOC>
@member DensityLevelA
@member DensityLevelB
@member DensityLevelC
<DOC>
public pcb-enum jsl/design/settings/DensityLevel:
DensityLevelA
DensityLevelB
Expand Down
2 changes: 2 additions & 0 deletions src/landpatterns/BGA/pads.stanza
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,8 @@ to distinguish between the typical pad types used in BGA.
These are sometimes referred to as `Non-Collapsible` and `Collapsible`,
respectively.

@member SolderMaskDefined
@member NonSolderMaskDefined
<DOC>
public defenum BGAPadType:
SolderMaskDefined
Expand Down
2 changes: 2 additions & 0 deletions src/landpatterns/grid-planner.stanza
Original file line number Diff line number Diff line change
Expand Up @@ -194,6 +194,8 @@ is populated.
X | O | X ...
...
```
@member Even-Phase
@member Odd-Phase
<DOC>
public defenum StaggerPhase :
Even-Phase
Expand Down
2 changes: 2 additions & 0 deletions src/landpatterns/pads.stanza
Original file line number Diff line number Diff line change
Expand Up @@ -157,6 +157,8 @@ This enum provides flags that can indicate the style of
pastemask to generate. This can often be useful for
generating a pastemask layer that conforms to certain
norms.
@member NominalPasteMask
@member NoPasteMask
<DOC>
public defenum PasteMaskStyle:
NominalPasteMask
Expand Down
2 changes: 2 additions & 0 deletions src/landpatterns/silkscreen.stanza
Original file line number Diff line number Diff line change
Expand Up @@ -236,6 +236,8 @@ public defmethod build-shape (s:InterstitialOutline, vp:VirtualLP -- side:Side =
doc: \<DOC>
Selector for whether the edge lines are
drawn on the Top / Bottom sides (N/S) or the Left/Right sides (E/W)
@member NS-Edge
@member EW-Edge
<DOC>
public defenum SilkscreenEdge :
NS-Edge
Expand Down
4 changes: 2 additions & 2 deletions src/landpatterns/two-pin/axial.stanza
Original file line number Diff line number Diff line change
Expand Up @@ -82,9 +82,9 @@ Axial Mounting Style
There are generally two ways to mount an axial component
on a PCB.

1. Horizontally - this is the typical method where the
@member Horz-Mount-Axial Horizontally: this is the typical method where the
lead axis is parallel with the board surface.
2. Vertically - In this configuration, the lead axis is
@member Vert-Mount-Axial Vertically: In this configuration, the lead axis is
perpendicular with the board surface, and the lead pointing
away from the board surface is bent 180 degrees to mate with
the board surface.
Expand Down
11 changes: 10 additions & 1 deletion src/protocols/displayport.stanza
Original file line number Diff line number Diff line change
Expand Up @@ -35,8 +35,17 @@ public val DISPLAYPORT_NUM_CONFIGS = 2
doc: \<DOC>
@brief DisplayPort Generation enums
This is a fixed list of possible generation definitions for DisplayPort
@member DP1p0
@member DP1p1
@member DP1p2
@member DP1p2a
@member DP1p3
@member DP1p4
@member DP1p4a
@member DP2p0
@member DP2p1
@member DP2p1a
<DOC>

public pcb-enum jsl/protocols/displayport/DPVersion:
DP1p0 ; 10.80 Gbit/s / 4 lanes => 2.7 Gbit/s / 10 UI => 270 MHz clk
DP1p1 ; 10.80 Gbit/s / 4 lanes => 2.7 Gbit/s / 10 UI => 270 MHz clk
Expand Down
2 changes: 2 additions & 0 deletions src/protocols/ethernet/MII/RGMII.stanza
Original file line number Diff line number Diff line change
Expand Up @@ -52,6 +52,8 @@ In RGMII v2, the spec introduces an optional "Internal Delay"
feature. Devices that provide this are labeled "RGMII-ID".
These devices don't require a PCB board delay because the
delay can be configured in firmware.
@member RGMII-STD
@member RGMII-ID
<DOC>
public pcb-enum jsl/protocols/ethernet/RGMII/RGMIIVersion:
RGMII-STD
Expand Down
5 changes: 5 additions & 0 deletions src/protocols/ethernet/utils.stanza
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,11 @@ defpackage jsl/protocols/ethernet/utils:
import jitx
import jitx/commands

doc: \<DOC>
@member MII-COL
@member MII-CS
@member MII-TXER
<DOC>
public pcb-enum jsl/protocols/ethernet/utils/MIIPins :
MII-COL ; Collision
MII-CS ; Carrier Sense
Expand Down
6 changes: 6 additions & 0 deletions src/protocols/memory/lpddr4.stanza
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,9 @@ defpackage jsl/protocols/memory/lpddr4 :
doc: \<DOC>
@brief LPDDR4 Width enums
This is a fixed list of possible channel widths for LPDDR4
@member LPDDR4-x16
@member LPDDR4-x32
@member LPDDR4-x64
<DOC>
public pcb-enum jsl/protocols/memory/lpddr4/LPDDR4-Width:
LPDDR4-x16
Expand All @@ -50,6 +53,9 @@ public defn num-x16-lanes (width:LPDDR4-Width) -> Int :
doc: \<DOC>
@brief LPDDR4 Rank enums
This is a fixed list of possible ranks for LPDDR4
@member LPDDR4-Rank1
@member LPDDR4-Rank2
@member LPDDR4-Rank3
<DOC>
public pcb-enum jsl/protocols/memory/lpddr4/LPDDR4-Rank:
LPDDR4-Rank1
Expand Down
17 changes: 16 additions & 1 deletion src/protocols/pcie.stanza
Original file line number Diff line number Diff line change
Expand Up @@ -38,6 +38,13 @@ doc: \<DOC>
@brief PCI-e Generation enums
This is a fixed list of possible generation definitions for PCIe
Can be extended if needed to include PCIE-V3.1, for example
@member PCIE-V1
@member PCIE-V2
@member PCIE-V3
@member PCIE-V4
@member PCIE-V5
@member PCIE-V6
@member PCIE-V7
<DOC>

public pcb-enum jsl/protocols/pcie/PCIeVersion:
Expand All @@ -52,6 +59,12 @@ public pcb-enum jsl/protocols/pcie/PCIeVersion:
doc: \<DOC>
@brief PCI-e Width enums
This is a fixed list of possible lane widths for PCIe
@member PCIe-x1
@member PCIe-x2
@member PCIe-x4
@member PCIe-x8
@member PCIe-x16
@member PCIe-x32
<DOC>
public pcb-enum jsl/protocols/pcie/PCIeWidth:
PCIe-x1
Expand All @@ -69,7 +82,9 @@ public defn PCIe-enum-to-int (en:PCIeWidth) -> Int:
PCIe-x8 : 8
PCIe-x16 : 16
PCIe-x32 : 32

doc: \<DOC>
@member PCIe-PRSNT#
<DOC>
public pcb-enum jsl/bundles/pcie/PCIePins :
PCIe-PRSNT#

Expand Down
7 changes: 7 additions & 0 deletions src/protocols/sata.stanza
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,13 @@ defpackage jsl/protocols/sata:
doc: \<DOC>
@brief SATA Generation enums
This is a fixed list of possible generation definitions for SATA
@member SATA1p0
@member SATA2p0
@member SATA3p0
@member SATA3p1
@member SATA3p2
@member SATA3p3
@member SATA3p4
<DOC>

public pcb-enum jsl/protocols/sata/SATAGen:
Expand Down
6 changes: 5 additions & 1 deletion src/protocols/usb.stanza
Original file line number Diff line number Diff line change
Expand Up @@ -163,7 +163,11 @@ public pcb-bundle usb-c-connector :
;;;;;;;;;;;;;;;;;;;;;;;;;
; Constraints
;;;;;;;;;;;;;;;;;;;;;;;;;

doc: \<DOC>
@member USB2
@member USB3
@member USB4
<DOC>
public pcb-enum jsl/protocols/usb/USBVersion:
USB2
USB3
Expand Down
7 changes: 5 additions & 2 deletions src/si/TransmissionLine.stanza
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,10 @@ defpackage jsl/si/TransmissionLine:
import core
import jitx


doc: \<DOC>
@member Single-Ended
@member Differential
<DOC>
public defenum TransmissionStructure:
Single-Ended
Differential
Expand Down Expand Up @@ -92,4 +95,4 @@ passed `t` object and which will be override with new values.
@param Z Target characteristic impedance for the structure.
@param freq Optional frequency to solve for - this includes the dispersion relationships.
<DOC>
public defmulti solve-Z (t:TransmissionLine, Z:Double -- freq:Double = ?) -> TransmissionLine
public defmulti solve-Z (t:TransmissionLine, Z:Double -- freq:Double = ?) -> TransmissionLine
4 changes: 3 additions & 1 deletion src/symbols/arrows.stanza
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,8 @@ defpackage jsl/symbols/arrows:

doc: \<DOC>
Select the style of arrow to construct
@member ClosedArrow
@member OpenArrow
<DOC>
public defenum ArrowStyle :
ClosedArrow
Expand Down Expand Up @@ -113,4 +115,4 @@ public defn construct-arrow (
shaft-length = shaft-length,
line-width = line-width
)
construct-arrow(v)
construct-arrow(v)
4 changes: 4 additions & 0 deletions src/symbols/capacitors.stanza
Original file line number Diff line number Diff line change
Expand Up @@ -60,6 +60,10 @@ public defn set-default-cap-symbol-params (v:CapacitorSymbolParams) -> False :
DEF_NON_POL_PARAMS = v


doc: \<DOC>
@member Polarized-Straight-Style
@member Polarized-Curved-Style
<DOC>
public defenum PolarizedStyle:
Polarized-Straight-Style
Polarized-Curved-Style
Expand Down
9 changes: 7 additions & 2 deletions src/symbols/decorators.stanza
Original file line number Diff line number Diff line change
Expand Up @@ -34,9 +34,9 @@ public defn ActiveLowDecorator (
)

doc: \<DOC>
* `OpenCollectorSink` = Low Side Open Collector Sink. This is the most common version. This
@member OpenCollectorSink Low Side Open Collector Sink. This is the most common version. This
is created using a NPN BJT or NMOS FET.
* `OpenCollectorSource` = High Side Open Collector Source. Less common - this is created using a PNP BJT
@member OpenCollectorSource High Side Open Collector Source. Less common - this is created using a PNP BJT
or PMOS FET.
<DOC>
public defenum OpenCollectorType:
Expand Down Expand Up @@ -146,6 +146,11 @@ public defn ClockDecorator (
)


doc: \<DOC>
@member InputPin
@member OutputPin
@member BidirectionalPin
<DOC>
public defenum CardinalityType :
InputPin
OutputPin
Expand Down
5 changes: 5 additions & 0 deletions src/symbols/inductors.stanza
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,11 @@ defpackage jsl/symbols/inductors:
import jsl/symbols/framework
import jsl/geometry/basics

doc: \<DOC>
@member NoBarCore
@member SingleBarCore
@member DoubleBarCore
<DOC>
public defenum InductorCoreStyle:
NoBarCore
SingleBarCore
Expand Down
4 changes: 4 additions & 0 deletions src/symbols/resistors.stanza
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,10 @@ defpackage jsl/symbols/resistors:
import jsl/design/Classable
import jsl/symbols/framework

doc: \<DOC>
@member TriangleWaveStyle
@member OpenRectangle
<DOC>
public defenum ResistorStyle:
TriangleWaveStyle
OpenRectangle
Expand Down
4 changes: 4 additions & 0 deletions src/symbols/transistors/BJT.stanza
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,10 @@ defpackage jsl/symbols/transistors/BJT:
import jsl/geometry/basics
import jsl/symbols/framework

doc: \<DOC>
@member NPN
@member PNP
<DOC>
public defenum BJT-Junction :
NPN
PNP
Expand Down
8 changes: 8 additions & 0 deletions src/symbols/transistors/FET.stanza
Original file line number Diff line number Diff line change
Expand Up @@ -10,10 +10,18 @@ defpackage jsl/symbols/transistors/FET:
import jsl/geometry/basics
import jsl/symbols/framework

doc: \<DOC>
@member N-Channel
@member P-Channel
<DOC>
public defenum FET-Junction :
N-Channel
P-Channel

doc: \<DOC>
@member Enhancement
@member Depletion
<DOC>
public defenum FET-Mode :
Enhancement
Depletion
Expand Down
2 changes: 2 additions & 0 deletions src/via-structures.stanza
Original file line number Diff line number Diff line change
Expand Up @@ -221,6 +221,8 @@ Via Signal Identifier Enum

This type distinguishes between single-ended and differential
via structures.
@member Via-Single-Ended
@member Via-Differential
<DOC>
public defenum ViaSignalType:
Via-Single-Ended
Expand Down