Hey guys, I am having some trouble with Device Tree Overlays and in need of some guidance. In a current project I want to connect an ilitek ili9341 2.2" screen to an Olimex Lime 2 and/or NanoPi NEO computer.
My current setup is a Olimex Lime 2 eMMC board running Linux lime2 4.7.3-sunxi and jesse.
I have found a .dts file and modified it to match my need on an Olimex Lime 2
/*
* Device Tree overlay for 2.2" SPI TFT from Elecfreaks
*
*/
/dts-v1/;
/plugin/;
/ {
compatible = "allwinner,sun7i-a20";
fragment@0 {
target = <&spi0>;
__overlay__ {
status = "okay";
spidev@0{
status = "disabled";
};
spidev@1{
status = "disabled";
};
};
};
fragment@1 {
target = <&gpio>;
__overlay__ {
rpi_display_pins: rpi_display_pins {
allwinner,pins = <66 129 128>;
allwinner,function = <1 1 1>; /* out out out in */
};
};
};
fragment@2 {
target = <&spi0>;
__overlay__ {
/* needed to avoid dtc warning */
#address-cells = <1>;
#size-cells = <0>;
rpidisplay: rpi-display@0{
compatible = "ilitek,ili9341";
reg = <0>;
pinctrl-names = "default";
pinctrl-0 = <&rpi_display_pins>;
spi-max-frequency = <32000000>;
rotate = <0>;
bgr;
fps = <30>;
buswidth = <8>;
reset-gpios = <&gpio 129 0>;
dc-gpios = <&gpio 128 0>;
led-gpios = <&gpio 66 1>;
debug = <0>;
};
};
};
__overrides__ {
speed = <&rpidisplay>,"spi-max-frequency:0";
rotate = <&rpidisplay>,"rotate:0";
fps = <&rpidisplay>,"fps:0";
debug = <&rpidisplay>,"debug:0";
};
};
Furthemore I have compiled it using dts (a newer version than the one built in to the Armbian mainline kernel image I am using) to a .dtb file and cat-ed it into a folder similar to `/sys/kernel/config/device-tree/overlays/mydtbo/dtbo`. Afterwards dmesg gives me the following errors:
[ 395.429019] __of_adjust_tree_phandle_references: Illegal property (size) 'fixup' @/__local_fixups__
[ 395.429058] of_resolve_phandles: __of_adjust_tree_phandle_references failed !
[ 395.429071] create_overlay: Failed to resolve tree
Am I forgetting to do something or is my modified .dts file simply wrong?