You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

71 lines
2.2 KiB

  1. /*
  2. * Device Tree overlay for Adafruit Mini PiTFT 1.3" and 1.5" 240x240 Display
  3. *
  4. */
  5. /dts-v1/;
  6. /plugin/;
  7. / {
  8. compatible = "brcm,bcm2835", "brcm,bcm2708", "brcm,bcm2709";
  9. fragment@0 {
  10. target = <&spi0>;
  11. __overlay__ {
  12. status = "okay";
  13. spidev@0{
  14. status = "disabled";
  15. };
  16. spidev@1{
  17. status = "disabled";
  18. };
  19. };
  20. };
  21. fragment@1 {
  22. target = <&gpio>;
  23. __overlay__ {
  24. pitft_pins: pitft_pins {
  25. brcm,pins = <25>;
  26. brcm,function = <1>; /* out */
  27. brcm,pull = <0>; /* none */
  28. };
  29. };
  30. };
  31. fragment@2 {
  32. target = <&spi0>;
  33. __overlay__ {
  34. /* needed to avoid dtc warning */
  35. #address-cells = <1>;
  36. #size-cells = <0>;
  37. pitft: pitft@0{
  38. compatible = "sitronix,st7789v";
  39. reg = <0>;
  40. pinctrl-names = "default";
  41. pinctrl-0 = <&pitft_pins>;
  42. spi-max-frequency = <32000000>;
  43. rotate = <0>;
  44. width = <240>;
  45. height = <240>;
  46. buswidth = <8>;
  47. dc-gpios = <&gpio 25 0>;
  48. led-gpios = <&gpio 26 0>;
  49. debug = <0>;
  50. };
  51. };
  52. };
  53. __overrides__ {
  54. speed = <&pitft>,"spi-max-frequency:0";
  55. rotate = <&pitft>,"rotate:0";
  56. width = <&pitft>,"width:0";
  57. height = <&pitft>,"height:0";
  58. fps = <&pitft>,"fps:0";
  59. debug = <&pitft>,"debug:0";
  60. };
  61. };