krishnax12/usb-c-control-dial

USB-C control dial PCB with an EC11 push encoder and a 16-LED ring for volume and brightness controls. Work in progress; firmware not included and not fabrication-ready.

Version
0.0.3
License
unset
Stars
1

imports/nSMD050_24V/nSMD050_24V.tsx

import objPath from "./nSMD050_24V.obj"
import stepPath from "./nSMD050_24V.step"
import type { FuseProps } from "@tscircuit/props"

const pinLabels = {
  pin1: ["pin1"],
  pin2: ["pin2"],
} as const

export const nSMD050_24V = (props: FuseProps) => {
  return (
    <fuse
      symbol={
        <symbol>
          <schematicpath
            points={[
              { x: -0.3, y: -0.1 },
              { x: -0.2, y: -0.1 },
            ]}
            strokeColor="#000000"
          />
          <schematicpath
            svgPath="M -0.2 -0.1 C -0.1 0.1 0 -0.1 0 -0.1 C 0.1 -0.3 0.2 -0.1 0.2 -0.1"
            strokeColor="#000000"
          />
          <schematicpath
            points={[
              { x: 0.2, y: -0.1 },
              { x: 0.3, y: -0.1 },
            ]}
            strokeColor="#000000"
          />
          <port
            name="pin1"
            pinNumber={1}
            aliases={["1"]}
            direction="left"
            schX={-0.7}
            schY={-0.1}
            schStemLength={0.4}
          />
          <port
            name="pin2"
            pinNumber={2}
            aliases={["2"]}
            direction="right"
            schX={0.7}
            schY={-0.1}
            schStemLength={0.4}
          />
          <schematictext
            schX={0}
            schY={0.3}
            text="{NAME}"
            fontSize={0.2}
            anchor="bottom_center"
          />
        </symbol>
      }
      supplierPartNumbers={{
        jlcpcb: ["C70076"],
      }}
      manufacturerPartNumber="nSMD050-24V"
      footprint={
        <footprint>
          <smtpad
            portHints={["pin1"]}
            pcbX="-1.445006mm"
            pcbY="0mm"
            width="1.1900916mm"
            height="1.7279874mm"
            shape="rect"
          />
          <smtpad
            portHints={["pin2"]}
            pcbX="1.445006mm"
            pcbY="0mm"
            width="1.1900916mm"
            height="1.7279874mm"
            shape="rect"
          />
          <silkscreenpath
            route={[
              { x: -0.9261856000000108, y: 1.0926064000000082 },
              { x: -2.1163026000000116, y: 1.0926064000000082 },
            ]}
          />
          <silkscreenpath
            route={[
              { x: 0.926210999999995, y: 1.0926064000000082 },
              { x: 2.1163026000000116, y: 1.0926064000000082 },
            ]}
          />
          <silkscreenpath
            route={[
              { x: -2.2687025999999975, y: 0.9402064000000081 },
              { x: -2.2687025999999975, y: -0.9402063999999939 },
            ]}
          />
          <silkscreenpath
            route={[
              { x: 2.2687025999999832, y: 0.9402064000000081 },
              { x: 2.2687025999999832, y: -0.9402063999999939 },
            ]}
          />
          <silkscreenpath
            route={[
              { x: -2.1163026000000116, y: -1.092606399999994 },
              { x: -0.9261856000000108, y: -1.092606399999994 },
            ]}
          />
          <silkscreenpath
            route={[
              { x: 2.1163026000000116, y: -1.092606399999994 },
              { x: 0.926210999999995, y: -1.092606399999994 },
            ]}
          />
          <silkscreenpath
            route={[
              { x: -1.4210854715202004e-14, y: 0 },
              { x: -0.08441074011676619, y: 0.2037855535998574 },
              { x: -0.11320167162334371, y: 0.422474390000005 },
              { x: -0.08441074011676619, y: 0.6411632264001383 },
              { x: 0, y: 0.8449487799999957 },
            ]}
          />
          <silkscreenpath
            route={[
              { x: 2.842170943040401e-14, y: 0 },
              { x: 0.08441074011679461, y: -0.20378555359984318 },
              { x: 0.11320167162334371, y: -0.42247438999999076 },
              { x: 0.08441074011679461, y: -0.6411632264001241 },
              { x: 0, y: -0.8449487799999957 },
            ]}
          />
          <silkscreentext
            text="{NAME}"
            pcbX="0.0127mm"
            pcbY="2.0922mm"
            anchorAlignment="center"
            fontSize="1mm"
          />
          <courtyardoutline
            outline={[
              { x: -2.2900518000000005, y: 1.1139936999999946 },
              { x: 2.2900518000000005, y: 1.1139936999999946 },
              { x: 2.2900518000000005, y: -1.1139936999999946 },
              { x: -2.2900518000000005, y: -1.1139936999999946 },
              { x: -2.2900518000000005, y: 1.1139936999999946 },
            ]}
          />
        </footprint>
      }
      cadModel={{
        objUrl: objPath,
        stepUrl: stepPath,
        pcbRotationOffset: 0,
        modelOriginPosition: { x: 0, y: -0.000012699999999199463, z: 0 },
      }}
      {...props}
    />
  )
}