astra/f1c100s

The code defines the physical pin layout, labels, and footprint for the F1C100S system-on-chip (SoC) component used in electronic devices.

Version
0.9.2
License
unset
Stars
0

src/ProfilePreview.tsx

import {
	F1C100SModule,
	F1C100SLcdSchematicBox,
	F1C100SStorageSchematicBox,
	F1C100SGpioSchematicBox,
	F1C100SAudioSchematicBox,
	F1C100SVideoTouchSchematicBox,
	F1C100SSystemSchematicBox,
	F1C100SPowerSchematicBox,
} from "./index";
import { MODULE_SIZE, type LayoutProfile } from "./profiles";

export function ProfilePreview({
	layoutProfile,
}: {
	layoutProfile: LayoutProfile;
}) {
	return (
		<board
			width={MODULE_SIZE}
			height={MODULE_SIZE}
			layers={4}
			minTraceWidth={0.12}
			minViaPadDiameter={0.45}
			minViaHoleDiameter={0.2}
			schLayout={{ layoutMode: "relative" }}
		>
			{/* Pours belong to the carrier/preview board, around the stored routes. */}
			<net name="GND" />
			{(["top", "inner1", "inner2", "bottom"] as const).map((layer) => (
				<copperpour
					{...{ key: layer }}
					name={`GND_${layer}`}
					layer={layer}
					connectsTo="net.GND"
					clearance={0.15}
					boardEdgeMargin={0.3}
					useThermalReliefs
					coveredWithSolderMask
				/>
			))}
			<schematicsheet
				name="interfaces"
				displayName="F1C100S — interfaces"
				sheetSize="A4"
			>
				<schematicsection name="lcd" displayName="RGB666 LCD" />
				<schematicsection name="storage" displayName="SPI / SDMMC" />
				<schematicsection name="gpio" displayName="UART / I²C / GPIO" />
				<schematicsection name="audio" displayName="Audio" />
				<schematicsection name="video" displayName="Video / touch" />
				<schematicsection name="system" displayName="Clock / reset / USB" />
				<F1C100SLcdSchematicBox
					moduleName="SOC"
					schX={-10}
					schY={5}
					schSectionName="lcd"
				/>
				<F1C100SStorageSchematicBox
					moduleName="SOC"
					schX={-1}
					schY={5}
					schSectionName="storage"
				/>
				<F1C100SGpioSchematicBox
					moduleName="SOC"
					schX={8}
					schY={5}
					schSectionName="gpio"
				/>
				<F1C100SAudioSchematicBox
					moduleName="SOC"
					schX={-10}
					schY={-4}
					schSectionName="audio"
				/>
				<F1C100SVideoTouchSchematicBox
					moduleName="SOC"
					schX={-1}
					schY={-4}
					schSectionName="video"
				/>
				<F1C100SSystemSchematicBox
					moduleName="SOC"
					schX={8}
					schY={-4}
					schSectionName="system"
				/>
			</schematicsheet>
			<schematicsheet
				name="power"
				displayName="F1C100S — power and support"
				sheetSize="A4"
			>
				<F1C100SModule
					name="SOC"
					layoutProfile={layoutProfile}
					schematicLayout="custom"
					connections={{ GND: "net.GND" }}
				/>
				<schematicsection name="power_pins" displayName="Power" />
				<F1C100SPowerSchematicBox
					moduleName="SOC"
					schX={-11}
					schY={6.5}
					schSectionName="power_pins"
				/>
			</schematicsheet>
		</board>
	);
}