I have MCP2515 connected to spiB port of zero
connections are follows
MCP2515 <==> Zero Header Pins
MISO -21
MOSI -19
SS - 24
INT - 18
SCLK - 23
I am have error in compiling overlay
/dts-v1/;
/plugin/;
/ {
compatible = “radxa,zero”, “amlogic,g12a”;
fragment@0 {
target = <&spicc1>;
__overlay__ {
mcp2515_int_pin: mcp2515_int_pin {
amlogic,pins = <&gpio 73>;
amlogic,function = "irq";
amlogic,pull = <0>;
};
};
};
fragment@1 {
target-path = "/";
__overlay__ {
can_mcp2515_osc: can-mcp2515-osc {
compatible = "fixed-clock";
clock-frequency = <16000000>;
#clock-cells = <0>;
};
};
};
fragment@2 {
target = <&spicc1>;
__overlay__ {
pinctrl-0 = <&spicc1_pins &spicc1_ss0_pins>;
pinctrl-names = "default";
#address-cells = <1>;
#size-cells = <0>;
status = "okay";
mcp2515: spidev@0 {
compatible = "microchip,mcp2515";
reg = <0>;
interrupt-parent = <&gpio_intc>;
interrupts = <60 2>;
spi-max-frequency = <16000000>;
clocks = <&can_mcp2515_osc>;
pinctrl-0 = <&mcp2515_int_pin>;
};
};
};
};