Jump to content

Recommended Posts

Posted

Hi all,

I wrote this dts to enable a high PG12 pin int the Bananapi M2P H3
can it be okay?

/dts-v1/;
/plugin/;

/ {
	compatible = "allwinner,sun8i-h3";

	fragment@0 {
		
		target = <&pio>;
		__overlay__ {
			bt_pins:bt_pins {
        		allwinner,pins = "PG12";
        		allwinner,function = "gpio_out";

			};
		};
	};

	fragment@1 {
	
		target-path = "/";
        	__overlay__ {
            		bt: bt {
                	compatible = "gpio-bt";
                	gpios = <&pio 6 12 1>;
 			};
    		};
	};
};

 

Posted

Hi @cusna ! Did you manage to get it working ? I'm trying to have this same functionality on my NanoPi Duo - only difference is pin number - PG11 - still no success.

Long week of digging in DT docs and internet resource and I'm still "thick as a brick" :(

Posted

I'm not good at it, and I don't know if it will be the right way, but to make my PG12 high after booting, I modified the sun8i-h3-bananapi-m2-plus.dtb file (in my case the board is a bananapi m2 plus) in /boot/dtb after decompiling it

adding then 

		pwr_din {
			label = "bananapi-m2-plus:din:pwr";
			gpios = <0xf 0x0 0x2 0x0>;
			default-state = "on";
		};

and recompiling. In your case you will have to change the door and the gpio depending on your processor which I don't know if it's an H3

Guest
This topic is now closed to further replies.
×
×
  • Create New...

Important Information

Terms of Use - Privacy Policy - Guidelines