RK3288 EDP调试方法
一.软件配置:
1.首先下载更新RK3288 Android5.1 SDK,最新提交:
1. commit:3e3038c
2. Message:Android->framework:fix btn default color
复制代码
2.软件修改配置:
1)打开kernel/arch/arm/boot/dts/firefly-rk3288-reload.dts,修改如下:
包含lcd的dtsi:
1. -#include "lcd-box.dtsi"
2. +#include "lcd-LP079Qx1.dtsi"
复制代码
关闭vga和gb2hdmi:
1. rgb2hdmi {
2. compatible = "firefly,rgb2hdmi";
3. power-gpio = <&gpio7 GPIO_A2 GPIO_ACTIVE_HIGH>;
4. lcdc-gpio = <&gpio7 GPIO_A3 GPIO_ACTIVE_HIGH>;
5. hpd-gpio = <&gpio4 GPIO_D3 GPIO_ACTIVE_HIGH>;
6. rockchip,source = <0>; //0: LCDC0; 1:LCDC1
7. rockchip,prop =<PRMRY>;//<PRMRY>;//<EXTEND>
8. - status = "okay";
9. + status = "disabled";
10. };
11. vga_ddc@50 {
12. compatible = "firefly,_ddc";
13. reg = <0x50>;
14. rockchip,source = <0>; //0: LCDC0; 1:LCDC1
15. rockchip,prop = <PRMRY>;//<EXTEND>
16. - status = "okay";
17. + status = "disabled";
18. };
复制代码
使能tp
1. mt@40 {
2. - status = "disabled";
3. + status = "okay";
4. compatible = "firefly,gsl3680";
5. reg = <0x40>;
6. touch-gpio= <&gpio5 GPIO_B0 IRQ_TYPE_EDGE_RISING>;
7. reset-gpio = <&gpio7 GPIO_B1 GPIO_ACTIVE_LOW>;
8. max-y =<2048>;
9. max-x =<1536>;
10. flip-x = <1>;
11. flip-y = <1>;
12. swap-xy = <0>;
13. };
复制代码
使能mpu6050
1. mpu6050:mpu@68{
2. + status = "okay";
3. - status = "disabled";
4. compatible = "mpu6050";
5. reg = <0x68>;
6. mpu-int_config = <0x10>;
7. mpu-level_shifter = <0>;
8. mpu-orientation = <0 1 0 1 0 0 0 01>;
9. orientation-x= <1>;
10. orientation-y= <1>;
11. orientation-z= <1>;
12. irq-gpio = <&gpio7 GPIO_B1IRQ_TYPE_LEVEL_LOW>;
13. mpu-debug = <0>;
14. };
复制代码
修改timing配置和添加屏使能脚:
1. &disp_timings {
2. - native-mode = <&timing1>;
3. + native-mode = <&timing0>;
4. };
5.
6. &rk_screen {
7. @@ -611,6 +611,29 @@
8. status = "okay";
9. rockchip,iommu-enabled = <1>;
10. rockchip,prop = <PRMRY>;
11. + power_ctr: power_ctr {
12. + rockchip,debug = <1>;
13. +
14. + lcd_en:lcd_en {
15. + rockchip,power_type = <GPIO>;
16. + gpios =<&gpio5 GPIO_C3 GPIO_ACTIVE_HIGH>;
17. + rockchip,delay = <10>;
18. + };
19. +
20. + /*
21. + lcd_cs:lcd_cs {
22. + rockchip,power_type = <GPIO>;
23. + gpios =<&gpio7 GPIO_A4 GPIO_ACTIVE_HIGH>;
24. + rockchip,delay = <10>;
25. + };
26. + */
27. + lcd_rst:lcd_rst {
28. + rockchip,power_type = <GPIO>;
29. + gpios =<&gpio5 GPIO_C1 GPIO_ACTIVE_LOW>;
30. + rockchip,delay = <0>;
31. + };
32. + };
33. };
复制代码
使能背光pwm:
1. &pwm1 {
2. - status = "disabled";
3. + status = "okay";
4. };
复制代码
2)打开kernel/arch/arm/boot/dts/rk3288.dtsi,修改如下:
关闭CTR_GTCLKS和复用脚:
1. rockchip,ctrbits = <
2. (0
3. |RKPM_CTR_PWR_DMNS
4. - |RKPM_CTR_GTCLKS
5. + // |RKPM_CTR_GTCLKS
6.
7. rockchip,isp,cifphy = <1>;
8. rockchip,isp,mipiphy1,reg =<0xff968000 0x4000>;
9. - rockchip,gpios = <&gpio7 GPIO_B5GPIO_ACTIVE_HIGH>;
10. + // rockchip,gpios =<&gpio7 GPIO_B5 GPIO_ACTIVE_HIGH>;
复制代码
3)打开kernel/arch/arm/configs/firefly-rk3288-reload_defconfig,修改如下:
修改触摸defconfig配置:
1. +CONFIG_TOUCHSCREEN_GSLX680_MT70817V2=y
复制代码
4)打开device/rockchip/rk3288/rk3288_box/system.prop,修改如下: (此修改需要重新编译上层)
修改图标大小
1. -ro.sf.lcd_density=160
2. +ro.sf.lcd_density=320
复制代码
5)打开frameworks/base/packages/SettingsProvider/src/com/android/providers/settings/DatabaseHelper.java,修改如下:(此修改需要重新编译上层)
添加屏幕旋转,此修改可以根据自己需求添加
1. loadSetting(stmt, Settings.System.HIDE_ROTATION_LOCK_TOGGLE_FOR_ACCESSIBILITY,
2. - "1");
3. + "0");
复制代码
三.编译烧写:
1)编译烧写内核:
1. tvbox-51/kernel$ makefirefly-rk3288-reload_defconfig
2. tvbox-51/kernel$ makefirefly-rk3288-reload.img -j4
复制代码
烧写kernel.img和resouce.img
2)编译烧写Android:
1. tvbox-51$ . build.sh
2. tvbox-51$ make installclean
3. tvbox-51$ make -j8
复制代码
烧写system.img和misc.img
完成
RK3288软硬件资料和技术交流可加QQ7643066
感谢分享