Skip to content

milkv-duo LED definition #6

@System64fumo

Description

@System64fumo

Hello, I'm not sure if this was ever planned on being added/supported or if this is the right place to submit such suggestions.

The LED on the milkv duo could be defined like so:

MilkV Duo cv1800b-milkv-duo.dts:


gpio-leds {
	compatible = "gpio-leds";

	blue_led {
		gpios = <&porta 24 GPIO_ACTIVE_HIGH>;
	};
};

MilkV Duo 256m sg2002-milkv-duo256m.dts: (Not currently in this repo/upstream)

gpio-leds {
	compatible = "gpio-leds";

	blue_led {
		gpios = <&porte 2 GPIO_ACTIVE_HIGH>;
	};
};

The duo256m depends on gpio4 being defined in cv180x.dtsi first:

gpio4: gpio@5021000 {
	compatible = "snps,dw-apb-gpio";
	reg = <0x5021000 0x1000>;
	#address-cells = <1>;
	#size-cells = <0>;
	resets = <&rst RST_GPIO4>;

	porte: gpio-controller@0 {
		compatible = "snps,dw-apb-gpio-port";
		gpio-controller;
		#gpio-cells = <2>;
		ngpios = <32>;
		reg = <0>;
		interrupt-controller;
		#interrupt-cells = <2>;
		interrupts = <SOC_PERIPHERAL_IRQ(48) IRQ_TYPE_LEVEL_HIGH>;
	};
};

gpio pinouts for reference:
https://milkv.io/docs/duo/getting-started/duo#gpio-pinout
https://milkv.io/docs/duo/getting-started/duo256m#gpio-pinout

I personally don't have a cv1800b duo so i can't confirm that it works there, But i can confirm this working on my sg2002 duo.

Metadata

Metadata

Assignees

No one assigned

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions