Back to home page

OSCL-LXR

 
 

    


0001 /*
0002  * Copyright 2017 Lothar Waßmann <LW@KARO-electronics.de>
0003  *
0004  * This file is dual-licensed: you can use it either under the terms
0005  * of the GPL or the X11 license, at your option. Note that this dual
0006  * licensing only applies to this file, and not this project as a
0007  * whole.
0008  *
0009  *  a) This file is free software; you can redistribute it and/or
0010  *     modify it under the terms of the GNU General Public License
0011  *     version 2 as published by the Free Software Foundation.
0012  *
0013  *     This file is distributed in the hope that it will be useful,
0014  *     but WITHOUT ANY WARRANTY; without even the implied warranty of
0015  *     MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
0016  *     GNU General Public License for more details.
0017  *
0018  * Or, alternatively,
0019  *
0020  *  b) Permission is hereby granted, free of charge, to any person
0021  *     obtaining a copy of this software and associated documentation
0022  *     files (the "Software"), to deal in the Software without
0023  *     restriction, including without limitation the rights to use,
0024  *     copy, modify, merge, publish, distribute, sublicense, and/or
0025  *     sell copies of the Software, and to permit persons to whom the
0026  *     Software is furnished to do so, subject to the following
0027  *     conditions:
0028  *
0029  *     The above copyright notice and this permission notice shall be
0030  *     included in all copies or substantial portions of the Software.
0031  *
0032  *     THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
0033  *     EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES
0034  *     OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
0035  *     NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
0036  *     HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,
0037  *     WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
0038  *     FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR
0039  *     OTHER DEALINGS IN THE SOFTWARE.
0040  */
0041 
0042 / {
0043         aliases {
0044                 display = &display;
0045         };
0046 
0047         backlight: backlight {
0048                 compatible = "pwm-backlight";
0049                 pwms = <&pwm2 0 500000 PWM_POLARITY_INVERTED>;
0050                 pinctrl-names = "default";
0051                 pinctrl-0 = <&pinctrl_lcd1_pwr>;
0052                 enable-gpios = <&gpio2 31 GPIO_ACTIVE_HIGH>;
0053                 power-supply = <&reg_3v3>;
0054                 turn-on-delay-ms = <35>;
0055                 /*
0056                  * a poor man's way to create a 1:1 relationship between
0057                  * the PWM value and the actual duty cycle
0058                  */
0059                 brightness-levels = < 0  1  2  3  4  5  6  7  8  9
0060                                      10 11 12 13 14 15 16 17 18 19
0061                                      20 21 22 23 24 25 26 27 28 29
0062                                      30 31 32 33 34 35 36 37 38 39
0063                                      40 41 42 43 44 45 46 47 48 49
0064                                      50 51 52 53 54 55 56 57 58 59
0065                                      60 61 62 63 64 65 66 67 68 69
0066                                      70 71 72 73 74 75 76 77 78 79
0067                                      80 81 82 83 84 85 86 87 88 89
0068                                      90 91 92 93 94 95 96 97 98 99
0069                                     100>;
0070                 default-brightness-level = <50>;
0071         };
0072 
0073         lcd_panel: lcd-panel {
0074                 compatible = "edt,etm0700g0dh6";
0075                 pinctrl-names = "default";
0076                 pinctrl-0 = <&pinctrl_lcd0_pwr>;
0077                 enable-gpios = <&gpio3 29 GPIO_ACTIVE_HIGH>;
0078                 power-supply = <&reg_3v3>;
0079                 backlight = <&backlight>;
0080 
0081                 port {
0082                         lcd_panel_in: endpoint {
0083                                 remote-endpoint = <&lcd_out>;
0084                         };
0085                 };
0086         };
0087 
0088         display: disp0 {
0089                 compatible = "fsl,imx-parallel-display";
0090                 #address-cells = <1>;
0091                 #size-cells = <0>;
0092                 pinctrl-names = "default";
0093                 pinctrl-0 = <&pinctrl_disp0_1>;
0094                 status = "okay";
0095 
0096                 port@0 {
0097                         reg = <0>;
0098 
0099                         lcd_in: endpoint {
0100                                 remote-endpoint = <&ipu1_di0_disp0>;
0101                         };
0102                 };
0103 
0104                 port@1 {
0105                         reg = <1>;
0106 
0107                         lcd_out: endpoint {
0108                                 remote-endpoint = <&lcd_panel_in>;
0109                         };
0110                 };
0111 
0112                 display-timings {
0113                         VGA {
0114                                 clock-frequency = <25200000>;
0115                                 hactive = <640>;
0116                                 vactive = <480>;
0117                                 hback-porch = <48>;
0118                                 hsync-len = <96>;
0119                                 hfront-porch = <16>;
0120                                 vback-porch = <31>;
0121                                 vsync-len = <2>;
0122                                 vfront-porch = <12>;
0123                                 hsync-active = <0>;
0124                                 vsync-active = <0>;
0125                                 de-active = <1>;
0126                                 pixelclk-active = <0>;
0127                         };
0128 
0129                         ETV570 {
0130                                 u-boot,panel-name = "edt,et057090dhu";
0131                                 clock-frequency = <25200000>;
0132                                 hactive = <640>;
0133                                 vactive = <480>;
0134                                 hback-porch = <114>;
0135                                 hsync-len = <30>;
0136                                 hfront-porch = <16>;
0137                                 vback-porch = <32>;
0138                                 vsync-len = <3>;
0139                                 vfront-porch = <10>;
0140                                 hsync-active = <0>;
0141                                 vsync-active = <0>;
0142                                 de-active = <1>;
0143                                 pixelclk-active = <0>;
0144                         };
0145 
0146                         ET0350 {
0147                                 u-boot,panel-name = "edt,et0350g0dh6";
0148                                 clock-frequency = <6413760>;
0149                                 hactive = <320>;
0150                                 vactive = <240>;
0151                                 hback-porch = <34>;
0152                                 hsync-len = <34>;
0153                                 hfront-porch = <20>;
0154                                 vback-porch = <15>;
0155                                 vsync-len = <3>;
0156                                 vfront-porch = <4>;
0157                                 hsync-active = <0>;
0158                                 vsync-active = <0>;
0159                                 de-active = <1>;
0160                                 pixelclk-active = <0>;
0161                         };
0162 
0163                         ET0430 {
0164                                 u-boot,panel-name = "edt,et0430g0dh6";
0165                                 clock-frequency = <9009000>;
0166                                 hactive = <480>;
0167                                 vactive = <272>;
0168                                 hback-porch = <2>;
0169                                 hsync-len = <41>;
0170                                 hfront-porch = <2>;
0171                                 vback-porch = <2>;
0172                                 vsync-len = <10>;
0173                                 vfront-porch = <2>;
0174                                 hsync-active = <0>;
0175                                 vsync-active = <0>;
0176                                 de-active = <1>;
0177                                 pixelclk-active = <1>;
0178                         };
0179 
0180                         ET0500 {
0181                                 clock-frequency = <33264000>;
0182                                 hactive = <800>;
0183                                 vactive = <480>;
0184                                 hback-porch = <88>;
0185                                 hsync-len = <128>;
0186                                 hfront-porch = <40>;
0187                                 vback-porch = <33>;
0188                                 vsync-len = <2>;
0189                                 vfront-porch = <10>;
0190                                 hsync-active = <0>;
0191                                 vsync-active = <0>;
0192                                 de-active = <1>;
0193                                 pixelclk-active = <0>;
0194                         };
0195 
0196                         ET0700 { /* same as ET0500 */
0197                                 u-boot,panel-name = "edt,etm0700g0dh6";
0198                                 clock-frequency = <33264000>;
0199                                 hactive = <800>;
0200                                 vactive = <480>;
0201                                 hback-porch = <88>;
0202                                 hsync-len = <128>;
0203                                 hfront-porch = <40>;
0204                                 vback-porch = <33>;
0205                                 vsync-len = <2>;
0206                                 vfront-porch = <10>;
0207                                 hsync-active = <0>;
0208                                 vsync-active = <0>;
0209                                 de-active = <1>;
0210                                 pixelclk-active = <0>;
0211                         };
0212 
0213                         ETQ570 {
0214                                 clock-frequency = <6596040>;
0215                                 hactive = <320>;
0216                                 vactive = <240>;
0217                                 hback-porch = <38>;
0218                                 hsync-len = <30>;
0219                                 hfront-porch = <30>;
0220                                 vback-porch = <16>;
0221                                 vsync-len = <3>;
0222                                 vfront-porch = <4>;
0223                                 hsync-active = <0>;
0224                                 vsync-active = <0>;
0225                                 de-active = <1>;
0226                                 pixelclk-active = <0>;
0227                         };
0228 
0229                         CoMTFT { /* same as ET0700 but with inverted pixel clock */
0230                                 u-boot,panel-name = "edt,etm0700g0edh6";
0231                                 clock-frequency = <33264000>;
0232                                 hactive = <800>;
0233                                 vactive = <480>;
0234                                 hback-porch = <88>;
0235                                 hsync-len = <128>;
0236                                 hfront-porch = <40>;
0237                                 vback-porch = <33>;
0238                                 vsync-len = <2>;
0239                                 vfront-porch = <10>;
0240                                 hsync-active = <0>;
0241                                 vsync-active = <0>;
0242                                 de-active = <1>;
0243                                 pixelclk-active = <1>;
0244                         };
0245                 };
0246         };
0247 };
0248 
0249 &ipu1_di0_disp0 {
0250         remote-endpoint = <&lcd_in>;
0251 };