Difference between revisions of "MIPI-DSI"

From Rockchip open source Document
Jump to: navigation, search
(Created page with " === * How to Enable MIPI Module === ---- '''1. Driver Compile'''<br/> Ensure below configures have been selected: <pre><code>CONFIG_ROCKCHIP_DW_MIPI_DSI=y</code> </pre> Be...")
 
Line 1: Line 1:
  
=== * How to Enable MIPI Module ===
+
= References =
  
----
+
[https://github.com/rockchip-linux/kernel/tree/release-4.4/drivers/gpu/drm/rockchip source code]
  
'''1. Driver Compile'''<br/> Ensure below configures have been selected:
+
[https://github.com/rockchip-linux/kernel/blob/release-4.4/Documentation/devicetree/bindings/display/rockchip/dw_mipi_dsi_rockchip.txt device-tree document]
<pre><code>CONFIG_ROCKCHIP_DW_MIPI_DSI=y</code>
 
</pre>
 
 
 
Bellow drivers have been compiled:
 
<pre><code>drivers/gpu/drm/rockchip/dw-mipi-dsi.c</code>
 
</pre>
 
  
'''2. DTS Setting'''<br/> 2.1 Enable MIPI Device Node:
+
&nbsp;
  
*Include the SoC DTS 'rk3288.dtsi' file.
+
= Tips =
*Set the MIPI device node state to 'okay'.
 
<pre><code>include "rk3288.dtsi"
 
&mipi_dsi {
 
        status = "okay";
 
};</code>
 
</pre>
 
  
2.2 MIPI device node parameters, there're only one property for MIPI device:
+
== Whether MIPI display card has been registered successfully ==
<pre><code>&mipi_dsi {
 
        panel {
 
                compatible ="boe,tv080wum-nl0";
 
                reg = <0>;
 
                backlight = <&backlight>;
 
                enable-gpios = <&gpio1 13 GPIO_ACTIVE_HIGH>;
 
                status = "okay";
 
        };
 
};</code>
 
</pre>
 
 
 
*"panel": Define the right panel device node.
 
 
 
----
 
 
 
=== * How To Debug MIPI Module ===
 
 
 
'''3. Whether MIPI display card has been registered successfully'''
 
  
 
If the MIPI display card has been created, it would create a sysfs debug directory.
 
If the MIPI display card has been created, it would create a sysfs debug directory.
Line 53: Line 23:
 
*Check the kernel log for more detail (dmesg | grep mipi)  
 
*Check the kernel log for more detail (dmesg | grep mipi)  
  
'''4. Check MIPI display card status: status, enabled, modes'''
+
== Check MIPI display card status: status, enabled, modes ==
 
<pre><code>$ cd /sys/class/drm/card0-DSI-1
 
<pre><code>$ cd /sys/class/drm/card0-DSI-1
 
$ cat status  # should printed "connected" or "disconnected"
 
$ cat status  # should printed "connected" or "disconnected"
Line 60: Line 30:
 
</pre>
 
</pre>
  
'''5. If you still have no picture on MIPI panel, please check bellow information:'''
+
== If you still have no picture on MIPI panel, please check bellow information: ==
  
 
*Check the MIPI panel power supply.  
 
*Check the MIPI panel power supply.  
Line 66: Line 36:
 
*Check the hardware connected status, or test the panel on workable board.  
 
*Check the hardware connected status, or test the panel on workable board.  
  
----
+
=== &nbsp; ===
 
 
=== * Reference MIPI DTS Configure: ===
 
<pre><code>include "rk3288.dtsi"
 
 
 
&mipi_dsi {
 
        status = "okay";
 
        panel {
 
                compatible ="boe,tv080wum-nl0";
 
                reg = <0>;
 
                backlight = <&backlight>;
 
                enable-gpios = <&gpio1 13 GPIO_ACTIVE_HIGH>;
 
                status = "okay";
 
        };
 
};</code></pre>
 

Revision as of 02:48, 11 October 2017

References

source code

device-tree document

 

Tips

Whether MIPI display card has been registered successfully

If the MIPI display card has been created, it would create a sysfs debug directory.

<code>$ ls /sys/class/drm/card0-DSI-1</code>

So you just need to check that directory. If that directory is missing in your machine board, please check:

  • Whether MIPI have been enabled in DTS files.
  • Whether MIPI panel have been registered successfully.
  • Whether you have available VOP module for MIPI.
  • Check the kernel log for more detail (dmesg | grep mipi)

Check MIPI display card status: status, enabled, modes

<code>$ cd /sys/class/drm/card0-DSI-1
$ cat status  # should printed "connected" or "disconnected"
$ cat enabled # should printed "enabled" or "disabled"
$ cat modes   # should printed the available mode list, like 1536x2048</code>

If you still have no picture on MIPI panel, please check bellow information:

  • Check the MIPI panel power supply.
  • Check the panel datasheet, ensure you have configured the timing and power sequence rightly.
  • Check the hardware connected status, or test the panel on workable board.