diff --git a/.vale.ini b/.vale.ini index f0be45d..fd285b5 100644 --- a/.vale.ini +++ b/.vale.ini @@ -7,13 +7,13 @@ Packages = Google, write-good, MDX Vocab = atopile # Completely ignore generated API reference docs -IgnoredPaths = atopile/api-reference/** +IgnoredPaths = atopile-*/api-reference/** [*.{md,mdx}] BasedOnStyles = Vale, Google, write-good Google.Exclamation = NO Google.Quotes = NO -[atopile/api-reference/**] +[atopile-*/api-reference/**] BasedOnStyles = Vale.Spelling = NO diff --git a/atopile/api-reference/components/battery.mdx b/atopile-0.12.x/api-reference/components/battery.mdx similarity index 100% rename from atopile/api-reference/components/battery.mdx rename to atopile-0.12.x/api-reference/components/battery.mdx diff --git a/atopile/api-reference/components/bjt.mdx b/atopile-0.12.x/api-reference/components/bjt.mdx similarity index 100% rename from atopile/api-reference/components/bjt.mdx rename to atopile-0.12.x/api-reference/components/bjt.mdx diff --git a/atopile/api-reference/components/capacitor.mdx b/atopile-0.12.x/api-reference/components/capacitor.mdx similarity index 100% rename from atopile/api-reference/components/capacitor.mdx rename to atopile-0.12.x/api-reference/components/capacitor.mdx diff --git a/atopile/api-reference/components/capacitorelectrolytic.mdx b/atopile-0.12.x/api-reference/components/capacitorelectrolytic.mdx similarity index 100% rename from atopile/api-reference/components/capacitorelectrolytic.mdx rename to atopile-0.12.x/api-reference/components/capacitorelectrolytic.mdx diff --git a/atopile/api-reference/components/common_mode_filter.mdx b/atopile-0.12.x/api-reference/components/common_mode_filter.mdx similarity index 100% rename from atopile/api-reference/components/common_mode_filter.mdx rename to atopile-0.12.x/api-reference/components/common_mode_filter.mdx diff --git a/atopile/api-reference/components/comparator.mdx b/atopile-0.12.x/api-reference/components/comparator.mdx similarity index 100% rename from atopile/api-reference/components/comparator.mdx rename to atopile-0.12.x/api-reference/components/comparator.mdx diff --git a/atopile/api-reference/components/crystal.mdx b/atopile-0.12.x/api-reference/components/crystal.mdx similarity index 100% rename from atopile/api-reference/components/crystal.mdx rename to atopile-0.12.x/api-reference/components/crystal.mdx diff --git a/atopile/api-reference/components/crystal_oscillator.mdx b/atopile-0.12.x/api-reference/components/crystal_oscillator.mdx similarity index 100% rename from atopile/api-reference/components/crystal_oscillator.mdx rename to atopile-0.12.x/api-reference/components/crystal_oscillator.mdx diff --git a/atopile/api-reference/components/diode.mdx b/atopile-0.12.x/api-reference/components/diode.mdx similarity index 100% rename from atopile/api-reference/components/diode.mdx rename to atopile-0.12.x/api-reference/components/diode.mdx diff --git a/atopile/api-reference/components/dip.mdx b/atopile-0.12.x/api-reference/components/dip.mdx similarity index 100% rename from atopile/api-reference/components/dip.mdx rename to atopile-0.12.x/api-reference/components/dip.mdx diff --git a/atopile/api-reference/components/eeprom.mdx b/atopile-0.12.x/api-reference/components/eeprom.mdx similarity index 100% rename from atopile/api-reference/components/eeprom.mdx rename to atopile-0.12.x/api-reference/components/eeprom.mdx diff --git a/atopile/api-reference/components/electriclogicgate.mdx b/atopile-0.12.x/api-reference/components/electriclogicgate.mdx similarity index 100% rename from atopile/api-reference/components/electriclogicgate.mdx rename to atopile-0.12.x/api-reference/components/electriclogicgate.mdx diff --git a/atopile/api-reference/components/fan.mdx b/atopile-0.12.x/api-reference/components/fan.mdx similarity index 100% rename from atopile/api-reference/components/fan.mdx rename to atopile-0.12.x/api-reference/components/fan.mdx diff --git a/atopile/api-reference/components/filter.mdx b/atopile-0.12.x/api-reference/components/filter.mdx similarity index 100% rename from atopile/api-reference/components/filter.mdx rename to atopile-0.12.x/api-reference/components/filter.mdx diff --git a/atopile/api-reference/components/filterelectricallc.mdx b/atopile-0.12.x/api-reference/components/filterelectricallc.mdx similarity index 100% rename from atopile/api-reference/components/filterelectricallc.mdx rename to atopile-0.12.x/api-reference/components/filterelectricallc.mdx diff --git a/atopile/api-reference/components/filterelectricalrc.mdx b/atopile-0.12.x/api-reference/components/filterelectricalrc.mdx similarity index 100% rename from atopile/api-reference/components/filterelectricalrc.mdx rename to atopile-0.12.x/api-reference/components/filterelectricalrc.mdx diff --git a/atopile/api-reference/components/footprint.mdx b/atopile-0.12.x/api-reference/components/footprint.mdx similarity index 100% rename from atopile/api-reference/components/footprint.mdx rename to atopile-0.12.x/api-reference/components/footprint.mdx diff --git a/atopile/api-reference/components/fuse.mdx b/atopile-0.12.x/api-reference/components/fuse.mdx similarity index 100% rename from atopile/api-reference/components/fuse.mdx rename to atopile-0.12.x/api-reference/components/fuse.mdx diff --git a/atopile/api-reference/components/gdt.mdx b/atopile-0.12.x/api-reference/components/gdt.mdx similarity index 100% rename from atopile/api-reference/components/gdt.mdx rename to atopile-0.12.x/api-reference/components/gdt.mdx diff --git a/atopile/api-reference/components/inductor.mdx b/atopile-0.12.x/api-reference/components/inductor.mdx similarity index 100% rename from atopile/api-reference/components/inductor.mdx rename to atopile-0.12.x/api-reference/components/inductor.mdx diff --git a/atopile/api-reference/components/kicadfootprint.mdx b/atopile-0.12.x/api-reference/components/kicadfootprint.mdx similarity index 100% rename from atopile/api-reference/components/kicadfootprint.mdx rename to atopile-0.12.x/api-reference/components/kicadfootprint.mdx diff --git a/atopile/api-reference/components/ldo.mdx b/atopile-0.12.x/api-reference/components/ldo.mdx similarity index 100% rename from atopile/api-reference/components/ldo.mdx rename to atopile-0.12.x/api-reference/components/ldo.mdx diff --git a/atopile/api-reference/components/led.mdx b/atopile-0.12.x/api-reference/components/led.mdx similarity index 100% rename from atopile/api-reference/components/led.mdx rename to atopile-0.12.x/api-reference/components/led.mdx diff --git a/atopile/api-reference/components/ledindicator.mdx b/atopile-0.12.x/api-reference/components/ledindicator.mdx similarity index 100% rename from atopile/api-reference/components/ledindicator.mdx rename to atopile-0.12.x/api-reference/components/ledindicator.mdx diff --git a/atopile/api-reference/components/logicgate.mdx b/atopile-0.12.x/api-reference/components/logicgate.mdx similarity index 100% rename from atopile/api-reference/components/logicgate.mdx rename to atopile-0.12.x/api-reference/components/logicgate.mdx diff --git a/atopile/api-reference/components/mosfet.mdx b/atopile-0.12.x/api-reference/components/mosfet.mdx similarity index 100% rename from atopile/api-reference/components/mosfet.mdx rename to atopile-0.12.x/api-reference/components/mosfet.mdx diff --git a/atopile/api-reference/components/multicapacitor.mdx b/atopile-0.12.x/api-reference/components/multicapacitor.mdx similarity index 100% rename from atopile/api-reference/components/multicapacitor.mdx rename to atopile-0.12.x/api-reference/components/multicapacitor.mdx diff --git a/atopile/api-reference/components/net.mdx b/atopile-0.12.x/api-reference/components/net.mdx similarity index 100% rename from atopile/api-reference/components/net.mdx rename to atopile-0.12.x/api-reference/components/net.mdx diff --git a/atopile/api-reference/components/nfet.mdx b/atopile-0.12.x/api-reference/components/nfet.mdx similarity index 100% rename from atopile/api-reference/components/nfet.mdx rename to atopile-0.12.x/api-reference/components/nfet.mdx diff --git a/atopile/api-reference/components/opamp.mdx b/atopile-0.12.x/api-reference/components/opamp.mdx similarity index 100% rename from atopile/api-reference/components/opamp.mdx rename to atopile-0.12.x/api-reference/components/opamp.mdx diff --git a/atopile/api-reference/components/pfet.mdx b/atopile-0.12.x/api-reference/components/pfet.mdx similarity index 100% rename from atopile/api-reference/components/pfet.mdx rename to atopile-0.12.x/api-reference/components/pfet.mdx diff --git a/atopile/api-reference/components/potentiometer.mdx b/atopile-0.12.x/api-reference/components/potentiometer.mdx similarity index 100% rename from atopile/api-reference/components/potentiometer.mdx rename to atopile-0.12.x/api-reference/components/potentiometer.mdx diff --git a/atopile/api-reference/components/poweredled.mdx b/atopile-0.12.x/api-reference/components/poweredled.mdx similarity index 100% rename from atopile/api-reference/components/poweredled.mdx rename to atopile-0.12.x/api-reference/components/poweredled.mdx diff --git a/atopile/api-reference/components/powermux.mdx b/atopile-0.12.x/api-reference/components/powermux.mdx similarity index 100% rename from atopile/api-reference/components/powermux.mdx rename to atopile-0.12.x/api-reference/components/powermux.mdx diff --git a/atopile/api-reference/components/powerswitch.mdx b/atopile-0.12.x/api-reference/components/powerswitch.mdx similarity index 100% rename from atopile/api-reference/components/powerswitch.mdx rename to atopile-0.12.x/api-reference/components/powerswitch.mdx diff --git a/atopile/api-reference/components/powerswitchmosfet.mdx b/atopile-0.12.x/api-reference/components/powerswitchmosfet.mdx similarity index 100% rename from atopile/api-reference/components/powerswitchmosfet.mdx rename to atopile-0.12.x/api-reference/components/powerswitchmosfet.mdx diff --git a/atopile/api-reference/components/powerswitchstatic.mdx b/atopile-0.12.x/api-reference/components/powerswitchstatic.mdx similarity index 100% rename from atopile/api-reference/components/powerswitchstatic.mdx rename to atopile-0.12.x/api-reference/components/powerswitchstatic.mdx diff --git a/atopile/api-reference/components/regulator.mdx b/atopile-0.12.x/api-reference/components/regulator.mdx similarity index 100% rename from atopile/api-reference/components/regulator.mdx rename to atopile-0.12.x/api-reference/components/regulator.mdx diff --git a/atopile/api-reference/components/relay.mdx b/atopile-0.12.x/api-reference/components/relay.mdx similarity index 100% rename from atopile/api-reference/components/relay.mdx rename to atopile-0.12.x/api-reference/components/relay.mdx diff --git a/atopile/api-reference/components/resistor.mdx b/atopile-0.12.x/api-reference/components/resistor.mdx similarity index 100% rename from atopile/api-reference/components/resistor.mdx rename to atopile-0.12.x/api-reference/components/resistor.mdx diff --git a/atopile/api-reference/components/resistorarray.mdx b/atopile-0.12.x/api-reference/components/resistorarray.mdx similarity index 100% rename from atopile/api-reference/components/resistorarray.mdx rename to atopile-0.12.x/api-reference/components/resistorarray.mdx diff --git a/atopile/api-reference/components/resistorvoltagedivider.mdx b/atopile-0.12.x/api-reference/components/resistorvoltagedivider.mdx similarity index 100% rename from atopile/api-reference/components/resistorvoltagedivider.mdx rename to atopile-0.12.x/api-reference/components/resistorvoltagedivider.mdx diff --git a/atopile/api-reference/components/smdtwopin.mdx b/atopile-0.12.x/api-reference/components/smdtwopin.mdx similarity index 100% rename from atopile/api-reference/components/smdtwopin.mdx rename to atopile-0.12.x/api-reference/components/smdtwopin.mdx diff --git a/atopile/api-reference/components/soic.mdx b/atopile-0.12.x/api-reference/components/soic.mdx similarity index 100% rename from atopile/api-reference/components/soic.mdx rename to atopile-0.12.x/api-reference/components/soic.mdx diff --git a/atopile/api-reference/components/spiflash.mdx b/atopile-0.12.x/api-reference/components/spiflash.mdx similarity index 100% rename from atopile/api-reference/components/spiflash.mdx rename to atopile-0.12.x/api-reference/components/spiflash.mdx diff --git a/atopile/api-reference/components/surgeprotection.mdx b/atopile-0.12.x/api-reference/components/surgeprotection.mdx similarity index 100% rename from atopile/api-reference/components/surgeprotection.mdx rename to atopile-0.12.x/api-reference/components/surgeprotection.mdx diff --git a/atopile/api-reference/components/symbol.mdx b/atopile-0.12.x/api-reference/components/symbol.mdx similarity index 100% rename from atopile/api-reference/components/symbol.mdx rename to atopile-0.12.x/api-reference/components/symbol.mdx diff --git a/atopile/api-reference/components/testpoint.mdx b/atopile-0.12.x/api-reference/components/testpoint.mdx similarity index 100% rename from atopile/api-reference/components/testpoint.mdx rename to atopile-0.12.x/api-reference/components/testpoint.mdx diff --git a/atopile/api-reference/components/tvs.mdx b/atopile-0.12.x/api-reference/components/tvs.mdx similarity index 100% rename from atopile/api-reference/components/tvs.mdx rename to atopile-0.12.x/api-reference/components/tvs.mdx diff --git a/atopile/api-reference/interfaces/addressor.mdx b/atopile-0.12.x/api-reference/interfaces/addressor.mdx similarity index 100% rename from atopile/api-reference/interfaces/addressor.mdx rename to atopile-0.12.x/api-reference/interfaces/addressor.mdx diff --git a/atopile/api-reference/interfaces/can.mdx b/atopile-0.12.x/api-reference/interfaces/can.mdx similarity index 100% rename from atopile/api-reference/interfaces/can.mdx rename to atopile-0.12.x/api-reference/interfaces/can.mdx diff --git a/atopile/api-reference/interfaces/can_ttl.mdx b/atopile-0.12.x/api-reference/interfaces/can_ttl.mdx similarity index 100% rename from atopile/api-reference/interfaces/can_ttl.mdx rename to atopile-0.12.x/api-reference/interfaces/can_ttl.mdx diff --git a/atopile/api-reference/interfaces/differentialpair.mdx b/atopile-0.12.x/api-reference/interfaces/differentialpair.mdx similarity index 100% rename from atopile/api-reference/interfaces/differentialpair.mdx rename to atopile-0.12.x/api-reference/interfaces/differentialpair.mdx diff --git a/atopile/api-reference/interfaces/electrical.mdx b/atopile-0.12.x/api-reference/interfaces/electrical.mdx similarity index 100% rename from atopile/api-reference/interfaces/electrical.mdx rename to atopile-0.12.x/api-reference/interfaces/electrical.mdx diff --git a/atopile/api-reference/interfaces/electriclogic.mdx b/atopile-0.12.x/api-reference/interfaces/electriclogic.mdx similarity index 100% rename from atopile/api-reference/interfaces/electriclogic.mdx rename to atopile-0.12.x/api-reference/interfaces/electriclogic.mdx diff --git a/atopile/api-reference/interfaces/electricpower.mdx b/atopile-0.12.x/api-reference/interfaces/electricpower.mdx similarity index 100% rename from atopile/api-reference/interfaces/electricpower.mdx rename to atopile-0.12.x/api-reference/interfaces/electricpower.mdx diff --git a/atopile/api-reference/interfaces/electricsignal.mdx b/atopile-0.12.x/api-reference/interfaces/electricsignal.mdx similarity index 100% rename from atopile/api-reference/interfaces/electricsignal.mdx rename to atopile-0.12.x/api-reference/interfaces/electricsignal.mdx diff --git a/atopile/api-reference/interfaces/enablepin.mdx b/atopile-0.12.x/api-reference/interfaces/enablepin.mdx similarity index 100% rename from atopile/api-reference/interfaces/enablepin.mdx rename to atopile-0.12.x/api-reference/interfaces/enablepin.mdx diff --git a/atopile/api-reference/interfaces/ethernet.mdx b/atopile-0.12.x/api-reference/interfaces/ethernet.mdx similarity index 100% rename from atopile/api-reference/interfaces/ethernet.mdx rename to atopile-0.12.x/api-reference/interfaces/ethernet.mdx diff --git a/atopile/api-reference/interfaces/hdmi.mdx b/atopile-0.12.x/api-reference/interfaces/hdmi.mdx similarity index 100% rename from atopile/api-reference/interfaces/hdmi.mdx rename to atopile-0.12.x/api-reference/interfaces/hdmi.mdx diff --git a/atopile/api-reference/interfaces/i2c.mdx b/atopile-0.12.x/api-reference/interfaces/i2c.mdx similarity index 100% rename from atopile/api-reference/interfaces/i2c.mdx rename to atopile-0.12.x/api-reference/interfaces/i2c.mdx diff --git a/atopile/api-reference/interfaces/i2s.mdx b/atopile-0.12.x/api-reference/interfaces/i2s.mdx similarity index 100% rename from atopile/api-reference/interfaces/i2s.mdx rename to atopile-0.12.x/api-reference/interfaces/i2s.mdx diff --git a/atopile/api-reference/interfaces/jtag.mdx b/atopile-0.12.x/api-reference/interfaces/jtag.mdx similarity index 100% rename from atopile/api-reference/interfaces/jtag.mdx rename to atopile-0.12.x/api-reference/interfaces/jtag.mdx diff --git a/atopile/api-reference/interfaces/logic.mdx b/atopile-0.12.x/api-reference/interfaces/logic.mdx similarity index 100% rename from atopile/api-reference/interfaces/logic.mdx rename to atopile-0.12.x/api-reference/interfaces/logic.mdx diff --git a/atopile/api-reference/interfaces/mechanical.mdx b/atopile-0.12.x/api-reference/interfaces/mechanical.mdx similarity index 100% rename from atopile/api-reference/interfaces/mechanical.mdx rename to atopile-0.12.x/api-reference/interfaces/mechanical.mdx diff --git a/atopile/api-reference/interfaces/multispi.mdx b/atopile-0.12.x/api-reference/interfaces/multispi.mdx similarity index 100% rename from atopile/api-reference/interfaces/multispi.mdx rename to atopile-0.12.x/api-reference/interfaces/multispi.mdx diff --git a/atopile/api-reference/interfaces/pad.mdx b/atopile-0.12.x/api-reference/interfaces/pad.mdx similarity index 100% rename from atopile/api-reference/interfaces/pad.mdx rename to atopile-0.12.x/api-reference/interfaces/pad.mdx diff --git a/atopile/api-reference/interfaces/pdm.mdx b/atopile-0.12.x/api-reference/interfaces/pdm.mdx similarity index 100% rename from atopile/api-reference/interfaces/pdm.mdx rename to atopile-0.12.x/api-reference/interfaces/pdm.mdx diff --git a/atopile/api-reference/interfaces/power.mdx b/atopile-0.12.x/api-reference/interfaces/power.mdx similarity index 100% rename from atopile/api-reference/interfaces/power.mdx rename to atopile-0.12.x/api-reference/interfaces/power.mdx diff --git a/atopile/api-reference/interfaces/rs232.mdx b/atopile-0.12.x/api-reference/interfaces/rs232.mdx similarity index 100% rename from atopile/api-reference/interfaces/rs232.mdx rename to atopile-0.12.x/api-reference/interfaces/rs232.mdx diff --git a/atopile/api-reference/interfaces/rs485halfduplex.mdx b/atopile-0.12.x/api-reference/interfaces/rs485halfduplex.mdx similarity index 100% rename from atopile/api-reference/interfaces/rs485halfduplex.mdx rename to atopile-0.12.x/api-reference/interfaces/rs485halfduplex.mdx diff --git a/atopile/api-reference/interfaces/sercom.mdx b/atopile-0.12.x/api-reference/interfaces/sercom.mdx similarity index 100% rename from atopile/api-reference/interfaces/sercom.mdx rename to atopile-0.12.x/api-reference/interfaces/sercom.mdx diff --git a/atopile/api-reference/interfaces/signal.mdx b/atopile-0.12.x/api-reference/interfaces/signal.mdx similarity index 100% rename from atopile/api-reference/interfaces/signal.mdx rename to atopile-0.12.x/api-reference/interfaces/signal.mdx diff --git a/atopile/api-reference/interfaces/spi.mdx b/atopile-0.12.x/api-reference/interfaces/spi.mdx similarity index 100% rename from atopile/api-reference/interfaces/spi.mdx rename to atopile-0.12.x/api-reference/interfaces/spi.mdx diff --git a/atopile/api-reference/interfaces/swd.mdx b/atopile-0.12.x/api-reference/interfaces/swd.mdx similarity index 100% rename from atopile/api-reference/interfaces/swd.mdx rename to atopile-0.12.x/api-reference/interfaces/swd.mdx diff --git a/atopile/api-reference/interfaces/uart.mdx b/atopile-0.12.x/api-reference/interfaces/uart.mdx similarity index 100% rename from atopile/api-reference/interfaces/uart.mdx rename to atopile-0.12.x/api-reference/interfaces/uart.mdx diff --git a/atopile/api-reference/interfaces/uart_base.mdx b/atopile-0.12.x/api-reference/interfaces/uart_base.mdx similarity index 100% rename from atopile/api-reference/interfaces/uart_base.mdx rename to atopile-0.12.x/api-reference/interfaces/uart_base.mdx diff --git a/atopile/api-reference/interfaces/usb2_0.mdx b/atopile-0.12.x/api-reference/interfaces/usb2_0.mdx similarity index 100% rename from atopile/api-reference/interfaces/usb2_0.mdx rename to atopile-0.12.x/api-reference/interfaces/usb2_0.mdx diff --git a/atopile/api-reference/interfaces/usb2_0_if.mdx b/atopile-0.12.x/api-reference/interfaces/usb2_0_if.mdx similarity index 100% rename from atopile/api-reference/interfaces/usb2_0_if.mdx rename to atopile-0.12.x/api-reference/interfaces/usb2_0_if.mdx diff --git a/atopile/api-reference/interfaces/usb3.mdx b/atopile-0.12.x/api-reference/interfaces/usb3.mdx similarity index 100% rename from atopile/api-reference/interfaces/usb3.mdx rename to atopile-0.12.x/api-reference/interfaces/usb3.mdx diff --git a/atopile/api-reference/interfaces/usb3_if.mdx b/atopile-0.12.x/api-reference/interfaces/usb3_if.mdx similarity index 100% rename from atopile/api-reference/interfaces/usb3_if.mdx rename to atopile-0.12.x/api-reference/interfaces/usb3_if.mdx diff --git a/atopile/api-reference/interfaces/usb_c.mdx b/atopile-0.12.x/api-reference/interfaces/usb_c.mdx similarity index 100% rename from atopile/api-reference/interfaces/usb_c.mdx rename to atopile-0.12.x/api-reference/interfaces/usb_c.mdx diff --git a/atopile/api-reference/interfaces/xtalif.mdx b/atopile-0.12.x/api-reference/interfaces/xtalif.mdx similarity index 100% rename from atopile/api-reference/interfaces/xtalif.mdx rename to atopile-0.12.x/api-reference/interfaces/xtalif.mdx diff --git a/atopile/api-reference/reference_instructions.md b/atopile-0.12.x/api-reference/reference_instructions.md similarity index 92% rename from atopile/api-reference/reference_instructions.md rename to atopile-0.12.x/api-reference/reference_instructions.md index 80f3d39..8e5752a 100644 --- a/atopile/api-reference/reference_instructions.md +++ b/atopile-0.12.x/api-reference/reference_instructions.md @@ -64,13 +64,13 @@ Convenience properties for accessing resistor terminals: The Resistor component automatically includes these traits: -### [pickable](/atopile/api-reference/traits/pickable) +### pickable Enables automatic part selection from the component database based on resistance, power, and voltage requirements. -### [can_bridge](/atopile/api-reference/traits/can-bridge) +### can_bridge Allows the resistor to be used in bridging connections with the `~>` operator for series connections. -### [simple_value_representation](/atopile/api-reference/traits/simple-value-representation) +### simple_value_representation Provides a simplified string representation showing key parameters for debugging and documentation. ## Package Selection diff --git a/atopile/api-reference/traits/can_bridge_by_name.mdx b/atopile-0.12.x/api-reference/traits/can_bridge_by_name.mdx similarity index 100% rename from atopile/api-reference/traits/can_bridge_by_name.mdx rename to atopile-0.12.x/api-reference/traits/can_bridge_by_name.mdx diff --git a/atopile/api-reference/traits/requires_pulls.mdx b/atopile-0.12.x/api-reference/traits/requires_pulls.mdx similarity index 100% rename from atopile/api-reference/traits/requires_pulls.mdx rename to atopile-0.12.x/api-reference/traits/requires_pulls.mdx diff --git a/atopile/changelog.mdx b/atopile-0.12.x/changelog.mdx similarity index 84% rename from atopile/changelog.mdx rename to atopile-0.12.x/changelog.mdx index 13d7fa8..bcaa10f 100644 --- a/atopile/changelog.mdx +++ b/atopile-0.12.x/changelog.mdx @@ -5,11 +5,17 @@ icon: 'rectangle-history' {/* https://www.mintlify.com/docs/content/components/update */} - + -This version is currently under development. Stay tuned for updates! +LSP autocomplete is here! The language server now provides dot auto-complete suggestions, import suggestions, and "go to definition" navigation, making the editor experience significantly more productive. The VSCode extension is also less noisy with annoying popups removed. -For up-to-date minor changes check out the [GitHub Releases](https://github.com/atopile/atopile/releases). +The build system has been rearchitected to model builds as a DAG of individual steps, improving reliability and fixing issues with extra build directories being generated for dependencies. + +A new `ato package verify` command helps validate packages before publishing. Package management is more robust with version fallback support, system cert store usage, and fixed authentication headers. + +Library improvements include support for parallel pull resistors in `requires_pulls` checks and hidden value text on the fab layer for cleaner board outputs. + +**Full Changelog**: https://github.com/atopile/atopile/releases/tag/v0.12.0 @@ -81,9 +87,9 @@ Added I2C Addressing & Bus viewer Build artifacts are now included when publishing. This means that when you go to https://packages.atopile.io/, you'll see the build artifacts ready to order or explore. -Added `hide_designators` [config option](/atopile/reference/config#builds-hide-designators). +Added `hide_designators` [config option](./reference/config#builds-hide-designators). -Improved checks system with [new exclude capability](/atopile/reference/config#builds-exclude-checks) +Improved checks system with [new exclude capability](./reference/config#builds-exclude-checks) Disabled required check for top level modules @@ -118,9 +124,9 @@ atopile's package management system has had a huge upgrade! To find packages, check out the entirely overhauled [package index](https://packages.atopile.io). -The new commands to packages are clearer and help keep the packages all in sync. See the updated [package guide](/atopile/essentials/4-packages). +The new commands to packages are clearer and help keep the packages all in sync. See the updated [package guide](./essentials/4-packages). -If you're looking to publish your own packages, [check out the guide](/atopile/guides/publish). +If you're looking to publish your own packages, [check out the guide](./guides/publish). ## Upgrading diff --git a/atopile/essentials/1-the-ato-language.mdx b/atopile-0.12.x/essentials/1-the-ato-language.mdx similarity index 100% rename from atopile/essentials/1-the-ato-language.mdx rename to atopile-0.12.x/essentials/1-the-ato-language.mdx diff --git a/atopile/essentials/2-the-ato-compiler.mdx b/atopile-0.12.x/essentials/2-the-ato-compiler.mdx similarity index 100% rename from atopile/essentials/2-the-ato-compiler.mdx rename to atopile-0.12.x/essentials/2-the-ato-compiler.mdx diff --git a/atopile/essentials/3-add-component.mdx b/atopile-0.12.x/essentials/3-add-component.mdx similarity index 96% rename from atopile/essentials/3-add-component.mdx rename to atopile-0.12.x/essentials/3-add-component.mdx index 5fa2c1e..3b649f2 100644 --- a/atopile/essentials/3-add-component.mdx +++ b/atopile-0.12.x/essentials/3-add-component.mdx @@ -7,7 +7,7 @@ icon: 'plus' ## 1) Auto pick passive components The simplest way to add components is to let atopile pick them for you. This works for passive components such as -[resistors](/atopile/api-reference/components/resistor), [capacitors](/atopile/api-reference/components/capacitor), and [inductors](/atopile/api-reference/components/inductor). +[resistors](../api-reference/components/resistor), [capacitors](../api-reference/components/capacitor), and [inductors](../api-reference/components/inductor). For example, let's say you need a 10kΩ resistor with 1% tolerance in an 0402 package: ```ato diff --git a/atopile/essentials/4-packages.mdx b/atopile-0.12.x/essentials/4-packages.mdx similarity index 100% rename from atopile/essentials/4-packages.mdx rename to atopile-0.12.x/essentials/4-packages.mdx diff --git a/atopile/essentials/5-project-structure.mdx b/atopile-0.12.x/essentials/5-project-structure.mdx similarity index 100% rename from atopile/essentials/5-project-structure.mdx rename to atopile-0.12.x/essentials/5-project-structure.mdx diff --git a/atopile/essentials/6-layout.mdx b/atopile-0.12.x/essentials/6-layout.mdx similarity index 100% rename from atopile/essentials/6-layout.mdx rename to atopile-0.12.x/essentials/6-layout.mdx diff --git a/atopile/essentials/7-saving-your-work.mdx b/atopile-0.12.x/essentials/7-saving-your-work.mdx similarity index 100% rename from atopile/essentials/7-saving-your-work.mdx rename to atopile-0.12.x/essentials/7-saving-your-work.mdx diff --git a/atopile/essentials/8-traits.mdx b/atopile-0.12.x/essentials/8-traits.mdx similarity index 95% rename from atopile/essentials/8-traits.mdx rename to atopile-0.12.x/essentials/8-traits.mdx index adfddee..ebd40fa 100644 --- a/atopile/essentials/8-traits.mdx +++ b/atopile-0.12.x/essentials/8-traits.mdx @@ -10,7 +10,7 @@ Currently the following traits are supported: ## can_bridge_by_name -This trait enables using the [sperm operator `~>`](/atopile/essentials/1-the-ato-language) to make a "bridging" connection over a module. +This trait enables using the [sperm operator `~>`](./1-the-ato-language) to make a "bridging" connection over a module. For example: diff --git a/atopile/essentials/assets/5-pcb-layout-sync.gif b/atopile-0.12.x/essentials/assets/5-pcb-layout-sync.gif similarity index 100% rename from atopile/essentials/assets/5-pcb-layout-sync.gif rename to atopile-0.12.x/essentials/assets/5-pcb-layout-sync.gif diff --git a/atopile/essentials/assets/5-pcb-layout-sync.mp4 b/atopile-0.12.x/essentials/assets/5-pcb-layout-sync.mp4 similarity index 100% rename from atopile/essentials/assets/5-pcb-layout-sync.mp4 rename to atopile-0.12.x/essentials/assets/5-pcb-layout-sync.mp4 diff --git a/atopile/essentials/assets/ato-create-component-search.png b/atopile-0.12.x/essentials/assets/ato-create-component-search.png similarity index 100% rename from atopile/essentials/assets/ato-create-component-search.png rename to atopile-0.12.x/essentials/assets/ato-create-component-search.png diff --git a/atopile/essentials/assets/download.png b/atopile-0.12.x/essentials/assets/download.png similarity index 100% rename from atopile/essentials/assets/download.png rename to atopile-0.12.x/essentials/assets/download.png diff --git a/atopile/essentials/assets/reload.png b/atopile-0.12.x/essentials/assets/reload.png similarity index 100% rename from atopile/essentials/assets/reload.png rename to atopile-0.12.x/essentials/assets/reload.png diff --git a/atopile/guides/development.mdx b/atopile-0.12.x/guides/development.mdx similarity index 100% rename from atopile/guides/development.mdx rename to atopile-0.12.x/guides/development.mdx diff --git a/atopile/guides/fabll.mdx b/atopile-0.12.x/guides/fabll.mdx similarity index 100% rename from atopile/guides/fabll.mdx rename to atopile-0.12.x/guides/fabll.mdx diff --git a/atopile/guides/faebryk.mdx b/atopile-0.12.x/guides/faebryk.mdx similarity index 100% rename from atopile/guides/faebryk.mdx rename to atopile-0.12.x/guides/faebryk.mdx diff --git a/atopile/guides/git.mdx b/atopile-0.12.x/guides/git.mdx similarity index 100% rename from atopile/guides/git.mdx rename to atopile-0.12.x/guides/git.mdx diff --git a/atopile/guides/images/debugger-vscode.png b/atopile-0.12.x/guides/images/debugger-vscode.png similarity index 100% rename from atopile/guides/images/debugger-vscode.png rename to atopile-0.12.x/guides/images/debugger-vscode.png diff --git a/atopile/guides/install.mdx b/atopile-0.12.x/guides/install.mdx similarity index 50% rename from atopile/guides/install.mdx rename to atopile-0.12.x/guides/install.mdx index d03cf35..da61028 100644 --- a/atopile/guides/install.mdx +++ b/atopile-0.12.x/guides/install.mdx @@ -4,9 +4,54 @@ description: 'How to install atopile' icon: 'terminal' --- -import QuickstartInstall from '/snippets/atopile/guides/quick-install.mdx'; +## Install via VSCode/Cursor (Recommended) - +atopile officially supports VSCode and Cursor. + +We recommend using Cursor. AI is already getting very good at writing `ato` code. + +Download it here: https://www.cursor.com/ + +Once you have VSCode/Cursor just install the [atopile VSCode/Cursor extension](https://marketplace.visualstudio.com/items?itemName=atopile.atopile). + +![atopile extension](/atopile-0.12.x/images/vscode-plugin.png) + +After installation it will prompt you to install the `ato` CLI. Click the `Install Automatically` button. + +![atopile extension install](/atopile-0.12.x/images/vscode-plugin-install-popup.png) + + + Set up an MCP server for this documentation with + + ``` sh + npx mint-mcp add atopile + ``` + + + +## Installing KiCAD + +If you want to layout or route PCBs you will need to install [KiCAD](https://www.kicad.org/download/). + + +```sh macOS (brew) +brew install kicad +``` + +```sh Arch Linux +sudo pacman -S kicad +``` + +```sh Ubuntu +sudo apt install kicad +``` + +```sh other +https://www.kicad.org/download/ +# or click the KiCAD link above +``` + + Ultimately, `atopile` is a Python package, so you can install it wherever and however you want—but some Python package managers are better than others. Here's the recommended method to install atopile. diff --git a/atopile/guides/publish.mdx b/atopile-0.12.x/guides/publish.mdx similarity index 100% rename from atopile/guides/publish.mdx rename to atopile-0.12.x/guides/publish.mdx diff --git a/atopile/images/ato-example-build.png b/atopile-0.12.x/images/ato-example-build.png similarity index 100% rename from atopile/images/ato-example-build.png rename to atopile-0.12.x/images/ato-example-build.png diff --git a/atopile/images/ato-menu-bar.png b/atopile-0.12.x/images/ato-menu-bar.png similarity index 100% rename from atopile/images/ato-menu-bar.png rename to atopile-0.12.x/images/ato-menu-bar.png diff --git a/atopile/images/quick-select-example.png b/atopile-0.12.x/images/quick-select-example.png similarity index 100% rename from atopile/images/quick-select-example.png rename to atopile-0.12.x/images/quick-select-example.png diff --git a/atopile/images/quickstart-layout.png b/atopile-0.12.x/images/quickstart-layout.png similarity index 100% rename from atopile/images/quickstart-layout.png rename to atopile-0.12.x/images/quickstart-layout.png diff --git a/atopile/images/vscode-plugin-install-popup.png b/atopile-0.12.x/images/vscode-plugin-install-popup.png similarity index 100% rename from atopile/images/vscode-plugin-install-popup.png rename to atopile-0.12.x/images/vscode-plugin-install-popup.png diff --git a/atopile/images/vscode-plugin.png b/atopile-0.12.x/images/vscode-plugin.png similarity index 100% rename from atopile/images/vscode-plugin.png rename to atopile-0.12.x/images/vscode-plugin.png diff --git a/atopile/introduction.mdx b/atopile-0.12.x/introduction.mdx similarity index 100% rename from atopile/introduction.mdx rename to atopile-0.12.x/introduction.mdx diff --git a/atopile/quickstart.mdx b/atopile-0.12.x/quickstart.mdx similarity index 75% rename from atopile/quickstart.mdx rename to atopile-0.12.x/quickstart.mdx index 8dc1b75..68eb143 100644 --- a/atopile/quickstart.mdx +++ b/atopile-0.12.x/quickstart.mdx @@ -7,9 +7,54 @@ icon: "rocket" See the [installation guide](./guides/install) for advanced setups. For the simple way to get started, read on. -import QuickstartInstall from "/snippets/atopile/guides/quick-install.mdx"; +## Install via VSCode/Cursor (Recommended) - +atopile officially supports VSCode and Cursor. + +We recommend using Cursor. AI is already getting very good at writing `ato` code. + +Download it here: https://www.cursor.com/ + +Once you have VSCode/Cursor just install the [atopile VSCode/Cursor extension](https://marketplace.visualstudio.com/items?itemName=atopile.atopile). + +![atopile extension](/atopile-0.12.x/images/vscode-plugin.png) + +After installation it will prompt you to install the `ato` CLI. Click the `Install Automatically` button. + +![atopile extension install](/atopile-0.12.x/images/vscode-plugin-install-popup.png) + + + Set up an MCP server for this documentation with + + ``` sh + npx mint-mcp add atopile + ``` + + + +## Installing KiCAD + +If you want to layout or route PCBs you will need to install [KiCAD](https://www.kicad.org/download/). + + +```sh macOS (brew) +brew install kicad +``` + +```sh Arch Linux +sudo pacman -S kicad +``` + +```sh Ubuntu +sudo apt install kicad +``` + +```sh other +https://www.kicad.org/download/ +# or click the KiCAD link above +``` + + ## Trying out an example @@ -20,12 +65,12 @@ Press `Ctrl+Shift+P` and search for `atopile: Open Example`. Choose any example you like from the selection. After confirming wait for the `ato menu bar` to appear: -![ato menu bar](/atopile/images/ato-menu-bar.png) +![ato menu bar](/atopile-0.12.x/images/ato-menu-bar.png) Press on the play button to compile the example. You will be greeted by the logs in the terminal: -![compile example](/atopile/images/ato-example-build.png) +![compile example](/atopile-0.12.x/images/ato-example-build.png) If you have KiCAD installed, you can now press on the PCB icon in the ato menu bar to open the layout file. @@ -113,7 +158,7 @@ INFO Build successful! 🚀 Then KiCAD will open up (that's what the `--open` flag does). Your shiny ✨ new component should be waiting for you in the top left corner (possibly off the current screen). -![layout](/atopile/images/quickstart-layout.png) +![layout](/atopile-0.12.x/images/quickstart-layout.png) Oh yeah! We're in business. 😎 diff --git a/atopile/reference/config.mdx b/atopile-0.12.x/reference/config.mdx similarity index 100% rename from atopile/reference/config.mdx rename to atopile-0.12.x/reference/config.mdx diff --git a/atopile/support.mdx b/atopile-0.12.x/support.mdx similarity index 100% rename from atopile/support.mdx rename to atopile-0.12.x/support.mdx diff --git a/atopile-0.14.x/api-reference/components/battery.mdx b/atopile-0.14.x/api-reference/components/battery.mdx new file mode 100644 index 0000000..7abf9e3 --- /dev/null +++ b/atopile-0.14.x/api-reference/components/battery.mdx @@ -0,0 +1,98 @@ +--- + +title: "Battery" +icon: microchip +description: "" +--- + + +## Parameters + + + + + + + + +## Interfaces + + + + + +## Global Attributes + + +These attributes are available to all modules and interfaces in a design. + + +Assign the LCSC ID of the module. + +If set, this will tell the picker to select that part from LCSC for this block. + + + + +This module's manufacturer name, as a string. + +Only exact matches on the manufacturer's name will be found by the picker. +It's recommended to fill this information based on what `ato create component` +provides. + + + + +This module's manufacturer part number, as a string. + +For the picker to select the correct part from the manufacturer, +this must be set. + + + + +The package of the module. + +This drives which components can be selected, and what footprint is used. + +Must exactly match a known package name. + + + + + + + +When set on an interface, this will override the net name of the interface. + +This is useful for renaming nets which are automatically generated. + + + + +Only for ModuleInterfaces. +If set to `True`, require that interface is connected to something outside +of the module it's defined in. + + + +```ato Basic Usage +import Battery, ElectricPower + +battery = new Battery +battery.voltage = 3.7V +/- 10% # Li-ion cell +battery.capacity = 2000mAh +/- 5% + +# Connect to system power +system_power = new ElectricPower +battery.power ~ system_power + +# Battery specifications will constrain system voltage +assert system_power.voltage within battery.voltage + +# For multiple cells in series +battery_pack = new Battery +battery_pack.voltage = 11.1V +/- 10% # 3S Li-ion pack +battery_pack.capacity = 2000mAh +/- 5% +``` + \ No newline at end of file diff --git a/atopile-0.14.x/api-reference/components/bjt.mdx b/atopile-0.14.x/api-reference/components/bjt.mdx new file mode 100644 index 0000000..4daf812 --- /dev/null +++ b/atopile-0.14.x/api-reference/components/bjt.mdx @@ -0,0 +1,103 @@ +--- + +title: "BJT" +icon: microchip +description: "" +--- + + +## Parameters + + + + + + + + +## Interfaces + + + + + + + + + + + +## Global Attributes + + +These attributes are available to all modules and interfaces in a design. + + +Assign the LCSC ID of the module. + +If set, this will tell the picker to select that part from LCSC for this block. + + + + +This module's manufacturer name, as a string. + +Only exact matches on the manufacturer's name will be found by the picker. +It's recommended to fill this information based on what `ato create component` +provides. + + + + +This module's manufacturer part number, as a string. + +For the picker to select the correct part from the manufacturer, +this must be set. + + + + +The package of the module. + +This drives which components can be selected, and what footprint is used. + +Must exactly match a known package name. + + + + + + + +When set on an interface, this will override the net name of the interface. + +This is useful for renaming nets which are automatically generated. + + + + +Only for ModuleInterfaces. +If set to `True`, require that interface is connected to something outside +of the module it's defined in. + + + +```ato Basic Usage +import BJT, Resistor, ElectricPower + +bjt = new BJT +bjt.doping_type ="NPN" +bjt.mpn = "C373737 + +# Use as amplifier with bias resistors +base_resistor = new Resistor +collector_resistor = new Resistor +power_supply = new ElectricPower + +# Basic amplifier configuration +power_supply.hv ~> collector_resistor ~> bjt.collector +bjt.emitter ~ power_supply.lv +input_signal ~> base_resistor ~> bjt.base +output_signal ~ bjt.collector +``` + \ No newline at end of file diff --git a/atopile-0.14.x/api-reference/components/capacitor.mdx b/atopile-0.14.x/api-reference/components/capacitor.mdx new file mode 100644 index 0000000..2ecc9b8 --- /dev/null +++ b/atopile-0.14.x/api-reference/components/capacitor.mdx @@ -0,0 +1,98 @@ +--- + +title: "Capacitor" +icon: microchip +description: "" +--- + + +## Parameters + + + + + + + + + + + +## Interfaces + + + + + + + + +## Global Attributes + + +These attributes are available to all modules and interfaces in a design. + + +Assign the LCSC ID of the module. + +If set, this will tell the picker to select that part from LCSC for this block. + + + + +This module's manufacturer name, as a string. + +Only exact matches on the manufacturer's name will be found by the picker. +It's recommended to fill this information based on what `ato create component` +provides. + + + + +This module's manufacturer part number, as a string. + +For the picker to select the correct part from the manufacturer, +this must be set. + + + + +The package of the module. + +This drives which components can be selected, and what footprint is used. + +Must exactly match a known package name. + + + + + + + +When set on an interface, this will override the net name of the interface. + +This is useful for renaming nets which are automatically generated. + + + + +Only for ModuleInterfaces. +If set to `True`, require that interface is connected to something outside +of the module it's defined in. + + + +```ato Basic Usage +import Capacitor + +capacitor = new Capacitor +capacitor.capacitance = 100nF +/- 10% +assert capacitor.max_voltage within 25V to 50V +capacitor.package = "0603" + +electrical1 ~ capacitor.unnamed[0] +electrical2 ~ capacitor.unnamed[1] +# OR +electrical1 ~> capacitor ~> electrical2 +``` + \ No newline at end of file diff --git a/atopile-0.14.x/api-reference/components/capacitorelectrolytic.mdx b/atopile-0.14.x/api-reference/components/capacitorelectrolytic.mdx new file mode 100644 index 0000000..7fdfbba --- /dev/null +++ b/atopile-0.14.x/api-reference/components/capacitorelectrolytic.mdx @@ -0,0 +1,122 @@ +--- + +title: "CapacitorElectrolytic" +icon: +description: "" +--- + + +## Parameters + + + + + + + + + + + +## Interfaces + + + + + + + + + + + + + + + + + +## Global Attributes + + +These attributes are available to all modules and interfaces in a design. + + +Assign the LCSC ID of the module. + +If set, this will tell the picker to select that part from LCSC for this block. + + + + +This module's manufacturer name, as a string. + +Only exact matches on the manufacturer's name will be found by the picker. +It's recommended to fill this information based on what `ato create component` +provides. + + + + +This module's manufacturer part number, as a string. + +For the picker to select the correct part from the manufacturer, +this must be set. + + + + +The package of the module. + +This drives which components can be selected, and what footprint is used. + +Must exactly match a known package name. + + + + + + + +When set on an interface, this will override the net name of the interface. + +This is useful for renaming nets which are automatically generated. + + + + +Only for ModuleInterfaces. +If set to `True`, require that interface is connected to something outside +of the module it's defined in. + + + +```ato Basic Usage +import CapacitorElectrolytic, ElectricPower + +electrolytic_cap = new CapacitorElectrolytic +electrolytic_cap.capacitance = 1000uF +/- 20% +electrolytic_cap.max_voltage = 25V +electrolytic_cap.package = "radial_8x12" # 8mm diameter, 12mm height + +# Connect to power supply for bulk filtering +power_supply = new ElectricPower +assert power_supply.voltage within 12V +/- 10% + +# CRITICAL: Observe polarity! Anode to positive, cathode to negative +power_supply.hv ~ electrolytic_cap.anode # Positive terminal +power_supply.lv ~ electrolytic_cap.cathode # Negative terminal + +# Alternative bridge syntax (maintains polarity) +power_supply.hv ~> electrolytic_cap ~> power_supply.lv + +# Common values and applications: +# - 10-100uF: Local power supply filtering +# - 100-1000uF: Bulk power supply capacitance +# - 1000-10000uF: Main power supply smoothing +# - Audio coupling: 1-100uF (mind polarity!) + +# WARNING: Reverse voltage will damage electrolytic capacitors! +# Use ceramic or film capacitors for AC coupling applications +``` + \ No newline at end of file diff --git a/atopile-0.14.x/api-reference/components/common_mode_filter.mdx b/atopile-0.14.x/api-reference/components/common_mode_filter.mdx new file mode 100644 index 0000000..8eaf85e --- /dev/null +++ b/atopile-0.14.x/api-reference/components/common_mode_filter.mdx @@ -0,0 +1,77 @@ +--- + +title: "Common_Mode_Filter" +icon: microchip +description: "" +--- + + +## Parameters + + + + + + + + + + + + + + +## Global Attributes + + +These attributes are available to all modules and interfaces in a design. + + +Assign the LCSC ID of the module. + +If set, this will tell the picker to select that part from LCSC for this block. + + + + +This module's manufacturer name, as a string. + +Only exact matches on the manufacturer's name will be found by the picker. +It's recommended to fill this information based on what `ato create component` +provides. + + + + +This module's manufacturer part number, as a string. + +For the picker to select the correct part from the manufacturer, +this must be set. + + + + +The package of the module. + +This drives which components can be selected, and what footprint is used. + +Must exactly match a known package name. + + + + + + + +When set on an interface, this will override the net name of the interface. + +This is useful for renaming nets which are automatically generated. + + + + +Only for ModuleInterfaces. +If set to `True`, require that interface is connected to something outside +of the module it's defined in. + + diff --git a/atopile-0.14.x/api-reference/components/comparator.mdx b/atopile-0.14.x/api-reference/components/comparator.mdx new file mode 100644 index 0000000..408ad52 --- /dev/null +++ b/atopile-0.14.x/api-reference/components/comparator.mdx @@ -0,0 +1,136 @@ +--- + +title: "Comparator" +icon: microchip +description: "" +--- + + +## Parameters + + + + + + + + + + + + + + + + + + + + +## Interfaces + + + + + + + + + + + + + + +## Global Attributes + + +These attributes are available to all modules and interfaces in a design. + + +Assign the LCSC ID of the module. + +If set, this will tell the picker to select that part from LCSC for this block. + + + + +This module's manufacturer name, as a string. + +Only exact matches on the manufacturer's name will be found by the picker. +It's recommended to fill this information based on what `ato create component` +provides. + + + + +This module's manufacturer part number, as a string. + +For the picker to select the correct part from the manufacturer, +this must be set. + + + + +The package of the module. + +This drives which components can be selected, and what footprint is used. + +Must exactly match a known package name. + + + + + + + +When set on an interface, this will override the net name of the interface. + +This is useful for renaming nets which are automatically generated. + + + + +Only for ModuleInterfaces. +If set to `True`, require that interface is connected to something outside +of the module it's defined in. + + + +```ato Basic Usage +import Comparator, Resistor, ElectricPower, Electrical + +comparator = new Comparator +comparator.common_mode_rejection_ratio = 80dB +/- 10% +comparator.input_bias_current = 1nA +/- 50% +comparator.input_hysteresis_voltage = 5mV +/- 20% +comparator.input_offset_voltage = 1mV +/- 30% +comparator.propagation_delay = 100ns +/- 20% +comparator.output_type = Comparator.OutputType.PushPull +comparator.package = "SOIC-8" + +# Power supply connections (dual supply) +power_pos = new ElectricPower +power_neg = new ElectricPower +assert power_pos.voltage within 5V +/- 5% +assert power_neg.voltage within -5V +/- 5% +comparator.power.hv ~ power_pos.hv +comparator.power.lv ~ power_neg.lv + +# Create voltage reference with resistor divider +ref_resistor_high = new Resistor +ref_resistor_low = new Resistor +ref_resistor_high.resistance = 10kohm +/- 1% +ref_resistor_low.resistance = 10kohm +/- 1% + +# Reference voltage = Vcc/2 +power_pos.hv ~> ref_resistor_high ~> comparator.non_inverting_input +comparator.non_inverting_input ~> ref_resistor_low ~> power_neg.lv + +# Connect input signal to inverting input +input_signal ~ comparator.inverting_input +output_signal ~ comparator.output + +# Output will be HIGH when input_signal > reference_voltage +``` + \ No newline at end of file diff --git a/atopile-0.14.x/api-reference/components/crystal.mdx b/atopile-0.14.x/api-reference/components/crystal.mdx new file mode 100644 index 0000000..d99e240 --- /dev/null +++ b/atopile-0.14.x/api-reference/components/crystal.mdx @@ -0,0 +1,122 @@ +--- + +title: "Crystal" +icon: microchip +description: "" +--- + + +## Parameters + + + + + + + + + + + + + + + + + + + + + + + +## Interfaces + + + + + + + + + + + +## Global Attributes + + +These attributes are available to all modules and interfaces in a design. + + +Assign the LCSC ID of the module. + +If set, this will tell the picker to select that part from LCSC for this block. + + + + +This module's manufacturer name, as a string. + +Only exact matches on the manufacturer's name will be found by the picker. +It's recommended to fill this information based on what `ato create component` +provides. + + + + +This module's manufacturer part number, as a string. + +For the picker to select the correct part from the manufacturer, +this must be set. + + + + +The package of the module. + +This drives which components can be selected, and what footprint is used. + +Must exactly match a known package name. + + + + + + + +When set on an interface, this will override the net name of the interface. + +This is useful for renaming nets which are automatically generated. + + + + +Only for ModuleInterfaces. +If set to `True`, require that interface is connected to something outside +of the module it's defined in. + + + +```ato Basic Usage +import Crystal, Capacitor + +crystal = new Crystal +crystal.frequency = 16MHz +/- 20ppm +crystal.frequency_tolerance = 20ppm +crystal.load_capacitance = 18pF +/- 10% +crystal.equivalent_series_resistance = 80ohm +/- 20% +crystal.package = "HC49U" + +# Connect to microcontroller with load capacitors +load_cap1 = new Capacitor +load_cap2 = new Capacitor +load_cap1.capacitance = 22pF +/- 5% +load_cap2.capacitance = 22pF +/- 5% + +mcu.xtal1 ~ crystal.unnamed[0] +mcu.xtal2 ~ crystal.unnamed[1] +crystal.unnamed[0] ~> load_cap1 ~> crystal.gnd +crystal.unnamed[1] ~> load_cap2 ~> crystal.gnd +crystal.gnd ~ power_supply.lv +``` + \ No newline at end of file diff --git a/atopile-0.14.x/api-reference/components/crystal_oscillator.mdx b/atopile-0.14.x/api-reference/components/crystal_oscillator.mdx new file mode 100644 index 0000000..6392bc0 --- /dev/null +++ b/atopile-0.14.x/api-reference/components/crystal_oscillator.mdx @@ -0,0 +1,100 @@ +--- + +title: "Crystal_Oscillator" +icon: microchip +description: "" +--- + + +## Interfaces + + + + + +## Global Attributes + + +These attributes are available to all modules and interfaces in a design. + + +Assign the LCSC ID of the module. + +If set, this will tell the picker to select that part from LCSC for this block. + + + + +This module's manufacturer name, as a string. + +Only exact matches on the manufacturer's name will be found by the picker. +It's recommended to fill this information based on what `ato create component` +provides. + + + + +This module's manufacturer part number, as a string. + +For the picker to select the correct part from the manufacturer, +this must be set. + + + + +The package of the module. + +This drives which components can be selected, and what footprint is used. + +Must exactly match a known package name. + + + + + + + +When set on an interface, this will override the net name of the interface. + +This is useful for renaming nets which are automatically generated. + + + + +Only for ModuleInterfaces. +If set to `True`, require that interface is connected to something outside +of the module it's defined in. + + + +```ato Basic Usage +import Crystal_Oscillator, ElectricPower + +crystal_osc = new Crystal_Oscillator + +# Configure crystal parameters +crystal_osc.crystal.frequency = 16MHz +/- 20ppm +crystal_osc.crystal.load_capacitance = 18pF +/- 10% +crystal_osc.crystal.equivalent_series_resistance = 80ohm +/- 20% +crystal_osc.crystal.package = "HC49U" + +# Connect power for ground reference +power_3v3 = new ElectricPower +assert power_3v3.voltage within 3.3V +/- 5% +crystal_osc.xtal_if.gnd ~ power_3v3.lv + +# Connect to microcontroller crystal pins +microcontroller.xtal_in ~ crystal_osc.xtal_if.xin +microcontroller.xtal_out ~ crystal_osc.xtal_if.xout + +# Load capacitors are automatically calculated: +# C_load = (Crystal_load_cap - Stray_cap) * 2 +# Typically results in 22pF capacitors for 18pF crystal + +# Current limiting resistor prevents overdrive (optional) +crystal_osc.current_limiting_resistor.resistance = 1kohm +/- 5% + +# Common frequencies: 8MHz, 12MHz, 16MHz, 20MHz, 25MHz +# Used for: microcontroller clocks, RTC, timing references +``` + \ No newline at end of file diff --git a/atopile-0.14.x/api-reference/components/diode.mdx b/atopile-0.14.x/api-reference/components/diode.mdx new file mode 100644 index 0000000..732afc8 --- /dev/null +++ b/atopile-0.14.x/api-reference/components/diode.mdx @@ -0,0 +1,108 @@ +--- + +title: "Diode" +icon: microchip +description: "" +--- + + +## Parameters + + + + + + + + + + + + + + + + + +## Interfaces + + + + + + + + +## Global Attributes + + +These attributes are available to all modules and interfaces in a design. + + +Assign the LCSC ID of the module. + +If set, this will tell the picker to select that part from LCSC for this block. + + + + +This module's manufacturer name, as a string. + +Only exact matches on the manufacturer's name will be found by the picker. +It's recommended to fill this information based on what `ato create component` +provides. + + + + +This module's manufacturer part number, as a string. + +For the picker to select the correct part from the manufacturer, +this must be set. + + + + +The package of the module. + +This drives which components can be selected, and what footprint is used. + +Must exactly match a known package name. + + + + + + + +When set on an interface, this will override the net name of the interface. + +This is useful for renaming nets which are automatically generated. + + + + +Only for ModuleInterfaces. +If set to `True`, require that interface is connected to something outside +of the module it's defined in. + + + +```ato Basic Usage +import Diode, Resistor, ElectricPower + +diode = new Diode +diode.forward_voltage = 0.7V +/- 10% +diode.current = 10mA +/- 5% +diode.reverse_working_voltage = 50V +diode.max_current = 100mA +diode.package = "SOD-123" + +# Connect as rectifier +ac_input ~ diode.anode +diode.cathode ~ dc_output + +# With current limiting resistor +power_supply.hv ~> current_limit_resistor ~> diode ~> power_supply.lv +``` + \ No newline at end of file diff --git a/atopile-0.14.x/api-reference/components/dip.mdx b/atopile-0.14.x/api-reference/components/dip.mdx new file mode 100644 index 0000000..d0a7b68 --- /dev/null +++ b/atopile-0.14.x/api-reference/components/dip.mdx @@ -0,0 +1,83 @@ +--- + +title: "DIP" +icon: microchip +description: "" +--- + + +## Init Args + + + + + + + + + + + + + + +## Interfaces + + + + + +## Global Attributes + + +These attributes are available to all modules and interfaces in a design. + + +Assign the LCSC ID of the module. + +If set, this will tell the picker to select that part from LCSC for this block. + + + + +This module's manufacturer name, as a string. + +Only exact matches on the manufacturer's name will be found by the picker. +It's recommended to fill this information based on what `ato create component` +provides. + + + + +This module's manufacturer part number, as a string. + +For the picker to select the correct part from the manufacturer, +this must be set. + + + + +The package of the module. + +This drives which components can be selected, and what footprint is used. + +Must exactly match a known package name. + + + + + + + +When set on an interface, this will override the net name of the interface. + +This is useful for renaming nets which are automatically generated. + + + + +Only for ModuleInterfaces. +If set to `True`, require that interface is connected to something outside +of the module it's defined in. + + diff --git a/atopile-0.14.x/api-reference/components/eeprom.mdx b/atopile-0.14.x/api-reference/components/eeprom.mdx new file mode 100644 index 0000000..fdd18e8 --- /dev/null +++ b/atopile-0.14.x/api-reference/components/eeprom.mdx @@ -0,0 +1,132 @@ +--- + +title: "EEPROM" +icon: microchip +description: " +Generic EEPROM module with F.I2C interface. +" +--- + + +## Parameters + + + + + +## Interfaces + + + + + + + + + + + + + + + + + + + + +## Global Attributes + + +These attributes are available to all modules and interfaces in a design. + + +Assign the LCSC ID of the module. + +If set, this will tell the picker to select that part from LCSC for this block. + + + + +This module's manufacturer name, as a string. + +Only exact matches on the manufacturer's name will be found by the picker. +It's recommended to fill this information based on what `ato create component` +provides. + + + + +This module's manufacturer part number, as a string. + +For the picker to select the correct part from the manufacturer, +this must be set. + + + + +The package of the module. + +This drives which components can be selected, and what footprint is used. + +Must exactly match a known package name. + + + + + + + +When set on an interface, this will override the net name of the interface. + +This is useful for renaming nets which are automatically generated. + + + + +Only for ModuleInterfaces. +If set to `True`, require that interface is connected to something outside +of the module it's defined in. + + + +```ato Basic Usage +import EEPROM, ElectricPower, I2C, Resistor + +eeprom = new EEPROM +eeprom.memory_size = 32kbit # Common sizes: 1k, 2k, 4k, 8k, 16k, 32k, 64k, 128k bit + +# Connect power supply +power_3v3 = new ElectricPower +assert power_3v3.voltage within 3.3V +/- 5% +eeprom.power ~ power_3v3 + +# Connect I2C bus +i2c_bus = new I2C +i2c_bus.frequency = 400kHz # Fast mode +eeprom.i2c ~ i2c_bus + +# Connect to microcontroller +microcontroller.i2c ~ i2c_bus + +# Set device address using address pins +eeprom.set_address(0) # Device address 0b000 + +# Connect address pins to power rails for different addresses +eeprom.address[0].line ~ power_3v3.lv # A0 = 0 +eeprom.address[1].line ~ power_3v3.lv # A1 = 0 +eeprom.address[2].line ~ power_3v3.lv # A2 = 0 + +# Write protect control (optional) +eeprom.write_protect.reference ~ power_3v3 +eeprom.write_protect.line ~ power_3v3.lv # Enable writes + +# Pull-up resistors for I2C (if not provided elsewhere) +sda_pullup = new Resistor +scl_pullup = new Resistor +sda_pullup.resistance = 4.7kohm +/- 5% +scl_pullup.resistance = 4.7kohm +/- 5% +i2c_bus.sda.line ~> sda_pullup ~> power_3v3.hv +i2c_bus.scl.line ~> scl_pullup ~> power_3v3.hv +``` + \ No newline at end of file diff --git a/atopile-0.14.x/api-reference/components/electriclogicgate.mdx b/atopile-0.14.x/api-reference/components/electriclogicgate.mdx new file mode 100644 index 0000000..e0213a9 --- /dev/null +++ b/atopile-0.14.x/api-reference/components/electriclogicgate.mdx @@ -0,0 +1,71 @@ +--- + +title: "ElectricLogicGate" +icon: microchip +description: "" +--- + + +## Interfaces + + + + + + + + +## Global Attributes + + +These attributes are available to all modules and interfaces in a design. + + +Assign the LCSC ID of the module. + +If set, this will tell the picker to select that part from LCSC for this block. + + + + +This module's manufacturer name, as a string. + +Only exact matches on the manufacturer's name will be found by the picker. +It's recommended to fill this information based on what `ato create component` +provides. + + + + +This module's manufacturer part number, as a string. + +For the picker to select the correct part from the manufacturer, +this must be set. + + + + +The package of the module. + +This drives which components can be selected, and what footprint is used. + +Must exactly match a known package name. + + + + + + + +When set on an interface, this will override the net name of the interface. + +This is useful for renaming nets which are automatically generated. + + + + +Only for ModuleInterfaces. +If set to `True`, require that interface is connected to something outside +of the module it's defined in. + + diff --git a/atopile-0.14.x/api-reference/components/fan.mdx b/atopile-0.14.x/api-reference/components/fan.mdx new file mode 100644 index 0000000..c52dca1 --- /dev/null +++ b/atopile-0.14.x/api-reference/components/fan.mdx @@ -0,0 +1,86 @@ +--- + +title: "Fan" +icon: microchip +description: "" +--- + + +## Interfaces + + + + + +## Global Attributes + + +These attributes are available to all modules and interfaces in a design. + + +Assign the LCSC ID of the module. + +If set, this will tell the picker to select that part from LCSC for this block. + + + + +This module's manufacturer name, as a string. + +Only exact matches on the manufacturer's name will be found by the picker. +It's recommended to fill this information based on what `ato create component` +provides. + + + + +This module's manufacturer part number, as a string. + +For the picker to select the correct part from the manufacturer, +this must be set. + + + + +The package of the module. + +This drives which components can be selected, and what footprint is used. + +Must exactly match a known package name. + + + + + + + +When set on an interface, this will override the net name of the interface. + +This is useful for renaming nets which are automatically generated. + + + + +Only for ModuleInterfaces. +If set to `True`, require that interface is connected to something outside +of the module it's defined in. + + + +```ato Basic Usage +import Fan, ElectricPower + +fan = new Fan + +# Connect power supply (typically 12V for PC fans) +power_12v = new ElectricPower +assert power_12v.voltage within 12V +/- 5% +assert power_12v.max_current >= 200mA # Typical fan current + +fan.power ~ power_12v + +# For PWM control, connect through a MOSFET or fan controller +# fan.power.hv ~ power_12v.hv +# fan.power.lv ~> pwm_controller ~> power_12v.lv +``` + \ No newline at end of file diff --git a/atopile-0.14.x/api-reference/components/filter.mdx b/atopile-0.14.x/api-reference/components/filter.mdx new file mode 100644 index 0000000..244779b --- /dev/null +++ b/atopile-0.14.x/api-reference/components/filter.mdx @@ -0,0 +1,83 @@ +--- + +title: "Filter" +icon: microchip +description: "" +--- + + +## Parameters + + + + + + + + + + + +## Interfaces + + + + + + + + +## Global Attributes + + +These attributes are available to all modules and interfaces in a design. + + +Assign the LCSC ID of the module. + +If set, this will tell the picker to select that part from LCSC for this block. + + + + +This module's manufacturer name, as a string. + +Only exact matches on the manufacturer's name will be found by the picker. +It's recommended to fill this information based on what `ato create component` +provides. + + + + +This module's manufacturer part number, as a string. + +For the picker to select the correct part from the manufacturer, +this must be set. + + + + +The package of the module. + +This drives which components can be selected, and what footprint is used. + +Must exactly match a known package name. + + + + + + + +When set on an interface, this will override the net name of the interface. + +This is useful for renaming nets which are automatically generated. + + + + +Only for ModuleInterfaces. +If set to `True`, require that interface is connected to something outside +of the module it's defined in. + + diff --git a/atopile-0.14.x/api-reference/components/filterelectricallc.mdx b/atopile-0.14.x/api-reference/components/filterelectricallc.mdx new file mode 100644 index 0000000..6a45f6a --- /dev/null +++ b/atopile-0.14.x/api-reference/components/filterelectricallc.mdx @@ -0,0 +1,88 @@ +--- + +title: "FilterElectricalLC" +icon: microchip +description: " +Basic Electrical LC filter +" +--- + + +## Parameters + + + + + + + + + + + + + + +## Interfaces + + + + + + + + +## Global Attributes + + +These attributes are available to all modules and interfaces in a design. + + +Assign the LCSC ID of the module. + +If set, this will tell the picker to select that part from LCSC for this block. + + + + +This module's manufacturer name, as a string. + +Only exact matches on the manufacturer's name will be found by the picker. +It's recommended to fill this information based on what `ato create component` +provides. + + + + +This module's manufacturer part number, as a string. + +For the picker to select the correct part from the manufacturer, +this must be set. + + + + +The package of the module. + +This drives which components can be selected, and what footprint is used. + +Must exactly match a known package name. + + + + + + + +When set on an interface, this will override the net name of the interface. + +This is useful for renaming nets which are automatically generated. + + + + +Only for ModuleInterfaces. +If set to `True`, require that interface is connected to something outside +of the module it's defined in. + + diff --git a/atopile-0.14.x/api-reference/components/filterelectricalrc.mdx b/atopile-0.14.x/api-reference/components/filterelectricalrc.mdx new file mode 100644 index 0000000..599ee21 --- /dev/null +++ b/atopile-0.14.x/api-reference/components/filterelectricalrc.mdx @@ -0,0 +1,109 @@ +--- + +title: "FilterElectricalRC" +icon: microchip +description: " +Basic Electrical RC filter +" +--- + + +## Parameters + + + + + + + + + + + +## Interfaces + + + + + + + + +## Global Attributes + + +These attributes are available to all modules and interfaces in a design. + + +Assign the LCSC ID of the module. + +If set, this will tell the picker to select that part from LCSC for this block. + + + + +This module's manufacturer name, as a string. + +Only exact matches on the manufacturer's name will be found by the picker. +It's recommended to fill this information based on what `ato create component` +provides. + + + + +This module's manufacturer part number, as a string. + +For the picker to select the correct part from the manufacturer, +this must be set. + + + + +The package of the module. + +This drives which components can be selected, and what footprint is used. + +Must exactly match a known package name. + + + + + + + +When set on an interface, this will override the net name of the interface. + +This is useful for renaming nets which are automatically generated. + + + + +Only for ModuleInterfaces. +If set to `True`, require that interface is connected to something outside +of the module it's defined in. + + + +```ato Basic Usage +import FilterElectricalRC, ElectricSignal, ElectricPower + +# Create low-pass RC filter +rc_filter = new FilterElectricalRC +rc_filter.cutoff_frequency = 1kHz +/- 10% + +# Connect power reference +power_supply = new ElectricPower +assert power_supply.voltage within 5V +/- 5% +rc_filter.in_.reference ~ power_supply +rc_filter.out.reference ~ power_supply + +# Connect input and output signals +input_signal = new ElectricSignal +output_signal = new ElectricSignal +input_signal ~ rc_filter.in_ +rc_filter.out ~ output_signal + +# Alternative: use hardcoded values for faster solving +rc_filter_fixed = FilterElectricalRC.hardcoded_rc(1kohm +/- 5%, 100nF +/- 10%) +``` + \ No newline at end of file diff --git a/atopile-0.14.x/api-reference/components/footprint.mdx b/atopile-0.14.x/api-reference/components/footprint.mdx new file mode 100644 index 0000000..67981d0 --- /dev/null +++ b/atopile-0.14.x/api-reference/components/footprint.mdx @@ -0,0 +1,62 @@ +--- + +title: "Footprint" +icon: microchip +description: "" +--- + + +## Global Attributes + + +These attributes are available to all modules and interfaces in a design. + + +Assign the LCSC ID of the module. + +If set, this will tell the picker to select that part from LCSC for this block. + + + + +This module's manufacturer name, as a string. + +Only exact matches on the manufacturer's name will be found by the picker. +It's recommended to fill this information based on what `ato create component` +provides. + + + + +This module's manufacturer part number, as a string. + +For the picker to select the correct part from the manufacturer, +this must be set. + + + + +The package of the module. + +This drives which components can be selected, and what footprint is used. + +Must exactly match a known package name. + + + + + + + +When set on an interface, this will override the net name of the interface. + +This is useful for renaming nets which are automatically generated. + + + + +Only for ModuleInterfaces. +If set to `True`, require that interface is connected to something outside +of the module it's defined in. + + diff --git a/atopile-0.14.x/api-reference/components/fuse.mdx b/atopile-0.14.x/api-reference/components/fuse.mdx new file mode 100644 index 0000000..ef66797 --- /dev/null +++ b/atopile-0.14.x/api-reference/components/fuse.mdx @@ -0,0 +1,110 @@ +--- + +title: "Fuse" +icon: microchip +description: "" +--- + + +## Parameters + + + + + + + + + + + +## Interfaces + + + + + + + + +## Global Attributes + + +These attributes are available to all modules and interfaces in a design. + + +Assign the LCSC ID of the module. + +If set, this will tell the picker to select that part from LCSC for this block. + + + + +This module's manufacturer name, as a string. + +Only exact matches on the manufacturer's name will be found by the picker. +It's recommended to fill this information based on what `ato create component` +provides. + + + + +This module's manufacturer part number, as a string. + +For the picker to select the correct part from the manufacturer, +this must be set. + + + + +The package of the module. + +This drives which components can be selected, and what footprint is used. + +Must exactly match a known package name. + + + + + + + +When set on an interface, this will override the net name of the interface. + +This is useful for renaming nets which are automatically generated. + + + + +Only for ModuleInterfaces. +If set to `True`, require that interface is connected to something outside +of the module it's defined in. + + + +```ato Basic Usage +import Fuse, ElectricPower + +fuse = new Fuse +fuse.trip_current = 2A +/- 10% +fuse.fuse_type = Fuse.FuseType.NON_RESETTABLE +fuse.response_type = Fuse.ResponseType.FAST +fuse.package = "1206" + +# Connect fuse in series with power supply +power_input = new ElectricPower +protected_power = new ElectricPower + +# Fuse protects the circuit from overcurrent +power_input.hv ~> fuse ~> protected_power.hv +power_input.lv ~ protected_power.lv + +# For resettable fuse (PTC) +ptc_fuse = new Fuse +ptc_fuse.trip_current = 500mA +/- 20% +ptc_fuse.fuse_type = Fuse.FuseType.RESETTABLE +ptc_fuse.response_type = Fuse.ResponseType.SLOW + +# Common applications: USB power protection, battery protection +``` + \ No newline at end of file diff --git a/atopile-0.14.x/api-reference/components/gdt.mdx b/atopile-0.14.x/api-reference/components/gdt.mdx new file mode 100644 index 0000000..0f92f2d --- /dev/null +++ b/atopile-0.14.x/api-reference/components/gdt.mdx @@ -0,0 +1,83 @@ +--- + +title: "GDT" +icon: microchip +description: "" +--- + + +## Parameters + + + + + + + + +## Interfaces + + + + + + + + + + + +## Global Attributes + + +These attributes are available to all modules and interfaces in a design. + + +Assign the LCSC ID of the module. + +If set, this will tell the picker to select that part from LCSC for this block. + + + + +This module's manufacturer name, as a string. + +Only exact matches on the manufacturer's name will be found by the picker. +It's recommended to fill this information based on what `ato create component` +provides. + + + + +This module's manufacturer part number, as a string. + +For the picker to select the correct part from the manufacturer, +this must be set. + + + + +The package of the module. + +This drives which components can be selected, and what footprint is used. + +Must exactly match a known package name. + + + + + + + +When set on an interface, this will override the net name of the interface. + +This is useful for renaming nets which are automatically generated. + + + + +Only for ModuleInterfaces. +If set to `True`, require that interface is connected to something outside +of the module it's defined in. + + diff --git a/atopile-0.14.x/api-reference/components/inductor.mdx b/atopile-0.14.x/api-reference/components/inductor.mdx new file mode 100644 index 0000000..29f19c1 --- /dev/null +++ b/atopile-0.14.x/api-reference/components/inductor.mdx @@ -0,0 +1,109 @@ +--- + +title: "Inductor" +icon: microchip +description: "" +--- + + +## Parameters + + + + + + + + + + + + + + + + + +## Interfaces + + + + + + + + +## Global Attributes + + +These attributes are available to all modules and interfaces in a design. + + +Assign the LCSC ID of the module. + +If set, this will tell the picker to select that part from LCSC for this block. + + + + +This module's manufacturer name, as a string. + +Only exact matches on the manufacturer's name will be found by the picker. +It's recommended to fill this information based on what `ato create component` +provides. + + + + +This module's manufacturer part number, as a string. + +For the picker to select the correct part from the manufacturer, +this must be set. + + + + +The package of the module. + +This drives which components can be selected, and what footprint is used. + +Must exactly match a known package name. + + + + + + + +When set on an interface, this will override the net name of the interface. + +This is useful for renaming nets which are automatically generated. + + + + +Only for ModuleInterfaces. +If set to `True`, require that interface is connected to something outside +of the module it's defined in. + + + +```ato Basic Usage +import Inductor + +inductor = new Inductor +inductor.inductance = 10uH +/- 10% +inductor.max_current = 2A +inductor.dc_resistance = 50mohm +/- 20% +inductor.self_resonant_frequency = 100MHz +/- 10% +inductor.package = "0805" + +electrical1 ~ inductor.unnamed[0] +electrical2 ~ inductor.unnamed[1] +# OR +electrical1 ~> inductor ~> electrical2 + +# For filtering applications +power_input ~> inductor ~> filtered_output +``` + \ No newline at end of file diff --git a/atopile-0.14.x/api-reference/components/kicadfootprint.mdx b/atopile-0.14.x/api-reference/components/kicadfootprint.mdx new file mode 100644 index 0000000..23798f8 --- /dev/null +++ b/atopile-0.14.x/api-reference/components/kicadfootprint.mdx @@ -0,0 +1,75 @@ +--- + +title: "KicadFootprint" +icon: microchip +description: "" +--- + + +## Init Args + + + + + + +## Interfaces + + + + + +## Global Attributes + + +These attributes are available to all modules and interfaces in a design. + + +Assign the LCSC ID of the module. + +If set, this will tell the picker to select that part from LCSC for this block. + + + + +This module's manufacturer name, as a string. + +Only exact matches on the manufacturer's name will be found by the picker. +It's recommended to fill this information based on what `ato create component` +provides. + + + + +This module's manufacturer part number, as a string. + +For the picker to select the correct part from the manufacturer, +this must be set. + + + + +The package of the module. + +This drives which components can be selected, and what footprint is used. + +Must exactly match a known package name. + + + + + + + +When set on an interface, this will override the net name of the interface. + +This is useful for renaming nets which are automatically generated. + + + + +Only for ModuleInterfaces. +If set to `True`, require that interface is connected to something outside +of the module it's defined in. + + diff --git a/atopile-0.14.x/api-reference/components/ldo.mdx b/atopile-0.14.x/api-reference/components/ldo.mdx new file mode 100644 index 0000000..e482148 --- /dev/null +++ b/atopile-0.14.x/api-reference/components/ldo.mdx @@ -0,0 +1,134 @@ +--- + +title: "LDO" +icon: microchip +description: "" +--- + + +## Parameters + + + + + + + + + + + + + + + + + + + + + + + + + + +## Interfaces + + + + + + + + + + + +## Global Attributes + + +These attributes are available to all modules and interfaces in a design. + + +Assign the LCSC ID of the module. + +If set, this will tell the picker to select that part from LCSC for this block. + + + + +This module's manufacturer name, as a string. + +Only exact matches on the manufacturer's name will be found by the picker. +It's recommended to fill this information based on what `ato create component` +provides. + + + + +This module's manufacturer part number, as a string. + +For the picker to select the correct part from the manufacturer, +this must be set. + + + + +The package of the module. + +This drives which components can be selected, and what footprint is used. + +Must exactly match a known package name. + + + + + + + +When set on an interface, this will override the net name of the interface. + +This is useful for renaming nets which are automatically generated. + + + + +Only for ModuleInterfaces. +If set to `True`, require that interface is connected to something outside +of the module it's defined in. + + + +```ato Basic Usage +import LDO, ElectricPower, Capacitor + +ldo = new LDO +ldo.output_voltage = 3.3V +/- 2% +ldo.max_input_voltage = 6V +ldo.max_current = 1A +ldo.dropout_voltage = 300mV +/- 50% +ldo.output_type = LDO.OutputType.FIXED +ldo.package = "SOT-223" + +# Connect input power (typically 5V) +power_5v = new ElectricPower +assert power_5v.voltage within 5V +/- 5% +ldo.power_in ~ power_5v + +# Connect output power (regulated 3.3V) +power_3v3 = new ElectricPower +ldo.power_out ~ power_3v3 + +# Enable the LDO +ldo.enable_output() + +# Add input and output capacitors +input_cap = new Capacitor +output_cap = new Capacitor +input_cap.capacitance = 1uF +/- 20% +output_cap.capacitance = 10uF +/- 20% +ldo.power_in.hv ~> input_cap ~> ldo.power_in.lv +ldo.power_out.hv ~> output_cap ~> ldo.power_out.lv +``` + \ No newline at end of file diff --git a/atopile-0.14.x/api-reference/components/led.mdx b/atopile-0.14.x/api-reference/components/led.mdx new file mode 100644 index 0000000..d008af7 --- /dev/null +++ b/atopile-0.14.x/api-reference/components/led.mdx @@ -0,0 +1,126 @@ +--- + +title: "LED" +icon: microchip +description: "" +--- + + +## Parameters + + + + + + + + + + + + + + + + + + + + + + + + + + +## Interfaces + + + + + + + + +## Global Attributes + + +These attributes are available to all modules and interfaces in a design. + + +Assign the LCSC ID of the module. + +If set, this will tell the picker to select that part from LCSC for this block. + + + + +This module's manufacturer name, as a string. + +Only exact matches on the manufacturer's name will be found by the picker. +It's recommended to fill this information based on what `ato create component` +provides. + + + + +This module's manufacturer part number, as a string. + +For the picker to select the correct part from the manufacturer, +this must be set. + + + + +The package of the module. + +This drives which components can be selected, and what footprint is used. + +Must exactly match a known package name. + + + + + + + +When set on an interface, this will override the net name of the interface. + +This is useful for renaming nets which are automatically generated. + + + + +Only for ModuleInterfaces. +If set to `True`, require that interface is connected to something outside +of the module it's defined in. + + + +```ato Basic Usage +import LED, Resistor, ElectricPower + +led = new LED +led.forward_voltage = 2.1V +/- 10% +led.current = 20mA +/- 5% +led.max_current = 30mA +led.color = LED.Color.RED +led.brightness = 100mcd +led.package = "0603" + +# Connect with current limiting resistor +current_resistor = new Resistor +power_supply = new ElectricPower +assert power_supply.voltage within 5V +/- 5% + +power_supply.hv ~> current_resistor ~> led ~> power_supply.lv + +# Alternative: use dedicated function +led.connect_via_current_limiting_resistor( + power_supply.voltage, + current_resistor, + power_supply.lv, + low_side=True +) +``` + \ No newline at end of file diff --git a/atopile-0.14.x/api-reference/components/ledindicator.mdx b/atopile-0.14.x/api-reference/components/ledindicator.mdx new file mode 100644 index 0000000..14a8dae --- /dev/null +++ b/atopile-0.14.x/api-reference/components/ledindicator.mdx @@ -0,0 +1,122 @@ +--- + +title: "LEDIndicator" +icon: microchip +description: "" +--- + + +## Init Args + + + + + + + + + + +## Interfaces + + + + + + + + +## Global Attributes + + +These attributes are available to all modules and interfaces in a design. + + +Assign the LCSC ID of the module. + +If set, this will tell the picker to select that part from LCSC for this block. + + + + +This module's manufacturer name, as a string. + +Only exact matches on the manufacturer's name will be found by the picker. +It's recommended to fill this information based on what `ato create component` +provides. + + + + +This module's manufacturer part number, as a string. + +For the picker to select the correct part from the manufacturer, +this must be set. + + + + +The package of the module. + +This drives which components can be selected, and what footprint is used. + +Must exactly match a known package name. + + + + + + + +When set on an interface, this will override the net name of the interface. + +This is useful for renaming nets which are automatically generated. + + + + +Only for ModuleInterfaces. +If set to `True`, require that interface is connected to something outside +of the module it's defined in. + + + +```ato Basic Usage +import LEDIndicator, ElectricPower, ElectricLogic + +# Basic LED indicator (active high) +status_led = new LEDIndicator(use_mosfet=False, active_low=False) + +# Connect power supply +power_5v = new ElectricPower +assert power_5v.voltage within 5V +/- 5% +status_led.power_in ~ power_5v + +# Connect control signal +status_signal = new ElectricLogic +status_signal.reference ~ power_5v +status_led.logic_in ~ status_signal + +# Connect to microcontroller +microcontroller.gpio_status ~ status_signal.line + +# Configure LED properties +status_led.led.led.color = LED.Color.GREEN +status_led.led.led.current = 20mA +/- 5% +status_led.led.led.forward_voltage = 2.1V +/- 10% + +# High-power LED with MOSFET driver +power_led = new LEDIndicator(use_mosfet=True, active_low=False) +power_led.power_in ~ power_5v +power_led.logic_in ~ power_control_signal +power_led.led.led.current = 100mA +/- 10% # Higher current + +# Active-low indicator (ON when signal is LOW) +error_led = new LEDIndicator(use_mosfet=False, active_low=True) +error_led.power_in ~ power_5v +error_led.logic_in ~ error_signal +error_led.led.led.color = LED.Color.RED + +# Common applications: status indication, debugging, user feedback +``` + \ No newline at end of file diff --git a/atopile-0.14.x/api-reference/components/logicgate.mdx b/atopile-0.14.x/api-reference/components/logicgate.mdx new file mode 100644 index 0000000..a1b4672 --- /dev/null +++ b/atopile-0.14.x/api-reference/components/logicgate.mdx @@ -0,0 +1,82 @@ +--- + +title: "LogicGate" +icon: microchip +description: "" +--- + + +## Init Args + + + + + + + + + + +## Interfaces + + + + + + + + +## Global Attributes + + +These attributes are available to all modules and interfaces in a design. + + +Assign the LCSC ID of the module. + +If set, this will tell the picker to select that part from LCSC for this block. + + + + +This module's manufacturer name, as a string. + +Only exact matches on the manufacturer's name will be found by the picker. +It's recommended to fill this information based on what `ato create component` +provides. + + + + +This module's manufacturer part number, as a string. + +For the picker to select the correct part from the manufacturer, +this must be set. + + + + +The package of the module. + +This drives which components can be selected, and what footprint is used. + +Must exactly match a known package name. + + + + + + + +When set on an interface, this will override the net name of the interface. + +This is useful for renaming nets which are automatically generated. + + + + +Only for ModuleInterfaces. +If set to `True`, require that interface is connected to something outside +of the module it's defined in. + + diff --git a/atopile-0.14.x/api-reference/components/mosfet.mdx b/atopile-0.14.x/api-reference/components/mosfet.mdx new file mode 100644 index 0000000..b83a0b2 --- /dev/null +++ b/atopile-0.14.x/api-reference/components/mosfet.mdx @@ -0,0 +1,118 @@ +--- + +title: "MOSFET" +icon: microchip +description: "" +--- + + +## Parameters + + + + + + + + + + + + + + + + + + + + +## Interfaces + + + + + + + + + + + +## Global Attributes + + +These attributes are available to all modules and interfaces in a design. + + +Assign the LCSC ID of the module. + +If set, this will tell the picker to select that part from LCSC for this block. + + + + +This module's manufacturer name, as a string. + +Only exact matches on the manufacturer's name will be found by the picker. +It's recommended to fill this information based on what `ato create component` +provides. + + + + +This module's manufacturer part number, as a string. + +For the picker to select the correct part from the manufacturer, +this must be set. + + + + +The package of the module. + +This drives which components can be selected, and what footprint is used. + +Must exactly match a known package name. + + + + + + + +When set on an interface, this will override the net name of the interface. + +This is useful for renaming nets which are automatically generated. + + + + +Only for ModuleInterfaces. +If set to `True`, require that interface is connected to something outside +of the module it's defined in. + + + +```ato Basic Usage +import MOSFET, ElectricLogic, ElectricPower + +mosfet = new MOSFET +mosfet.channel_type = MOSFET.ChannelType.N_CHANNEL +mosfet.saturation_type = MOSFET.SaturationType.ENHANCEMENT +mosfet.gate_source_threshold_voltage = 2.5V +/- 10% +mosfet.max_drain_source_voltage = 60V +mosfet.max_continuous_drain_current = 30A +mosfet.on_resistance = 5mohm +/- 20% +mosfet.package = "SOT-23" + +# Use as a switch +gate_control = new ElectricLogic +power_supply = new ElectricPower +load = new ElectricLogic + +mosfet.gate ~ gate_control.line +mosfet.source ~ power_supply.lv +mosfet.drain ~ load.line +``` + \ No newline at end of file diff --git a/atopile-0.14.x/api-reference/components/multicapacitor.mdx b/atopile-0.14.x/api-reference/components/multicapacitor.mdx new file mode 100644 index 0000000..8a59297 --- /dev/null +++ b/atopile-0.14.x/api-reference/components/multicapacitor.mdx @@ -0,0 +1,105 @@ +--- + +title: "MultiCapacitor" +icon: microchip +description: " +MultiCapacitor acts a single cap but contains multiple in parallel. +" +--- + + +## Init Args + + + + + + +## Parameters + + + + + + + + + + + +## Interfaces + + + + + + + + +## Global Attributes + + +These attributes are available to all modules and interfaces in a design. + + +Assign the LCSC ID of the module. + +If set, this will tell the picker to select that part from LCSC for this block. + + + + +This module's manufacturer name, as a string. + +Only exact matches on the manufacturer's name will be found by the picker. +It's recommended to fill this information based on what `ato create component` +provides. + + + + +This module's manufacturer part number, as a string. + +For the picker to select the correct part from the manufacturer, +this must be set. + + + + +The package of the module. + +This drives which components can be selected, and what footprint is used. + +Must exactly match a known package name. + + + + + + + +When set on an interface, this will override the net name of the interface. + +This is useful for renaming nets which are automatically generated. + + + + +Only for ModuleInterfaces. +If set to `True`, require that interface is connected to something outside +of the module it's defined in. + + + +```ato Basic Usage +import MultiCapacitor + +multicapacitor = new MultiCapacitor +for c in multicapacitor.capacitors: + c.capacitance = 100nF +/- 10% + c.package = "0402" + +electrical1 ~ multicapacitor.unnamed[0] +electrical2 ~ multicapacitor.unnamed[1] +``` + \ No newline at end of file diff --git a/atopile-0.14.x/api-reference/components/net.mdx b/atopile-0.14.x/api-reference/components/net.mdx new file mode 100644 index 0000000..3144ea9 --- /dev/null +++ b/atopile-0.14.x/api-reference/components/net.mdx @@ -0,0 +1,68 @@ +--- + +title: "Net" +icon: microchip +description: "" +--- + + +## Interfaces + + + + + +## Global Attributes + + +These attributes are available to all modules and interfaces in a design. + + +Assign the LCSC ID of the module. + +If set, this will tell the picker to select that part from LCSC for this block. + + + + +This module's manufacturer name, as a string. + +Only exact matches on the manufacturer's name will be found by the picker. +It's recommended to fill this information based on what `ato create component` +provides. + + + + +This module's manufacturer part number, as a string. + +For the picker to select the correct part from the manufacturer, +this must be set. + + + + +The package of the module. + +This drives which components can be selected, and what footprint is used. + +Must exactly match a known package name. + + + + + + + +When set on an interface, this will override the net name of the interface. + +This is useful for renaming nets which are automatically generated. + + + + +Only for ModuleInterfaces. +If set to `True`, require that interface is connected to something outside +of the module it's defined in. + + diff --git a/atopile-0.14.x/api-reference/components/nfet.mdx b/atopile-0.14.x/api-reference/components/nfet.mdx new file mode 100644 index 0000000..44953de --- /dev/null +++ b/atopile-0.14.x/api-reference/components/nfet.mdx @@ -0,0 +1,118 @@ +--- + +title: "NFET" +icon: microchip +description: "" +--- + + +## Parameters + + + + + + + + + + + + + + + + + + + + +## Interfaces + + + + + + + + + + + +## Global Attributes + + +These attributes are available to all modules and interfaces in a design. + + +Assign the LCSC ID of the module. + +If set, this will tell the picker to select that part from LCSC for this block. + + + + +This module's manufacturer name, as a string. + +Only exact matches on the manufacturer's name will be found by the picker. +It's recommended to fill this information based on what `ato create component` +provides. + + + + +This module's manufacturer part number, as a string. + +For the picker to select the correct part from the manufacturer, +this must be set. + + + + +The package of the module. + +This drives which components can be selected, and what footprint is used. + +Must exactly match a known package name. + + + + + + + +When set on an interface, this will override the net name of the interface. + +This is useful for renaming nets which are automatically generated. + + + + +Only for ModuleInterfaces. +If set to `True`, require that interface is connected to something outside +of the module it's defined in. + + + +```ato Basic Usage +import NFET, ElectricLogic, ElectricPower + +nfet = new NFET +nfet.gate_source_threshold_voltage = 2.5V +/- 10% +nfet.max_drain_source_voltage = 60V +nfet.max_continuous_drain_current = 30A +nfet.on_resistance = 5mohm +/- 20% +nfet.package = "SOT-23" + +# Use as low-side switch +gate_control = new ElectricLogic +power_supply = new ElectricPower +load = new ElectricLogic + +nfet.gate ~ gate_control.line +nfet.source ~ power_supply.lv # Connect to ground for low-side +nfet.drain ~ load.line + +# When gate_control is HIGH, NFET conducts (load connected to ground) +``` + \ No newline at end of file diff --git a/atopile-0.14.x/api-reference/components/opamp.mdx b/atopile-0.14.x/api-reference/components/opamp.mdx new file mode 100644 index 0000000..b71b235 --- /dev/null +++ b/atopile-0.14.x/api-reference/components/opamp.mdx @@ -0,0 +1,133 @@ +--- + +title: "OpAmp" +icon: microchip +description: "" +--- + + +## Parameters + + + + + + + + + + + + + + + + + + + + + + + +## Interfaces + + + + + + + + + + + + + + +## Global Attributes + + +These attributes are available to all modules and interfaces in a design. + + +Assign the LCSC ID of the module. + +If set, this will tell the picker to select that part from LCSC for this block. + + + + +This module's manufacturer name, as a string. + +Only exact matches on the manufacturer's name will be found by the picker. +It's recommended to fill this information based on what `ato create component` +provides. + + + + +This module's manufacturer part number, as a string. + +For the picker to select the correct part from the manufacturer, +this must be set. + + + + +The package of the module. + +This drives which components can be selected, and what footprint is used. + +Must exactly match a known package name. + + + + + + + +When set on an interface, this will override the net name of the interface. + +This is useful for renaming nets which are automatically generated. + + + + +Only for ModuleInterfaces. +If set to `True`, require that interface is connected to something outside +of the module it's defined in. + + + +```ato Basic Usage +import OpAmp, Resistor, ElectricPower, Electrical + +opamp = new OpAmp +opamp.bandwidth = 1MHz +/- 10% +opamp.gain_bandwidth_product = 10MHz +/- 20% +opamp.input_offset_voltage = 1mV +/- 50% +opamp.slew_rate = 1V/us +/- 20% +opamp.package = "SOIC-8" + +# Power supply connections (dual supply) +power_pos = new ElectricPower +power_neg = new ElectricPower +assert power_pos.voltage within 5V +/- 5% +assert power_neg.voltage within -5V +/- 5% +opamp.power.hv ~ power_pos.hv +opamp.power.lv ~ power_neg.lv + +# Non-inverting amplifier configuration +feedback_resistor = new Resistor +gain_resistor = new Resistor +feedback_resistor.resistance = 10kohm +/- 1% +gain_resistor.resistance = 1kohm +/- 1% + +# Connections for gain = 1 + (Rf/Rg) = 11 +input_signal ~ opamp.non_inverting_input +opamp.inverting_input ~> gain_resistor ~> power_neg.lv +opamp.output ~> feedback_resistor ~> opamp.inverting_input +output_signal ~ opamp.output +``` + \ No newline at end of file diff --git a/atopile-0.14.x/api-reference/components/pfet.mdx b/atopile-0.14.x/api-reference/components/pfet.mdx new file mode 100644 index 0000000..bda8177 --- /dev/null +++ b/atopile-0.14.x/api-reference/components/pfet.mdx @@ -0,0 +1,119 @@ +--- + +title: "PFET" +icon: microchip +description: "" +--- + + +## Parameters + + + + + + + + + + + + + + + + + + + + +## Interfaces + + + + + + + + + + + +## Global Attributes + + +These attributes are available to all modules and interfaces in a design. + + +Assign the LCSC ID of the module. + +If set, this will tell the picker to select that part from LCSC for this block. + + + + +This module's manufacturer name, as a string. + +Only exact matches on the manufacturer's name will be found by the picker. +It's recommended to fill this information based on what `ato create component` +provides. + + + + +This module's manufacturer part number, as a string. + +For the picker to select the correct part from the manufacturer, +this must be set. + + + + +The package of the module. + +This drives which components can be selected, and what footprint is used. + +Must exactly match a known package name. + + + + + + + +When set on an interface, this will override the net name of the interface. + +This is useful for renaming nets which are automatically generated. + + + + +Only for ModuleInterfaces. +If set to `True`, require that interface is connected to something outside +of the module it's defined in. + + + +```ato Basic Usage +import PFET, ElectricLogic, ElectricPower + +pfet = new PFET +pfet.gate_source_threshold_voltage = -2.5V +/- 10% +pfet.max_drain_source_voltage = 30V +pfet.max_continuous_drain_current = 20A +pfet.on_resistance = 10mohm +/- 20% +pfet.package = "SOT-23" + +# Use as high-side switch +gate_control = new ElectricLogic +power_supply = new ElectricPower +load = new ElectricLogic + +pfet.gate ~ gate_control.line +pfet.source ~ power_supply.hv # Connect to positive supply for high-side +pfet.drain ~ load.line + +# When gate_control is LOW, PFET conducts (load connected to Vcc) +# Note: For P-channel, gate needs to be pulled low to turn on +``` + \ No newline at end of file diff --git a/atopile-0.14.x/api-reference/components/potentiometer.mdx b/atopile-0.14.x/api-reference/components/potentiometer.mdx new file mode 100644 index 0000000..e6f41e0 --- /dev/null +++ b/atopile-0.14.x/api-reference/components/potentiometer.mdx @@ -0,0 +1,96 @@ +--- + +title: "Potentiometer" +icon: microchip +description: "" +--- + + +## Parameters + + + + + +## Interfaces + + + + + + + + + + + +## Global Attributes + + +These attributes are available to all modules and interfaces in a design. + + +Assign the LCSC ID of the module. + +If set, this will tell the picker to select that part from LCSC for this block. + + + + +This module's manufacturer name, as a string. + +Only exact matches on the manufacturer's name will be found by the picker. +It's recommended to fill this information based on what `ato create component` +provides. + + + + +This module's manufacturer part number, as a string. + +For the picker to select the correct part from the manufacturer, +this must be set. + + + + +The package of the module. + +This drives which components can be selected, and what footprint is used. + +Must exactly match a known package name. + + + + + + + +When set on an interface, this will override the net name of the interface. + +This is useful for renaming nets which are automatically generated. + + + + +Only for ModuleInterfaces. +If set to `True`, require that interface is connected to something outside +of the module it's defined in. + + + +```ato Basic Usage +import Potentiometer, ElectricPower, Electrical + +potentiometer = new Potentiometer +potentiometer.total_resistance = 10kohm +/- 5% + +power_supply = new ElectricPower +output_voltage = new Electrical + +# Use as voltage divider +power_supply.hv ~ potentiometer.resistors_ifs[0] +power_supply.lv ~ potentiometer.resistors_ifs[1] +output_voltage ~ potentiometer.wiper +``` + \ No newline at end of file diff --git a/atopile-0.14.x/api-reference/components/poweredled.mdx b/atopile-0.14.x/api-reference/components/poweredled.mdx new file mode 100644 index 0000000..e36aadd --- /dev/null +++ b/atopile-0.14.x/api-reference/components/poweredled.mdx @@ -0,0 +1,75 @@ +--- + +title: "PoweredLED" +icon: microchip +description: "" +--- + + +## Init Args + + + + + + +## Interfaces + + + + + +## Global Attributes + + +These attributes are available to all modules and interfaces in a design. + + +Assign the LCSC ID of the module. + +If set, this will tell the picker to select that part from LCSC for this block. + + + + +This module's manufacturer name, as a string. + +Only exact matches on the manufacturer's name will be found by the picker. +It's recommended to fill this information based on what `ato create component` +provides. + + + + +This module's manufacturer part number, as a string. + +For the picker to select the correct part from the manufacturer, +this must be set. + + + + +The package of the module. + +This drives which components can be selected, and what footprint is used. + +Must exactly match a known package name. + + + + + + + +When set on an interface, this will override the net name of the interface. + +This is useful for renaming nets which are automatically generated. + + + + +Only for ModuleInterfaces. +If set to `True`, require that interface is connected to something outside +of the module it's defined in. + + diff --git a/atopile-0.14.x/api-reference/components/powermux.mdx b/atopile-0.14.x/api-reference/components/powermux.mdx new file mode 100644 index 0000000..4d38e67 --- /dev/null +++ b/atopile-0.14.x/api-reference/components/powermux.mdx @@ -0,0 +1,77 @@ +--- + +title: "PowerMux" +icon: microchip +description: "" +--- + + +## Interfaces + + + + + + + + + + + + + + +## Global Attributes + + +These attributes are available to all modules and interfaces in a design. + + +Assign the LCSC ID of the module. + +If set, this will tell the picker to select that part from LCSC for this block. + + + + +This module's manufacturer name, as a string. + +Only exact matches on the manufacturer's name will be found by the picker. +It's recommended to fill this information based on what `ato create component` +provides. + + + + +This module's manufacturer part number, as a string. + +For the picker to select the correct part from the manufacturer, +this must be set. + + + + +The package of the module. + +This drives which components can be selected, and what footprint is used. + +Must exactly match a known package name. + + + + + + + +When set on an interface, this will override the net name of the interface. + +This is useful for renaming nets which are automatically generated. + + + + +Only for ModuleInterfaces. +If set to `True`, require that interface is connected to something outside +of the module it's defined in. + + diff --git a/atopile-0.14.x/api-reference/components/powerswitch.mdx b/atopile-0.14.x/api-reference/components/powerswitch.mdx new file mode 100644 index 0000000..5cd4e9b --- /dev/null +++ b/atopile-0.14.x/api-reference/components/powerswitch.mdx @@ -0,0 +1,116 @@ +--- + +title: "PowerSwitch" +icon: microchip +description: " +A generic module that switches power based on a logic signal, needs specialization + +The logic signal is active high. When left floating, the state is determined by the +normally_closed parameter. +" +--- + + +## Init Args + + + + + + +## Interfaces + + + + + + + + + + + +## Global Attributes + + +These attributes are available to all modules and interfaces in a design. + + +Assign the LCSC ID of the module. + +If set, this will tell the picker to select that part from LCSC for this block. + + + + +This module's manufacturer name, as a string. + +Only exact matches on the manufacturer's name will be found by the picker. +It's recommended to fill this information based on what `ato create component` +provides. + + + + +This module's manufacturer part number, as a string. + +For the picker to select the correct part from the manufacturer, +this must be set. + + + + +The package of the module. + +This drives which components can be selected, and what footprint is used. + +Must exactly match a known package name. + + + + + + + +When set on an interface, this will override the net name of the interface. + +This is useful for renaming nets which are automatically generated. + + + + +Only for ModuleInterfaces. +If set to `True`, require that interface is connected to something outside +of the module it's defined in. + + + +```ato Basic Usage +import PowerSwitch, ElectricPower, ElectricLogic + +# Create normally-open power switch +power_switch = new PowerSwitch(normally_closed=False) + +# Connect input power +input_power = new ElectricPower +assert input_power.voltage within 5V +/- 5% +power_switch.power_in ~ input_power + +# Connect control signal +enable_signal = new ElectricLogic +enable_signal.reference ~ input_power +power_switch.logic_in ~ enable_signal + +# Connect switched output to load +switched_output = new ElectricPower +power_switch.switched_power_out ~ switched_output +load_circuit ~ switched_output + +# When enable_signal is HIGH, power flows to load +# When enable_signal is LOW (or floating), power is disconnected + +# For normally-closed switch (fails safe) +fail_safe_switch = new PowerSwitch(normally_closed=True) +# This switch passes power when control is LOW or floating +``` + \ No newline at end of file diff --git a/atopile-0.14.x/api-reference/components/powerswitchmosfet.mdx b/atopile-0.14.x/api-reference/components/powerswitchmosfet.mdx new file mode 100644 index 0000000..1d57c12 --- /dev/null +++ b/atopile-0.14.x/api-reference/components/powerswitchmosfet.mdx @@ -0,0 +1,102 @@ +--- + +title: "PowerSwitchMOSFET" +icon: microchip +description: " +Power switch using a MOSFET + +This power switch uses an NMOS when lowside, and a PMOS when highside. +" +--- + + +## Init Args + + + + + + + + + + +## Interfaces + + + + + + + + + + + +## Global Attributes + + +These attributes are available to all modules and interfaces in a design. + + +Assign the LCSC ID of the module. + +If set, this will tell the picker to select that part from LCSC for this block. + + + + +This module's manufacturer name, as a string. + +Only exact matches on the manufacturer's name will be found by the picker. +It's recommended to fill this information based on what `ato create component` +provides. + + + + +This module's manufacturer part number, as a string. + +For the picker to select the correct part from the manufacturer, +this must be set. + + + + +The package of the module. + +This drives which components can be selected, and what footprint is used. + +Must exactly match a known package name. + + + + + + + +When set on an interface, this will override the net name of the interface. + +This is useful for renaming nets which are automatically generated. + + + + +Only for ModuleInterfaces. +If set to `True`, require that interface is connected to something outside +of the module it's defined in. + + + +```ato Basic Usage +import PowerSwitchMOSFET, ElectricPower + +# High-side power switch controlled by logic +pwr_sw = new PowerSwitchMOSFET +supply = new ElectricPower +load_pwr = new ElectricPower + +supply ~ pwr_sw.power_in +pwr_sw.switched_power_out ~ load_pwr +``` + \ No newline at end of file diff --git a/atopile-0.14.x/api-reference/components/powerswitchstatic.mdx b/atopile-0.14.x/api-reference/components/powerswitchstatic.mdx new file mode 100644 index 0000000..56096bc --- /dev/null +++ b/atopile-0.14.x/api-reference/components/powerswitchstatic.mdx @@ -0,0 +1,115 @@ +--- + +title: "PowerSwitchStatic" +icon: microchip +description: " +A power switch that bridges power through statically + +This is useful when transforming an F.ElectricLogic to an F.ElectricPower +" +--- + + +## Init Args + + + + + + +## Interfaces + + + + + + + + + + + +## Global Attributes + + +These attributes are available to all modules and interfaces in a design. + + +Assign the LCSC ID of the module. + +If set, this will tell the picker to select that part from LCSC for this block. + + + + +This module's manufacturer name, as a string. + +Only exact matches on the manufacturer's name will be found by the picker. +It's recommended to fill this information based on what `ato create component` +provides. + + + + +This module's manufacturer part number, as a string. + +For the picker to select the correct part from the manufacturer, +this must be set. + + + + +The package of the module. + +This drives which components can be selected, and what footprint is used. + +Must exactly match a known package name. + + + + + + + +When set on an interface, this will override the net name of the interface. + +This is useful for renaming nets which are automatically generated. + + + + +Only for ModuleInterfaces. +If set to `True`, require that interface is connected to something outside +of the module it's defined in. + + + +```ato Basic Usage +import PowerSwitch, ElectricPower, ElectricLogic + +# Create normally-open power switch +power_switch = new PowerSwitch(normally_closed=False) + +# Connect input power +input_power = new ElectricPower +assert input_power.voltage within 5V +/- 5% +power_switch.power_in ~ input_power + +# Connect control signal +enable_signal = new ElectricLogic +enable_signal.reference ~ input_power +power_switch.logic_in ~ enable_signal + +# Connect switched output to load +switched_output = new ElectricPower +power_switch.switched_power_out ~ switched_output +load_circuit ~ switched_output + +# When enable_signal is HIGH, power flows to load +# When enable_signal is LOW (or floating), power is disconnected + +# For normally-closed switch (fails safe) +fail_safe_switch = new PowerSwitch(normally_closed=True) +# This switch passes power when control is LOW or floating +``` + \ No newline at end of file diff --git a/atopile-0.14.x/api-reference/components/regulator.mdx b/atopile-0.14.x/api-reference/components/regulator.mdx new file mode 100644 index 0000000..8462fef --- /dev/null +++ b/atopile-0.14.x/api-reference/components/regulator.mdx @@ -0,0 +1,101 @@ +--- + +title: "Regulator" +icon: microchip +description: "" +--- + + +## Interfaces + + + + + + + + +## Global Attributes + + +These attributes are available to all modules and interfaces in a design. + + +Assign the LCSC ID of the module. + +If set, this will tell the picker to select that part from LCSC for this block. + + + + +This module's manufacturer name, as a string. + +Only exact matches on the manufacturer's name will be found by the picker. +It's recommended to fill this information based on what `ato create component` +provides. + + + + +This module's manufacturer part number, as a string. + +For the picker to select the correct part from the manufacturer, +this must be set. + + + + +The package of the module. + +This drives which components can be selected, and what footprint is used. + +Must exactly match a known package name. + + + + + + + +When set on an interface, this will override the net name of the interface. + +This is useful for renaming nets which are automatically generated. + + + + +Only for ModuleInterfaces. +If set to `True`, require that interface is connected to something outside +of the module it's defined in. + + + +```ato Basic Usage +import Regulator, ElectricPower + +regulator = new Regulator + +# Connect input power (unregulated) +power_input = new ElectricPower +assert power_input.voltage within 7V to 20V # Wide input range +regulator.power_in ~ power_input + +# Connect output power (regulated) +power_output = new ElectricPower +regulator.power_out ~ power_output + +# Output voltage depends on regulator type: +# - LDO: Vout = Vin - Dropout_voltage +# - Switching: Vout = Function(Vin, feedback network) + +# Connect to load +load_circuit ~ power_output + +# Note: This is a generic regulator interface +# Use specific regulator types for actual implementations: +# - LDO for low noise, low efficiency +# - Buck for high efficiency step-down +# - Boost for step-up conversion +# - Buck-boost for bidirectional conversion +``` + \ No newline at end of file diff --git a/atopile-0.14.x/api-reference/components/relay.mdx b/atopile-0.14.x/api-reference/components/relay.mdx new file mode 100644 index 0000000..0a73b27 --- /dev/null +++ b/atopile-0.14.x/api-reference/components/relay.mdx @@ -0,0 +1,143 @@ +--- + +title: "Relay" +icon: microchip +description: "" +--- + + +## Parameters + + + + + + + + + + + + + + + + + + + + +## Interfaces + + + + + + + + + + + + + + + + + + + + + + + +## Global Attributes + + +These attributes are available to all modules and interfaces in a design. + + +Assign the LCSC ID of the module. + +If set, this will tell the picker to select that part from LCSC for this block. + + + + +This module's manufacturer name, as a string. + +Only exact matches on the manufacturer's name will be found by the picker. +It's recommended to fill this information based on what `ato create component` +provides. + + + + +This module's manufacturer part number, as a string. + +For the picker to select the correct part from the manufacturer, +this must be set. + + + + +The package of the module. + +This drives which components can be selected, and what footprint is used. + +Must exactly match a known package name. + + + + + + + +When set on an interface, this will override the net name of the interface. + +This is useful for renaming nets which are automatically generated. + + + + +Only for ModuleInterfaces. +If set to `True`, require that interface is connected to something outside +of the module it's defined in. + + + +```ato Basic Usage +import Relay, ElectricPower, Diode, NFET, ElectricLogic + +relay = new Relay +relay.coil_max_voltage = 12V +relay.coil_max_current = 50mA +relay.coil_resistance = 240ohm +/- 10% +relay.contact_max_switching_voltage = 250V +relay.contact_max_switching_current = 10A +relay.contact_max_current = 16A + +# Connect coil power +power_12v = new ElectricPower +assert power_12v.voltage within 12V +/- 5% +relay.coil_power ~ power_12v + +# Control relay with MOSFET and flyback diode +control_mosfet = new NFET +flyback_diode = new Diode +control_signal = new ElectricLogic + +# Coil control circuit +power_12v.hv ~ relay.coil_power.hv +relay.coil_power.lv ~> control_mosfet ~> power_12v.lv +control_signal ~ control_mosfet.gate + +# Flyback diode for coil protection +relay.coil_power.hv ~ flyback_diode.cathode +flyback_diode.anode ~ relay.coil_power.lv + +# Switch high-power load using normally open contact +high_power_load ~ relay.switch_a_no +relay.switch_a_common ~ high_voltage_supply +``` + \ No newline at end of file diff --git a/atopile-0.14.x/api-reference/components/resistor.mdx b/atopile-0.14.x/api-reference/components/resistor.mdx new file mode 100644 index 0000000..4d0b28d --- /dev/null +++ b/atopile-0.14.x/api-reference/components/resistor.mdx @@ -0,0 +1,97 @@ +--- + +title: "Resistor" +icon: microchip +description: "" +--- + + +## Parameters + + + + + + + + + + + +## Interfaces + + + + + + + + +## Global Attributes + + +These attributes are available to all modules and interfaces in a design. + + +Assign the LCSC ID of the module. + +If set, this will tell the picker to select that part from LCSC for this block. + + + + +This module's manufacturer name, as a string. + +Only exact matches on the manufacturer's name will be found by the picker. +It's recommended to fill this information based on what `ato create component` +provides. + + + + +This module's manufacturer part number, as a string. + +For the picker to select the correct part from the manufacturer, +this must be set. + + + + +The package of the module. + +This drives which components can be selected, and what footprint is used. + +Must exactly match a known package name. + + + + + + + +When set on an interface, this will override the net name of the interface. + +This is useful for renaming nets which are automatically generated. + + + + +Only for ModuleInterfaces. +If set to `True`, require that interface is connected to something outside +of the module it's defined in. + + + +```ato Basic Usage +import Resistor + +resistor = new Resistor +resistor.resistance = 10kohm +/- 5% +resistor.package = "0402" + +electrical1 ~ resistor.unnamed[0] +electrical2 ~ resistor.unnamed[1] +# OR +electrical1 ~> resistor ~> electrical2 +``` + \ No newline at end of file diff --git a/atopile-0.14.x/api-reference/components/resistorarray.mdx b/atopile-0.14.x/api-reference/components/resistorarray.mdx new file mode 100644 index 0000000..c9100d5 --- /dev/null +++ b/atopile-0.14.x/api-reference/components/resistorarray.mdx @@ -0,0 +1,112 @@ +--- + +title: "ResistorArray" +icon: microchip +description: "" +--- + + +## Init Args + + + + + + +## Parameters + + + + + + + + + + + +## Global Attributes + + +These attributes are available to all modules and interfaces in a design. + + +Assign the LCSC ID of the module. + +If set, this will tell the picker to select that part from LCSC for this block. + + + + +This module's manufacturer name, as a string. + +Only exact matches on the manufacturer's name will be found by the picker. +It's recommended to fill this information based on what `ato create component` +provides. + + + + +This module's manufacturer part number, as a string. + +For the picker to select the correct part from the manufacturer, +this must be set. + + + + +The package of the module. + +This drives which components can be selected, and what footprint is used. + +Must exactly match a known package name. + + + + + + + +When set on an interface, this will override the net name of the interface. + +This is useful for renaming nets which are automatically generated. + + + + +Only for ModuleInterfaces. +If set to `True`, require that interface is connected to something outside +of the module it's defined in. + + + +```ato Basic Usage +import ResistorArray, ElectricPower, ElectricLogic + +# Create 8-resistor array for pull-ups +pullup_array = new ResistorArray(resistor_count=8) +pullup_array.resistance = 10kohm +/- 5% +pullup_array.rated_power = 125mW +pullup_array.rated_voltage = 50V +pullup_array.package = "4816" # 8-pin SIP package + +# Connect power supply +power_3v3 = new ElectricPower +assert power_3v3.voltage within 3.3V +/- 5% + +# Use for GPIO pull-ups +gpio_signals = new ElectricLogic[8] +for i in range(8): + gpio_signals[i].reference ~ power_3v3 + gpio_signals[i].line ~> pullup_array.resistors[i] ~> power_3v3.hv + microcontroller.gpio[i] ~ gpio_signals[i].line + +# Alternative: 4-resistor array for I2C/SPI bus termination +termination_array = new ResistorArray(resistor_count=4) +termination_array.resistance = 33ohm +/- 1% +termination_array.package = "4806" # 4-pin array + +# Common applications: pull-up/pull-down networks, bus termination, +# voltage dividers, current limiting, LED drivers +``` + \ No newline at end of file diff --git a/atopile-0.14.x/api-reference/components/resistorvoltagedivider.mdx b/atopile-0.14.x/api-reference/components/resistorvoltagedivider.mdx new file mode 100644 index 0000000..4a494b4 --- /dev/null +++ b/atopile-0.14.x/api-reference/components/resistorvoltagedivider.mdx @@ -0,0 +1,96 @@ +--- + +title: "ResistorVoltageDivider" +icon: +description: " +A voltage divider using two resistors. +node[0] ~ resistor[1] ~ node[1] ~ resistor[2] ~ node[2] +power.hv ~ node[0] +power.lv ~ node[2] +output.line ~ node[1] +output.reference.lv ~ node[2] +" +--- + + +## Parameters + + + + + + + + + + + + + + + + + +## Interfaces + + + + + + + + +## Global Attributes + + +These attributes are available to all modules and interfaces in a design. + + +Assign the LCSC ID of the module. + +If set, this will tell the picker to select that part from LCSC for this block. + + + + +This module's manufacturer name, as a string. + +Only exact matches on the manufacturer's name will be found by the picker. +It's recommended to fill this information based on what `ato create component` +provides. + + + + +This module's manufacturer part number, as a string. + +For the picker to select the correct part from the manufacturer, +this must be set. + + + + +The package of the module. + +This drives which components can be selected, and what footprint is used. + +Must exactly match a known package name. + + + + + + + +When set on an interface, this will override the net name of the interface. + +This is useful for renaming nets which are automatically generated. + + + + +Only for ModuleInterfaces. +If set to `True`, require that interface is connected to something outside +of the module it's defined in. + + diff --git a/atopile-0.14.x/api-reference/components/smdtwopin.mdx b/atopile-0.14.x/api-reference/components/smdtwopin.mdx new file mode 100644 index 0000000..41a1413 --- /dev/null +++ b/atopile-0.14.x/api-reference/components/smdtwopin.mdx @@ -0,0 +1,82 @@ +--- + +title: "SMDTwoPin" +icon: microchip +description: "" +--- + + +## Init Args + + + + + + + + + + +## Interfaces + + + + + + + + +## Global Attributes + + +These attributes are available to all modules and interfaces in a design. + + +Assign the LCSC ID of the module. + +If set, this will tell the picker to select that part from LCSC for this block. + + + + +This module's manufacturer name, as a string. + +Only exact matches on the manufacturer's name will be found by the picker. +It's recommended to fill this information based on what `ato create component` +provides. + + + + +This module's manufacturer part number, as a string. + +For the picker to select the correct part from the manufacturer, +this must be set. + + + + +The package of the module. + +This drives which components can be selected, and what footprint is used. + +Must exactly match a known package name. + + + + + + + +When set on an interface, this will override the net name of the interface. + +This is useful for renaming nets which are automatically generated. + + + + +Only for ModuleInterfaces. +If set to `True`, require that interface is connected to something outside +of the module it's defined in. + + diff --git a/atopile-0.14.x/api-reference/components/soic.mdx b/atopile-0.14.x/api-reference/components/soic.mdx new file mode 100644 index 0000000..2a30e2e --- /dev/null +++ b/atopile-0.14.x/api-reference/components/soic.mdx @@ -0,0 +1,83 @@ +--- + +title: "SOIC" +icon: microchip +description: "" +--- + + +## Init Args + + + + + + + + + + + + + + +## Interfaces + + + + + +## Global Attributes + + +These attributes are available to all modules and interfaces in a design. + + +Assign the LCSC ID of the module. + +If set, this will tell the picker to select that part from LCSC for this block. + + + + +This module's manufacturer name, as a string. + +Only exact matches on the manufacturer's name will be found by the picker. +It's recommended to fill this information based on what `ato create component` +provides. + + + + +This module's manufacturer part number, as a string. + +For the picker to select the correct part from the manufacturer, +this must be set. + + + + +The package of the module. + +This drives which components can be selected, and what footprint is used. + +Must exactly match a known package name. + + + + + + + +When set on an interface, this will override the net name of the interface. + +This is useful for renaming nets which are automatically generated. + + + + +Only for ModuleInterfaces. +If set to `True`, require that interface is connected to something outside +of the module it's defined in. + + diff --git a/atopile-0.14.x/api-reference/components/spiflash.mdx b/atopile-0.14.x/api-reference/components/spiflash.mdx new file mode 100644 index 0000000..57f6953 --- /dev/null +++ b/atopile-0.14.x/api-reference/components/spiflash.mdx @@ -0,0 +1,110 @@ +--- + +title: "SPIFlash" +icon: microchip +description: "" +--- + + +## Parameters + + + + + +## Interfaces + + + + + + + + +## Global Attributes + + +These attributes are available to all modules and interfaces in a design. + + +Assign the LCSC ID of the module. + +If set, this will tell the picker to select that part from LCSC for this block. + + + + +This module's manufacturer name, as a string. + +Only exact matches on the manufacturer's name will be found by the picker. +It's recommended to fill this information based on what `ato create component` +provides. + + + + +This module's manufacturer part number, as a string. + +For the picker to select the correct part from the manufacturer, +this must be set. + + + + +The package of the module. + +This drives which components can be selected, and what footprint is used. + +Must exactly match a known package name. + + + + + + + +When set on an interface, this will override the net name of the interface. + +This is useful for renaming nets which are automatically generated. + + + + +Only for ModuleInterfaces. +If set to `True`, require that interface is connected to something outside +of the module it's defined in. + + + +```ato Basic Usage +import SPIFlash, ElectricPower, ElectricLogic + +spi_flash = new SPIFlash +spi_flash.memory_size = 16MB # Common sizes: 1MB, 2MB, 4MB, 8MB, 16MB, 32MB + +# Connect power supply +power_3v3 = new ElectricPower +assert power_3v3.voltage within 3.3V +/- 5% +spi_flash.power ~ power_3v3 + +# Connect SPI/QSPI interface +microcontroller.qspi ~ spi_flash.qspi + +# For standard SPI (using only 2 data lines) +microcontroller.spi.sclk ~ spi_flash.qspi.sclk +microcontroller.spi.mosi ~ spi_flash.qspi.ios[0] # DI/IO0 +microcontroller.spi.miso ~ spi_flash.qspi.ios[1] # DO/IO1 + +# Chip select +chip_select = new ElectricLogic +chip_select.reference ~ power_3v3 +microcontroller.gpio_cs ~ chip_select.line +spi_flash.qspi.cs ~ chip_select + +# For Quad SPI (4x faster) +# microcontroller.qspi.ios[2] ~ spi_flash.qspi.ios[2] # WP/IO2 +# microcontroller.qspi.ios[3] ~ spi_flash.qspi.ios[3] # HOLD/IO3 + +# Common applications: firmware storage, data logging, file systems +``` + \ No newline at end of file diff --git a/atopile-0.14.x/api-reference/components/surgeprotection.mdx b/atopile-0.14.x/api-reference/components/surgeprotection.mdx new file mode 100644 index 0000000..a2b5500 --- /dev/null +++ b/atopile-0.14.x/api-reference/components/surgeprotection.mdx @@ -0,0 +1,69 @@ +--- + +title: "SurgeProtection" +icon: microchip +description: "" +--- + + +## Init Args + + + + + + +## Global Attributes + + +These attributes are available to all modules and interfaces in a design. + + +Assign the LCSC ID of the module. + +If set, this will tell the picker to select that part from LCSC for this block. + + + + +This module's manufacturer name, as a string. + +Only exact matches on the manufacturer's name will be found by the picker. +It's recommended to fill this information based on what `ato create component` +provides. + + + + +This module's manufacturer part number, as a string. + +For the picker to select the correct part from the manufacturer, +this must be set. + + + + +The package of the module. + +This drives which components can be selected, and what footprint is used. + +Must exactly match a known package name. + + + + + + + +When set on an interface, this will override the net name of the interface. + +This is useful for renaming nets which are automatically generated. + + + + +Only for ModuleInterfaces. +If set to `True`, require that interface is connected to something outside +of the module it's defined in. + + diff --git a/atopile-0.14.x/api-reference/components/symbol.mdx b/atopile-0.14.x/api-reference/components/symbol.mdx new file mode 100644 index 0000000..e82f7ff --- /dev/null +++ b/atopile-0.14.x/api-reference/components/symbol.mdx @@ -0,0 +1,65 @@ +--- + +title: "Symbol" +icon: microchip +description: " +Symbols represent a symbol instance and are bi-directionally +linked with the module they represent via the `has_linked` trait. +" +--- + + +## Global Attributes + + +These attributes are available to all modules and interfaces in a design. + + +Assign the LCSC ID of the module. + +If set, this will tell the picker to select that part from LCSC for this block. + + + + +This module's manufacturer name, as a string. + +Only exact matches on the manufacturer's name will be found by the picker. +It's recommended to fill this information based on what `ato create component` +provides. + + + + +This module's manufacturer part number, as a string. + +For the picker to select the correct part from the manufacturer, +this must be set. + + + + +The package of the module. + +This drives which components can be selected, and what footprint is used. + +Must exactly match a known package name. + + + + + + + +When set on an interface, this will override the net name of the interface. + +This is useful for renaming nets which are automatically generated. + + + + +Only for ModuleInterfaces. +If set to `True`, require that interface is connected to something outside +of the module it's defined in. + + diff --git a/atopile-0.14.x/api-reference/components/testpoint.mdx b/atopile-0.14.x/api-reference/components/testpoint.mdx new file mode 100644 index 0000000..5d5c487 --- /dev/null +++ b/atopile-0.14.x/api-reference/components/testpoint.mdx @@ -0,0 +1,80 @@ +--- + +title: "TestPoint" +icon: microchip +description: " +Basic test point. +" +--- + + +## Interfaces + + + + + +## Global Attributes + + +These attributes are available to all modules and interfaces in a design. + + +Assign the LCSC ID of the module. + +If set, this will tell the picker to select that part from LCSC for this block. + + + + +This module's manufacturer name, as a string. + +Only exact matches on the manufacturer's name will be found by the picker. +It's recommended to fill this information based on what `ato create component` +provides. + + + + +This module's manufacturer part number, as a string. + +For the picker to select the correct part from the manufacturer, +this must be set. + + + + +The package of the module. + +This drives which components can be selected, and what footprint is used. + +Must exactly match a known package name. + + + + + + + +When set on an interface, this will override the net name of the interface. + +This is useful for renaming nets which are automatically generated. + + + + +Only for ModuleInterfaces. +If set to `True`, require that interface is connected to something outside +of the module it's defined in. + + + +```ato Basic Usage +import TestPoint + +test_point = new TestPoint + +# Connect to signal you want to probe +signal_to_test ~ test_point.contact +``` + \ No newline at end of file diff --git a/atopile-0.14.x/api-reference/components/tvs.mdx b/atopile-0.14.x/api-reference/components/tvs.mdx new file mode 100644 index 0000000..4bc0fc1 --- /dev/null +++ b/atopile-0.14.x/api-reference/components/tvs.mdx @@ -0,0 +1,122 @@ +--- + +title: "TVS" +icon: microchip +description: "" +--- + + +## Parameters + + + + + + + + + + + + + + + + + + + + +## Interfaces + + + + + + + + +## Global Attributes + + +These attributes are available to all modules and interfaces in a design. + + +Assign the LCSC ID of the module. + +If set, this will tell the picker to select that part from LCSC for this block. + + + + +This module's manufacturer name, as a string. + +Only exact matches on the manufacturer's name will be found by the picker. +It's recommended to fill this information based on what `ato create component` +provides. + + + + +This module's manufacturer part number, as a string. + +For the picker to select the correct part from the manufacturer, +this must be set. + + + + +The package of the module. + +This drives which components can be selected, and what footprint is used. + +Must exactly match a known package name. + + + + + + + +When set on an interface, this will override the net name of the interface. + +This is useful for renaming nets which are automatically generated. + + + + +Only for ModuleInterfaces. +If set to `True`, require that interface is connected to something outside +of the module it's defined in. + + + +```ato Basic Usage +import TVS, ElectricPower, Electrical + +tvs = new TVS +tvs.reverse_breakdown_voltage = 5.1V +/- 5% +tvs.max_current = 1A +tvs.reverse_working_voltage = 5V +tvs.package = "SOD-123" + +# Connect TVS for power line protection +power_supply = new ElectricPower +protected_line = new Electrical + +# TVS protects against voltage spikes +protected_line ~ tvs.anode +tvs.cathode ~ power_supply.lv # Connect to ground + +# Bidirectional TVS for signal line protection +signal_tvs = new TVS +signal_tvs.reverse_breakdown_voltage = 3.3V +/- 5% +signal_line = new Electrical + +signal_line ~ signal_tvs.anode +signal_tvs.cathode ~ power_supply.lv + +# Common applications: ESD protection, power surge protection +# TVS clamps voltage spikes to protect sensitive components +``` + \ No newline at end of file diff --git a/atopile-0.14.x/api-reference/interfaces/addressor.mdx b/atopile-0.14.x/api-reference/interfaces/addressor.mdx new file mode 100644 index 0000000..fdea0b4 --- /dev/null +++ b/atopile-0.14.x/api-reference/interfaces/addressor.mdx @@ -0,0 +1,110 @@ +--- + +title: "Addressor" +icon: right-left +description: "" +--- + + +## Init Args + + + + + + +## Parameters + + + + + + + + + + + +## Interfaces + + + + + +## Global Attributes + + +These attributes are available to all modules and interfaces in a design. + + +Assign the LCSC ID of the module. + +If set, this will tell the picker to select that part from LCSC for this block. + + + + +This module's manufacturer name, as a string. + +Only exact matches on the manufacturer's name will be found by the picker. +It's recommended to fill this information based on what `ato create component` +provides. + + + + +This module's manufacturer part number, as a string. + +For the picker to select the correct part from the manufacturer, +this must be set. + + + + +The package of the module. + +This drives which components can be selected, and what footprint is used. + +Must exactly match a known package name. + + + + + + + +When set on an interface, this will override the net name of the interface. + +This is useful for renaming nets which are automatically generated. + + + + +Only for ModuleInterfaces. +If set to `True`, require that interface is connected to something outside +of the module it's defined in. + + + +```ato Basic Usage +import Addressor, I2C, ElectricPower + +# For I2C device with 2 address pins (4 possible addresses) +addressor = new Addressor +addressor.base = 0x48 # Base address from datasheet + +# Connect power reference for address pins +power_3v3 = new ElectricPower +for line in addressor.address_lines: + line.reference ~ power_3v3 + +# Connect address pins to device +device.addr0 ~ addressor.address_lines[0].line +device.addr1 ~ addressor.address_lines[1].line + +# Connect to I2C interface +i2c_bus = new I2C +assert i2c_bus.address is addressor.address +device.i2c ~ i2c_bus +``` + \ No newline at end of file diff --git a/atopile-0.14.x/api-reference/interfaces/can.mdx b/atopile-0.14.x/api-reference/interfaces/can.mdx new file mode 100644 index 0000000..2fa8e45 --- /dev/null +++ b/atopile-0.14.x/api-reference/interfaces/can.mdx @@ -0,0 +1,104 @@ +--- + +title: "CAN" +icon: right-left +description: " +CAN bus interface +" +--- + + +## Parameters + + + + + +## Interfaces + + + + + +## Global Attributes + + +These attributes are available to all modules and interfaces in a design. + + +Assign the LCSC ID of the module. + +If set, this will tell the picker to select that part from LCSC for this block. + + + + +This module's manufacturer name, as a string. + +Only exact matches on the manufacturer's name will be found by the picker. +It's recommended to fill this information based on what `ato create component` +provides. + + + + +This module's manufacturer part number, as a string. + +For the picker to select the correct part from the manufacturer, +this must be set. + + + + +The package of the module. + +This drives which components can be selected, and what footprint is used. + +Must exactly match a known package name. + + + + + + + +When set on an interface, this will override the net name of the interface. + +This is useful for renaming nets which are automatically generated. + + + + +Only for ModuleInterfaces. +If set to `True`, require that interface is connected to something outside +of the module it's defined in. + + + +```ato Basic Usage +import CAN, ElectricPower, Resistor + +can_bus = new CAN +can_bus.speed = 250kbps # Common CAN speeds: 125k, 250k, 500k, 1Mbps +can_bus.diff_pair.impedance = 120ohm +/- 5% + +# Connect power reference for logic levels +power_5v = new ElectricPower +assert power_5v.voltage within 5V +/- 5% +can_bus.diff_pair.p.reference ~ power_5v +can_bus.diff_pair.n.reference ~ power_5v + +# Connect to CAN transceiver +can_transceiver.can_bus ~ can_bus + +# Connect to microcontroller CAN peripheral +microcontroller.can ~ can_transceiver.mcu_interface + +# CAN termination resistors (120 ohm at each end of bus) +termination_resistor = new Resistor +termination_resistor.resistance = 120ohm +/- 1% +can_bus.diff_pair.p.line ~> termination_resistor ~> can_bus.diff_pair.n.line + +# Common applications: automotive, industrial automation, IoT +``` + \ No newline at end of file diff --git a/atopile-0.14.x/api-reference/interfaces/can_ttl.mdx b/atopile-0.14.x/api-reference/interfaces/can_ttl.mdx new file mode 100644 index 0000000..0064f73 --- /dev/null +++ b/atopile-0.14.x/api-reference/interfaces/can_ttl.mdx @@ -0,0 +1,77 @@ +--- + +title: "CAN_TTL" +icon: right-left +description: "" +--- + + +## Parameters + + + + + +## Interfaces + + + + + + + + +## Global Attributes + + +These attributes are available to all modules and interfaces in a design. + + +Assign the LCSC ID of the module. + +If set, this will tell the picker to select that part from LCSC for this block. + + + + +This module's manufacturer name, as a string. + +Only exact matches on the manufacturer's name will be found by the picker. +It's recommended to fill this information based on what `ato create component` +provides. + + + + +This module's manufacturer part number, as a string. + +For the picker to select the correct part from the manufacturer, +this must be set. + + + + +The package of the module. + +This drives which components can be selected, and what footprint is used. + +Must exactly match a known package name. + + + + + + + +When set on an interface, this will override the net name of the interface. + +This is useful for renaming nets which are automatically generated. + + + + +Only for ModuleInterfaces. +If set to `True`, require that interface is connected to something outside +of the module it's defined in. + + diff --git a/atopile-0.14.x/api-reference/interfaces/differentialpair.mdx b/atopile-0.14.x/api-reference/interfaces/differentialpair.mdx new file mode 100644 index 0000000..88fc6be --- /dev/null +++ b/atopile-0.14.x/api-reference/interfaces/differentialpair.mdx @@ -0,0 +1,103 @@ +--- + +title: "DifferentialPair" +icon: right-left +description: "" +--- + + +## Parameters + + + + + +## Interfaces + + + + + + + + +## Global Attributes + + +These attributes are available to all modules and interfaces in a design. + + +Assign the LCSC ID of the module. + +If set, this will tell the picker to select that part from LCSC for this block. + + + + +This module's manufacturer name, as a string. + +Only exact matches on the manufacturer's name will be found by the picker. +It's recommended to fill this information based on what `ato create component` +provides. + + + + +This module's manufacturer part number, as a string. + +For the picker to select the correct part from the manufacturer, +this must be set. + + + + +The package of the module. + +This drives which components can be selected, and what footprint is used. + +Must exactly match a known package name. + + + + + + + +When set on an interface, this will override the net name of the interface. + +This is useful for renaming nets which are automatically generated. + + + + +Only for ModuleInterfaces. +If set to `True`, require that interface is connected to something outside +of the module it's defined in. + + + +```ato Basic Usage +import DifferentialPair, ElectricPower + +diff_pair = new DifferentialPair +diff_pair.impedance = 100ohm +/- 10% # Common for high-speed signals + +# Connect power reference for signal levels +power_3v3 = new ElectricPower +assert power_3v3.voltage within 3.3V +/- 5% +diff_pair.p.reference ~ power_3v3 +diff_pair.n.reference ~ power_3v3 + +# Connect between transmitter and receiver +transmitter.diff_out ~ diff_pair +diff_pair ~ receiver.diff_in + +# For terminated transmission line +terminated_pair = diff_pair.terminated() +transmitter.diff_out ~ terminated_pair + +# Common applications: USB, Ethernet, PCIe, HDMI +usb_dp_dn = new DifferentialPair +usb_dp_dn.impedance = 90ohm +/- 10% +``` + \ No newline at end of file diff --git a/atopile-0.14.x/api-reference/interfaces/electrical.mdx b/atopile-0.14.x/api-reference/interfaces/electrical.mdx new file mode 100644 index 0000000..627a356 --- /dev/null +++ b/atopile-0.14.x/api-reference/interfaces/electrical.mdx @@ -0,0 +1,90 @@ +--- + +title: "Electrical" +icon: right-left +description: " +Electrical interface. +" +--- + + +## Global Attributes + + +These attributes are available to all modules and interfaces in a design. + + +Assign the LCSC ID of the module. + +If set, this will tell the picker to select that part from LCSC for this block. + + + + +This module's manufacturer name, as a string. + +Only exact matches on the manufacturer's name will be found by the picker. +It's recommended to fill this information based on what `ato create component` +provides. + + + + +This module's manufacturer part number, as a string. + +For the picker to select the correct part from the manufacturer, +this must be set. + + + + +The package of the module. + +This drives which components can be selected, and what footprint is used. + +Must exactly match a known package name. + + + + + + + +When set on an interface, this will override the net name of the interface. + +This is useful for renaming nets which are automatically generated. + + + + +Only for ModuleInterfaces. +If set to `True`, require that interface is connected to something outside +of the module it's defined in. + + + +```ato Basic Usage +import Electrical, Resistor, Capacitor + +# Basic electrical connection point +electrical1 = new Electrical +electrical2 = new Electrical + +# Connect two electrical interfaces directly +electrical1 ~ electrical2 + +# Connect through components +resistor = new Resistor +resistor.resistance = 1kohm +/- 5% +electrical1 ~ resistor.unnamed[0] +resistor.unnamed[1] ~ electrical2 + +# Or using bridge syntax +electrical1 ~> resistor ~> electrical2 + +# Multiple connections to same net +capacitor = new Capacitor +electrical1 ~ capacitor.unnamed[0] +capacitor.unnamed[1] ~ electrical2 +``` + \ No newline at end of file diff --git a/atopile-0.14.x/api-reference/interfaces/electriclogic.mdx b/atopile-0.14.x/api-reference/interfaces/electriclogic.mdx new file mode 100644 index 0000000..41741d9 --- /dev/null +++ b/atopile-0.14.x/api-reference/interfaces/electriclogic.mdx @@ -0,0 +1,96 @@ +--- + +title: "ElectricLogic" +icon: right-left +description: " +ElectricLogic is a class that represents a logic signal. +Logic signals only have two states: high and low. +For more states / continuous signals check ElectricSignal. +" +--- + + +## Parameters + + + + + +## Interfaces + + + + + + + + +## Global Attributes + + +These attributes are available to all modules and interfaces in a design. + + +Assign the LCSC ID of the module. + +If set, this will tell the picker to select that part from LCSC for this block. + + + + +This module's manufacturer name, as a string. + +Only exact matches on the manufacturer's name will be found by the picker. +It's recommended to fill this information based on what `ato create component` +provides. + + + + +This module's manufacturer part number, as a string. + +For the picker to select the correct part from the manufacturer, +this must be set. + + + + +The package of the module. + +This drives which components can be selected, and what footprint is used. + +Must exactly match a known package name. + + + + + + + +When set on an interface, this will override the net name of the interface. + +This is useful for renaming nets which are automatically generated. + + + + +Only for ModuleInterfaces. +If set to `True`, require that interface is connected to something outside +of the module it's defined in. + + + +```ato Basic Usage +import ElectricLogic + +logic_signal = new ElectricLogic + +logic_signal.reference ~ example_electric_power + +logic_signal.line ~ electrical +# OR +logic_signal.line ~ electricLogic.line +# OR +logic_signal.line ~> example_resistor ~> electrical +``` + \ No newline at end of file diff --git a/atopile-0.14.x/api-reference/interfaces/electricpower.mdx b/atopile-0.14.x/api-reference/interfaces/electricpower.mdx new file mode 100644 index 0000000..4bbb23d --- /dev/null +++ b/atopile-0.14.x/api-reference/interfaces/electricpower.mdx @@ -0,0 +1,100 @@ +--- + +title: "ElectricPower" +icon: right-left +description: " +ElectricPower is a class that represents a power rail. Power rails have a higher potential (hv), and lower potential (lv) Electrical. +" +--- + + +## Parameters + + + + + + + + + + + +## Interfaces + + + + + + + + +## Global Attributes + + +These attributes are available to all modules and interfaces in a design. + + +Assign the LCSC ID of the module. + +If set, this will tell the picker to select that part from LCSC for this block. + + + + +This module's manufacturer name, as a string. + +Only exact matches on the manufacturer's name will be found by the picker. +It's recommended to fill this information based on what `ato create component` +provides. + + + + +This module's manufacturer part number, as a string. + +For the picker to select the correct part from the manufacturer, +this must be set. + + + + +The package of the module. + +This drives which components can be selected, and what footprint is used. + +Must exactly match a known package name. + + + + + + + +When set on an interface, this will override the net name of the interface. + +This is useful for renaming nets which are automatically generated. + + + + +Only for ModuleInterfaces. +If set to `True`, require that interface is connected to something outside +of the module it's defined in. + + + +```ato Basic Usage +import ElectricPower + +power_5v = new ElectricPower +assert power_5v.voltage within 5V +/- 5% +assert power_5v.max_current <= 1A + +# Connect 2 ElectricPowers together +power_5v ~ ic.power_input + +# Connect an example bypass capacitor +power_5v.hv ~> example_capacitor ~> power_5v.lv +``` + \ No newline at end of file diff --git a/atopile-0.14.x/api-reference/interfaces/electricsignal.mdx b/atopile-0.14.x/api-reference/interfaces/electricsignal.mdx new file mode 100644 index 0000000..23210eb --- /dev/null +++ b/atopile-0.14.x/api-reference/interfaces/electricsignal.mdx @@ -0,0 +1,96 @@ +--- + +title: "ElectricSignal" +icon: right-left +description: " +ElectricSignal is a class that represents a signal that is represented +by the voltage between the reference.hv and reference.lv. +" +--- + + +## Interfaces + + + + + + + + +## Global Attributes + + +These attributes are available to all modules and interfaces in a design. + + +Assign the LCSC ID of the module. + +If set, this will tell the picker to select that part from LCSC for this block. + + + + +This module's manufacturer name, as a string. + +Only exact matches on the manufacturer's name will be found by the picker. +It's recommended to fill this information based on what `ato create component` +provides. + + + + +This module's manufacturer part number, as a string. + +For the picker to select the correct part from the manufacturer, +this must be set. + + + + +The package of the module. + +This drives which components can be selected, and what footprint is used. + +Must exactly match a known package name. + + + + + + + +When set on an interface, this will override the net name of the interface. + +This is useful for renaming nets which are automatically generated. + + + + +Only for ModuleInterfaces. +If set to `True`, require that interface is connected to something outside +of the module it's defined in. + + + +```ato Basic Usage +import ElectricSignal, ElectricPower + +signal = new ElectricSignal + +# Connect power reference for signal levels +power_3v3 = new ElectricPower +assert power_3v3.voltage within 3.3V +/- 5% +signal.reference ~ power_3v3 + +# Connect between components +sensor_output ~ signal.line +adc_input ~ signal.line + +# For differential signals, use two ElectricSignals +diff_pos = new ElectricSignal +diff_neg = new ElectricSignal +diff_pos.reference ~ power_3v3 +diff_neg.reference ~ power_3v3 +``` + \ No newline at end of file diff --git a/atopile-0.14.x/api-reference/interfaces/enablepin.mdx b/atopile-0.14.x/api-reference/interfaces/enablepin.mdx new file mode 100644 index 0000000..f12740c --- /dev/null +++ b/atopile-0.14.x/api-reference/interfaces/enablepin.mdx @@ -0,0 +1,68 @@ +--- + +title: "EnablePin" +icon: right-left +description: "" +--- + + +## Interfaces + + + + + +## Global Attributes + + +These attributes are available to all modules and interfaces in a design. + + +Assign the LCSC ID of the module. + +If set, this will tell the picker to select that part from LCSC for this block. + + + + +This module's manufacturer name, as a string. + +Only exact matches on the manufacturer's name will be found by the picker. +It's recommended to fill this information based on what `ato create component` +provides. + + + + +This module's manufacturer part number, as a string. + +For the picker to select the correct part from the manufacturer, +this must be set. + + + + +The package of the module. + +This drives which components can be selected, and what footprint is used. + +Must exactly match a known package name. + + + + + + + +When set on an interface, this will override the net name of the interface. + +This is useful for renaming nets which are automatically generated. + + + + +Only for ModuleInterfaces. +If set to `True`, require that interface is connected to something outside +of the module it's defined in. + + diff --git a/atopile-0.14.x/api-reference/interfaces/ethernet.mdx b/atopile-0.14.x/api-reference/interfaces/ethernet.mdx new file mode 100644 index 0000000..0c69a16 --- /dev/null +++ b/atopile-0.14.x/api-reference/interfaces/ethernet.mdx @@ -0,0 +1,108 @@ +--- + +title: "Ethernet" +icon: right-left +description: " +1000BASE-T Gigabit Ethernet Interface +" +--- + + +## Interfaces + + + + + + + + + + + + + + + + + + + + +## Global Attributes + + +These attributes are available to all modules and interfaces in a design. + + +Assign the LCSC ID of the module. + +If set, this will tell the picker to select that part from LCSC for this block. + + + + +This module's manufacturer name, as a string. + +Only exact matches on the manufacturer's name will be found by the picker. +It's recommended to fill this information based on what `ato create component` +provides. + + + + +This module's manufacturer part number, as a string. + +For the picker to select the correct part from the manufacturer, +this must be set. + + + + +The package of the module. + +This drives which components can be selected, and what footprint is used. + +Must exactly match a known package name. + + + + + + + +When set on an interface, this will override the net name of the interface. + +This is useful for renaming nets which are automatically generated. + + + + +Only for ModuleInterfaces. +If set to `True`, require that interface is connected to something outside +of the module it's defined in. + + + +```ato Basic Usage +import Ethernet, ElectricPower + +ethernet = new Ethernet + +# Connect power reference for logic levels +power_3v3 = new ElectricPower +ethernet.led_speed.reference ~ power_3v3 +ethernet.led_link.reference ~ power_3v3 + +# Connect to PHY or connector +# Four differential pairs for 1000BASE-T +ethernet_connector.tx_pairs[0] ~ ethernet.pairs[0] +ethernet_connector.tx_pairs[1] ~ ethernet.pairs[1] +ethernet_connector.rx_pairs[2] ~ ethernet.pairs[2] +ethernet_connector.rx_pairs[3] ~ ethernet.pairs[3] + +# Connect status LEDs +ethernet.led_speed ~ speed_led_output +ethernet.led_link ~ link_led_output +``` + \ No newline at end of file diff --git a/atopile-0.14.x/api-reference/interfaces/hdmi.mdx b/atopile-0.14.x/api-reference/interfaces/hdmi.mdx new file mode 100644 index 0000000..9a3d75f --- /dev/null +++ b/atopile-0.14.x/api-reference/interfaces/hdmi.mdx @@ -0,0 +1,91 @@ +--- + +title: "HDMI" +icon: right-left +description: " +HDMI interface +" +--- + + +## Interfaces + + + + + + + + + + + + + + + + + + + + + + + + + + +## Global Attributes + + +These attributes are available to all modules and interfaces in a design. + + +Assign the LCSC ID of the module. + +If set, this will tell the picker to select that part from LCSC for this block. + + + + +This module's manufacturer name, as a string. + +Only exact matches on the manufacturer's name will be found by the picker. +It's recommended to fill this information based on what `ato create component` +provides. + + + + +This module's manufacturer part number, as a string. + +For the picker to select the correct part from the manufacturer, +this must be set. + + + + +The package of the module. + +This drives which components can be selected, and what footprint is used. + +Must exactly match a known package name. + + + + + + + +When set on an interface, this will override the net name of the interface. + +This is useful for renaming nets which are automatically generated. + + + + +Only for ModuleInterfaces. +If set to `True`, require that interface is connected to something outside +of the module it's defined in. + + diff --git a/atopile-0.14.x/api-reference/interfaces/i2c.mdx b/atopile-0.14.x/api-reference/interfaces/i2c.mdx new file mode 100644 index 0000000..7c31f60 --- /dev/null +++ b/atopile-0.14.x/api-reference/interfaces/i2c.mdx @@ -0,0 +1,109 @@ +--- + +title: "I2C" +icon: right-left +description: "" +--- + + +## Parameters + + + + + + + + + + + +## Interfaces + + + + + + + + +## Traits + +**requires_pulls** + + +## Global Attributes + + +These attributes are available to all modules and interfaces in a design. + + +Assign the LCSC ID of the module. + +If set, this will tell the picker to select that part from LCSC for this block. + + + + +This module's manufacturer name, as a string. + +Only exact matches on the manufacturer's name will be found by the picker. +It's recommended to fill this information based on what `ato create component` +provides. + + + + +This module's manufacturer part number, as a string. + +For the picker to select the correct part from the manufacturer, +this must be set. + + + + +The package of the module. + +This drives which components can be selected, and what footprint is used. + +Must exactly match a known package name. + + + + + + + +When set on an interface, this will override the net name of the interface. + +This is useful for renaming nets which are automatically generated. + + + + +Only for ModuleInterfaces. +If set to `True`, require that interface is connected to something outside +of the module it's defined in. + + + +```ato Basic Usage +import I2C, ElectricPower + +i2c_bus = new I2C +i2c_bus.frequency = 400kHz # Fast mode +i2c_bus.address = 0x48 # Device address + +# Connect power reference for logic levels +power_3v3 = new ElectricPower +assert power_3v3.voltage within 3.3V +/- 5% +i2c_bus.scl.reference ~ power_3v3 +i2c_bus.sda.reference ~ power_3v3 + +# Connect to microcontroller +microcontroller.i2c ~ i2c_bus + +# Connect to I2C sensor +sensor.i2c ~ i2c_bus +``` + \ No newline at end of file diff --git a/atopile-0.14.x/api-reference/interfaces/i2s.mdx b/atopile-0.14.x/api-reference/interfaces/i2s.mdx new file mode 100644 index 0000000..709808d --- /dev/null +++ b/atopile-0.14.x/api-reference/interfaces/i2s.mdx @@ -0,0 +1,114 @@ +--- + +title: "I2S" +icon: right-left +description: "" +--- + + +## Parameters + + + + + + + + +## Interfaces + + + + + + + + + + + +## Global Attributes + + +These attributes are available to all modules and interfaces in a design. + + +Assign the LCSC ID of the module. + +If set, this will tell the picker to select that part from LCSC for this block. + + + + +This module's manufacturer name, as a string. + +Only exact matches on the manufacturer's name will be found by the picker. +It's recommended to fill this information based on what `ato create component` +provides. + + + + +This module's manufacturer part number, as a string. + +For the picker to select the correct part from the manufacturer, +this must be set. + + + + +The package of the module. + +This drives which components can be selected, and what footprint is used. + +Must exactly match a known package name. + + + + + + + +When set on an interface, this will override the net name of the interface. + +This is useful for renaming nets which are automatically generated. + + + + +Only for ModuleInterfaces. +If set to `True`, require that interface is connected to something outside +of the module it's defined in. + + + +```ato Basic Usage +import I2S, ElectricPower + +i2s = new I2S +i2s.sample_rate = 44100Hz # Common rates: 8k, 16k, 22k, 44.1k, 48k, 96k Hz +i2s.bit_depth = 16bit # Common depths: 16, 24, 32 bit + +# Connect power reference for logic levels +power_3v3 = new ElectricPower +assert power_3v3.voltage within 3.3V +/- 5% +i2s.sd.reference ~ power_3v3 # Serial Data +i2s.ws.reference ~ power_3v3 # Word Select (Left/Right Clock) +i2s.sck.reference ~ power_3v3 # Serial Clock (Bit Clock) + +# Connect to microcontroller I2S peripheral +microcontroller.i2s_sd ~ i2s.sd.line +microcontroller.i2s_ws ~ i2s.ws.line +microcontroller.i2s_sck ~ i2s.sck.line + +# Connect to audio codec or DAC/ADC +audio_codec.i2s ~ i2s + +# I2S timing relationships: +# - SCK frequency = sample_rate * bit_depth * 2 (stereo) +# - WS frequency = sample_rate (toggles left/right channel) +# - SD carries time-multiplexed audio data + +# Common applications: digital audio, microphones, speakers +``` + \ No newline at end of file diff --git a/atopile-0.14.x/api-reference/interfaces/jtag.mdx b/atopile-0.14.x/api-reference/interfaces/jtag.mdx new file mode 100644 index 0000000..297d1e9 --- /dev/null +++ b/atopile-0.14.x/api-reference/interfaces/jtag.mdx @@ -0,0 +1,129 @@ +--- + +title: "JTAG" +icon: right-left +description: "" +--- + + +## Interfaces + + + + + + + + + + + + + + + + + + + + + + + + + + +## Global Attributes + + +These attributes are available to all modules and interfaces in a design. + + +Assign the LCSC ID of the module. + +If set, this will tell the picker to select that part from LCSC for this block. + + + + +This module's manufacturer name, as a string. + +Only exact matches on the manufacturer's name will be found by the picker. +It's recommended to fill this information based on what `ato create component` +provides. + + + + +This module's manufacturer part number, as a string. + +For the picker to select the correct part from the manufacturer, +this must be set. + + + + +The package of the module. + +This drives which components can be selected, and what footprint is used. + +Must exactly match a known package name. + + + + + + + +When set on an interface, this will override the net name of the interface. + +This is useful for renaming nets which are automatically generated. + + + + +Only for ModuleInterfaces. +If set to `True`, require that interface is connected to something outside +of the module it's defined in. + + + +```ato Basic Usage +import JTAG, ElectricPower, Resistor + +jtag = new JTAG + +# Connect voltage reference for all logic signals +power_3v3 = new ElectricPower +assert power_3v3.voltage within 3.3V +/- 5% +jtag.vtref ~ power_3v3 + +# All logic signals use same reference +jtag.tdo.reference ~ power_3v3 +jtag.tdi.reference ~ power_3v3 +jtag.tms.reference ~ power_3v3 +jtag.tck.reference ~ power_3v3 +jtag.n_trst.reference ~ power_3v3 +jtag.n_reset.reference ~ power_3v3 +jtag.dbgrq.reference ~ power_3v3 + +# Connect to microcontroller JTAG interface +microcontroller.jtag_tdo ~ jtag.tdo.line +microcontroller.jtag_tdi ~ jtag.tdi.line +microcontroller.jtag_tms ~ jtag.tms.line +microcontroller.jtag_tck ~ jtag.tck.line +microcontroller.jtag_trst ~ jtag.n_trst.line +microcontroller.reset_n ~ jtag.n_reset.line + +# Connect to JTAG debugger/programmer +debugger.jtag ~ jtag + +# Pullup resistors for reset lines +trst_pullup = new Resistor +reset_pullup = new Resistor +trst_pullup.resistance = 10kohm +/- 5% +reset_pullup.resistance = 10kohm +/- 5% +jtag.n_trst.line ~> trst_pullup ~> power_3v3.hv +jtag.n_reset.line ~> reset_pullup ~> power_3v3.hv +``` + \ No newline at end of file diff --git a/atopile-0.14.x/api-reference/interfaces/logic.mdx b/atopile-0.14.x/api-reference/interfaces/logic.mdx new file mode 100644 index 0000000..cb77ab7 --- /dev/null +++ b/atopile-0.14.x/api-reference/interfaces/logic.mdx @@ -0,0 +1,64 @@ +--- + +title: "Logic" +icon: right-left +description: " +Acts as protocol, because multi inheritance is not supported +" +--- + + +## Global Attributes + + +These attributes are available to all modules and interfaces in a design. + + +Assign the LCSC ID of the module. + +If set, this will tell the picker to select that part from LCSC for this block. + + + + +This module's manufacturer name, as a string. + +Only exact matches on the manufacturer's name will be found by the picker. +It's recommended to fill this information based on what `ato create component` +provides. + + + + +This module's manufacturer part number, as a string. + +For the picker to select the correct part from the manufacturer, +this must be set. + + + + +The package of the module. + +This drives which components can be selected, and what footprint is used. + +Must exactly match a known package name. + + + + + + + +When set on an interface, this will override the net name of the interface. + +This is useful for renaming nets which are automatically generated. + + + + +Only for ModuleInterfaces. +If set to `True`, require that interface is connected to something outside +of the module it's defined in. + + diff --git a/atopile-0.14.x/api-reference/interfaces/mechanical.mdx b/atopile-0.14.x/api-reference/interfaces/mechanical.mdx new file mode 100644 index 0000000..1f5b188 --- /dev/null +++ b/atopile-0.14.x/api-reference/interfaces/mechanical.mdx @@ -0,0 +1,62 @@ +--- + +title: "Mechanical" +icon: right-left +description: "" +--- + + +## Global Attributes + + +These attributes are available to all modules and interfaces in a design. + + +Assign the LCSC ID of the module. + +If set, this will tell the picker to select that part from LCSC for this block. + + + + +This module's manufacturer name, as a string. + +Only exact matches on the manufacturer's name will be found by the picker. +It's recommended to fill this information based on what `ato create component` +provides. + + + + +This module's manufacturer part number, as a string. + +For the picker to select the correct part from the manufacturer, +this must be set. + + + + +The package of the module. + +This drives which components can be selected, and what footprint is used. + +Must exactly match a known package name. + + + + + + + +When set on an interface, this will override the net name of the interface. + +This is useful for renaming nets which are automatically generated. + + + + +Only for ModuleInterfaces. +If set to `True`, require that interface is connected to something outside +of the module it's defined in. + + diff --git a/atopile-0.14.x/api-reference/interfaces/multispi.mdx b/atopile-0.14.x/api-reference/interfaces/multispi.mdx new file mode 100644 index 0000000..ee6f186 --- /dev/null +++ b/atopile-0.14.x/api-reference/interfaces/multispi.mdx @@ -0,0 +1,95 @@ +--- + +title: "MultiSPI" +icon: right-left +description: "" +--- + + +## Init Args + + + + + + +## Interfaces + + + + + + + + + + + +## Global Attributes + + +These attributes are available to all modules and interfaces in a design. + + +Assign the LCSC ID of the module. + +If set, this will tell the picker to select that part from LCSC for this block. + + + + +This module's manufacturer name, as a string. + +Only exact matches on the manufacturer's name will be found by the picker. +It's recommended to fill this information based on what `ato create component` +provides. + + + + +This module's manufacturer part number, as a string. + +For the picker to select the correct part from the manufacturer, +this must be set. + + + + +The package of the module. + +This drives which components can be selected, and what footprint is used. + +Must exactly match a known package name. + + + + + + + +When set on an interface, this will override the net name of the interface. + +This is useful for renaming nets which are automatically generated. + + + + +Only for ModuleInterfaces. +If set to `True`, require that interface is connected to something outside +of the module it's defined in. + + + +```ato Basic Usage +import MultiSPI, SPI + +# Microcontroller SPI peripheral +mcu_spi = new SPI + +# Quad-SPI flash interface (4 data lanes) +qspi = new MultiSPI + +# Connect the buses +mcu_spi ~ qspi +``` + \ No newline at end of file diff --git a/atopile-0.14.x/api-reference/interfaces/pad.mdx b/atopile-0.14.x/api-reference/interfaces/pad.mdx new file mode 100644 index 0000000..830516b --- /dev/null +++ b/atopile-0.14.x/api-reference/interfaces/pad.mdx @@ -0,0 +1,79 @@ +--- + +title: "Pad" +icon: right-left +description: "" +--- + + +## Interfaces + + + + + + + + +## Global Attributes + + +These attributes are available to all modules and interfaces in a design. + + +Assign the LCSC ID of the module. + +If set, this will tell the picker to select that part from LCSC for this block. + + + + +This module's manufacturer name, as a string. + +Only exact matches on the manufacturer's name will be found by the picker. +It's recommended to fill this information based on what `ato create component` +provides. + + + + +This module's manufacturer part number, as a string. + +For the picker to select the correct part from the manufacturer, +this must be set. + + + + +The package of the module. + +This drives which components can be selected, and what footprint is used. + +Must exactly match a known package name. + + + + + + + +When set on an interface, this will override the net name of the interface. + +This is useful for renaming nets which are automatically generated. + + + + +Only for ModuleInterfaces. +If set to `True`, require that interface is connected to something outside +of the module it's defined in. + + + +```ato Basic Usage +import Pad + +pad = new Pad +electrical_signal ~ pad.net +``` + \ No newline at end of file diff --git a/atopile-0.14.x/api-reference/interfaces/pdm.mdx b/atopile-0.14.x/api-reference/interfaces/pdm.mdx new file mode 100644 index 0000000..7850d65 --- /dev/null +++ b/atopile-0.14.x/api-reference/interfaces/pdm.mdx @@ -0,0 +1,78 @@ +--- + +title: "PDM" +icon: right-left +description: " +Pulse Density Modulation is a way of representing a sampled signal as a stream of +single bits where the relative density of the pulses correspond to the analog +signal's amplitude +" +--- + + +## Interfaces + + + + + + + + + + + +## Global Attributes + + +These attributes are available to all modules and interfaces in a design. + + +Assign the LCSC ID of the module. + +If set, this will tell the picker to select that part from LCSC for this block. + + + + +This module's manufacturer name, as a string. + +Only exact matches on the manufacturer's name will be found by the picker. +It's recommended to fill this information based on what `ato create component` +provides. + + + + +This module's manufacturer part number, as a string. + +For the picker to select the correct part from the manufacturer, +this must be set. + + + + +The package of the module. + +This drives which components can be selected, and what footprint is used. + +Must exactly match a known package name. + + + + + + + +When set on an interface, this will override the net name of the interface. + +This is useful for renaming nets which are automatically generated. + + + + +Only for ModuleInterfaces. +If set to `True`, require that interface is connected to something outside +of the module it's defined in. + + diff --git a/atopile-0.14.x/api-reference/interfaces/power.mdx b/atopile-0.14.x/api-reference/interfaces/power.mdx new file mode 100644 index 0000000..bb9ee4f --- /dev/null +++ b/atopile-0.14.x/api-reference/interfaces/power.mdx @@ -0,0 +1,62 @@ +--- + +title: "Power" +icon: right-left +description: "" +--- + + +## Global Attributes + + +These attributes are available to all modules and interfaces in a design. + + +Assign the LCSC ID of the module. + +If set, this will tell the picker to select that part from LCSC for this block. + + + + +This module's manufacturer name, as a string. + +Only exact matches on the manufacturer's name will be found by the picker. +It's recommended to fill this information based on what `ato create component` +provides. + + + + +This module's manufacturer part number, as a string. + +For the picker to select the correct part from the manufacturer, +this must be set. + + + + +The package of the module. + +This drives which components can be selected, and what footprint is used. + +Must exactly match a known package name. + + + + + + + +When set on an interface, this will override the net name of the interface. + +This is useful for renaming nets which are automatically generated. + + + + +Only for ModuleInterfaces. +If set to `True`, require that interface is connected to something outside +of the module it's defined in. + + diff --git a/atopile-0.14.x/api-reference/interfaces/rs232.mdx b/atopile-0.14.x/api-reference/interfaces/rs232.mdx new file mode 100644 index 0000000..6d15246 --- /dev/null +++ b/atopile-0.14.x/api-reference/interfaces/rs232.mdx @@ -0,0 +1,89 @@ +--- + +title: "RS232" +icon: right-left +description: "" +--- + + +## Interfaces + + + + + + + + + + + + + + + + + + + + + + + + + + +## Global Attributes + + +These attributes are available to all modules and interfaces in a design. + + +Assign the LCSC ID of the module. + +If set, this will tell the picker to select that part from LCSC for this block. + + + + +This module's manufacturer name, as a string. + +Only exact matches on the manufacturer's name will be found by the picker. +It's recommended to fill this information based on what `ato create component` +provides. + + + + +This module's manufacturer part number, as a string. + +For the picker to select the correct part from the manufacturer, +this must be set. + + + + +The package of the module. + +This drives which components can be selected, and what footprint is used. + +Must exactly match a known package name. + + + + + + + +When set on an interface, this will override the net name of the interface. + +This is useful for renaming nets which are automatically generated. + + + + +Only for ModuleInterfaces. +If set to `True`, require that interface is connected to something outside +of the module it's defined in. + + diff --git a/atopile-0.14.x/api-reference/interfaces/rs485halfduplex.mdx b/atopile-0.14.x/api-reference/interfaces/rs485halfduplex.mdx new file mode 100644 index 0000000..01fee4a --- /dev/null +++ b/atopile-0.14.x/api-reference/interfaces/rs485halfduplex.mdx @@ -0,0 +1,72 @@ +--- + +title: "RS485HalfDuplex" +icon: right-left +description: " +Half-duplex RS485 interface +A = p +B = n +" +--- + + +## Interfaces + + + + + +## Global Attributes + + +These attributes are available to all modules and interfaces in a design. + + +Assign the LCSC ID of the module. + +If set, this will tell the picker to select that part from LCSC for this block. + + + + +This module's manufacturer name, as a string. + +Only exact matches on the manufacturer's name will be found by the picker. +It's recommended to fill this information based on what `ato create component` +provides. + + + + +This module's manufacturer part number, as a string. + +For the picker to select the correct part from the manufacturer, +this must be set. + + + + +The package of the module. + +This drives which components can be selected, and what footprint is used. + +Must exactly match a known package name. + + + + + + + +When set on an interface, this will override the net name of the interface. + +This is useful for renaming nets which are automatically generated. + + + + +Only for ModuleInterfaces. +If set to `True`, require that interface is connected to something outside +of the module it's defined in. + + diff --git a/atopile-0.14.x/api-reference/interfaces/sercom.mdx b/atopile-0.14.x/api-reference/interfaces/sercom.mdx new file mode 100644 index 0000000..03dfbc6 --- /dev/null +++ b/atopile-0.14.x/api-reference/interfaces/sercom.mdx @@ -0,0 +1,77 @@ +--- + +title: "Sercom" +icon: right-left +description: "" +--- + + +## Interfaces + + + + + + + + + + + + + + +## Global Attributes + + +These attributes are available to all modules and interfaces in a design. + + +Assign the LCSC ID of the module. + +If set, this will tell the picker to select that part from LCSC for this block. + + + + +This module's manufacturer name, as a string. + +Only exact matches on the manufacturer's name will be found by the picker. +It's recommended to fill this information based on what `ato create component` +provides. + + + + +This module's manufacturer part number, as a string. + +For the picker to select the correct part from the manufacturer, +this must be set. + + + + +The package of the module. + +This drives which components can be selected, and what footprint is used. + +Must exactly match a known package name. + + + + + + + +When set on an interface, this will override the net name of the interface. + +This is useful for renaming nets which are automatically generated. + + + + +Only for ModuleInterfaces. +If set to `True`, require that interface is connected to something outside +of the module it's defined in. + + diff --git a/atopile-0.14.x/api-reference/interfaces/signal.mdx b/atopile-0.14.x/api-reference/interfaces/signal.mdx new file mode 100644 index 0000000..ed64e7d --- /dev/null +++ b/atopile-0.14.x/api-reference/interfaces/signal.mdx @@ -0,0 +1,62 @@ +--- + +title: "Signal" +icon: right-left +description: "" +--- + + +## Global Attributes + + +These attributes are available to all modules and interfaces in a design. + + +Assign the LCSC ID of the module. + +If set, this will tell the picker to select that part from LCSC for this block. + + + + +This module's manufacturer name, as a string. + +Only exact matches on the manufacturer's name will be found by the picker. +It's recommended to fill this information based on what `ato create component` +provides. + + + + +This module's manufacturer part number, as a string. + +For the picker to select the correct part from the manufacturer, +this must be set. + + + + +The package of the module. + +This drives which components can be selected, and what footprint is used. + +Must exactly match a known package name. + + + + + + + +When set on an interface, this will override the net name of the interface. + +This is useful for renaming nets which are automatically generated. + + + + +Only for ModuleInterfaces. +If set to `True`, require that interface is connected to something outside +of the module it's defined in. + + diff --git a/atopile-0.14.x/api-reference/interfaces/spi.mdx b/atopile-0.14.x/api-reference/interfaces/spi.mdx new file mode 100644 index 0000000..8f3a3dd --- /dev/null +++ b/atopile-0.14.x/api-reference/interfaces/spi.mdx @@ -0,0 +1,97 @@ +--- + +title: "SPI" +icon: right-left +description: "" +--- + + +## Interfaces + + + + + + + + + + + +## Global Attributes + + +These attributes are available to all modules and interfaces in a design. + + +Assign the LCSC ID of the module. + +If set, this will tell the picker to select that part from LCSC for this block. + + + + +This module's manufacturer name, as a string. + +Only exact matches on the manufacturer's name will be found by the picker. +It's recommended to fill this information based on what `ato create component` +provides. + + + + +This module's manufacturer part number, as a string. + +For the picker to select the correct part from the manufacturer, +this must be set. + + + + +The package of the module. + +This drives which components can be selected, and what footprint is used. + +Must exactly match a known package name. + + + + + + + +When set on an interface, this will override the net name of the interface. + +This is useful for renaming nets which are automatically generated. + + + + +Only for ModuleInterfaces. +If set to `True`, require that interface is connected to something outside +of the module it's defined in. + + + +```ato Basic Usage +import SPI, ElectricPower, ElectricLogic + +spi_bus = new SPI + +# Connect power reference for logic levels +power_3v3 = new ElectricPower +assert power_3v3.voltage within 3.3V +/- 5% +spi_bus.sclk.reference ~ power_3v3 +spi_bus.miso.reference ~ power_3v3 +spi_bus.mosi.reference ~ power_3v3 + +# Connect to microcontroller +microcontroller.spi ~ spi_bus + +# Connect to SPI device with chip select +chip_select = new ElectricLogic +chip_select.reference ~ power_3v3 +flash_memory.spi ~ spi_bus +flash_memory.cs ~ chip_select +``` + \ No newline at end of file diff --git a/atopile-0.14.x/api-reference/interfaces/swd.mdx b/atopile-0.14.x/api-reference/interfaces/swd.mdx new file mode 100644 index 0000000..ad303a2 --- /dev/null +++ b/atopile-0.14.x/api-reference/interfaces/swd.mdx @@ -0,0 +1,108 @@ +--- + +title: "SWD" +icon: right-left +description: "" +--- + + +## Interfaces + + + + + + + + + + + + + + +## Global Attributes + + +These attributes are available to all modules and interfaces in a design. + + +Assign the LCSC ID of the module. + +If set, this will tell the picker to select that part from LCSC for this block. + + + + +This module's manufacturer name, as a string. + +Only exact matches on the manufacturer's name will be found by the picker. +It's recommended to fill this information based on what `ato create component` +provides. + + + + +This module's manufacturer part number, as a string. + +For the picker to select the correct part from the manufacturer, +this must be set. + + + + +The package of the module. + +This drives which components can be selected, and what footprint is used. + +Must exactly match a known package name. + + + + + + + +When set on an interface, this will override the net name of the interface. + +This is useful for renaming nets which are automatically generated. + + + + +Only for ModuleInterfaces. +If set to `True`, require that interface is connected to something outside +of the module it's defined in. + + + +```ato Basic Usage +import SWD, ElectricPower, Resistor + +swd = new SWD + +# Connect power reference for logic levels +power_3v3 = new ElectricPower +assert power_3v3.voltage within 3.3V +/- 5% +swd.clk.reference ~ power_3v3 +swd.dio.reference ~ power_3v3 +swd.swo.reference ~ power_3v3 +swd.reset.reference ~ power_3v3 + +# Connect to microcontroller SWD interface +microcontroller.swd_clk ~ swd.clk.line +microcontroller.swd_dio ~ swd.dio.line +microcontroller.swd_swo ~ swd.swo.line +microcontroller.reset_n ~ swd.reset.line + +# Connect to debugger/programmer +debugger.swd ~ swd + +# Optional pullup resistors for robust operation +reset_pullup = new Resistor +reset_pullup.resistance = 10kohm +/- 5% +swd.reset.line ~> reset_pullup ~> power_3v3.hv + +# SWD is commonly used for ARM Cortex-M debugging and programming +``` + \ No newline at end of file diff --git a/atopile-0.14.x/api-reference/interfaces/uart.mdx b/atopile-0.14.x/api-reference/interfaces/uart.mdx new file mode 100644 index 0000000..b310b60 --- /dev/null +++ b/atopile-0.14.x/api-reference/interfaces/uart.mdx @@ -0,0 +1,115 @@ +--- + +title: "UART" +icon: right-left +description: "" +--- + + +## Interfaces + + + + + + + + + + + + + + + + + + + + + + + +## Global Attributes + + +These attributes are available to all modules and interfaces in a design. + + +Assign the LCSC ID of the module. + +If set, this will tell the picker to select that part from LCSC for this block. + + + + +This module's manufacturer name, as a string. + +Only exact matches on the manufacturer's name will be found by the picker. +It's recommended to fill this information based on what `ato create component` +provides. + + + + +This module's manufacturer part number, as a string. + +For the picker to select the correct part from the manufacturer, +this must be set. + + + + +The package of the module. + +This drives which components can be selected, and what footprint is used. + +Must exactly match a known package name. + + + + + + + +When set on an interface, this will override the net name of the interface. + +This is useful for renaming nets which are automatically generated. + + + + +Only for ModuleInterfaces. +If set to `True`, require that interface is connected to something outside +of the module it's defined in. + + + +```ato Basic Usage +import UART, ElectricPower + +uart = new UART +uart.base_uart.baud_rate = 115200 + +# Connect power reference for logic levels +power_3v3 = new ElectricPower +assert power_3v3.voltage within 3.3V +/- 5% +uart.base_uart.tx.reference ~ power_3v3 +uart.base_uart.rx.reference ~ power_3v3 +uart.rts.reference ~ power_3v3 +uart.cts.reference ~ power_3v3 + +# Connect to microcontroller +microcontroller.uart ~ uart + +# Connect to external UART device or RS232 transceiver +external_device.uart_rx ~ uart.base_uart.tx.line +external_device.uart_tx ~ uart.base_uart.rx.line + +# Hardware flow control (optional) +external_device.rts ~ uart.cts.line +external_device.cts ~ uart.rts.line + +# Common baud rates: 9600, 38400, 115200, 230400, 460800 +``` + \ No newline at end of file diff --git a/atopile-0.14.x/api-reference/interfaces/uart_base.mdx b/atopile-0.14.x/api-reference/interfaces/uart_base.mdx new file mode 100644 index 0000000..88121c5 --- /dev/null +++ b/atopile-0.14.x/api-reference/interfaces/uart_base.mdx @@ -0,0 +1,77 @@ +--- + +title: "UART_Base" +icon: right-left +description: "" +--- + + +## Parameters + + + + + +## Interfaces + + + + + + + + +## Global Attributes + + +These attributes are available to all modules and interfaces in a design. + + +Assign the LCSC ID of the module. + +If set, this will tell the picker to select that part from LCSC for this block. + + + + +This module's manufacturer name, as a string. + +Only exact matches on the manufacturer's name will be found by the picker. +It's recommended to fill this information based on what `ato create component` +provides. + + + + +This module's manufacturer part number, as a string. + +For the picker to select the correct part from the manufacturer, +this must be set. + + + + +The package of the module. + +This drives which components can be selected, and what footprint is used. + +Must exactly match a known package name. + + + + + + + +When set on an interface, this will override the net name of the interface. + +This is useful for renaming nets which are automatically generated. + + + + +Only for ModuleInterfaces. +If set to `True`, require that interface is connected to something outside +of the module it's defined in. + + diff --git a/atopile-0.14.x/api-reference/interfaces/usb2_0.mdx b/atopile-0.14.x/api-reference/interfaces/usb2_0.mdx new file mode 100644 index 0000000..02ebffc --- /dev/null +++ b/atopile-0.14.x/api-reference/interfaces/usb2_0.mdx @@ -0,0 +1,68 @@ +--- + +title: "USB2_0" +icon: right-left +description: "" +--- + + +## Interfaces + + + + + +## Global Attributes + + +These attributes are available to all modules and interfaces in a design. + + +Assign the LCSC ID of the module. + +If set, this will tell the picker to select that part from LCSC for this block. + + + + +This module's manufacturer name, as a string. + +Only exact matches on the manufacturer's name will be found by the picker. +It's recommended to fill this information based on what `ato create component` +provides. + + + + +This module's manufacturer part number, as a string. + +For the picker to select the correct part from the manufacturer, +this must be set. + + + + +The package of the module. + +This drives which components can be selected, and what footprint is used. + +Must exactly match a known package name. + + + + + + + +When set on an interface, this will override the net name of the interface. + +This is useful for renaming nets which are automatically generated. + + + + +Only for ModuleInterfaces. +If set to `True`, require that interface is connected to something outside +of the module it's defined in. + + diff --git a/atopile-0.14.x/api-reference/interfaces/usb2_0_if.mdx b/atopile-0.14.x/api-reference/interfaces/usb2_0_if.mdx new file mode 100644 index 0000000..2ebd0ab --- /dev/null +++ b/atopile-0.14.x/api-reference/interfaces/usb2_0_if.mdx @@ -0,0 +1,71 @@ +--- + +title: "USB2_0_IF" +icon: right-left +description: "" +--- + + +## Interfaces + + + + + + + + +## Global Attributes + + +These attributes are available to all modules and interfaces in a design. + + +Assign the LCSC ID of the module. + +If set, this will tell the picker to select that part from LCSC for this block. + + + + +This module's manufacturer name, as a string. + +Only exact matches on the manufacturer's name will be found by the picker. +It's recommended to fill this information based on what `ato create component` +provides. + + + + +This module's manufacturer part number, as a string. + +For the picker to select the correct part from the manufacturer, +this must be set. + + + + +The package of the module. + +This drives which components can be selected, and what footprint is used. + +Must exactly match a known package name. + + + + + + + +When set on an interface, this will override the net name of the interface. + +This is useful for renaming nets which are automatically generated. + + + + +Only for ModuleInterfaces. +If set to `True`, require that interface is connected to something outside +of the module it's defined in. + + diff --git a/atopile-0.14.x/api-reference/interfaces/usb3.mdx b/atopile-0.14.x/api-reference/interfaces/usb3.mdx new file mode 100644 index 0000000..33f9c6f --- /dev/null +++ b/atopile-0.14.x/api-reference/interfaces/usb3.mdx @@ -0,0 +1,68 @@ +--- + +title: "USB3" +icon: right-left +description: "" +--- + + +## Interfaces + + + + + +## Global Attributes + + +These attributes are available to all modules and interfaces in a design. + + +Assign the LCSC ID of the module. + +If set, this will tell the picker to select that part from LCSC for this block. + + + + +This module's manufacturer name, as a string. + +Only exact matches on the manufacturer's name will be found by the picker. +It's recommended to fill this information based on what `ato create component` +provides. + + + + +This module's manufacturer part number, as a string. + +For the picker to select the correct part from the manufacturer, +this must be set. + + + + +The package of the module. + +This drives which components can be selected, and what footprint is used. + +Must exactly match a known package name. + + + + + + + +When set on an interface, this will override the net name of the interface. + +This is useful for renaming nets which are automatically generated. + + + + +Only for ModuleInterfaces. +If set to `True`, require that interface is connected to something outside +of the module it's defined in. + + diff --git a/atopile-0.14.x/api-reference/interfaces/usb3_if.mdx b/atopile-0.14.x/api-reference/interfaces/usb3_if.mdx new file mode 100644 index 0000000..347b572 --- /dev/null +++ b/atopile-0.14.x/api-reference/interfaces/usb3_if.mdx @@ -0,0 +1,77 @@ +--- + +title: "USB3_IF" +icon: right-left +description: "" +--- + + +## Interfaces + + + + + + + + + + + + + + +## Global Attributes + + +These attributes are available to all modules and interfaces in a design. + + +Assign the LCSC ID of the module. + +If set, this will tell the picker to select that part from LCSC for this block. + + + + +This module's manufacturer name, as a string. + +Only exact matches on the manufacturer's name will be found by the picker. +It's recommended to fill this information based on what `ato create component` +provides. + + + + +This module's manufacturer part number, as a string. + +For the picker to select the correct part from the manufacturer, +this must be set. + + + + +The package of the module. + +This drives which components can be selected, and what footprint is used. + +Must exactly match a known package name. + + + + + + + +When set on an interface, this will override the net name of the interface. + +This is useful for renaming nets which are automatically generated. + + + + +Only for ModuleInterfaces. +If set to `True`, require that interface is connected to something outside +of the module it's defined in. + + diff --git a/atopile-0.14.x/api-reference/interfaces/usb_c.mdx b/atopile-0.14.x/api-reference/interfaces/usb_c.mdx new file mode 100644 index 0000000..9f26520 --- /dev/null +++ b/atopile-0.14.x/api-reference/interfaces/usb_c.mdx @@ -0,0 +1,119 @@ +--- + +title: "USB_C" +icon: right-left +description: "" +--- + + +## Interfaces + + + + + + + + + + + + + + + + + + + + + + + +## Global Attributes + + +These attributes are available to all modules and interfaces in a design. + + +Assign the LCSC ID of the module. + +If set, this will tell the picker to select that part from LCSC for this block. + + + + +This module's manufacturer name, as a string. + +Only exact matches on the manufacturer's name will be found by the picker. +It's recommended to fill this information based on what `ato create component` +provides. + + + + +This module's manufacturer part number, as a string. + +For the picker to select the correct part from the manufacturer, +this must be set. + + + + +The package of the module. + +This drives which components can be selected, and what footprint is used. + +Must exactly match a known package name. + + + + + + + +When set on an interface, this will override the net name of the interface. + +This is useful for renaming nets which are automatically generated. + + + + +Only for ModuleInterfaces. +If set to `True`, require that interface is connected to something outside +of the module it's defined in. + + + +```ato Basic Usage +import USB_C, ElectricPower, Resistor + +usb_c = new USB_C + +# Configure differential pair impedances +usb_c.rx.impedance = 90ohm +/- 10% +usb_c.tx.impedance = 90ohm +/- 10% +usb_c.usb3.usb2.dp.impedance = 90ohm +/- 10% +usb_c.usb3.usb2.dm.impedance = 90ohm +/- 10% + +# Connect power reference for logic levels +power_3v3 = new ElectricPower +assert power_3v3.voltage within 3.3V +/- 5% +usb_c.usb3.usb2.dp.p.reference ~ power_3v3 +usb_c.usb3.usb2.dp.n.reference ~ power_3v3 +usb_c.usb3.usb2.dm.p.reference ~ power_3v3 +usb_c.usb3.usb2.dm.n.reference ~ power_3v3 + +# CC resistors for device detection (5.1k for device, 56k for host) +cc1_resistor = new Resistor +cc2_resistor = new Resistor +cc1_resistor.resistance = 5.1kohm +/- 1% # Device +cc2_resistor.resistance = 5.1kohm +/- 1% # Device + +usb_c.cc1 ~> cc1_resistor ~> power_3v3.lv +usb_c.cc2 ~> cc2_resistor ~> power_3v3.lv + +# Connect to USB controller +usb_controller.usb_c ~ usb_c +``` + \ No newline at end of file diff --git a/atopile-0.14.x/api-reference/interfaces/xtalif.mdx b/atopile-0.14.x/api-reference/interfaces/xtalif.mdx new file mode 100644 index 0000000..3b9c9d9 --- /dev/null +++ b/atopile-0.14.x/api-reference/interfaces/xtalif.mdx @@ -0,0 +1,76 @@ +--- + +title: "XtalIF" +icon: right-left +description: " +TODO: Docstring describing your module +" +--- + + +## Interfaces + + + + + + + + + + + +## Global Attributes + + +These attributes are available to all modules and interfaces in a design. + + +Assign the LCSC ID of the module. + +If set, this will tell the picker to select that part from LCSC for this block. + + + + +This module's manufacturer name, as a string. + +Only exact matches on the manufacturer's name will be found by the picker. +It's recommended to fill this information based on what `ato create component` +provides. + + + + +This module's manufacturer part number, as a string. + +For the picker to select the correct part from the manufacturer, +this must be set. + + + + +The package of the module. + +This drives which components can be selected, and what footprint is used. + +Must exactly match a known package name. + + + + + + + +When set on an interface, this will override the net name of the interface. + +This is useful for renaming nets which are automatically generated. + + + + +Only for ModuleInterfaces. +If set to `True`, require that interface is connected to something outside +of the module it's defined in. + + diff --git a/atopile-0.14.x/api-reference/reference_instructions.md b/atopile-0.14.x/api-reference/reference_instructions.md new file mode 100644 index 0000000..8e5752a --- /dev/null +++ b/atopile-0.14.x/api-reference/reference_instructions.md @@ -0,0 +1,92 @@ +# Structure + +* The target codebase to be documented is atopile/src/faebryk/library +* Python script will parse the library and directly generate markdown for mintlify within atopile/docs repo + +# Example Page +--- +title: "Resistor" +api: "COMP /components/Resistor" +icon: "microchip" +description: "A resistor is a two-terminal electrical component." +--- + + +```ato Quick Example +module Example: + r1 = new Resistor + r1.resistance = 10kohm +/- 5% + r1.max_power = 0.125W + r1.max_voltage = 50V +``` + + +## Parameters + +The Resistor component has the following configurable parameters: + + + Resistance of resistor in Ohms. + + + + Maximum power dissipation rating in Watts. + + + + Maximum voltage rating in Volts. + + + +## Interfaces + +Connection points for the resistor: + + + Array of 2 Electrical connection points + + + +## Properties + +Convenience properties for accessing resistor terminals: + + + One side of the resistor. + + + + The other side of the resistor. + + + +## Traits + +The Resistor component automatically includes these traits: + +### pickable +Enables automatic part selection from the component database based on resistance, power, and voltage requirements. + +### can_bridge +Allows the resistor to be used in bridging connections with the `~>` operator for series connections. + +### simple_value_representation +Provides a simplified string representation showing key parameters for debugging and documentation. + +## Package Selection + +The resistor's package is automatically selected based on the power rating: +- **0402, 0603**: Up to 0.1W (1/10 watt) +- **0805**: Up to 0.125W (1/8 watt) +- **1206**: Up to 0.25W (1/4 watt) +- **1210, 2010**: Higher power ratings + +## Best Practices + +1. **Always use tolerances**: Real resistors have tolerances. Use `+/- 5%` for standard parts, `+/- 1%` for precision. + +2. **Power derating**: Choose power rating 2x higher than calculated dissipation for safety margin. + +3. **Standard values**: Use E12 series values (1.0, 1.2, 1.5, 1.8, 2.2, 2.7, 3.3, 3.9, 4.7, 5.6, 6.8, 8.2) for better availability. + +4. **Voltage rating**: Ensure max_voltage exceeds your circuit's maximum voltage. diff --git a/atopile-0.14.x/api-reference/traits/can_bridge_by_name.mdx b/atopile-0.14.x/api-reference/traits/can_bridge_by_name.mdx new file mode 100644 index 0000000..d220d24 --- /dev/null +++ b/atopile-0.14.x/api-reference/traits/can_bridge_by_name.mdx @@ -0,0 +1,18 @@ +--- + +title: "can_bridge_by_name" +icon: right-left +description: "" +--- + + +## Init Args + + + + + + + + + diff --git a/atopile-0.14.x/api-reference/traits/requires_pulls.mdx b/atopile-0.14.x/api-reference/traits/requires_pulls.mdx new file mode 100644 index 0000000..df0c541 --- /dev/null +++ b/atopile-0.14.x/api-reference/traits/requires_pulls.mdx @@ -0,0 +1,7 @@ +--- + +title: "requires_pulls" +icon: right-left +description: "" +--- + diff --git a/atopile-0.14.x/changelog.mdx b/atopile-0.14.x/changelog.mdx new file mode 100644 index 0000000..5ba5b0f --- /dev/null +++ b/atopile-0.14.x/changelog.mdx @@ -0,0 +1,189 @@ +--- +title: 'Change Log' +icon: 'rectangle-history' +--- + +{/* https://www.mintlify.com/docs/content/components/update */} + + + +This release features a complete rewrite of the atopile core, laying the foundation for faster builds and new language capabilities. The VSCode extension has a brand new UI for a more polished development experience, including a migration flow for upgrading from earlier versions, tightened project selection, and faster startup times. + +Windows support has been improved for 0.14.x compatibility. The extension also adds an "open ato shell" menu option and fixes for SSH port forwarding and GLB workflows. + +The CLI now has better `ato package verify` behavior with fixes for overly broad file globbing. The core compiler improves detection of duplicate and unused import statements. KiCad integration fixes ensure correct layer type handling in SEXP output. + +Under the hood, Python 3.14 compatibility has been addressed across the toolchain, including ABI fixes, pynng version pinning, and KiCad Dockerfile updates. + +**Full Changelog**: https://github.com/atopile/atopile/releases/tag/v0.14.0 + + + + + +LSP autocomplete is here! The language server now provides dot auto-complete suggestions, import suggestions, and "go to definition" navigation, making the editor experience significantly more productive. The VSCode extension is also less noisy with annoying popups removed. + +The build system has been rearchitected to model builds as a DAG of individual steps, improving reliability and fixing issues with extra build directories being generated for dependencies. + +A new `ato package verify` command helps validate packages before publishing. Package management is more robust with version fallback support, system cert store usage, and fixed authentication headers. + +Library improvements include support for parallel pull resistors in `requires_pulls` checks and hidden value text on the fab layer for cleaner board outputs. + +**Full Changelog**: https://github.com/atopile/atopile/releases/tag/v0.12.0 + + + + + +This release brings a major rewrite of the KiCAD plugin, making it easier than ever to apply layouts and interact with your designs directly from KiCAD with a single button. The Model Context Protocol (MCP) is now set up automatically, streamlining AI-assisted development workflows and package management. + +The atopile library and example projects have been thoroughly cleaned up, and the language now supports enums in template arguments, unlocking new design possibilities. The VSCode extension introduces a powerful 3D model viewer, making it simple to visualize your designs in three dimensions. + +Numerous bug fixes and small improvements enhance stability, performance, and the overall user experience across the CLI, library, and extension. For a complete list of changes and improvements, see the full changelog linked below. + +**Full Changelog**: https://github.com/atopile/atopile/releases/tag/v0.11.0 + + + + + +Massive VSCode extension improvements with embedded package browser, KiCanvas PCB viewer, and 3D model viewer with GLB export. Added Model Context Protocol (MCP) support enabling AI-assisted development workflows. + +Multi-net support for complex routing configurations. Enhanced component lifecycle management with better datasheet handling and footprint loading from dependencies. + +Significantly improved Windows support fixing symlink permissions, PosixPath errors, and KiCad plugin issues. Better package management with automatic dependency syncing. + +Deterministic builds with stable file hashing and consistent net naming. CLI improvements including telemetry, better DRC error messages, and detection of CI providers. + + + + + + +Introduced comprehensive component lifecycle management for tracking part availability and obsolescence. Added support for 3D models in packages with automatic model rebuilding. + +Language Server Protocol (LSP) improvements including hover information, definition navigation, and enhanced syntax highlighting in VSCode. + +Better error handling with improved logging and diagnostic messages. Fixed deterministic net naming and part selection issues. + +Enhanced CLI with better part import path display and archive folder for logs. + +## Upgrading + +Modules using `footprint =` will need to transition to parts. + + + + + +Major Language Server Protocol (LSP) upgrade providing real-time syntax and compile-time error reporting. VSCode extension refactored with auto-installation of atopile and enhanced syntax highlighting. + +Improved snippets and trailing comment support. Fixed KiCad file format issues including pad zone connections and dimension handling. + +Better development workflow with automatic rebuilding of editable packages when using `uv sync`. + + + + + +Extended atopile language capabilities with new syntax features. Enhanced I2C support with addressors for 1 and 2 bit implementations and isolated bus checking. + +Improved `ato create component` command to handle missing signals and numeric pin names. Better syntax error formatting in the CLI. + +Library updates including adjustable regulator improvements and bridgeable trait for regulators. + + + + + + +Added I2C Addressing & Bus viewer + +Build artifacts are now included when publishing. This means that when you go to https://packages.atopile.io/, you'll see the build artifacts ready to order or explore. + +Added `hide_designators` [config option](./reference/config#builds-hide-designators). + +Improved checks system with [new exclude capability](./reference/config#builds-exclude-checks) + +Disabled required check for top level modules + +Enhanced `ato create component` to handle pins named as numbers + +## Upgrading + +No required changes for upgrading. + + + + + +If the `.required` attribute is set `True` on an interface, that interface MUST be connected to from outside that module. +Take the example of a `LDO` - you reasonably MUST connect to the power input and outputs. +The antagonist concept to this is, like python, adding a `_leading_underscore` to private variables. + +`I2C` interfaces are now checked to ensure they have 900 to 100kΩ pullups on them. + +You can access lists and dicts (from stdlib/fabll) using square braces! + +(Beta) Windows support! `atopile` now runs on Windows. + +## Upgrading + +No required changes for upgrading. + + + + +atopile's package management system has had a huge upgrade! + +To find packages, check out the entirely overhauled [package index](https://packages.atopile.io). + +The new commands to packages are clearer and help keep the packages all in sync. See the updated [package guide](./essentials/4-packages). + +If you're looking to publish your own packages, [check out the guide](./guides/publish). + +## Upgrading + +- The `ato-version` field in your `ato.yaml` is now called `requires-atopile`. It remains a version spec, and we recommend that you set it to `^0.4.0`. +- The structure of dependencies has changed! It's best to remap them to the new registry using the `ato add` command. **Note:** Many of the package names have also changed. +- The `import` identifiers have also changed - to match the new project identifiers. Update these to `from "{package-identifier}/file.ato" import MyThing`. + + + + + +Firstly, thanks for using atopile! It's been a ride, and we're glad you're here. 🙌 + +### Changed Commands + +Add `--help` after any command to see new options in the CLI. This is always the most accurate source of information. + +| Old | New | +| ---------------------- | ---------------------- | +| `ato install --jlcpcb` | `ato create component` | + + +### I'm seeing a bunch of `DeprecationWarning` + +There will be a LOT of new deprecation warnings you'll see. + +For the most part, it's safe to ignore them for the minute, and we plan to make the breaking changes in 0.4.0 + +Upgrading will give you more access to features as they're added, but there's no need to rush if you're content. + +### PCBs are now directly modified + +This means no more need to open the PCB file, import the netlist and cycle. + +`ato build` now directly modifies the PCB file as required on each build. + + +### Standard Library (previously `generics`) is now shipped built-in! + +This vastly improves our ability to version and iterate on the standard library, use the best practices and latest features. + +See [`library`](https://github.com/atopile/atopile/tree/main/src/faebryk/library) for the latest and greatest. + +It should be better documented. If this is important for you, please vote on the [issue](https://github.com/atopile/atopile/issues/936). + + diff --git a/atopile-0.14.x/essentials/1-the-ato-language.mdx b/atopile-0.14.x/essentials/1-the-ato-language.mdx new file mode 100644 index 0000000..42611eb --- /dev/null +++ b/atopile-0.14.x/essentials/1-the-ato-language.mdx @@ -0,0 +1,168 @@ +--- +title: '1. `ato` Language' +description: "`ato` is a domain specific language (DSL) for describing electronic circuit boards. It's heavily inspired by, and attempts to follow the syntax of Python 🐍 for consistency and familiarity." +icon: 'atom' +--- + + +## Basic types + +The most basic types in `ato` are a `module` and an `interface`. + +An `Electrical` is a special built-in type of `interface` that represents a single [electrical](https://github.com/atopile/atopile/blob/main/src/faebryk/library/Electrical.py#L7) interface. + +A `component` is a subclass of a `module` that expects to represent a single physical component. + +You can also define your own types, in a similar way to defining a `class` in Python. +Like classes in most modern languages, you can subclass and inherit from blocks. + +```python +module SomeModule: + some_signal = new ElectricSignal + gnd = new Electrical + some_signal.reference.lv ~ gnd + some_variable = "some value" + +module SubclassedModule from SomeModule: + # inherits all the signals and variables from SomeModule + # we don't need to declare the signals again, + # but we will replace the value of some_variable + some_variable = "some other value" + +module Test: + gnd = new Electrical + # creates an instance of the SubclassedModule + subclassed_module = new SubclassedModule + # connects the some_signal of the SubclassedModule to the gnd of Test + subclassed_module.gnd ~ gnd +``` + + + You can subclass a `module` as a `component`, but not the other way around. A component is expected to represent a specific component. + + +## Configuring blocks + +Configuration of a `module` or `interface` is done by assigning to its attributes. + +```ato +some_instance.value = 100ohm +/- 10% +``` + +Unlike Python, you don't need to state `self.` Instead, any assignments you make within the scope of a block, are automatically assigned to the block. + +Built-in attributes influence the behavior of the compiler with respect to the block. + +Setting the `package` attribute, for example, makes the compiler select only components with the specified package to use in that component's slot. + +## Connecting it up + +Any `interface` can connect to any other interface of the same type using the `~` operator. + +```ato +some_signal ~ another +``` + +## Units and tolerances, assertions and maths + +Remember how NASA slung a rocket straight into Mars because of a metric/imperial error? + +Let's not do that again. + +### Units + +Resistors' resistances must be a resistance; whether `1.23Ω` (option+Z on macOS), `1.23ohm`, `4.56Kohm`, `7.89Mohm` or similar. + +Any attribute of any block may have a unit attached, written (without a space) after any number. + +Unsurprisingly, a capacitor's capacitance needs to be a capacitance (for example, `23.4uF`); other limits are in volts, amperes, degrees, and so on. + +Add units. + +### Tolerances + +Another unfamiliar first-class language feature when dealing with the physical world is the ability (and generally specification) +to spec tolerances for attributes. + +You could try to find a `10kΩ` resistor, but it probably won't exist - it'll likely be at least `10kΩ +/- 0.1%` (which you can write!). + +Tolerances can be written in the forms of: +- `1V to 2V` +- `3uF +/- 1uF` +- `4Kohm +/- 1%` + +These are hopefully sufficiently intuitive to not warrant further explanation 🤞 + + +### Units and Tolerances + +With Units and Tolerances together, physical attributes can be defined. + +Several legal ways exist to combine them. + +- `3V to 3.6V` perhaps for a supply rail +- `3V +/- 10mV` maybe for a reference +- `4.7uF +/- 20%` for a generic cap +- even `25lb +/- 200g` 🤣 + + +### Sweet, so now that all these values are around the place, what can be done with them? + +✨ **Maths** ✨ + +atopile does two things for you with these values: +1. Check that assertions about their relationships to one another are true +2. Solve systems of constraints based on these relationships to find component values + +This maths is all done including the units and tolerances, so you can be absolutely sure everything always works. + +Use the `assert` keyword to apply constraints on the values of attributes to one another. + +Supported operators are currently `<`, `>` and `within` (all are inclusive of the bounds). + +```atopile +a = 1 ± 0.1 +b = 2 ± 0.2 +c: resistance # variable declaration without assignment + +assert a < b # always true before 0.9 and 1.1 (the bounds of a) are both lower than the bounds of b (1.8 and 2.2) +assert a > b # always false --> Yields a failure at compile time +assert c within 1Kohm to 10Kohm # first solved for, then the solution is independently checked at the end of the build +``` + +Not sure about you, but this author (Matt) is not fond of working too hard. +Perhaps you've got a better method, but generally, when trying to find resistor values for something as simple as a voltage divider, one is guessed that seems approximately right, then the other is calculated—giving something that doesn't exist—before finally checking through a few other nearby options until finding a pair that works. + +This is fine and dandy as long as you only care about the ratio of a voltage divider, but as soon as the check for what that does for the regulator's output voltage is needed? Ugh, fine! What about the extremes of the tolerances on those resistors? Fine, it can be done once—but if someone goes to tweak those values for whatever reason, the author is unlikely to be pleased. + +Therefore, let atopile do it! + +atopile automatically solves systems of constraints for you with free variables, and checks that the values of attributes are within their tolerances. + +## Specialization + +The `->` operator will specialize a module from its existing instance to an instance of the type on the right-hand side. + +```ato +some_instance -> AnotherModuleType +``` + +This is useful for configuring a topology specified earlier. + +## Imports + +You can import assets by specifying what you want to import and where you want to import it from using the following syntax within your `.ato` files: + +`from "where.ato" import What, Why, Wow` + +Notes on that statement: +- Add quotes on the "where.ato"—it's a string. +- `What`, `Why`, and `Wow` are capitalized because they are in the source file. It has to match precisely—it's a type, and types should be capitalized, though this isn't enforced, and you can import things other than types from other files. + +The import statements are relative to the current project (the root of which is where your `ato.yaml` is), or within the standard library (`.ato/modules/`) + + + You'll likely see import statements in the form of `import XYZ from "abc.ato"`. This is a legacy syntax and will be removed in the future. Use the new syntax. + + It also doesn't support importing multiple things on the same line. + diff --git a/atopile-0.14.x/essentials/2-the-ato-compiler.mdx b/atopile-0.14.x/essentials/2-the-ato-compiler.mdx new file mode 100644 index 0000000..c053db2 --- /dev/null +++ b/atopile-0.14.x/essentials/2-the-ato-compiler.mdx @@ -0,0 +1,129 @@ +--- +title: '2. `ato` Compiler' +description: 'The `ato` command line interface is the main way to interact with atopile.' +icon: 'terminal' +--- + +The command-line tool has tools to: + +- Build your code to update your PCB +- Test your design +- Generate files to order your PCBs from manufacturers +- Install and manage dependencies +- Create new projects, components or build-targets + +There's a semi-de-facto standard format for running apps from the terminal, including `ato`. + +```sh +app command [options] arguments +``` + +1. `app` is the name of the app you're running. +2. `command` is the command; think of it as a "menu option" the app provides. +3. `options` are the options for the command, typically zero to many instances of `--some-option option-value`. +4. `arguments` are just like options, but they only take a value. Their position tells the app which argument they are. + + + Add `--help` to the app/command/subcommand to get more information at any point. + + + +## Command structure +Some commands might have subcommands. Think of it like a menu where, from left to right you're choosing deeper and deeper into the menu. + +If an upper command/app accepts options, those options should go right after the app/command, rather than at the end after subcommands. + +For example, `-v` is a special option, called a "flag," which doesn't take a value. Its presence or absence is what matters. It increases the amount of information the compiler prints -> increase its verbosity. + +The `-v` flag is an app option, so to use it, place it right after the app name. + +```sh +ato -v build + ``` + +## Build process + +As a rough overview, here's what happens when you run `ato build`: + +```mermaid +graph TD + A[Run ato build] --> B[Compiler looks for your ato.yaml] + B --> C["Compile the code, starting from the 'entry point'"] + code1[src/] -->|some_code.ato| C + code3[Dependencies] -->|dependency_code.ato| C + C -->|App - the model of your design| D[Solve equations] + D --> E[Pick components] + cloud[atopile server recommends components] --> E + E --> D + E -->|Picked all components| F[Run tests] + F --> G[Update PCB File] + G --> H[Generate Manufacturing Data] + G --> I[Generate Reports] + G --> J[Generate ... Target] +``` + +## Explaining the hello-world project + + + This tutorial continues from the [quickstart](../quickstart) guide. + + If you haven't already, complete it, and then come back here. + +With the explanation of `ato` code and the [build process](#build-process), it should be a little more clear what's happening now in the [quickstart](../quickstart) project. + + +import Ch1_0_Quickstart from '/snippets/examples/ch1_0_quickstart.mdx'; + + + + +Here's a breakdown: + + +1. Import a `Resistor` +2. Define a new `module`, named `App`. + This is the [**entry point**](../reference/config.md#builds.entry) of the build (see your `ato.yaml`). +3. Create an instance of the `Resistor` +4. Set the resistor's `value` attribute + This constrains what components the compiler can pick for this resistor. + For picking, the rated resistance must be wholly within the `value` attribute. The precise way to say this in more CS terms / what atopile says internally is that the picked resistor's resistance must be a subset of the quantity interval defined by the value attribute. + +## Extending it + +Suppose the circuit needs a simple voltage divider - and the standard library doesn't exist containing one pre-made and tested for you. + +It's easy to create your own! + +import Ch1_1_BadVoltageDivider from '/snippets/examples/ch1_1_bad_voltage_divider.mdx'; + + + +Now, this is, technically, a voltage divider. And the compiler happily builds it, grabbing the right components etc. + +But, it's not a good voltage divider. + +- There's no clear interface showing how to connect to it +- The point of a voltage divider is to scale voltage, but it's unclear what its scaling actually is +- No documentation describes what's going on + +To fix that: + +import Ch1_2_GoodVoltageDivider from '/snippets/examples/ch1_2_good_voltage_divider.mdx'; + + + +Much better! This is a better approach. + +Here's a breakdown: + +1. When possible, import from the standard library. +2. Define a new `module`, named `VoltageDivider` + This means you can trivially have as many `VoltageDivider`s as you want, all configured properly with all the same interfaces. +3. Document with `"""` +4. Place external interfaces somewhere obvious + Use sensible types, like `Power` to expose them. +5. Embed the relationships between parameters with `assert` + Read these statements as "make sure the following is true." + 1. The output voltage is within the range of the voltage divider ratio equation + 2. The input voltage must be greater than the output voltage + 3. The current through the bottom resistor must be within the allowed range of the maximum quiescent current diff --git a/atopile-0.14.x/essentials/3-add-component.mdx b/atopile-0.14.x/essentials/3-add-component.mdx new file mode 100644 index 0000000..3b649f2 --- /dev/null +++ b/atopile-0.14.x/essentials/3-add-component.mdx @@ -0,0 +1,130 @@ +--- +title: '3. Add a component' +description: 'Four different methods exist for adding components to a project.' +icon: 'plus' +--- + +## 1) Auto pick passive components + +The simplest way to add components is to let atopile pick them for you. This works for passive components such as +[resistors](../api-reference/components/resistor), [capacitors](../api-reference/components/capacitor), and [inductors](../api-reference/components/inductor). + +For example, let's say you need a 10kΩ resistor with 1% tolerance in an 0402 package: +```ato +resistor = new Resistor +resistor.resistance = 10kohm +/- 5% +resistor.package = "0402" +``` +When you build your project, atopile will automatically select a resistor that meets your requirements from the JLCPCB parts library. + +## 2) Add specific component + +The embedded `ato create part` CLI tool fetches a part and adds the pinout, footprint, and 3D model to your project. + +```bash +ato create part +``` + +You'll be prompted for a search term for a component. This may be: + + - A JLCPCB part number (for example `C7426`) + - An **exact** manufacturer part number (for example `NE5532DR`) + +Enter `C7426` and press enter. + + + ato create component search prompt + + +Go ahead and tap `Enter` through the default options. + +## The new `component` + +```ato +#pragma experiment("TRAITS") +import has_datasheet_defined +import has_designator_prefix +import has_part_picked +import is_atomic_part +import is_auto_generated + +component Texas_Instruments_NE5532DR_package: + """Dual Low-Noise High-Speed Audio Operational Amplifier, 10 to 30 V, 0 to 70 degC, 8-pin SOIC (D8), Green (RoHS no SbBr)""" + + # This trait marks this file as auto-generated + # If you want to manually change it, remove the trait + trait is_auto_generated + + trait is_atomic_part + trait has_part_picked::by_supplier + trait has_designator_prefix + trait has_datasheet_defined + + # pins + signal IN1neg ~ pin 2 + signal IN1pos ~ pin 3 + signal IN2neg ~ pin 6 + signal IN2pos ~ pin 5 + signal OUT1 ~ pin 1 + signal OUT2 ~ pin 7 + signal VCC_GND ~ pin 4 + signal VCCpos ~ pin 8 + +``` + +Let's break it down. + +The `component` keyword tells the compiler that a new component class is being specified, which is a subclass of `module`. + +The `has_part_picked` trait tells the compiler it can pick that JLCPCB part to fill this spot. +The `manufacturer` and `mpn` attributes together fully specify which component this is as well. +If you're making a component class for a specific component, it's typically a good idea to include at least either the `lcsc_id` or the `mpn` + `manufacturer`. + +The `is_atomic_part` trait tells the compiler that this component represents a physical part that can be placed on a PCB. The trait takes several important attributes including the manufacturer and partnumber (MPN) of the part, along with the KiCad footprint and symbol files and 3D model (STEP) file to use for rendering the part. + + +The `datasheet_url` and `designator_prefix` attributes are optional, but it's a good idea to include them. They're self-explanatory. + +### `pin` + +Use the `pin` keyword to define electrical interfaces, which the compiler maps to pads on the footprint. + +That is, `pin 2` says: + +- Create a signal named `2` (the compiler treats pins as a special-case where they may have an integer name) +- Connect the signal to pad "2" on the footprint + +## 3) Use a package from the registry + +The [atopile package registry](https://packages.atopile.io) contains many pre-made [packages](./4-packages) for common components. For example, if you need an RP2040 microcontroller, you can install the package: + +```bash +ato add atopile/rp2040 +``` +## 4) Create custom part + +For parts not available through `ato create part`, you can manually add components to your parts directory. + +1) Create a new folder to your parts directory `project/parts/` named the same as your component. +2) Add existing KiCad footprint and 3D model to parts directory, or use KiCad's footprint editor to create a new footprint. +3) Create a .ato file in this folder with the same name as your component. + +## Good practice + +Here are a few recommended tweaks to your component class: + +### Abstract classes + +When you're creating a class representing a specific component, for which there's a generic abstract class (for example, an `LDO`), import and subclass that abstract class to get its generic methods and attributes. + +For example, you should update the component class like this: + +```ato +component Texas_Instruments_NE5532DR from LDO: +``` + +Then, connect its pins to the LDO's signals, set known attributes etc... + +### Take the `mpn` and `manufacturer` from `ato create component` + +`mpn` and `manufacturer` are only interpreted properly if they exactly match a component in the database. diff --git a/atopile-0.14.x/essentials/4-packages.mdx b/atopile-0.14.x/essentials/4-packages.mdx new file mode 100644 index 0000000..61134e2 --- /dev/null +++ b/atopile-0.14.x/essentials/4-packages.mdx @@ -0,0 +1,83 @@ +--- +title: '4. Packages' +#description: "One of the key benefits of designing circuit boards with code is that it unlocks modularity. As in software, this modularity means you can package up and reuse modules others have developed and tested." +icon: 'cubes' +--- + +One of the key benefits of designing circuit boards with code is that it unlocks modularity. As in software, this modularity means you can package up and reuse modules others have developed and tested. + +## Finding packages + +Check [first-party packages](https://packages.atopile.io/) for a list designed and used internally at atopile. Discussion planning to open this up publicly +These are built, known to work and come with a functioning layout too. + +Also, Google is your friend. Packages are often publicly available on github or other repositories. + +## Using packages + +First, add the package dependency to your project with `ato add` + +```bash +ato add atopile/ti-ads1115 +``` +```ato +from "ti-ads1115.ato" import TI_ADS1115 + +module ExampleADCProject + adc = new TI_ADS1115 +``` + +After building your project, use the [KiCad plugins](./6-layout#start-with-existing-packages) to pull the layout from the package. + + + +## Managing dependencies + +Dependencies of your project can be found in the project/ato.yaml file. + +```ato +dependencies: + - type: registry + identifier: atopile/buttons + release: 0.2.2 + - type: registry + identifier: atopile/ti-ads1115 + release: 0.1.6 +``` + +You can manage dependencies using three commands: `ato add`, `ato sync` and `ato remove`. + +All dependency commands keep your installed packages in sync automatically, so you don't need to think too much about managing environments. + +Here are the key commands: + +### `ato sync` +Installs all dependencies listed in `ato.yaml`. Run this when you pull a new project. Dependencies are cached in project/.ato directory + +### `ato add {package}` +Adds a new package dependency to your project: +- Adds the package to `ato.yaml` +- Installs the package locally +- Syncs all dependencies + +### `ato remove {package}` +Removes a package dependency from your project: +- Removes the package from `ato.yaml` +- Removes the package locally +- Syncs remaining dependencies + + + atopile manages dependencies in a similar way to [uv](https://docs.astral.sh/uv/). If you know how that works, think about it in the same way! + + +## Development dependencies + +You can install dependencies from git: + +`ato add git://{git-url}` + +or from a local directory: + +`ato add file://./path/to/package` + +Importantly, you cannot publish a package that depends on unpublished packages. diff --git a/atopile-0.14.x/essentials/5-project-structure.mdx b/atopile-0.14.x/essentials/5-project-structure.mdx new file mode 100644 index 0000000..a4cbbd1 --- /dev/null +++ b/atopile-0.14.x/essentials/5-project-structure.mdx @@ -0,0 +1,82 @@ +--- +title: '5. Project Structure' +#description: "One of the key benefits of designing circuit boards with code is that it unlocks modularity. As in software, this modularity means you can package up and reuse modules others have developed and tested." +icon: 'list-tree' +--- + + +A well-organised folder structure makes it easy to navigate, build and publish atopile projects. This page walks through the **recommended structure** for both everyday projects and reusable packages. + +## 1. High–level layout + +```text +/ + ├─ .ato/ # Cached dependencies + ├─ build/ # Build outputs + ├─ ato.yaml # Project manifest (paths, builds, dependencies) + ├─ elec/ # Electrical files and layouts + ├── layouts/ # Board layout files + ├── src/ # Core ato code and parts + ├─── .ato # Main project file + ├─── parts/ # Part info (pinout, footprint, 3d model) +``` + +* **ato.yaml**–the central manifest read by the compiler and package manager. +* **src/**–pure ato source; keep one module per file where possible. +* **layout/**–KiCad footprints, STEP models or manual board tweaks. + +## 2. The `ato.yaml` manifest + +The manifest glues everything together. A minimal example: + +```yaml +requires-atopile: "^0.10.8" + +paths: + src: ./src + layout: ./layout + +builds: + default: # The target you usually build + entry: main.ato:App + hide_designators: true + exclude_checks: ["PCB.requires_drc_check"] + +dependencies: # Added automatically by `ato add` + - type: registry + identifier: atopile/ti-ads1115 + release: 0.1.6 +``` + +* **paths**–lets you move `src/` or `layout/` somewhere else if needed. +* **builds**–define one or more build targets (for example: default, panelized, test-jig). +* **dependencies**–registry, git or local packages installed with `ato add`. + +## 3. A typical workflow + +1. Sketch your circuit on paper. +2. Search https://packages.atopile.io and GitHub for pre-existing modules you need, and use `ato add` to install them. +3. Design a module and do its calculations using `ato` code. +4. Run `ato build` to compile your project, choose components to suit your design, and update your layout (PCB) file. +5. Use KiCAD to lay out any changes +6. Repeat steps 3-5 until you're happy with your design. +7. When you're done with your design, push your changes to your repo. +8. CI will automatically build and test your project, and generate the manufacturing files you need to order your PCBs. +9. Take these manufacturing files to your PCB manufacturer to get your PCBAs. + +```mermaid +graph TB + A[Sketch] --> AA['ato create project']; + AA --> BB[Pick a module]; + BB --> B{Package exists?}; + B -->|Yes| C['ato add']; + B -->|No| CC['ato create component' and Design it!]; + C --> D[Hook it up]; + CC --> D; + D --> E['ato build']; + E --> F[Layout using KiCAD]; + F --> G{More modules to do?}; + G -->|Yes| BB; + G -->|No| H[Download gerbers from CI]; + H --> I[Order PCBs from manufacturer]; +``` \ No newline at end of file diff --git a/atopile-0.14.x/essentials/6-layout.mdx b/atopile-0.14.x/essentials/6-layout.mdx new file mode 100644 index 0000000..0d23eb6 --- /dev/null +++ b/atopile-0.14.x/essentials/6-layout.mdx @@ -0,0 +1,70 @@ +--- +title: '6. Layout' +#description: "`ato` code defines the function of the circuit via the connections between elements. Unlike a software compiler, these components all need to end up placed somewhere and copper traces need routing between the elements for the circuit to function." +icon: 'arrows-split-up-and-left' +--- + +`ato` code defines the function of the circuit via the connections between elements. Unlike a software compiler, these components all need to end up placed somewhere and copper traces need routing between the elements for the circuit to function. + +This process is typically called "layout." + +atopile uses [KiCad](https://kicad.org), the premier open source electronics design package for layout. + +## Opening KiCad + +When you run `ato build`, `ato` generates a KiCad project file for you. If you're only building a single build-target, `ato` will open the KiCAD file for you. + +## KiCad plugin + +The `ato` compiler automatically installs a KiCad plugin to help you with layout. This saves a lot of time. + +The plugin installs automatically when you run the `ato` command-line tool, but in case something went wrong, you can re-trigger the installation by running `ato configure`. + +## Start with existing packages + +If you import the `rp2040` module installed in the [previous section](./4-packages), you can reuse its layout. + +```ato +from "rp2040/RP2040Kit.ato" import RP2040Kit + +module App: + uc = new RP2040Kit + # Note: I've emptied this module out for brevity. + # You can decide whether you want to keep the demo voltage divider or not. + +``` + +To reuse a layout from a package: + +- run an `ato build`, to make sure the layout syncs with the code +- hit the "Sync Group" button in the KiCad plugin +- select the group you want to sync, and hit the "Pull" (Down arrow) button to pull the layout from the module's KiCad layout file + + + + + The `ato` compiler will map layouts with a **class or super-class** that **has a build**. + + The `RP2040Kit` in the example is the class, and the `ato.yaml` config file in the `rp2040` package means that there's a layout associated with it. + + If you want to create a reusable layout for a class of your own, the easiest way is to add a new build config with `ato create build`, and then point the newly created [entry](../reference/config.md#builds.entry) at the module you've made. + + + If the plugin is not available in KiCad, try running `ato configure` to set it up + + +## Layout the rest of your design + +Use KiCad to place-and-route the rest of your design, just like if you got it from the schematic editor. + +If you can't find the quality of KiCad docs you need to get started, drop a comment or upvote on this GitHub Issue !882 + + +## Auto-layout 🚀 + +atopile can do small bits of auto-layout for you, but it's not fully exposed to `ato` yet. + +If this is a feature that'd super-charge your workflow, please come vote and discuss it in the [GitHub Discussion](https://github.com/atopile/atopile/discussions/881). diff --git a/atopile-0.14.x/essentials/7-saving-your-work.mdx b/atopile-0.14.x/essentials/7-saving-your-work.mdx new file mode 100644 index 0000000..2e959b1 --- /dev/null +++ b/atopile-0.14.x/essentials/7-saving-your-work.mdx @@ -0,0 +1,73 @@ +--- +title: '7. Saving Your Work' +description: 'atopile strongly recommends using `git` for version control.' +icon: 'github' +--- + +atopile strongly recommends using `git` for version control. + +## Committing + +1. Survey what you've done: `git status` +2. Add the files you want to associate with this commit `git add ` + + + You can add multiple files at once by running `git add ` + + You can also add all files in a directory by running `git add ` + + This includes the current directory if you use `git add .` — but be careful! This is often a trap, and you end up adding a lot of unrelated files. At the start of a project, however, it often makes sense. + + +3. Sanity check: `git status`. It'll tell you all the files you've got staged (ready to commit) + +4. Commit your changes: `git commit -m "Add the RP2040 module"`. Commit messages should describe the changes you've made and why. + +5. Push your changes up to GitHub: `git push` + + + If you're on a branch other than `main`, the response from GitHub gives you a link to the pull request. + + Cmd+Click on Mac, Ctrl+Click on Windows to open the link in your browser. + + +## Up on GitHub + +A few paths exist to contribute back to a repository. + +If you have permissions to push directly to the repo, by far the easiest way to update it is to contribute directly. + +As your project progresses and stabilizes, you typically want to create a new branch and pull request (PR) for each change you're making, even if you're working alone. + + +### Directly to `main` + +If you're right at the start of your project, you might want to push straight to `main`. This is fast and dirty. All you need to do is: + +1. Commit your changes: `git commit -m "Add the RP2040 module"` +2. Push your changes up to GitHub: `git push` + +They'll be up on `main` + + +### Create a branch and pull request + +For a more controlled development process, especially as your project grows, it's best practice to work on feature branches and create pull requests. Here are some recommendations: + +- Use descriptive branch names, like `feature/add-bluetooth-support` or `bugfix/fix-routing-error`. +- Keep your commits focused and well-documented. Write clear commit messages that explain the "why" behind a change, not just the "what." +- When you open a pull request, include a detailed description of the change, the rationale behind it, and steps for testing. +- If your repository is set up with [`Continuous Integration`](#continuous-integration), ensure that all tests pass before merging your PR. +- Request code reviews from your team. Peer reviews help catch potential issues early and improve code quality. + +### Continuous Integration (CI) + +atopile's project template includes basic CI workflows to check your design, build manufacturing data you can order with, and run testing. + +It builds in CI as a `frozen` project, meaning it tries its hardest to rebuild your design exactly as it stands, with the exact same parts and layout. When it can't - whether because your source code has changes and the components no longer meet the design, or because the layout is out of date - it fails the build. + +Additionally, CI runs to build all targets, which means it also produces the gerber files to order your PCBs. + + + Consistent use of pull requests and CI pipelines not only improves code quality but also fosters better team collaboration. Keep your `main` branch in a deployable state by merging only after successful CI runs. + diff --git a/atopile-0.14.x/essentials/8-traits.mdx b/atopile-0.14.x/essentials/8-traits.mdx new file mode 100644 index 0000000..ebd40fa --- /dev/null +++ b/atopile-0.14.x/essentials/8-traits.mdx @@ -0,0 +1,130 @@ +--- +title: '8. Traits' +description: 'Traits are a way to extend the functionality of a module.' +icon: 'at' +--- + +# Traits + +Currently the following traits are supported: + +## can_bridge_by_name + +This trait enables using the [sperm operator `~>`](./1-the-ato-language) to make a "bridging" connection over a module. + +For example: + +```ato +module BridgableModule: + """ + Module that can be bridged + """ + input = new ElectricLogic + output = new ElectricLogic + + trait can_bridge_by_name + +module MainModule: + bridgable_module_a = new BridgableModule + bridgable_module_b = new BridgableModule + + input_signal = new ElectricLogic + output_signal = new ElectricLogic + + input_signal ~> bridgable_module_a ~> bridgable_module_b ~> output_signal +``` + +The default input_name and output_name are `input` and `output` respectively, but you can use any name of any interface you want. + +It is even possible to bridge with different interface types, as long as they match the interface type in the other side of the connection. + +```ato +module BridgableModule: + """ + Module that can be bridged with a different interface type + """ + input = new ElectricLogic + output = new I2C + + trait can_bridge_by_name + +module MainModule: + bridgable_module = new BridgableModule + + input_signal = new ElectricLogic + output_signal = new I2C + + input_signal ~> bridgable_module ~> output_signal +``` + + +Import with: + +```ato +#pragma experiment("MODULE_TEMPLATING") +#pragma experiment("BRIDGE_CONNECT") +#pragma experiment("TRAITS") +import can_bridge_by_name +``` + + +## has_single_electric_reference_shared + +This trait is very useful to connect all the electric references within the module together. + +Instead of doing this: + +```ato +module SomeModule: + logic_a = new ElectricLogic + logic_b = new ElectricLogic + power = new ElectricPower + + power ~ logic_a.reference + power ~ logic_b.reference +``` + +You can do this: + +```ato +module SomeModule: + """ + Module with 1 single reference power rail: + - power is connected to logic_a.reference and logic_b.reference + """ + logic_a = new ElectricLogic + logic_b = new ElectricLogic + power = new ElectricPower + + trait has_single_electric_reference_shared +``` + +if you only want to connect the lv (gnd) of the references together, you can do this: + +```ato +module SomeModule: + """ + Module with 3 different reference power rails: + - logic_a.reference/power_a + - logic_b.reference + - power_c + """ + logic_a = new ElectricLogic + logic_b = new ElectricLogic + power_a = new ElectricPower + power_c = new ElectricPower + + logic_a.reference ~ power_a + + trait has_single_electric_reference_shared +``` + + +Import with: + +```ato +#pragma experiment("MODULE_TEMPLATING") +#pragma experiment("TRAITS") +import has_single_electric_reference_shared +``` + diff --git a/atopile-0.14.x/essentials/assets/5-pcb-layout-sync.gif b/atopile-0.14.x/essentials/assets/5-pcb-layout-sync.gif new file mode 100644 index 0000000..151cc73 Binary files /dev/null and b/atopile-0.14.x/essentials/assets/5-pcb-layout-sync.gif differ diff --git a/atopile-0.14.x/essentials/assets/5-pcb-layout-sync.mp4 b/atopile-0.14.x/essentials/assets/5-pcb-layout-sync.mp4 new file mode 100644 index 0000000..4ac00f3 Binary files /dev/null and b/atopile-0.14.x/essentials/assets/5-pcb-layout-sync.mp4 differ diff --git a/atopile-0.14.x/essentials/assets/ato-create-component-search.png b/atopile-0.14.x/essentials/assets/ato-create-component-search.png new file mode 100644 index 0000000..a1d877d Binary files /dev/null and b/atopile-0.14.x/essentials/assets/ato-create-component-search.png differ diff --git a/atopile-0.14.x/essentials/assets/download.png b/atopile-0.14.x/essentials/assets/download.png new file mode 100644 index 0000000..62bfe5b Binary files /dev/null and b/atopile-0.14.x/essentials/assets/download.png differ diff --git a/atopile-0.14.x/essentials/assets/reload.png b/atopile-0.14.x/essentials/assets/reload.png new file mode 100644 index 0000000..5ba31c5 Binary files /dev/null and b/atopile-0.14.x/essentials/assets/reload.png differ diff --git a/atopile-0.14.x/guides/development.mdx b/atopile-0.14.x/guides/development.mdx new file mode 100644 index 0000000..a02c595 --- /dev/null +++ b/atopile-0.14.x/guides/development.mdx @@ -0,0 +1,39 @@ +--- +title: 'Development' +description: 'How to set up your development environment for atopile.' +icon: 'wrench' +--- + +## Prerequisites + +- [Editable atopile install](../quickstart/1-installation) + +## Dev tools + +VSCode is recommended for development. If nothing else, it has heaps of high quality extensions and atopile language support, plus it's used internally - making it easier to configure for purpose. + +You should have at a minimum: +- [Cursor](https://www.cursor.com/) or [VSCode](https://code.visualstudio.com) +- [Cursor / VSCode atopile extension](https://marketplace.visualstudio.com/items?itemName=atopile.atopile) (also works for Cursor) + +### Verbosity + +You can increase the verbosity of atopile by using the `-v`, `-vv` or `-vvv` flags, for example `ato -vv build` + + + Flags are placed after the `ato` command and before the command you want to run. For example, `ato -vv build` runs the build command with the verbose flag set to the highest level, while `ato build -vv` will not work. + + +### Debugging + +You can start the command-line tool in debug mode by using the `--debug` flag, for example `ato --debug build` + +This runs a [`debugpy`](https://github.com/microsoft/debugpy) server on port `5678` which you can connect to with the VSCode built-in debugger. + + + connect debugger + + + + If you're having trouble with syntax highlighting in the debugger, it might be because VSCode sets up a mapping between the remote and local file paths by default—remove it. + diff --git a/atopile-0.14.x/guides/fabll.mdx b/atopile-0.14.x/guides/fabll.mdx new file mode 100644 index 0000000..a3db937 --- /dev/null +++ b/atopile-0.14.x/guides/fabll.mdx @@ -0,0 +1,30 @@ +--- +title: 'fabll (python)' +description: fabll is atopile's Python framework for modeling circuits. +icon: 'python' +--- + + +`fabll` is a Python framework to model circuits, much like `ato`. It unlocks the whole Turing-complete power of Python to do design in, plus low-level procedural code and logic. Think of it like writing C for a Python module. Its focus is power—not ease of use like `ato`—so it's not recommended for most designs to start with. + + + `fabll` is currently in a very early stage of development. It's not publicly supported yet. + + +## Disambiguation: `fabll` vs `ato` +Think of it like the difference between C (fabll) and JavaScript (ato). +fabll is for really complicated modular building block modules, while ato is better for most of the composition and simple modules. + +## Building `fabll` code + +To build a `fabll` module with atopile, you just need to point to the module within your `ato.yaml` configuration file. + +When you run `ato build`, atopile automatically builds the `fabll` module and links it to your project. + +## Importing `fabll` code + +You can just import `fabll` modules in `ato` like any other import: + +```python +from "path/to/some/fabll.py" import SomeModule +``` diff --git a/atopile-0.14.x/guides/faebryk.mdx b/atopile-0.14.x/guides/faebryk.mdx new file mode 100644 index 0000000..39e4744 --- /dev/null +++ b/atopile-0.14.x/guides/faebryk.mdx @@ -0,0 +1,13 @@ +--- +title: 'faebryk' +description: faebryk is atopile's kernel. It's the way the world is modeled. +icon: 'brain' +--- + +# Disambiguation: `faebryk` vs `fabll` 🐍 + +`faebryk` is atopile's core. It's the way the world is modeled. + +`faebryk` is a Python module that uses a powerful and efficient core graph (nodes + edges) to represent every relationship in your design or circuit. + +`fabll` is a Python framework to model circuits in, much like `ato` it acts as a language in the atopile ecosystem. It unlocks the whole power and ecosystem of Python to do design in. diff --git a/atopile-0.14.x/guides/git.mdx b/atopile-0.14.x/guides/git.mdx new file mode 100644 index 0000000..b3b8154 --- /dev/null +++ b/atopile-0.14.x/guides/git.mdx @@ -0,0 +1,54 @@ +--- +title: 'git' +description: 'Using `git` for Hardware' +icon: 'git-alt' +--- + +`git` is a powerful way to version control your design and one of the key reasons atopile was started. If you don't know about `git`, learning it is strongly recommended. It's highly likely you'll end up loving it. + +## Basic usage + +```sh +git clone +git checkout -b +git add +git commit -m "This commits adds an LED indicator..." +git push -u origin HEAD +``` + +## Workflow overview + +`git` is the de facto standard for version control in software development. For people who haven't used it before, it's worth explaining a few terms and the workflow: + +| Term | Definition | +| --- | --- | +| "Repo" or Repository | A collection of files and directories that are version controlled together. | +| Branch | A "branch" is an isolated space for your changes. | +| Commit | A "commit" is a snapshot of some changes at that place in time. | +| Push | A "push" is sending your changes to the remote repo. | +| Pull Request | A "pull request" is a request to merge your changes into the main branch. This is the time to review and test your changes with others on your team. | + +```mermaid +flowchart TD + AA[Find a project you want to work on on GitHub] --> A[**Clone** a copy of the repo to your computer] + AB[Create a new project on GitHub] --> A + A --> B["Create an isolated space (or **branch**) for your changes"] + B --> C[Do some work ⛏️] + C --> D[Check the **status** of your changes] + D --> E[**Stage** the changes for one topic] + E --> F[**Commit** the changes with a message explaining what you did] + F -->|More work to do on this topic| D + F -->|Ready for review| H[**Push** your branch to the **remote** repo on GitHub] + H --> I[Create **Pull Request** on GitHub] + I --> II["Continuous Integration (**CI**) runs tests and ensures your project still builds after your updates"] + II -->|Tests pass| J[**Review** all the changes] + II -->|Tests fail| D + J -->|Changes requested in review| D + J -->|Approved| K[**Merge** to main] + K --> L[Your changes are now combined with the work of everyone else on the project] +``` + +## More resources + +- https://github.com/git-guides +- https://git-scm.com/docs/gittutorial diff --git a/atopile-0.14.x/guides/images/debugger-vscode.png b/atopile-0.14.x/guides/images/debugger-vscode.png new file mode 100644 index 0000000..79acd50 Binary files /dev/null and b/atopile-0.14.x/guides/images/debugger-vscode.png differ diff --git a/atopile-0.14.x/guides/publish.mdx b/atopile-0.14.x/guides/publish.mdx new file mode 100644 index 0000000..0560049 --- /dev/null +++ b/atopile-0.14.x/guides/publish.mdx @@ -0,0 +1,236 @@ +--- +title: Publishing Packages +description: Standing on the shoulders of giants +icon: ship +--- + +You've made something great and you want to share it. Awesome! 🥳 🙌 + +The best way to do this is to publish it to the [public atopile registry](https://packages.atopile.io), where it becomes available to everyone to embed in their projects. + + + + Packages need some additional metadata in their `ato.yaml` config to explain what they are, their version and to give you credit. + + + Install and configure our `atopile/publish-package` action. + + + The action will automatically package and publish your project whenever you're ready! + + + + +You can structure your project in two common ways. Keep an eye out for the notes on each, as they'll affect your workflow slightly +1. A **single package** in the repo, like [nonos](https://github.com/atopile/nonos). +2. A **monorepo** with multiple separate packages, like [packages](https://github.com/atopile/packages). This is common when you're a larger org, and have a lot to share. +{/* 3. A project with multiple **sub-packages**, like [HiL](https://github.com/atopile/hil). This is common when you design something, and then later realise some part of it is useful on its own. */} + +## Making good packages + + +Documentation goes a long way to smooth setup! A useful summary helps, but a `README.md` is even better. + +The package index automatically detects your `README.md`, and will display the it for you. + + + Currently, the package index doesn't support image uploads. If you want this, check out https://github.com/atopile/atopile/issues/1156 + + +## Package Metadata + +Here's an example of some package metadata. Copying this, and updating it with your own information is a good place to start. + +**The first section of the identifier must be your GitHub username or organization name.** This is enforced on upload. + + + + Recommendations: + - Name the repo the same as the package. + - Version the package with releases, and use the tag as the version. + + ```yaml ato.yaml + package: + identifier: atopile/some-package + repository: https://github.com/atopile/some-package + authors: + - name: Pepper + email: pepper@atopile.io + - name: Narayan + email: naraya@atopile.io + summary: Lorem ipsum dolor sit amet, consectetur adipiscing elit. + license: MIT + homepage: https://github.com/atopile/some-package + ``` + + {/* + Recommendations: + - Name the package the same as the repo + - Version the package with releases, and use the tag as the version. + + ```yaml + package: + identifier: atopile/some-project + repository: https://github.com/atopile/some-project + authors: + - name: Pepper + email: pepper@atopile.io + - name: Narayan + email: naraya@atopile.io + summary: Lorem ipsum dolor sit amet, consectetur adipiscing elit. + license: MIT + homepage: https://github.com/atopile/some-project + + ``` + */} + + Recommendations: + - Create a separate atopile project for each package + - Version the packages with a version in their own `ato.yaml` config + + ```yaml packages/some-package/ato.yaml + package: + identifier: atopile/some-package + repository: https://github.com/atopile/packages + version: "0.1.0" + authors: + - name: Pepper + email: pepper@atopile.io + - name: Narayan + email: naraya@atopile.io + summary: Lorem ipsum dolor sit amet, consectetur adipiscing elit. + license: MIT + homepage: https://github.com/atopile/packages + ``` + + + +Check [below](#package-metadata-2) for more details on the fields. + +## Configuring your publish workflow + +Publishing is currently supported exclusively through the [atopile/publish-package](https://github.com/atopile/publish-package) action. + + + The reason only GitHub is supported at the moment is because we only currently support [GitHub OIDC tokens](https://github.com/atopile/fastapi-github-oidc) for authorization. + + + +Whichever workflow you use, you'll need to add the [GitHub OIDC permissions](https://docs.github.com/en/actions/security-for-github-actions/security-hardening-your-deployments/about-security-hardening-with-openid-connect) to the workflow: + +```yaml +permissions: + contents: write + packages: write +``` + + + + + Recommendations: + - Name the repo the same as the package. + - Version the package with releases, and use the tag as the version. + + ```yaml + on: + release: + types: [created] + + jobs: + release: + if: github.event.release.draft != true && github.event.release.prerelease != true + permissions: + contents: write + packages: write + + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v4 + - uses: atopile/publish-package@main + ``` + + + Recommendations: + - Create a separate atopile project for each package + - Version the packages with a version in their own `ato.yaml` config + - Use the `package-entrypoint` input to specify the package to publish + + There are a bunch of ways to configure the workflow, but here's an example from our own [packages](https://github.com/atopile/packages/blob/main/.github/workflows/main.yml) repo. + + {/* Add a sub-package example here */} + + +## Hitting "publish"! + +This must be a valid [semver](https://semver.org/) string, with the following additional restrictions: +- No leading `v` character +- No pre-release or dev tags +- No build metadata + +For example: `1.2.3` + + + + Create a [release on GitHub](https://docs.github.com/en/repositories/releasing-projects-on-github/managing-releases-in-a-repository), tagged as the version you want to publish. + + + Update the version in the `ato.yaml` config for the package you want to publish, and merge to main. + ```yaml packages/some-package/ato.yaml {2} + package: + version: "0.1.0" # <- Update this + ``` + + {/* Add a sub-package example here */} + + +## Reference + +Nitty gritty details for advanced configuration. + +### Package Metadata + +#### `package.identifier` + +The identifier is a unique identifier for the package. It must be in the form `{owner}/{name}` +, where `owner` is your GitHub username or organization name. + +If the URL to your repository is `https://github.com/atopile/packages`, then your "owner" is `atopile`. +You can name your package whatever you want, but it must be unique within the owner. + +#### `package.repository` + +The repository is the URL to the repository containing the package source code. This should be a link to the repository on GitHub. + +#### `package.version` [optional] + +The version is the version of the package. + +This must be a valid [semver](https://semver.org/) string, with the following additional restrictions: +- No leading `v` character +- No pre-release or dev tags +- No build metadata + +If you want to dynamically generate the version leave this blank, and use the `package-version` action input instead. + +#### `package.authors` + +The authors are the people who should be credited for the package. +This is a list, with each entry having a `name` and `email`. + +#### `package.summary` + +The summary is a short description of the package. + +#### `package.license` + +The license describing the terms under which the package is released. + +#### `package.homepage` + +The homepage is the URL to the website where the package is documented or sold. +This can be a link to your GitHub repository, or perhaps your website where you sell or document it. + + +### GitHub Action + +For the most up-to-date details on the GitHub Action, see the [GitHub Action README](https://github.com/atopile/publish-package). diff --git a/atopile-0.14.x/images/ato-example-build.png b/atopile-0.14.x/images/ato-example-build.png new file mode 100644 index 0000000..8517a47 Binary files /dev/null and b/atopile-0.14.x/images/ato-example-build.png differ diff --git a/atopile-0.14.x/images/ato-menu-bar.png b/atopile-0.14.x/images/ato-menu-bar.png new file mode 100644 index 0000000..90128a8 Binary files /dev/null and b/atopile-0.14.x/images/ato-menu-bar.png differ diff --git a/atopile-0.14.x/images/project-build.png b/atopile-0.14.x/images/project-build.png new file mode 100644 index 0000000..5d4c3b7 Binary files /dev/null and b/atopile-0.14.x/images/project-build.png differ diff --git a/atopile-0.14.x/images/project-create-1.png b/atopile-0.14.x/images/project-create-1.png new file mode 100644 index 0000000..5e09143 Binary files /dev/null and b/atopile-0.14.x/images/project-create-1.png differ diff --git a/atopile-0.14.x/images/project-create-2.png b/atopile-0.14.x/images/project-create-2.png new file mode 100644 index 0000000..91bc648 Binary files /dev/null and b/atopile-0.14.x/images/project-create-2.png differ diff --git a/atopile-0.14.x/images/project-overview.png b/atopile-0.14.x/images/project-overview.png new file mode 100644 index 0000000..e1b2f76 Binary files /dev/null and b/atopile-0.14.x/images/project-overview.png differ diff --git a/atopile-0.14.x/images/quick-select-example.png b/atopile-0.14.x/images/quick-select-example.png new file mode 100644 index 0000000..56782e4 Binary files /dev/null and b/atopile-0.14.x/images/quick-select-example.png differ diff --git a/atopile-0.14.x/images/quickstart-layout.png b/atopile-0.14.x/images/quickstart-layout.png new file mode 100644 index 0000000..7001ca9 Binary files /dev/null and b/atopile-0.14.x/images/quickstart-layout.png differ diff --git a/atopile-0.14.x/images/quickstart-package-overview.png b/atopile-0.14.x/images/quickstart-package-overview.png new file mode 100644 index 0000000..fbc42aa Binary files /dev/null and b/atopile-0.14.x/images/quickstart-package-overview.png differ diff --git a/atopile-0.14.x/images/quickstart-package-search.png b/atopile-0.14.x/images/quickstart-package-search.png new file mode 100644 index 0000000..f46068f Binary files /dev/null and b/atopile-0.14.x/images/quickstart-package-search.png differ diff --git a/atopile-0.14.x/images/vscode-plugin-install-complete.png b/atopile-0.14.x/images/vscode-plugin-install-complete.png new file mode 100644 index 0000000..32e905d Binary files /dev/null and b/atopile-0.14.x/images/vscode-plugin-install-complete.png differ diff --git a/atopile-0.14.x/images/vscode-plugin-installing.png b/atopile-0.14.x/images/vscode-plugin-installing.png new file mode 100644 index 0000000..4f22b16 Binary files /dev/null and b/atopile-0.14.x/images/vscode-plugin-installing.png differ diff --git a/atopile-0.14.x/images/vscode-plugin-overview.png b/atopile-0.14.x/images/vscode-plugin-overview.png new file mode 100644 index 0000000..1f3a89c Binary files /dev/null and b/atopile-0.14.x/images/vscode-plugin-overview.png differ diff --git a/atopile-0.14.x/images/vscode-plugin.png b/atopile-0.14.x/images/vscode-plugin.png new file mode 100644 index 0000000..d2e1f22 Binary files /dev/null and b/atopile-0.14.x/images/vscode-plugin.png differ diff --git a/atopile-0.14.x/introduction.mdx b/atopile-0.14.x/introduction.mdx new file mode 100644 index 0000000..ef1593c --- /dev/null +++ b/atopile-0.14.x/introduction.mdx @@ -0,0 +1,29 @@ +--- +title: Introduction +description: Design circuit boards blazing fast - with code +icon: hand-wave +--- + +atopile brings the power of software development workflows to hardware design. +By describing electronics with code, you can leverage modularity, version control, and deep validation. + +Capture design intelligence and constraints directly in your code, enabling auto-selection of +components, embedded calculations checked on every build, and reliable, configurable modules. + +This allows for rapid iteration, easier collaboration, and robust designs validated through +continuous integration. + + + + Get set up and running. + + + Confidently reuse chunks of design between projects. + + + Tell us what you need and we'll pick discretes for you! + + + Recheck every calculation, tolerance and requirement on every build - all automatically. + + diff --git a/atopile-0.14.x/quickstart/1-installation.mdx b/atopile-0.14.x/quickstart/1-installation.mdx new file mode 100644 index 0000000..6ba46dc --- /dev/null +++ b/atopile-0.14.x/quickstart/1-installation.mdx @@ -0,0 +1,129 @@ +--- +title: "1. Install" +description: "Get atopile extension and KiCad set up" +icon: "download" +--- + + +Just want to try atopile without installing anything? Check out the [playground](https://atopile-playground.fly.dev/) — it runs entirely in your browser. + +Note: Nothing is saved between sessions. If you want to save your work, proceed with installing the extension. + + +The primary way to interact with atopile locally is via the VS Code extension. We also support forks like Cursor or Antigravity. + +## 1. Install Preferred VS Code Fork + +| Editor | Download | +| --- | --- | +| VSCode | https://code.visualstudio.com/download | +| Cursor | https://cursor.com/download | +| Google Antigravity | https://antigravity.google/download | + + + +## 2. Install Extension + +Once you have a VS Code editor, search for the extension or install by clicking [atopile extension](https://marketplace.visualstudio.com/items?itemName=atopile.atopile). + +![atopile extension](/atopile-0.14.x/images/vscode-plugin.png) + +{/* + Set up an MCP server for this documentation with + + ``` sh + npx mint-mcp add atopile + ``` + */} + +Once the extension is installed, you might see a popup for uv installing. Allow that to finish. +![atopile extension installing](/atopile-0.14.x/images/vscode-plugin-installing.png) + +Complete! +![atopile extension installed](/atopile-0.14.x/images/vscode-plugin-install-complete.png) + +You will now have a *fresh* new atopile icon in your sidebar. Click it to open the extension and get started. +![atopile extension overview](/atopile-0.14.x/images/vscode-plugin-overview.png) + + +## 3. Install KiCAD + +If you want to layout or route PCBs you will need to install [KiCAD](https://www.kicad.org/download/). + + +```sh macOS (brew) +brew install kicad +``` + +```sh Arch Linux +sudo pacman -S kicad +``` + +```sh Ubuntu +sudo apt install kicad +``` + +```sh other +https://www.kicad.org/download/ +# or click the KiCAD link above +``` + + + +## 4. Done! +Great! At this point you can move on and [create your first project](./2-create-a-project). + + +## Other Install Methods (Optional) + +### Homebrew (recommended for macOS) + +``` sh +brew install atopile/tap/atopile +``` + +### uv (recommended for other platforms) + +1. Install `uv` + + https://docs.astral.sh/uv/getting-started/installation/ + +2. Install atopile with `uv` + + ``` sh + uv tool install atopile + ``` + + + If this is the first time you've used `uv` for a tool install, it might give you another command to run to finish setup. + + Do it. + + +3. Check `ato` installed + + ``` sh + ato --version + ``` + +### Editable Installation (best for development) + +1. Install `uv` (see above) + +2. Clone the repo + + ``` sh + git clone https://github.com/atopile/atopile + ``` + +3. `cd` into the repo + + ``` sh + cd atopile + ``` + +4. Install + + ``` sh + uv sync --dev + ``` diff --git a/atopile-0.14.x/quickstart/2-create-a-project.mdx b/atopile-0.14.x/quickstart/2-create-a-project.mdx new file mode 100644 index 0000000..ab97df2 --- /dev/null +++ b/atopile-0.14.x/quickstart/2-create-a-project.mdx @@ -0,0 +1,48 @@ +--- +title: "2. Hello, World!" +description: "Create a project and build your first component" +icon: "hand-wave" +--- + +## Create a project + +Click the `+` button next to the project selector to create a new project. + +![Create a project](/atopile-0.14.x/images/project-create-1.png) + +Fill in the prompts, then click **Create**. + +![Fill in project details](/atopile-0.14.x/images/project-create-2.png) + +Click on `main.ato` in the file explorer to open it in the editor. + +![Project overview](/atopile-0.14.x/images/project-overview.png) + +`.ato` files are where design intent is captured. See [`ato` Language](/atopile-0.14.x/essentials/1-the-ato-language) for more details. + +Other project files contain metadata and export artifacts. They are auto-generated when creating a new project. See [Project Structure](/atopile-0.14.x/essentials/5-project-structure) for more details. + +## Build it + +import QuickstartExample from "/snippets/examples/ch1_0_quickstart.mdx"; + + + +Update `main.ato` with this code, then click the **Build** button in the extension. + +![Build button](/atopile-0.14.x/images/project-build.png) + +Build progress will appear in the **Build Queue** at the bottom of the sidebar. + +A green checkmark means success! 🎉 + +## Views + +After a successful build, you can visualize your design with the buttons next to the build button: + +- **2D Layout:** opens a built-in viewer showing component placement and board outline. +- **3D Model:** opens a built-in 3D preview of your assembled board. +- **KiCad:** opens the layout in KiCad for routing and detailed editing. Requires [KiCad](https://www.kicad.org/) to be installed. + +![layout](/atopile-0.14.x/images/quickstart-layout.png) + diff --git a/atopile-0.14.x/quickstart/3-adding-parts.mdx b/atopile-0.14.x/quickstart/3-adding-parts.mdx new file mode 100644 index 0000000..84181db --- /dev/null +++ b/atopile-0.14.x/quickstart/3-adding-parts.mdx @@ -0,0 +1,65 @@ +--- +title: "3. Adding Parts" +description: "Add components to your design from packages, suppliers, and more!" +icon: "plus" +--- + +You can add parts to your design in three ways: + +- Install a pre-made **package** +- Find specific component with **supplier search** +- Select passives automatically with the **auto-picker** + +## Packages + +A **package** is a re-usable module with design, layout, and validation already completed. +It's a quick and easy way to integrate components and functionality in your design. + +See the [packages guide](../essentials/4-packages) for more details. + +### Installing Packages + +Let's add an ESP32 microcontroller and WiFi module. + +In the sidebar, open the **Packages** tab. Under the **Browse** tab, you can search for and browse available packages. + +![Package search showing ESP32 results](/atopile-0.14.x/images/quickstart-package-search.png) + +Click a package to get an overview and install it! + +![Package overview showing ESP32-S3 layout and install button](/atopile-0.14.x/images/quickstart-package-overview.png) + +```ato +from "esp32-s3.ato" import ESP32S3 + +module MyProject: + mcu = new ESP32S3 +``` + + + +## Supplier Part Search + +### Finding Parts + +In the sidebar, open the **Find Parts** tab. Under the **Find Parts** sub-tab, search for JLCPCB parts by name, description, or part number. Click on a part to add it to your project. + +You can switch to the **Project** tab to view the parts already added to your project. + +See the [adding components guide](../essentials/3-add-component) for more details. + +## Auto-picker + +For passives and other common components, specify your requirements and atopile will automatically select a matching part: + +### Standard Library + +```ato +resistor = new Resistor +resistor.resistance = 10kohm +/- 5% +resistor.package = "0402" +``` + +The **Standard Library** tab in the sidebar lists built-in interfaces and modules (such as `Resistor`, `Capacitor`, `LED`, `MOSFET`, and more). Most of the components in the standard library are auto-pickable. + +See the [Standard Library Reference](../api-reference/components/battery) for more details. diff --git a/atopile-0.14.x/quickstart/4-manufacturing-files.mdx b/atopile-0.14.x/quickstart/4-manufacturing-files.mdx new file mode 100644 index 0000000..456ab62 --- /dev/null +++ b/atopile-0.14.x/quickstart/4-manufacturing-files.mdx @@ -0,0 +1,33 @@ +--- +title: "4. Manufacturing Export" +description: "Generate manufacturing outputs from your design" +icon: "file-export" +--- + +## Exporting production files + +Click the **Generate manufacturing data** button in the sidebar to open the manufacturing export wizard. The wizard walks you through three stages: + +### 1. Build + +The wizard checks for uncommitted changes and then builds your project to generate manufacturing outputs. Click **Start Build** to begin. You'll see live progress as each build step completes. + +### 2. Review + +Once the build finishes, review your outputs across three tabs: + +- **Gerber files** - Visual preview of your PCB layers +- **BOM** - Bill of materials with part pricing and stock availability +- **3D Preview** - 3D model of your assembled board + +Mark each tab as reviewed by clicking the checkmark button. The wizard also runs post-build checks including verifying that gerber, BOM, and pick-and-place files were generated, and checking parts availability. + +### 3. Export + +After reviewing, the wizard shows a board summary and estimated cost breakdown (PCB fabrication, components, and assembly). Choose an export directory and click **Export Files** to generate: + +- **Gerber files** (.zip) - PCB layer artwork for fabrication +- **BOM** (.csv) - Component list for procurement +- **Pick and place** (.csv) - Component placement data for assembly + +The exported files are ready to upload to JLCPCB. The wizard includes a direct link to their order page. diff --git a/atopile-0.14.x/quickstart/5-examples.mdx b/atopile-0.14.x/quickstart/5-examples.mdx new file mode 100644 index 0000000..531962e --- /dev/null +++ b/atopile-0.14.x/quickstart/5-examples.mdx @@ -0,0 +1,27 @@ +--- +title: "5. Examples" +description: "Try out a built-in example project" +icon: "lightbulb" +--- + +## Trying out an example + +Press `Ctrl+Shift+P` and search for `atopile: Open Example`. + +![open example](../images/quick-select-example.png) + +Choose any example you like from the selection. +After confirming wait for the `ato menu bar` to appear: + +![ato menu bar](/atopile-0.14.x/images/ato-menu-bar.png) + +Press on the play button to compile the example. +You will be greeted by the logs in the terminal: + +![compile example](/atopile-0.14.x/images/ato-example-build.png) + +If you have KiCAD installed, you can now press on the PCB icon in the ato menu bar to open the layout file. + +## What's next? + +In the [Essentials tutorial](../essentials/1-the-ato-language) we continue with a real circuit, installing and using packages, maths and version control. diff --git a/atopile-0.14.x/reference/config.mdx b/atopile-0.14.x/reference/config.mdx new file mode 100644 index 0000000..13ea360 --- /dev/null +++ b/atopile-0.14.x/reference/config.mdx @@ -0,0 +1,176 @@ +--- +title: 'config' +description: 'The `ato.yaml` config file' +icon: 'gear' +--- + +### `ato-version` + +The compiler version with which the project was developed. + +This is used by the compiler to ensure the code in this project is compatible with the compiler version. + +**Default value**: current compiler version + +**Type**: `str` + +**Example usage**: + +```toml title="ato.yaml" +ato-version: 0.3.0 +``` + +### `paths.src` + +Project source code directory + +**Default value**: `elec/src` + +**Type**: `str` + +**Example usage**: + +```toml title="ato.yaml" +paths: + src: "./" +``` + +### `paths.layout` + +Project layout directory where KiCAD projects are stored and searched for + +**Default value**: `elec/layout` + +**Type**: `str` + +**Example usage**: + +```toml title="ato.yaml" +paths: + layout: "./" +``` + +### `dependencies` + +List of dependencies for the project + +**Default value**: `[]` or no dependencies + +**Type**: + +| Field | Type | Description | Default | +| ----- | ---- | ----------- | ------- | +| `name` | `str` | The name of the dependency | No default and required | +| `version_spec` | `str` | The version specifier for the dependency | Latest tagged version or commit on `main` | +| `link_broken` | `bool` | Whether the link to the upstream version is maintained / broken | `false` | +| `path` | `str` | The path to the dependency within this project | `.ato/modules/` | + +**Example usage**: + +```toml title="ato.yaml" +dependencies: + - name: rp2040 + version_spec: ">=3.0.0,<4.0.0" +``` + +### `builds` + +Build targets for the project + +**Default value**: `{}` or no build targets + +**Type**: `dict` (see "builds.name" etc... below for details) + + +### `builds.entry` + +Entry point for the build + +**Default value**: Required, no default + +**Type**: `str` + +**Example usage**: + +```toml title="ato.yaml" +builds: + default: + entry: some_file.ato:App +``` + + +### `builds.targets` + +Build targets for the project + +**Default value**: `["__default__"]`, which is a special value. + +**Type**: `list[str]` + +**Example usage**: + +```toml title="ato.yaml" +builds: + default: + targets: + - bom + - mfg-data +``` + + +### `builds.exclude_targets` + +Excluding the `mfg-data` target is useful, for example, for CI build targets that represent a +module, but not a board you'd manufacture. + +**Default value**: `[]`, don't actively exclude any targets + +**Type**: `list[str]` + +**Example usage**: + +```toml title="ato.yaml" +builds: + default: + exclude_targets: + - bom + - mfg-data +``` + +### `builds.exclude_checks` + +A list of checks to exclude. Use qualified name of check e.g + - `PCB.requires_drc_check` + - `I2C.requires_unique_addresses` + - `requires_external_usage` + +**Default value**: `[]`, don't actively exclude any targets + +**Type**: `list[str]` + +**Example usage**: + +```toml title="ato.yaml" +builds: + default: + exclude_checks: + - PCB.requires_drc_check + - I2C.requires_unique_addresses + - requires_external_usage +``` + +### `builds.hide_designators` + +Hide all the designators from the built PCB. + +**Default value**: `false` + +**Type**: `bool` + +**Example usage**: + +```toml title="ato.yaml" +builds: + default: + hide_designators: true +``` diff --git a/atopile-0.14.x/support.mdx b/atopile-0.14.x/support.mdx new file mode 100644 index 0000000..8219bd8 --- /dev/null +++ b/atopile-0.14.x/support.mdx @@ -0,0 +1,17 @@ +--- +title: 'Support' +description: 'Get help with atopile' +icon: 'pray' +--- + +## Immediate Support + +The "help" channel in [Discord](https://discord.gg/CRe5xaDBr3) is the best way to get an immediate hand with anything the docs don't cover. + +## Commercial Support + +For support of commercial projects using atopile, Discord remains a great resource, however please contact us at [hi@atopile.io](mailto:hi@atopile.io) for specific projects. + +## Bugs and Feature Requests + +Please report bugs and feature requests on [GitHub](https://github.com/atopile/atopile/issues). diff --git a/docs.json b/docs.json index 20c8159..3921042 100644 --- a/docs.json +++ b/docs.json @@ -15,183 +15,377 @@ }, "favicon": "/favicon.svg", "navigation": { - "tabs": [ + "versions": [ { - "tab": "atopile", + "version": "0.12.x", + "default": true, + "tabs": [ + { + "tab": "atopile", + "global": { + "anchors": [ + { + "anchor": "GitHub", + "href": "https://github.com/atopile/atopile", + "icon": "github" + } + ] + }, + "groups": [ + { + "group": "Get Started", + "pages": [ + "atopile-0.12.x/introduction", + "atopile-0.12.x/quickstart", + "atopile-0.12.x/changelog" + ] + }, + { + "group": "Essentials", + "pages": [ + "atopile-0.12.x/essentials/1-the-ato-language", + "atopile-0.12.x/essentials/2-the-ato-compiler", + "atopile-0.12.x/essentials/3-add-component", + "atopile-0.12.x/essentials/4-packages", + "atopile-0.12.x/essentials/5-project-structure", + "atopile-0.12.x/essentials/6-layout", + "atopile-0.12.x/essentials/7-saving-your-work", + "atopile-0.12.x/essentials/8-traits" + ] + }, + { + "group": "Guides", + "pages": [ + "atopile-0.12.x/guides/install", + "atopile-0.12.x/guides/git", + "atopile-0.12.x/guides/publish", + "atopile-0.12.x/guides/faebryk", + "atopile-0.12.x/guides/fabll", + "atopile-0.12.x/guides/development" + ] + }, + { + "group": "Library Reference", + "pages": [ + { + "group": "Components", + "pages": [ + "atopile-0.12.x/api-reference/components/battery", + "atopile-0.12.x/api-reference/components/bjt", + "atopile-0.12.x/api-reference/components/capacitor", + "atopile-0.12.x/api-reference/components/capacitorelectrolytic", + "atopile-0.12.x/api-reference/components/common_mode_filter", + "atopile-0.12.x/api-reference/components/comparator", + "atopile-0.12.x/api-reference/components/crystal", + "atopile-0.12.x/api-reference/components/crystal_oscillator", + "atopile-0.12.x/api-reference/components/diode", + "atopile-0.12.x/api-reference/components/dip", + "atopile-0.12.x/api-reference/components/eeprom", + "atopile-0.12.x/api-reference/components/electriclogicgate", + "atopile-0.12.x/api-reference/components/fan", + "atopile-0.12.x/api-reference/components/filter", + "atopile-0.12.x/api-reference/components/filterelectricallc", + "atopile-0.12.x/api-reference/components/filterelectricalrc", + "atopile-0.12.x/api-reference/components/footprint", + "atopile-0.12.x/api-reference/components/fuse", + "atopile-0.12.x/api-reference/components/gdt", + "atopile-0.12.x/api-reference/components/inductor", + "atopile-0.12.x/api-reference/components/kicadfootprint", + "atopile-0.12.x/api-reference/components/ldo", + "atopile-0.12.x/api-reference/components/led", + "atopile-0.12.x/api-reference/components/ledindicator", + "atopile-0.12.x/api-reference/components/logicgate", + "atopile-0.12.x/api-reference/components/mosfet", + "atopile-0.12.x/api-reference/components/multicapacitor", + "atopile-0.12.x/api-reference/components/net", + "atopile-0.12.x/api-reference/components/nfet", + "atopile-0.12.x/api-reference/components/opamp", + "atopile-0.12.x/api-reference/components/pfet", + "atopile-0.12.x/api-reference/components/potentiometer", + "atopile-0.12.x/api-reference/components/poweredled", + "atopile-0.12.x/api-reference/components/powermux", + "atopile-0.12.x/api-reference/components/powerswitch", + "atopile-0.12.x/api-reference/components/powerswitchmosfet", + "atopile-0.12.x/api-reference/components/powerswitchstatic", + "atopile-0.12.x/api-reference/components/regulator", + "atopile-0.12.x/api-reference/components/relay", + "atopile-0.12.x/api-reference/components/resistor", + "atopile-0.12.x/api-reference/components/resistorarray", + "atopile-0.12.x/api-reference/components/resistorvoltagedivider", + "atopile-0.12.x/api-reference/components/smdtwopin", + "atopile-0.12.x/api-reference/components/soic", + "atopile-0.12.x/api-reference/components/spiflash", + "atopile-0.12.x/api-reference/components/surgeprotection", + "atopile-0.12.x/api-reference/components/symbol", + "atopile-0.12.x/api-reference/components/testpoint", + "atopile-0.12.x/api-reference/components/tvs" + ] + }, + { + "group": "Interfaces", + "pages": [ + "atopile-0.12.x/api-reference/interfaces/addressor", + "atopile-0.12.x/api-reference/interfaces/can", + "atopile-0.12.x/api-reference/interfaces/can_ttl", + "atopile-0.12.x/api-reference/interfaces/differentialpair", + "atopile-0.12.x/api-reference/interfaces/electrical", + "atopile-0.12.x/api-reference/interfaces/electriclogic", + "atopile-0.12.x/api-reference/interfaces/electricpower", + "atopile-0.12.x/api-reference/interfaces/electricsignal", + "atopile-0.12.x/api-reference/interfaces/enablepin", + "atopile-0.12.x/api-reference/interfaces/ethernet", + "atopile-0.12.x/api-reference/interfaces/hdmi", + "atopile-0.12.x/api-reference/interfaces/i2c", + "atopile-0.12.x/api-reference/interfaces/i2s", + "atopile-0.12.x/api-reference/interfaces/jtag", + "atopile-0.12.x/api-reference/interfaces/logic", + "atopile-0.12.x/api-reference/interfaces/mechanical", + "atopile-0.12.x/api-reference/interfaces/multispi", + "atopile-0.12.x/api-reference/interfaces/pad", + "atopile-0.12.x/api-reference/interfaces/pdm", + "atopile-0.12.x/api-reference/interfaces/power", + "atopile-0.12.x/api-reference/interfaces/rs232", + "atopile-0.12.x/api-reference/interfaces/rs485halfduplex", + "atopile-0.12.x/api-reference/interfaces/sercom", + "atopile-0.12.x/api-reference/interfaces/signal", + "atopile-0.12.x/api-reference/interfaces/spi", + "atopile-0.12.x/api-reference/interfaces/swd", + "atopile-0.12.x/api-reference/interfaces/uart", + "atopile-0.12.x/api-reference/interfaces/uart_base", + "atopile-0.12.x/api-reference/interfaces/usb2_0", + "atopile-0.12.x/api-reference/interfaces/usb2_0_if", + "atopile-0.12.x/api-reference/interfaces/usb3", + "atopile-0.12.x/api-reference/interfaces/usb3_if", + "atopile-0.12.x/api-reference/interfaces/usb_c", + "atopile-0.12.x/api-reference/interfaces/xtalif" + ] + }, + { + "group": "Traits", + "pages": [ + "atopile-0.12.x/api-reference/traits/can_bridge_by_name", + "atopile-0.12.x/api-reference/traits/requires_pulls" + ] + } + ] + } + ] + } + ], "global": { "anchors": [ { - "anchor": "GitHub", - "href": "https://github.com/atopile/atopile", - "icon": "github" + "anchor": "Packages", + "href": "https://packages.atopile.io", + "icon": "box" + }, + { + "anchor": "Support", + "href": "https://docs.atopile.io/support", + "icon": "question" + }, + { + "anchor": "Community", + "href": "https://discord.gg/CRe5xaDBr3", + "icon": "discord" + }, + { + "anchor": "Blog", + "href": "https://blog.atopile.io", + "icon": "newspaper" } ] - }, - "groups": [ - { - "group": "Get Started", - "pages": [ - "atopile/introduction", - "atopile/quickstart", - "atopile/changelog" - ] - }, - { - "group": "Essentials", - "pages": [ - "atopile/essentials/1-the-ato-language", - "atopile/essentials/2-the-ato-compiler", - "atopile/essentials/3-add-component", - "atopile/essentials/4-packages", - "atopile/essentials/5-project-structure", - "atopile/essentials/6-layout", - "atopile/essentials/7-saving-your-work", - "atopile/essentials/8-traits" - ] - }, - { - "group": "Guides", - "pages": [ - "atopile/guides/install", - "atopile/guides/git", - "atopile/guides/publish", - "atopile/guides/faebryk", - "atopile/guides/fabll", - "atopile/guides/development" - ] - }, + } + }, + { + "version": "0.14.x", + "tabs": [ { - "group": "Library Reference", - "pages": [ + "tab": "atopile", + "global": { + "anchors": [ + { + "anchor": "GitHub", + "href": "https://github.com/atopile/atopile", + "icon": "github" + } + ] + }, + "groups": [ + { + "group": "Introduction", + "pages": [ + "atopile-0.14.x/introduction", + "atopile-0.14.x/changelog" + ] + }, + { + "group": "Getting Started Guide", + "pages": [ + "atopile-0.14.x/quickstart/1-installation", + "atopile-0.14.x/quickstart/2-create-a-project", + "atopile-0.14.x/quickstart/3-adding-parts", + "atopile-0.14.x/quickstart/4-manufacturing-files", + "atopile-0.14.x/quickstart/5-examples" + ] + }, { - "group": "Components", + "group": "Essentials", "pages": [ - "atopile/api-reference/components/battery", - "atopile/api-reference/components/bjt", - "atopile/api-reference/components/capacitor", - "atopile/api-reference/components/capacitorelectrolytic", - "atopile/api-reference/components/common_mode_filter", - "atopile/api-reference/components/comparator", - "atopile/api-reference/components/crystal", - "atopile/api-reference/components/crystal_oscillator", - "atopile/api-reference/components/diode", - "atopile/api-reference/components/dip", - "atopile/api-reference/components/eeprom", - "atopile/api-reference/components/electriclogicgate", - "atopile/api-reference/components/fan", - "atopile/api-reference/components/filter", - "atopile/api-reference/components/filterelectricallc", - "atopile/api-reference/components/filterelectricalrc", - "atopile/api-reference/components/footprint", - "atopile/api-reference/components/fuse", - "atopile/api-reference/components/gdt", - "atopile/api-reference/components/inductor", - "atopile/api-reference/components/kicadfootprint", - "atopile/api-reference/components/ldo", - "atopile/api-reference/components/led", - "atopile/api-reference/components/ledindicator", - "atopile/api-reference/components/logicgate", - "atopile/api-reference/components/mosfet", - "atopile/api-reference/components/multicapacitor", - "atopile/api-reference/components/net", - "atopile/api-reference/components/nfet", - "atopile/api-reference/components/opamp", - "atopile/api-reference/components/pfet", - "atopile/api-reference/components/potentiometer", - "atopile/api-reference/components/poweredled", - "atopile/api-reference/components/powermux", - "atopile/api-reference/components/powerswitch", - "atopile/api-reference/components/powerswitchmosfet", - "atopile/api-reference/components/powerswitchstatic", - "atopile/api-reference/components/regulator", - "atopile/api-reference/components/relay", - "atopile/api-reference/components/resistor", - "atopile/api-reference/components/resistorarray", - "atopile/api-reference/components/resistorvoltagedivider", - "atopile/api-reference/components/smdtwopin", - "atopile/api-reference/components/soic", - "atopile/api-reference/components/spiflash", - "atopile/api-reference/components/surgeprotection", - "atopile/api-reference/components/symbol", - "atopile/api-reference/components/testpoint", - "atopile/api-reference/components/tvs" + "atopile-0.14.x/essentials/1-the-ato-language", + "atopile-0.14.x/essentials/2-the-ato-compiler", + "atopile-0.14.x/essentials/3-add-component", + "atopile-0.14.x/essentials/4-packages", + "atopile-0.14.x/essentials/5-project-structure", + "atopile-0.14.x/essentials/6-layout", + "atopile-0.14.x/essentials/7-saving-your-work", + "atopile-0.14.x/essentials/8-traits" ] }, { - "group": "Interfaces", + "group": "Guides", "pages": [ - "atopile/api-reference/interfaces/addressor", - "atopile/api-reference/interfaces/can", - "atopile/api-reference/interfaces/can_ttl", - "atopile/api-reference/interfaces/differentialpair", - "atopile/api-reference/interfaces/electrical", - "atopile/api-reference/interfaces/electriclogic", - "atopile/api-reference/interfaces/electricpower", - "atopile/api-reference/interfaces/electricsignal", - "atopile/api-reference/interfaces/enablepin", - "atopile/api-reference/interfaces/ethernet", - "atopile/api-reference/interfaces/hdmi", - "atopile/api-reference/interfaces/i2c", - "atopile/api-reference/interfaces/i2s", - "atopile/api-reference/interfaces/jtag", - "atopile/api-reference/interfaces/logic", - "atopile/api-reference/interfaces/mechanical", - "atopile/api-reference/interfaces/multispi", - "atopile/api-reference/interfaces/pad", - "atopile/api-reference/interfaces/pdm", - "atopile/api-reference/interfaces/power", - "atopile/api-reference/interfaces/rs232", - "atopile/api-reference/interfaces/rs485halfduplex", - "atopile/api-reference/interfaces/sercom", - "atopile/api-reference/interfaces/signal", - "atopile/api-reference/interfaces/spi", - "atopile/api-reference/interfaces/swd", - "atopile/api-reference/interfaces/uart", - "atopile/api-reference/interfaces/uart_base", - "atopile/api-reference/interfaces/usb2_0", - "atopile/api-reference/interfaces/usb2_0_if", - "atopile/api-reference/interfaces/usb3", - "atopile/api-reference/interfaces/usb3_if", - "atopile/api-reference/interfaces/usb_c", - "atopile/api-reference/interfaces/xtalif" + "atopile-0.14.x/guides/git", + "atopile-0.14.x/guides/publish", + "atopile-0.14.x/guides/faebryk", + "atopile-0.14.x/guides/fabll", + "atopile-0.14.x/guides/development" ] }, { - "group": "Traits", + "group": "Library Reference", "pages": [ - "atopile/api-reference/traits/can_bridge_by_name", - "atopile/api-reference/traits/requires_pulls" + { + "group": "Components", + "pages": [ + "atopile-0.14.x/api-reference/components/battery", + "atopile-0.14.x/api-reference/components/bjt", + "atopile-0.14.x/api-reference/components/capacitor", + "atopile-0.14.x/api-reference/components/capacitorelectrolytic", + "atopile-0.14.x/api-reference/components/common_mode_filter", + "atopile-0.14.x/api-reference/components/comparator", + "atopile-0.14.x/api-reference/components/crystal", + "atopile-0.14.x/api-reference/components/crystal_oscillator", + "atopile-0.14.x/api-reference/components/diode", + "atopile-0.14.x/api-reference/components/dip", + "atopile-0.14.x/api-reference/components/eeprom", + "atopile-0.14.x/api-reference/components/electriclogicgate", + "atopile-0.14.x/api-reference/components/fan", + "atopile-0.14.x/api-reference/components/filter", + "atopile-0.14.x/api-reference/components/filterelectricallc", + "atopile-0.14.x/api-reference/components/filterelectricalrc", + "atopile-0.14.x/api-reference/components/footprint", + "atopile-0.14.x/api-reference/components/fuse", + "atopile-0.14.x/api-reference/components/gdt", + "atopile-0.14.x/api-reference/components/inductor", + "atopile-0.14.x/api-reference/components/kicadfootprint", + "atopile-0.14.x/api-reference/components/ldo", + "atopile-0.14.x/api-reference/components/led", + "atopile-0.14.x/api-reference/components/ledindicator", + "atopile-0.14.x/api-reference/components/logicgate", + "atopile-0.14.x/api-reference/components/mosfet", + "atopile-0.14.x/api-reference/components/multicapacitor", + "atopile-0.14.x/api-reference/components/net", + "atopile-0.14.x/api-reference/components/nfet", + "atopile-0.14.x/api-reference/components/opamp", + "atopile-0.14.x/api-reference/components/pfet", + "atopile-0.14.x/api-reference/components/potentiometer", + "atopile-0.14.x/api-reference/components/poweredled", + "atopile-0.14.x/api-reference/components/powermux", + "atopile-0.14.x/api-reference/components/powerswitch", + "atopile-0.14.x/api-reference/components/powerswitchmosfet", + "atopile-0.14.x/api-reference/components/powerswitchstatic", + "atopile-0.14.x/api-reference/components/regulator", + "atopile-0.14.x/api-reference/components/relay", + "atopile-0.14.x/api-reference/components/resistor", + "atopile-0.14.x/api-reference/components/resistorarray", + "atopile-0.14.x/api-reference/components/resistorvoltagedivider", + "atopile-0.14.x/api-reference/components/smdtwopin", + "atopile-0.14.x/api-reference/components/soic", + "atopile-0.14.x/api-reference/components/spiflash", + "atopile-0.14.x/api-reference/components/surgeprotection", + "atopile-0.14.x/api-reference/components/symbol", + "atopile-0.14.x/api-reference/components/testpoint", + "atopile-0.14.x/api-reference/components/tvs" + ] + }, + { + "group": "Interfaces", + "pages": [ + "atopile-0.14.x/api-reference/interfaces/addressor", + "atopile-0.14.x/api-reference/interfaces/can", + "atopile-0.14.x/api-reference/interfaces/can_ttl", + "atopile-0.14.x/api-reference/interfaces/differentialpair", + "atopile-0.14.x/api-reference/interfaces/electrical", + "atopile-0.14.x/api-reference/interfaces/electriclogic", + "atopile-0.14.x/api-reference/interfaces/electricpower", + "atopile-0.14.x/api-reference/interfaces/electricsignal", + "atopile-0.14.x/api-reference/interfaces/enablepin", + "atopile-0.14.x/api-reference/interfaces/ethernet", + "atopile-0.14.x/api-reference/interfaces/hdmi", + "atopile-0.14.x/api-reference/interfaces/i2c", + "atopile-0.14.x/api-reference/interfaces/i2s", + "atopile-0.14.x/api-reference/interfaces/jtag", + "atopile-0.14.x/api-reference/interfaces/logic", + "atopile-0.14.x/api-reference/interfaces/mechanical", + "atopile-0.14.x/api-reference/interfaces/multispi", + "atopile-0.14.x/api-reference/interfaces/pad", + "atopile-0.14.x/api-reference/interfaces/pdm", + "atopile-0.14.x/api-reference/interfaces/power", + "atopile-0.14.x/api-reference/interfaces/rs232", + "atopile-0.14.x/api-reference/interfaces/rs485halfduplex", + "atopile-0.14.x/api-reference/interfaces/sercom", + "atopile-0.14.x/api-reference/interfaces/signal", + "atopile-0.14.x/api-reference/interfaces/spi", + "atopile-0.14.x/api-reference/interfaces/swd", + "atopile-0.14.x/api-reference/interfaces/uart", + "atopile-0.14.x/api-reference/interfaces/uart_base", + "atopile-0.14.x/api-reference/interfaces/usb2_0", + "atopile-0.14.x/api-reference/interfaces/usb2_0_if", + "atopile-0.14.x/api-reference/interfaces/usb3", + "atopile-0.14.x/api-reference/interfaces/usb3_if", + "atopile-0.14.x/api-reference/interfaces/usb_c", + "atopile-0.14.x/api-reference/interfaces/xtalif" + ] + }, + { + "group": "Traits", + "pages": [ + "atopile-0.14.x/api-reference/traits/can_bridge_by_name", + "atopile-0.14.x/api-reference/traits/requires_pulls" + ] + } ] } ] } - ] - } - ], - "global": { - "anchors": [ - { - "anchor": "Packages", - "href": "https://packages.atopile.io", - "icon": "box" - }, - { - "anchor": "Support", - "href": "https://docs.atopile.io/support", - "icon": "question" - }, - { - "anchor": "Community", - "href": "https://discord.gg/CRe5xaDBr3", - "icon": "discord" - }, - { - "anchor": "Blog", - "href": "https://blog.atopile.io", - "icon": "newspaper" + ], + "global": { + "anchors": [ + { + "anchor": "Packages", + "href": "https://packages.atopile.io", + "icon": "box" + }, + { + "anchor": "Support", + "href": "https://docs.atopile.io/support", + "icon": "question" + }, + { + "anchor": "Community", + "href": "https://discord.gg/CRe5xaDBr3", + "icon": "discord" + }, + { + "anchor": "Blog", + "href": "https://blog.atopile.io", + "icon": "newspaper" + } + ] } - ] - } + } + ] }, "logo": { "light": "/logo/light.svg", @@ -203,23 +397,23 @@ "redirects": [ { "source": "/support", - "destination": "/atopile/support" + "destination": "/atopile-0.12.x/support" }, { "source": "/installation", - "destination": "/atopile/guides/install" + "destination": "/atopile-0.12.x/guides/install" }, { "source": "/publish-package", - "destination": "/atopile/guides/publish" + "destination": "/atopile-0.12.x/guides/publish" }, { "source": "/quickstart", - "destination": "/atopile/quickstart" + "destination": "/atopile-0.12.x/quickstart" }, { "source": "/package-management", - "destination": "/atopile/essentials/4-packages" + "destination": "/atopile-0.12.x/essentials/4-packages" } ], "footer": { @@ -236,4 +430,4 @@ "apiHost": "https://us.i.posthog.com" } } -} \ No newline at end of file +} diff --git a/snippets/atopile/guides/quick-install.mdx b/snippets/atopile/guides/quick-install.mdx deleted file mode 100644 index b45a10b..0000000 --- a/snippets/atopile/guides/quick-install.mdx +++ /dev/null @@ -1,48 +0,0 @@ -## Install via VSCode/Cursor (Recommended) - -atopile officially supports VSCode and Cursor. - -We recommend using Cursor. AI is already getting very good at writing `ato` code. - -Download it here: https://www.cursor.com/ - -Once you have VSCode/Cursor just install the [atopile VSCode/Cursor extension](vscode:extension/atopile.atopile). - -![atopile extension](/atopile/images/vscode-plugin.png) - -After installation it will prompt you to install the `ato` CLI. Click the `Install Automatically` button. - -![atopile extension install](/atopile/images/vscode-plugin-install-popup.png) - - - Set up an MCP server for this documentation with - - ``` sh - npx mint-mcp add atopile - ``` - - - -## Installing KiCAD - -If you want to layout or route PCBs you will need to install [KiCAD](https://www.kicad.org/download/). - - -```sh macOS (brew) -brew install kicad -``` - -```sh Arch Linux -sudo pacman -S kicad -``` - -```sh Ubuntu -sudo apt install kicad -``` - -```sh other -https://www.kicad.org/download/ -# or click the KiCAD link above -``` - - diff --git a/snippets/examples/ch1_0_quickstart.mdx b/snippets/examples/ch1_0_quickstart.mdx index a979945..dae74b5 100644 --- a/snippets/examples/ch1_0_quickstart.mdx +++ b/snippets/examples/ch1_0_quickstart.mdx @@ -3,7 +3,6 @@ import Resistor module App: - r1 = new Resistor # Create a new resistor - r1.resistance = 100ohm +/- 10% # Set the resistor value - + r1 = new Resistor # Create a new resistor + r1.resistance = 50 kohm +/- 10% # Set the resistor value ``` diff --git a/snippets/examples/quickstart/quickstart.mdx b/snippets/examples/quickstart/quickstart.mdx deleted file mode 100644 index a979945..0000000 --- a/snippets/examples/quickstart/quickstart.mdx +++ /dev/null @@ -1,9 +0,0 @@ - -```python -import Resistor - -module App: - r1 = new Resistor # Create a new resistor - r1.resistance = 100ohm +/- 10% # Set the resistor value - -``` diff --git a/styles/config/vocabularies/atopile/accept.txt b/styles/config/vocabularies/atopile/accept.txt index af4777f..3d269de 100644 --- a/styles/config/vocabularies/atopile/accept.txt +++ b/styles/config/vocabularies/atopile/accept.txt @@ -8,7 +8,7 @@ baudrate config fabll faebryk -gerber +(?i)gerbers? githash github|GitHub ing @@ -35,4 +35,7 @@ has_single_electric_reference_shared CLI pinout panelized -partnumber \ No newline at end of file +partnumber +lightbulb +[Uu]v +auto-pickable \ No newline at end of file