Jump to content

kerel

Validating
  • Posts

    1
  • Joined

  • Last visited

Reputation Activity

  1. Like
    kerel reacted to mhc in Enable SPI - Banana pi m2u   
    Hi martinayotte, many thanks for your comments.
     
    I changed armbianEnv.txt file according your suggestion, but spi dev did not appear, however I modified compatible property in .dtsi (from "allwinner,sun8i-spi" to  "allwinner,sun8i-h3-spi";  and after a reboot spidev0.0 does appear (even excluding overlay property in armbianEnv.txt).
     
    allwinner,sun8i-spi made sense to me, it is difficult for me to know which driver to use in each case.
     
    So, here is my working environment just in case someone has the same problem and wants to use it.
     
    sun8i-r40.dtsi spi0_pins: spi0-pins { pins = "PC0", "PC1", "PC2"; function = "spi0"; }; spi0: spi@1c05000 { compatible = "allwinner,sun8i-h3-spi"; device_type = "spidev"; reg = <0x01c05000 0x1000>; interrupts = <GIC_SPI 10 IRQ_TYPE_LEVEL_HIGH>; clocks = <&ccu CLK_BUS_SPI0>, <&ccu CLK_SPI0>; clock-names = "ahb", "mod"; pinctrl-names = "default"; pinctrl-0 = <&spi0_pins>; resets = <&ccu RST_BUS_SPI0>; status = "disabled"; #address-cells = <1>; #size-cells = <0>; }; And
     
    sun8i-r40-bananapi-m2-ultra.dts &spi0 { status = "okay"; num-chipselects = <1>; cs-gpios = <&pio 2 23 GPIO_ACTIVE_LOW>; // CS = PC23 spidev@0 { reg = <0>; compatible = "spidev"; status = "okay"; spi-max-frequency = <1000000>; }; };  
    Thanks again!
     
    mhc
×
×
  • Create New...

Important Information

Terms of Use - Privacy Policy - Guidelines