shibosoftwaredev/f1c100s-linux-nema8-stepper-controller

Restores component part numbers and CAD models, removes test-point 3D bodies, and validates that solder paste exists only on top-side SMT pads without altering copper or DRC.

Version
0.3.5
License
unset
Stars
0

firmware/carrier.dtsi

/* Include after suniv-f1c100s.dtsi in the complete board DTS.
 * Hardware integration fragment only: it is not a complete bootable DTS. */
#include <dt-bindings/gpio/gpio.h>
#include <dt-bindings/interrupt-controller/irq.h>

/ {
    aliases {
        ethernet0 = &ethernet0;
        serial0 = &uart0; /* dedicated to the STM32 motion controller */
        spi0 = &spi0;
        spi1 = &spi1;
    };
    /* Do not select uart0 as stdout: it is the safety-controller link. */
};

&pio {
    carrier_spi1: spi1-pe-pins {
        pins = "PE7", "PE8", "PE9", "PE10";
        function = "spi1";
    };
    carrier_eth_gpio: ethernet-control-pins {
        pins = "PE5", "PE6";
        function = "gpio_in";
    };
};

/* PE0 TX -> STM32 PA3; PE1 RX <- STM32 PA2, 115200 8N1. */
&uart0 {
    pinctrl-names = "default";
    pinctrl-0 = <&uart0_pe_pins>;
    status = "okay";
};

&spi0 {
    pinctrl-names = "default";
    pinctrl-0 = <&spi0_pc_pins>;
    status = "okay";

    flash@0 {
        compatible = "winbond,w25q128", "jedec,spi-nor";
        reg = <0>;
        spi-max-frequency = <24000000>;
        /* Partition layout must match the SPL/U-Boot/Linux image. */
    };
};

&spi1 {
    pinctrl-names = "default";
    pinctrl-0 = <&carrier_spi1>;
    status = "okay";

    ethernet0: ethernet@0 {
        compatible = "wiznet,w5500";
        reg = <0>;
        spi-max-frequency = <30000000>;
        interrupt-parent = <&pio>;
        interrupts = <4 6 IRQ_TYPE_LEVEL_LOW>; /* PE6 */
        reset-gpios = <&pio 4 5 GPIO_ACTIVE_LOW>; /* PE5 */
    };
};

&usb_otg {
    dr_mode = "peripheral";
    status = "okay";
};

&usbphy { status = "okay"; };