MustafaMulla29/usb-pd-motherboard

4-layer USB-C PD hub motherboard with 20 V USB-C input, Linux T113-S3 computer, CH338F USB hub, four individually controlled 5–20 V PD outputs, USB data/camera ports, regulated rails, and hardware watchdog/E-stop safety interlock.

Version
1.0.24
License
unset
Stars
0

Use with the tscircuit CLI

tsci is the tscircuit CLI. Install it with npm install -g tscircuit.

tsci clone MustafaMulla29/usb-pd-motherboard  # download the package files into ./usb-pd-motherboard
tsci add MustafaMulla29/usb-pd-motherboard    # add it to your project as @tsci/MustafaMulla29.usb-pd-motherboard

In a cloned or new (tsci init) project: tsci dev starts a local preview, tsci build outputs Circuit JSON, and tsci push publishes to tscircuit.com.

imports/HYG040N04LS1C1.tsx

import type { ChipProps } from "@tscircuit/props"

const pinLabels = {
  pin1: ["S3"],
  pin2: ["S2"],
  pin3: ["S1"],
  pin4: ["G"],
  pin5: ["D2"],
  pin6: ["D3"],
  pin7: ["D4"],
  pin8: ["D5"],
  pin9: ["D1"]
} as const

const footprinterPinLabels = {
  ...pinLabels,
  "pin9": [...pinLabels["pin9"], "thermalpad"],
} as const

export const HYG040N04LS1C1 = (props: ChipProps<typeof pinLabels>) => {
  return (
    <chip
      pinLabels={footprinterPinLabels}
      symbol={
        <symbol>
          <port name="pin3" pinNumber={3} aliases={["S1"]} direction="down" schX={0.4} schY={-0.4} schStemLength={0.2} />
          <port name="pin2" pinNumber={2} aliases={["S2"]} direction="down" schX={0.2} schY={-0.4} schStemLength={0.2} />
          <port name="pin1" pinNumber={1} aliases={["S3"]} direction="down" schX={0} schY={-0.4} schStemLength={0.2} />
          <port name="pin4" pinNumber={4} aliases={["G"]} direction="left" schX={-0.4} schY={0} schStemLength={0.16} />
          <port name="pin5" pinNumber={5} aliases={["D2"]} direction="up" schX={0} schY={0.4} schStemLength={0.2} />
          <schematicpath points={[{"x":0.26,"y":0.04},{"x":0.24,"y":0.04},{"x":0.16,"y":0.04},{"x":0.14,"y":0.04}]} strokeColor="#880000" />
          <schematicpath points={[{"x":-0.2,"y":-0.18},{"x":-0.2,"y":-0.1}]} strokeColor="#880000" />
          <schematicpath points={[{"x":-0.2,"y":-0.04},{"x":-0.2,"y":0.04}]} strokeColor="#880000" />
          <schematicpath points={[{"x":-0.2,"y":0.18},{"x":-0.2,"y":0.1}]} strokeColor="#880000" />
          <schematicpath points={[{"x":-0.24,"y":0.18},{"x":-0.24,"y":-0.18}]} strokeColor="#880000" />
          <schematicpath points={[{"x":0,"y":-0.14},{"x":-0.2,"y":-0.14}]} strokeColor="#880000" />
          <schematicpath points={[{"x":-0.2,"y":0},{"x":0,"y":0},{"x":0,"y":-0.2},{"x":0.4,"y":-0.2},{"x":0.2,"y":-0.2},{"x":0.2,"y":0}]} strokeColor="#880000" />
          <schematicpath points={[{"x":-0.2,"y":0.14},{"x":0,"y":0.14},{"x":0,"y":0.2},{"x":0.2,"y":0.2},{"x":0.2,"y":0.2},{"x":0.2,"y":0.04}]} strokeColor="#880000" />
          <schematicpath points={[{"x":0.2,"y":0.04},{"x":0.14,"y":-0.06},{"x":0.26,"y":-0.06},{"x":0.2,"y":0.04}]} strokeColor="#880000" isFilled fillColor="#880000" />
          <schematicpath points={[{"x":-0.2,"y":0},{"x":-0.08,"y":-0.04},{"x":-0.08,"y":0.04},{"x":-0.2,"y":0}]} strokeColor="#880000" isFilled fillColor="#880000" />
          <port name="pin6" pinNumber={6} aliases={["D3"]} direction="up" schX={0.2} schY={0.4} schStemLength={0.2} />
          <port name="pin7" pinNumber={7} aliases={["D4"]} direction="up" schX={0.4} schY={0.4} schStemLength={0.2} />
          <port name="pin8" pinNumber={8} aliases={["D5"]} direction="up" schX={0.6} schY={0.4} schStemLength={0.2} />
          <port name="pin9" pinNumber={9} aliases={["D1"]} direction="up" schX={0.8} schY={0.4} schStemLength={0.2} />
          <schematicpath points={[{"x":0.2,"y":0.2},{"x":0.8,"y":0.2}]} strokeColor="#880000" />
          <schematictext schX={0.2} schY={0.62} text="{NAME}" fontSize={0.2} anchor="bottom_center" />
        </symbol>
      }
      supplierPartNumbers={{
  "jlcpcb": [
    "C5250956"
  ]
}}
      manufacturerPartNumber="HYG040N04LS1C1"
      footprint="dfn8_thermalpad2.05mmx2.6mm_thermalpadcenteroffsetx0.35mm_p0.65mm_w3.64mm_pw0.4mm_pl0.6mm_pin1location(leftside,bottom)"
      cadModel={{
        objUrl: "https://modelcdn.tscircuit.com/easyeda_models/assets/C5250956.obj?uuid=e22328b7e36c4e8cb5fb593b770ac99b",
        stepUrl: "https://modelcdn.tscircuit.com/easyeda_models/assets/C5250956.step?uuid=e22328b7e36c4e8cb5fb593b770ac99b",
        pcbRotationOffset: 0,
        modelOriginPosition: { x: -0.000012699999956566899, y: 0, z: 0 },
      }}
      {...props}
    />
  )
}