ark1668e_c281.dts 4.9 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246
  1. // SPDX-License-Identifier: GPL-2.0
  2. /dts-v1/;
  3. #include "ark1668e.dtsi"
  4. #include "ark1668e-pinctrl.dtsi"
  5. //#define I2S_USE_EXTERNAL_CODEC
  6. //#define DYNAMIC_TRACK_DISPLAY
  7. / {
  8. i2c-gpio-0 {
  9. #address-cells = <1>;
  10. #size-cells = <0>;
  11. compatible = "i2c-gpio";
  12. gpios = <&gportf 25 0 /* SDA */
  13. &gportf 24 0 /* SCL */
  14. >;
  15. i2c-gpio,delay-us = <6>; /* clk freq = 500/delay KHz */
  16. i2c-gpio,scl-output-only;
  17. amp:drv_bd37033@40{
  18. status = "okay";
  19. compatible = "arkmicro,drv_bd37033";
  20. reg = <0x40>; /* i2c address(7 bit)*/
  21. flout-gain = <65>; /*min = 0 ;max = 95*/
  22. frout-gain = <65>; /*min = 0 ;max = 95*/
  23. rlout-gain = <65>; /*min = 0 ;max = 95*/
  24. rrout-gain = <65>; /*min = 0 ;max = 95*/
  25. #sound-dai-cells = <0>;
  26. };
  27. };
  28. i2c-gpio-1 {
  29. #address-cells = <1>;
  30. #size-cells = <0>;
  31. compatible = "i2c-gpio";
  32. gpios = <&gportf 29 0 /* SDA */
  33. &gportf 28 0 /* SCL */
  34. >;
  35. i2c-gpio,delay-us = <6>; /* clk freq = 500/delay KHz */
  36. i2c-gpio,scl-output-only;
  37. ark7116: ark7116@B2 {
  38. compatible = "arkmicro,ark7116_1668e_devb";
  39. reset-gpio = <&gportf 27 0>;
  40. reg = <0x59>; /* i2c address(7 bits) */
  41. default-channel = <0>;
  42. carback-config = <1>;
  43. port {
  44. ark7116_0: endpoint@0{
  45. remote-endpoint = <&itu_1>;
  46. };
  47. };
  48. };
  49. rn6752: da380@4e {
  50. compatible = "arkmicro,ark1668e_rn6752";
  51. //reset-gpio = <&gpio3 11 0>;
  52. reg = <0x2c>; /* i2c address(7 bits) */
  53. default-channel = <0>; /* 0:channel A; 1:channel B */
  54. camera-format = <3>; /* 0:unknown; 1:cvbs pal; 2:cvbs ntsc; 3:720p pal; 4:720p ntsc */
  55. port {
  56. rn6752_0: endpoint@0{
  57. remote-endpoint = <&itu_0>;
  58. };
  59. };
  60. };
  61. mclk: mclk@12K {
  62. #clock-cells = <0>;
  63. compatible = "fixed-clock";
  64. clock-frequency = <12288000>;
  65. };
  66. escodec: es8316@10 {
  67. compatible = "arkmicro,es8316";
  68. reg = <0x10>;
  69. clocks = <&mclk>;
  70. clock-names = "mclk";
  71. #sound-dai-cells = <0>;
  72. };
  73. };
  74. cs4334_codec: ark1668e_cs4334_codec {
  75. status = "okay";
  76. compatible = "arkmicro,ark1668e_cs4334_codec";
  77. clock-names = "cs4334_mclk";
  78. clocks = <&mclk>;
  79. #sound-dai-cells = <0>;
  80. };
  81. cs5343_codec: ark1668e_cs5343_codec {
  82. status = "okay";
  83. compatible = "arkmicro,ark1668e_cs5343_codec";
  84. clock-names = "cs5343_mclk";
  85. clocks = <&mclk>;
  86. #sound-dai-cells = <0>;
  87. };
  88. adc {
  89. compatible = "arkmicro,ark1668e-adc";
  90. reg = <0xe4500000 0x1000
  91. 0xe4900000 0x1000>;
  92. interrupts = <GIC_SPI 4 IRQ_TYPE_LEVEL_HIGH>;
  93. };
  94. };
  95. &lcdc {
  96. display = <&display0>;
  97. pinctrl-names = "default";
  98. /* set pad only to prevent gpio use */
  99. pinctrl-0 = <&pinctrl_lcd_dlvds>;
  100. display0: display@0 {
  101. interface-type = "DLVDS";
  102. lvds-con = <0x4545>;
  103. lvds-con2 = <0xfa000101>;
  104. bits-per-pixel = <32>;
  105. fb-buffer-nums = <3>;
  106. power-control-gpio = <&gportd 0 GPIO_ACTIVE_HIGH>;
  107. lcd-wiring-mode = "RGB";
  108. lcdcon-backlight;
  109. pwms = <&pwm0 0 50000>;
  110. pwm-names = "backlight";
  111. backlight-value = <30>;
  112. backlight-delay = <200>;
  113. display-timings {
  114. native-mode = <&timing0>;
  115. timing0: timing0 {
  116. clock-frequency = <40000000>;
  117. hactive = <1280>;
  118. vactive = <480>;
  119. hback-porch = <20>;
  120. hfront-porch = <45>;
  121. vback-porch = <5>;
  122. vfront-porch = <10>;
  123. hsync-len = <5>;
  124. vsync-len = <6>;
  125. hsync-active = <1>;
  126. vsync-active = <1>;
  127. de-active = <0>;
  128. pixelclk-active = <0>;
  129. };
  130. };
  131. };
  132. };
  133. &usb0_phy {
  134. compatible = "usb-nop-xceiv";
  135. #phy-cells = <0>;
  136. status = "okay";
  137. };
  138. &usb0 {
  139. status = "okay";
  140. };
  141. &usb1_phy {
  142. compatible = "usb-nop-xceiv";
  143. #phy-cells = <0>;
  144. status = "okay";
  145. };
  146. &usb1 {
  147. status = "okay";
  148. };
  149. #ifdef DYNAMIC_TRACK_DISPLAY
  150. &uart3 {
  151. use-in-kernel;
  152. use-for-mcu;
  153. };
  154. #endif
  155. &ituin {
  156. status = "okay";
  157. channel = <1>; //for no pinctr
  158. x_pos = <0>;
  159. y_pos = <0>;
  160. //width = <800>; //if this line is commented out, it is displayed in full screen
  161. height = <720>;
  162. port {
  163. itu_0: endpoint@0 {
  164. is-itu601;
  165. vsync-active = <1>;
  166. hsync-active = <1>;
  167. remote-endpoint = <&rn6752_0>;
  168. channel = <0>;
  169. };
  170. itu_1: endpoint@1 {
  171. remote-endpoint = <&ark7116_0>;
  172. channel = <1>;
  173. };
  174. };
  175. };
  176. &ethernet {
  177. status = "okay";
  178. phy-handle = <&eth_phy0>;
  179. phy-mode = "rgmii";
  180. //snps,reset-gpio = <&gportd 15 GPIO_ACTIVE_LOW>;
  181. //snps,reset-active-low;
  182. //snps,reset-delays-us = <0 10000 1000000>;
  183. mdio {
  184. compatible = "snps,dwmac-mdio";
  185. #address-cells = <1>;
  186. #size-cells = <0>;
  187. eth_phy0: ethernet-phy@0 {
  188. /* Realtek RTL8211F (0x001cc916) */
  189. reg = <1>;
  190. };
  191. };
  192. };
  193. &i2c0 {
  194. gt911: touchscreen@5d {
  195. compatible = "goodix,gt911";
  196. reg = <0x5d>;
  197. interrupt-parent = <&gportf>;
  198. interrupts = <22 IRQ_TYPE_EDGE_FALLING>;
  199. irq-gpios = <&gportf 22 GPIO_ACTIVE_HIGH>;
  200. reset-gpios = <&gportf 23 GPIO_ACTIVE_HIGH>;
  201. //touchscreen-inverted-x;
  202. };
  203. };
  204. &gpu{
  205. shared-mem-size =<0x18000000>;
  206. };
  207. &can0{
  208. status = "disabled";
  209. };
  210. &can1{
  211. status = "disabled";
  212. };