Hi,
I am using a IMX6qdl-sabrelite board with a customized ft5x06 touch lvd screen as below:
* the touch screen is connected to I2C0 rather than I2C2
* the interrupt is GPIO_19 rather than GPIO_9
* the backlight control is on pwm1 through DSIP0_DAT8 rather than pwm4 through MX6QDL_PAD_SD1_CMD_PWM4_OUT
so firstly, I added a structure into file "imx6qdl-sabrelite.dtsi" as below
ft5x06_ts@38 {
compatible = "ft5x06-ts,ft5x06-ts";
reg = <0x38>
interrupt-parent = <&gpio4>
interrupts = <19 2>
wakeup-gpios = <&gpio4 5 2>
};
under '&i2c1'
Although it is unnecessary, but I also removed the line of "MX6QDL_PAD_GPIO_9_GPIO1_IO09 0x80000000 /*I2C3 touch screen interrupt */" from
imx6q-sabrelite{
pinctrl_hog_1: hoggrp-1{
fsl,pins = <
...
/*MX6QDL_PAD_GPIO_9_GPIO1_IO09 0x80000000 I2C3 touch screen interrupt */
...
>;
}
...
};
then I test it, and everything works fine, i.e. the machine displays and responses to every touch fine. so I move on to change the backlight.
1) I changed backlight_lvds to
backlight_lvds{
...
pwms = <&pwm1 0 5000000> /* from pwms = <&pwm4 0 5000000> */
...
};
2) I changed pwm1 in file imx6qdl.dtsi to
pwm1 {
...
MX6QDL_PAD_DISP0_DAT8_PWM1_OUT 0x1b0b1 /* from MX6QDL_PAD_SD1_DAT3_PWM1_OUT 0x1b0b1*/
...
};
3) I removed "backlight_lcd" from file imx6qdl-sabrelite.dtsi
After I run the new dts, the backlight control seems working fine, I can change it with command 'echo 7 > /sys/class/backlight/backlight_lvds.0/brightness'. But the problem is my already worked touch screen seems not working any more. things are still display correctly, but machine is not response to any touch.
I then removed structure 'lcd0: lcd@0' from file imx6qdl-sabrelite.dtsi, element 'pwm1grp-1: ipu1grp-1' and 'ipu1grp-4: ipu1grp-4' from structure ipu1 to eliminate all reference to MX6QDL_PAD_DISP0_DAT8_xxx, but problem did not get fix. What did it do wrong? how can I get the problem fix?
Would be much appreciated if you can give me a hand.
below are some 'fdt' print out on the runtime device tree
fdt print /soc/aips-bus@02100000/i2c@021a0000/ft5x06_ts@38
ft5x06_ts@38 {
compatible = "ft5x06-ts,ft5x06-ts";
reg = <0x00000038>;
interrupt-parent = <0x0000002e>;
interrupts = <0x00000013 0x00000002>;
wakeup-gpios = <0x0000002e 0x00000013 0x00000000>;
};
fdt print /soc/aips-bus@0210000/i2c@021a8000
i2c@021a8000 {
#address-cells = <0x00000001>;
#size-cells = <0x00000000>;
compatible = "fsl,imx6q-i2c", "fsl,imx21-i2c";
reg = <0x021a8000 0x00004000>;
interrupts = <0x00000000 0x00000026 0x00000004>;
clocks = <0x00000002 0x0000007f>;
status = "okay";
clock-frequency = <0x000186a0>;
pinctrl-names = "default";
pinctrl-0 = <0x00000029>;
egalax_ts@04 {
compatible = "eeti,egalax_ts";
reg = <0x00000004>;
interrupt-parent = <0x00000010>;
interrupts = <0x00000009 0x00000002>;
wakeup-gpios = <0x00000010 0x00000009 0x00000000>;
};
ili210x@41 {
compatible = "ili210x";
reg = <0x00000041>;
interrupt-parent = <0x00000010>;
interrupts = <0x00000009 0x00000002>;
wakeup-gpios = <0x00000010 0x00000009 0x00000000>;
};
ov5640@3c {
compatible = "ovti,ov5640";
reg = <0x0000003c>;
pinctrl-names = "default";
pinctrl-0 = <0x0000002a 0x0000002b>;
clocks = <0x0000002c 0x00000000>;
clock-names = "csi_mclk";
DOVDD-supply = <0x00000026>;
AVDD-supply = <0x00000023>;
DVDD-supply = <0x00000026>;
pwn-gpios = <0x00000005 0x0000000d 0x00000001>;
rst-gpios = <0x00000005 0x0000000e 0x00000000>;
csi_id = <0x00000001>;
mclk = <0x016e3600>;
mclk_source = <0x00000000>;
ipu_id = <0x00000001>;
};
tsc2004@48 {
compatible = "tsc2004,tsc2004";
reg = <0x00000048>;
pinctrl-names = "default";
pinctrl-0 = <0x0000002d>;
interrupt-parent = <0x0000002e>;
interrupts = <0x00000014 0x00000002>;
wakeup-gpios = <0x0000002e 0x00000014 0x00000000>;
};
};
fdt print /soc/aips-bus@02000000/iomuxc@020e0000/pwm1
pwm1 {
pwm1grp-1 {
fsl,pins = <0x00000190 0x000004a4 0x00000000 0x00000002 0x00000000 0x0001b0b1>;
linux,phandle = <0x0000000b>;
phandle = <0x0000000b>;
};
};
fdt print /soc/aips-bus202000000/pwm@02080000
pwm@02080000 {
#pwm-cells = <0x00000002>;
compatible = "fsl,imx6q-pwm", "fsl,imx27-pwm";
reg = <0x02080000 0x00004000>;
interrupts = <0x00000000 0x00000053 0x00000000>;
clocks = <0x00000002 0x0000003e 0x00000002 0x00000091>;
clock-names = "ipg", "per";
pinctrl-names = "default";
pinctrl-0 = <0x0000000b>;
status = "okay";
linux,phandle = <0x00000038>;
phandle = <0x00000038>;
};
fdt print /backlight_lvds
backlight_lvds {
compatible = "pwm-backlight";
pwms = <0x00000038 0x00000000 0x004c4b40>;
brightness-levels = <0x00000000 0x00000004 0x00000008 0x00000010 0x00000020 0x00000040 0x00000080 0x000000ff>;
default-brightness-level = <0x00000007>;
};
fdt print /soc/aips-bus@02000000/iomuxc@020e000/ipu1
ipu1 {
ipu1grp-2 {
fsl,pins = * 0x12005334 [0x00000120];
linux,phandle = <0x00000025>;
phandle = <0x00000025>;
};
ipu1grp-3 {
fsl,pins = * 0x12005494 [0x000001c8];
};
};