Quectel SC66 Display Driver Development Guide V1.0
Quectel SC66 Display Driver Development Guide V1.0
Development Guide
Rev. SC66_Display_Driver_Development_Guide_V1.0
Date: 2019-10-12
Status: Released
www.quectel.com
Smart Module Series
SC66 Display Driver Development Guide
Our aim is to provide customers with timely and comprehensive service. For any
assistance, please contact our company headquarters:
GENERAL NOTES
QUECTEL OFFERS THE INFORMATION AS A SERVICE TO ITS CUSTOMERS. THE INFORMATION
PROVIDED IS BASED UPON CUSTOMERS’ REQUIREMENTS. QUECTEL MAKES EVERY EFFORT
TO ENSURE THE QUALITY OF THE INFORMATION IT MAKES AVAILABLE. QUECTEL DOES NOT
MAKE ANY WARRANTY AS TO THE INFORMATION CONTAINED HEREIN, AND DOES NOT ACCEPT
ANY LIABILITY FOR ANY INJURY, LOSS OR DAMAGE OF ANY KIND INCURRED BY USE OF OR
RELIANCE UPON THE INFORMATION. ALL INFORMATION SUPPLIED HEREIN IS SUBJECT TO
CHANGE WITHOUT PRIOR NOTICE.
COPYRIGHT
THE INFORMATION CONTAINED HERE IS PROPRIETARY TECHNICAL INFORMATION OF
QUECTEL WIRELESS SOLUTIONS CO., LTD. TRANSMITTING, REPRODUCTION, DISSEMINATION
AND EDITING OF THIS DOCUMENT AS WELL AS UTILIZATION OF THE CONTENT ARE
FORBIDDEN WITHOUT PERMISSION. OFFENDERS WILL BE HELD LIABLE FOR PAYMENT OF
DAMAGES. ALL RIGHTS ARE RESERVED IN THE EVENT OF A PATENT GRANT OR
REGISTRATION OF A UTILITY MODEL OR DESIGN.
Copyright © Quectel Wireless Solutions Co., Ltd. 2019. All rights reserved.
SC66_Display_Driver_Development_Guide 1 / 29
Smart Module Series
SC66 Display Driver Development Guide
History
SC66_Display_Driver_Development_Guide 2 / 29
Smart Module Series
SC66 Display Driver Development Guide
Contents
1 Introduction .......................................................................................................................................... 6
4 Appendix ............................................................................................................................................. 29
SC66_Display_Driver_Development_Guide 3 / 29
Smart Module Series
SC66 Display Driver Development Guide
Table Index
SC66_Display_Driver_Development_Guide 4 / 29
Smart Module Series
SC66 Display Driver Development Guide
Figure Index
SC66_Display_Driver_Development_Guide 5 / 29
Smart Module Series
SC66 Display Driver Development Guide
1 Introduction
This document describes how to use the Display Serial Interface (DSI) to bring up the display panel on
the Android platform of Quectel SC66 module.
This document only describes the important parts of display driver development.
◼NOTE
SC66_Display_Driver_Development_Guide 6 / 29
Smart Module Series
SC66 Display Driver Development Guide
This chapter describes the display XML tags required to configure the Android kernel and the little kernel
(LK) to bring up the panel. The following sections provide detailed information on input entries,
descriptions and possible values of the XML tags that can be used in the display parser module for the
GCDB, version 1.0.
NOTE
This document only describes the important parameters. The unspecified parameters usually do not need
to be modified.
Take the following steps to develop display driver for any display panel and platform. The procedure can
also be found at device/qcom/common/display/tools/README.txt.
2. Enter the tools directory #cd device/qcom/common/display/tools, the following information will appear.
SC66_Display_Driver_Development_Guide 7 / 29
Smart Module Series
SC66 Display Driver Development Guide
NOTE
In most cases, LCD is in video mode which is determined by the LCD module type.
5. Generate the device tree file (.dtsi) and header file (.h) by executing the following command:
#cp device/qcom/common/display/tools/dsi-panel-hx8394f-720p-video.dtsi
kernel/msm-4.4/arch/arm64/boot/dts/qcom/
source build/envsetup.sh
lunch sdm660_64-userdebug
make bootimage
SC66_Display_Driver_Development_Guide 8 / 29
Smart Module Series
SC66 Display Driver Development Guide
This chapter defines the specific XML tag entries for the panel.
The parser expects the entries in the following table to be part of the <GCDB> XML tag.
MAJOR_VERSION.MINOR_VERSION
Each version is bind to be a set of For example: in 1.0, 1 means the major
Version
panel tags. version and 0 means the minor
version.
Name used to generate the .dtsi file
PanelId See the following XML input example.
for kernel.
Name used to generate the header file
PanelH See the following XML input example.
for LK.
For example:
SC66_Display_Driver_Development_Guide 9 / 29
Smart Module Series
SC66 Display Driver Development Guide
The parser expects all other entries to be part of the <GCDB> and <PanelEntry> tag. Please refer to the
following XML input example for more information.
For example:
SC66_Display_Driver_Development_Guide 10 / 29
Smart Module Series
SC66 Display Driver Development Guide
The following table defines different panel resolution-specific tags. All dimensions should be provided in
pixel format.
For example:
SC66_Display_Driver_Development_Guide 11 / 29
Smart Module Series
SC66 Display Driver Development Guide
The panel color information includes color format, swap values, and border color, some of which are
defined in the following table.
24 = 888_RGB
18 = 666_RGB
16 = 565_RGB
ColorFormat Defines the bits per pixel.
12 = 444_RGB
8 = 332_RGB
3 = 111_RGB
0 = DSI_RGB_SWAP_RGB
1 = DSI_RGB_SWAP_RBG
Defines pixel component color 2 = DSI_RGB_SWAP_BGR
ColorOrder
order between MSM and panel. 3 = DSI_RGB_SWAP_BRG
4 = DSI_RGB_SWAP_GRB
5 = DSI_RGB_SWAP_GBR
For example:
SC66_Display_Driver_Development_Guide 12 / 29
Smart Module Series
SC66 Display Driver Development Guide
This chapter describes the on/off commands sent to the panel. Users can send all valid DSI commands to
the panel.
Generally speaking, <OnCommandState> and <OffCommandState> only need to keep the default
values.
SC66_Display_Driver_Development_Guide 13 / 29
Smart Module Series
SC66 Display Driver Development Guide
Each command needs the input information listed in the following table. The current parser supports one
complete command per line.
Some LCD may need to wait for several milliseconds before sending the next command. Then the
parameter “Wait” need to be modified.
For example:
The parameters provided by LCD module manufacturer in the following format are preferable:
SC66_Display_Driver_Development_Guide 14 / 29
Smart Module Series
SC66 Display Driver Development Guide
When parameters are provided in the above formats, the <OnCommand> parameters will be:
REGISTER,FF,3,98,81,03
REGISTER,01,01,00
0x39, 0x01, 0x00, 0x00, 0x00, 0x00, 0x04, 0xFF, 0x98, 0x81, 0x03,
0x39, 0x01, 0x00, 0x00, 0x00, 0x00, 0x02, 0x01, 0x00,
3. Usually the last two commands of <OnCommand> are available as shown below, but some LCD
chips do not need them.
SC66_Display_Driver_Development_Guide 15 / 29
Smart Module Series
SC66 Display Driver Development Guide
The following table describes the video mode panel configuration entries.
Usually, these parameters do not need to be modified. Users may need to note the parameter
“TrafficMode” which may vary with the LCD chip. For example:
SC66_Display_Driver_Development_Guide 16 / 29
Smart Module Series
SC66 Display Driver Development Guide
The foloowing table lists the DSI panel’s lane configuration entries.
For example:
SC66_Display_Driver_Development_Guide 17 / 29
Smart Module Series
SC66 Display Driver Development Guide
The following table describes all panel’s physical configuration register entries.
For example:
The panel requires the PHY value setup for “bitclk” in the DSI PHY register. The
80-NH713-1_U_DSI_Timing_Parameters_User_Interactive_Spreadsheet.xlsm in 80-NH713-1_DSI.zip
(the zip file is available in tools directory) can be used to calculate the timing values automatically.
NOTE
Please use Microsoft Excel (Microsoft Excel 2016 is recommended) to open this file. Other tools, such as
WPS, are not recommended.
SC66_Display_Driver_Development_Guide 18 / 29
Smart Module Series
SC66 Display Driver Development Guide
2. Open the DSI and MDP Registers sheet. Input frame rate/lane numbers/panel resolution/porch/ chip
value to the area framed in red line in the example shown below:
SC66_Display_Driver_Development_Guide 19 / 29
Smart Module Series
SC66 Display Driver Development Guide
NOTE
If the spreadsheet requires to change the porches to be multiple of 4 or make it even, please change it
accordingly and also update the panel porch node. Users can refer to the user instructions in the Excel
sheet.
3. Open the DSI PHY Timing Setting sheet to see the calculated DSI-related clock rate in the blue fields.
Press CTRL+J, a value of INVALID will appear in the Check for T_CLK_ZERO field. Then press
CTRL+K to recalculate T_CLK_ZERO to VALID, as shown below.
SC66_Display_Driver_Development_Guide 20 / 29
Smart Module Series
SC66 Display Driver Development Guide
The spreadsheet will show the PHY value setup for “bitclk” which the panel requires in the DSI PHY
register.
4. Update the panel XML file <PanelTimings> with the values listed above that obtained from the Excel
worksheet.
The following is an example. The following values are copied from Figure 5.
<PanelTimings>"0x7B, 0x1A, 0x10, 0x00, 0x3C, 0x42, 0x14, 0x1C, 0x15, 0x03,
0x04,0x00"</PanelTimings>
5. Copy the program value for T_CLK_POST and T_CLK_PRE fields obtained from the Excel
worksheet into the panel XML. The values in the Excel worksheet are in decimal. Make sure that they
are converted to HEX before updating the two elements.
<TClkPost>0x4</TClkPost>
<TClkPre>0x1A</TClkPre>
SC66_Display_Driver_Development_Guide 21 / 29
Smart Module Series
SC66 Display Driver Development Guide
6. For SC66, DSI PHY 2.0.0 timing configuration needs to be added, and it can be found in
kernel/msm-4.4/arch/arm/boot/dts/qcom/sdm660-mdss-panels.dtsi, as shown below:
SC66_Display_Driver_Development_Guide 22 / 29
Smart Module Series
SC66 Display Driver Development Guide
All TE-related entries listed in the following table are only used in Android kernel.
These parameters are only used in command mode panel. If the LCD is a video mode panel, these
parameters can be ignored.
SC66_Display_Driver_Development_Guide 23 / 29
Smart Module Series
SC66 Display Driver Development Guide
For example
0=PWM GPIO
1=WLED
2=DCS COMMANDS (for
BLPMICControlType PMIC controller for current backlight.
OLED panel backlight
controller)
3=LPG
For example:
SC66_Display_Driver_Development_Guide 24 / 29
Smart Module Series
SC66 Display Driver Development Guide
After the procedure in Chapter 2.1 is completed, the file dsi-panel-hx8394f-720p-video.dtsi will be
generated, then copy it to the following directory kernel/msm-4.4/arch/arm64/boot/dts/qcom/. And then
configure the kernel to add a new panel according to the following steps.
SC66_Display_Driver_Development_Guide 25 / 29
Smart Module Series
SC66 Display Driver Development Guide
qcom,mdss-dsi-bl-pmic-control-type: a string that specifies the implementation of backlight control for this
panel.
If the following values are configured in the red-framed area of the above figure, then:
"bl_ctrl_pwm" indicates backlight controlled by PWM
"bl_ctrl_wled" indicates backlight controlled by WLED
"bl_ctrl_dcs" indicates backlight controlled by DCS commands (for OLED panel backlight controller).
Others: Unknown backlight control.
⚫ For the PWM default backlight control, select the “control-type”, “pwm-frequency” and “pwms” shown
below:
&dsi_hx8394f_720p_video {
qcom,mdss-dsi-bl-pmic-control-type = "bl_ctrl_pwm";
qcom,mdss-dsi-bl-pmic-pwm-frequency = <100>;/* in microseconds */
qcom,mdss-dsi-bl-pmic-bank-select = <0>;
qcom,mdss-dsi-bl-pwm-pmi;
pwms = <&pm660l_pwm_4 0 0>;
qcom,panel-supply-entries = <&dsi_panel_pwr_supply>;
};
SC66_Display_Driver_Development_Guide 26 / 29
Smart Module Series
SC66 Display Driver Development Guide
⚫ For the WLED backlight control, select the “control-type” shown as below.
&dsi_dual_nt35597_truly_video {
qcom,mdss-dsi-bl-pmic-control-type = "bl_ctrl_wled";
qcom,mdss-dsi-bl-min-level = <1>;
qcom,mdss-dsi-bl-max-level = <4095>;
qcom,mdss-dsi-mode-sel-gpio-state = "dual_port";
qcom,panel-supply-entries = <&dsi_panel_pwr_supply>;
};
qcom,mdss-dsi-bl-min-level = <1>;
qcom,mdss-dsi-bl-max-level = <255>;
qcom,mdss-dsi-bl-pmic-control-type = "bl_ctrl_dcs";
SC66_Display_Driver_Development_Guide 27 / 29
Smart Module Series
SC66 Display Driver Development Guide
The bootloader of SC66 was replaced by UEFI and the source code of UEFI has not been publiclly
unavailable. Therefore, to configure the UEFI, users should take the following steps:
After this, Quectel will update the bin file xbl.elf for users.
After being updated by Quectel, users are able to update the xbl.elf file with Fastboot by the following
commands to verify whether the LCD in UEFI has been brought up. If not, please contact Quectel.
SC66_Display_Driver_Development_Guide 28 / 29
Smart Module Series
SC66 Display Driver Development Guide
4 Appendix
Abbreviation Description
LK Little Kernel
TE Tearing Effect
SC66_Display_Driver_Development_Guide 29 / 29