Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- // The "ports" linking lcdc to its panel are officially required, and you
- // get a warning for omitting them. But, if you uncomment them then lcdc
- // actually no longer works. The framebuffer never appears. Lol.
- &lcdc {
- status = "okay";
- // "straight" if d0 is blue, typical for 16-bit color (supports RGB565, BGR888, and XBGR8888)
- // "crossed" if d0 is red, typical for 24-bit color (supports BGR565, RGB888, and XRGB8888)
- blue-and-red-wiring = "straight";
- // port {
- // lcd_output: endpoint {
- // remote-endpoint = <&lcd_input>;
- // };
- // };
- };
- / {
- lcd-panel {
- compatible = "ti,tilcdc,panel";
- pinctrl-names = "default";
- pinctrl-0 = <&lcd_pins>;
- enable-gpios = <&gpio1 13 0>;
- // port {
- // lcd_input: endpoint {
- // remote-endpoint = <&lcd_output>;
- // };
- // };
- panel-info {
- // all these properties are required by the driver,
- // even the ones which are completely useless.
- // pixel format
- bpp = <16>; // bits/pixel
- // by default, data and OE change on rising pclk edge.
- // following property selects falling edge:
- //invert-pxl-clk;
- // pclk edge on which hsync and vsync change:
- sync-edge = <1>; // 0=falling, 1=rising
- // if hsync/vsync don't use same pclk edge as data/OE
- // then sync is delayed by 1/2 clock, increasing the
- // back porch and decreasing the front porch time.
- // useless but must be 1
- sync-ctrl = <1>;
- // DMA config
- dma-burst-sz = <16>; // burst size (words)
- fifo-th = <4>; // FIFO threshold
- // for palette mode only, which isn't even supported
- raster-order = <0>;
- fdd = <0x80>;
- //tft-alt-mode;
- // for passive matrix only, which isn't even supported
- ac-bias = <255>;
- ac-bias-intrpt = <0>;
- };
- display-timings {
- // ranges supported by LCDC:
- // 1-2048 vactive, hactive
- // 1-64 vsync, hsync
- // 0-255 vfront, vback
- // 1-256 hfront, vback
- // hactive must additionally be multiple of 16 pixels.
- native-mode = <&lcd_mode>;
- lcd_mode: 1024x786-60 {
- vactive = < 768>;
- hactive = <1024>;
- // our panel specifies:
- // min typ max
- // hblank 216 320 440 pixels
- // vblank 6 38 80 lines
- // vfreq 56 60 75 Hz
- // pfreq 57.5 64.9 74.4 MHz
- //
- // hsync/vsync not used
- // VESA timings for 1024x768p60:
- // (+/- after sync indicates polarity)
- // DMT GTF CVT
- // vfront 3 1 3
- // vsync 6- 3+ 4+
- // vback 29 23 23
- //
- // vblank 38 27 30
- // vtotal 806 795 798
- //
- // hfreq ~48.4 47.7 ~47.9 kHz
- //
- // hfront 24 56 48
- // hsync 136- 104- 104-
- // hback 160 160 152
- //
- // hblank 320 320 304
- // htotal 1344 1344 1328
- //
- // pfreq ~65.0 ~64.1 ~63.6 MHz
- //
- // DMT matches panel 'typ', let's use that.
- // note: you can also specify <min typ max>
- vfront-porch = < 3>;
- vsync-len = < 6>;
- vback-porch = < 29>;
- hfront-porch = < 24>;
- hsync-len = < 136>;
- hback-porch = < 160>;
- clock-frequency = <65000000>;
- // 0 = active low
- // 1 = active high
- // omitted = unused
- de-active = <1>; // lcdc ignores this
- pixelclk-active = <1>; // lcdc ignores this
- vsync-active = <0>;
- hsync-active = <1>;
- };
- };
- };
- };
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement