LuckfoxTECH / luckfox-pico

luckfox-pico sdk
245 stars 82 forks source link

After customizing the buildroot, the device disappeared #132

Open nopnop2002 opened 2 weeks ago

nopnop2002 commented 2 weeks ago

I'm using the official buildroot image of Mini board.

This is before customizing the buildroot. Mini-Buildroot-device-1

I followed this tutorial and customized the buildroot.

https://wiki.luckfox.com/Luckfox-Pico/Luckfox-Pico-RV1103/Luckfox-Pico-SDK

device file is gone. Mini-Buildroot-device-2

x-magic commented 2 weeks ago

It seems PWM pins needs to be explicitly enabled before accessible in /sys/class/pwm https://wiki.luckfox.com/Luckfox-Pico/Luckfox-Pico-RV1106/Luckfox-Pico-Pro-Max/Luckfox-Pico-PWM#22-enable-pwm

nopnop2002 commented 6 days ago

This is probably because this file is not configured correctly.

$ cat rv1103g-luckfox-pico-mini-b.dts
// SPDX-License-Identifier: (GPL-2.0+ OR MIT)
/*
 * Copyright (c) 2023 Luckfox Electronics Co., Ltd.
 */

/dts-v1/;

#include "rv1103.dtsi"
#include "rv1106-evb.dtsi"
#include "rv1103-luckfox-pico-ipc.dtsi"

/ {
        model = "Luckfox Pico Mini B";
        compatible = "rockchip,rv1103g-38x38-ipc-v10", "rockchip,rv1103";
};

/**********SFC**********/
&sfc {
        status = "okay";
        flash@0 {
                compatible = "spi-nand";
                reg = <0>;
                spi-max-frequency = <75000000>;
                spi-rx-bus-width = <4>;
                spi-tx-bus-width = <1>;
        };
};

/**********SDMMC**********/
&sdmmc {
        max-frequency = <50000000>;
        no-sdio;
        no-mmc;
        bus-width = <4>;
        cap-mmc-highspeed;
        cap-sd-highspeed;
        disable-wp;
        pinctrl-names = "default";
        pinctrl-0 = <&sdmmc0_clk &sdmmc0_cmd &sdmmc0_det &sdmmc0_bus4>;
        status = "okay";
};

/**********ETH**********/
&gmac {
        status = "disabled";
};

/**********USB**********/
&usbdrd_dwc3 {
        status = "okay";
        dr_mode = "peripheral";
};

/**********SPI**********/
/* SPI0_M0 */
&spi0 {
        status = "disabled";
        spidev@0 {
                spi-max-frequency = <50000000>;
        };
};

/**********I2C**********/
/* I2C3_M1 */
&i2c3 {
        status = "disabled";
        clock-frequency = <100000>;
};

/**********UART**********/
/* UART3_M1 */
&uart3 {
        status = "disabled";
};

/* UART4_M1 */
&uart4 {
        status = "disabled";
};

/**********PWM**********/
/* PWM1_M0 */
&pwm1 {
        status = "disabled";
};