T527 使用 DRM 驱动 edp 屏幕
-
进入 menuconfig 勾选 drm 驱动
./build.sh menuconfig
先勾选 DRM
再勾选 DRM 驱动
选择驱动的phy
选择屏幕
选择 general 屏幕面板驱动
关闭原来的 disp2 fbdev 驱动
配置设备树
edp_panel_backlight: edp_backlight { compatible = "pwm-backlight"; status = "okay"; brightness-levels = < 0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255>; default-brightness-level = <200>; enable-gpios = <&pio PI 5 GPIO_ACTIVE_HIGH>; /* power-supply = <®_backlight_12v>; */ pwms = <&a_pwm 5 5000000 0>; }; edp_panel: edp_panel { compatible = "edp-general-panel"; status = "okay"; power0-supply = <®_dcdc4>; backlight = <&edp_panel_backlight>; panel-timing { clock-frequency = <348577920>; /* pixel clock */ hactive = <2560>; hback-porch = <120>; hfront-porch = <88>; hsync-len = <32>; vactive = <1600>; vback-porch = <71>; vfront-porch = <28>; vsync-len = <5>; /* hor_sync_polarity */ hsync-active = <1>; /* ver_sync_polarity */ vsync-active = <1>; // unused now /* de-active = <1>; pixelclk-active = <1>; syncclk-active = <0>; interlaced; doublescan; doubleclk; */ }; ports { #address-cells = <1>; #size-cells = <0>; panel_in: port@0 { #address-cells = <1>; #size-cells = <0>; reg = <0>; edp_panel_in: endpoint@0 { reg = <0>; remote-endpoint = <&edp_panel_out>; }; }; }; };
和 drm_edp 的配置
&drm_edp { status = "okay"; edp_ssc_en = <0>; edp_ssc_mode = <0>; edp_psr_support = <0>; edp_colordepth = <8>; /* 6/8/10/12/16 */ edp_color_fmt = <0>; /* 0:RGB 1: YUV444 2: YUV422 */ lane1_sw = <0>; lane1_pre = <0>; lane2_sw = <0>; lane2_pre = <0>; lane3_sw = <0>; lane3_pre = <0>; efficient_training = <0>; sink_capacity_prefer = <1>; edid_timings_prefer = <1>; timings_fixed = <1>; vcc-edp-supply = <®_bldo3>; vdd-edp-supply = <®_dcdc2>; panel = <&edp_panel>; ports { edp_out: port@1 { edp_panel_out: endpoint@0 { reg = <0>; remote-endpoint = <&edp_panel_in>; }; }; }; };
-
@awwwwa 哪里可以找到T527的评估板呢?项目要做但找不到板
-
DSI
dsi1_backlight: backlight0 { compatible = "pwm-backlight"; status = "okay"; brightness-levels = < 0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255>; default-brightness-level = <200>; enable-gpios = <&pio PH 18 GPIO_ACTIVE_HIGH>; pwms = <&pwm0 0 50000 0>; }; &de { chn_cfg_mode = <3>; status = "okay"; }; &vo0 { status = "okay"; }; &dlcd1 { status = "okay"; }; &dsi1 { status = "okay"; pinctrl-0 = <&dsi1_4lane_pins_a>; pinctrl-1 = <&dsi1_4lane_pins_b>; pinctrl-names = "active","sleep"; ports { dsi1_out: port@1{ reg = <1>; dsi_out_panel: endpoint { remote-endpoint = <&panel_in>; }; }; }; panel: panel@0 { compatible = "panel-dsi"; status = "okay"; reg = <0>; power0-supply = <®_cldo4>; power1-supply = <®_cldo1>; reset-gpios = <&pio PD 22 GPIO_ACTIVE_HIGH>; //reset backlight = <&dsi1_backlight>; dsi,flags = <MIPI_DSI_MODE_VIDEO>; dsi,lanes = <4>; dsi,format = <0>; panel-init-sequence = [ 15 00 02 E0 00 15 00 02 E1 93 15 00 02 E2 65 15 00 02 E3 F8 15 00 02 80 03 15 00 02 E0 01 15 00 02 00 00 15 00 02 01 25 15 00 02 03 00 15 00 02 04 30 15 00 02 0C 74 15 00 02 17 00 15 00 02 18 C7 15 00 02 19 01 15 00 02 1A 00 15 00 02 1B C7 15 00 02 1C 01 15 00 02 24 FE 15 00 02 37 19 15 00 02 35 28 15 00 02 38 05 15 00 02 39 08 15 00 02 3A 12 15 00 02 3C 7E 15 00 02 3D FF 15 00 02 3E FF 15 00 02 3F 7F 15 00 02 40 06 15 00 02 41 A0 15 00 02 43 1E 15 00 02 44 0B 15 00 02 55 02 15 00 02 57 6A 15 00 02 59 0A 15 00 02 5A 2E 15 00 02 5B 1A 15 00 02 5C 15 15 00 02 5D 7F 15 00 02 5E 61 15 00 02 5F 50 15 00 02 60 43 15 00 02 61 3F 15 00 02 62 32 15 00 02 63 35 15 00 02 64 1F 15 00 02 65 38 15 00 02 66 36 15 00 02 67 36 15 00 02 68 54 15 00 02 69 42 15 00 02 6A 48 15 00 02 6B 39 15 00 02 6C 34 15 00 02 6D 26 15 00 02 6E 14 15 00 02 6F 02 15 00 02 70 7F 15 00 02 71 61 15 00 02 72 50 15 00 02 73 43 15 00 02 74 3F 15 00 02 75 32 15 00 02 76 35 15 00 02 77 1F 15 00 02 78 38 15 00 02 79 36 15 00 02 7A 36 15 00 02 7B 54 15 00 02 7C 42 15 00 02 7D 48 15 00 02 7E 39 15 00 02 7F 34 15 00 02 80 26 15 00 02 81 14 15 00 02 82 02 15 00 02 E0 02 15 00 02 00 52 15 00 02 01 5F 15 00 02 02 5F 15 00 02 03 50 15 00 02 04 77 15 00 02 05 57 15 00 02 06 5F 15 00 02 07 4E 15 00 02 08 4C 15 00 02 09 5F 15 00 02 0A 4A 15 00 02 0B 48 15 00 02 0C 5F 15 00 02 0D 46 15 00 02 0E 44 15 00 02 0F 40 15 00 02 10 5F 15 00 02 11 5F 15 00 02 12 5F 15 00 02 13 5F 15 00 02 14 5F 15 00 02 15 5F 15 00 02 16 53 15 00 02 17 5F 15 00 02 18 5F 15 00 02 19 51 15 00 02 1A 77 15 00 02 1B 57 15 00 02 1C 5F 15 00 02 1D 4F 15 00 02 1E 4D 15 00 02 1F 5F 15 00 02 20 4B 15 00 02 21 49 15 00 02 22 5F 15 00 02 23 47 15 00 02 24 45 15 00 02 25 41 15 00 02 26 5F 15 00 02 27 5F 15 00 02 28 5F 15 00 02 29 5F 15 00 02 2A 5F 15 00 02 2B 5F 15 00 02 2C 13 15 00 02 2D 1F 15 00 02 2E 1F 15 00 02 2F 01 15 00 02 30 17 15 00 02 31 17 15 00 02 32 1F 15 00 02 33 0D 15 00 02 34 0F 15 00 02 35 1F 15 00 02 36 05 15 00 02 37 07 15 00 02 38 1F 15 00 02 39 09 15 00 02 3A 0B 15 00 02 3B 11 15 00 02 3C 1F 15 00 02 3D 1F 15 00 02 3E 1F 15 00 02 3F 1F 15 00 02 40 1F 15 00 02 41 1F 15 00 02 42 12 15 00 02 43 1F 15 00 02 44 1F 15 00 02 45 00 15 00 02 46 17 15 00 02 47 17 15 00 02 48 1F 15 00 02 49 0C 15 00 02 4A 0E 15 00 02 4B 1F 15 00 02 4C 04 15 00 02 4D 06 15 00 02 4E 1F 15 00 02 4F 08 15 00 02 50 0A 15 00 02 51 10 15 00 02 52 1F 15 00 02 53 1F 15 00 02 54 1F 15 00 02 55 1F 15 00 02 56 1F 15 00 02 57 1F 15 00 02 58 40 15 00 02 5B 10 15 00 02 5C 06 15 00 02 5D 40 15 00 02 5E 00 15 00 02 5F 00 15 00 02 60 40 15 00 02 61 03 15 00 02 62 04 15 00 02 63 6C 15 00 02 64 6C 15 00 02 65 75 15 00 02 66 08 15 00 02 67 B4 15 00 02 68 08 15 00 02 69 6C 15 00 02 6A 6C 15 00 02 6B 0C 15 00 02 6D 00 15 00 02 6E 00 15 00 02 6F 88 15 00 02 75 BB 15 00 02 76 00 15 00 02 77 05 15 00 02 78 2A 15 00 02 E0 04 15 00 02 37 58 15 00 02 00 0E 15 00 02 02 B3 15 00 02 09 61 15 00 02 0E 48 15 00 02 E0 00 05 32 01 11 05 05 01 29 15 32 02 35 00 ]; panel-exit-sequence = [ 05 14 01 28 05 50 01 10 ]; display-timings { native-mode = <&dsi1_timing0>; dsi1_timing0: timing0 { clock-frequency = <68215200>; hback-porch = <20>; hactive = <800>; hfront-porch = <20>; hsync-len = <20>; vback-porch = <8>; vactive = <1280>; vfront-porch = <30>; vsync-len = <4>; }; }; port { panel_in: endpoint { remote-endpoint = <&dsi_out_panel>; }; }; }; }; &dsi0combophy { status = "disabled"; }; &dsi1combophy { status = "okay"; };
-
Copyright © 2024 深圳全志在线有限公司 粤ICP备2021084185号 粤公网安备44030502007680号