Difference between revisions of "Logo IMX8"

From ESS-WIKI
Jump to: navigation, search
 
(21 intermediate revisions by the same user not shown)
Line 11: Line 11:
 
*Modify partitions size  
 
*Modify partitions size  
 
**After change the u-boot logo maybe cause flash.bin to be too large (more then 8MB).  
 
**After change the u-boot logo maybe cause flash.bin to be too large (more then 8MB).  
**User should extend boot partition size by modify BOOT_SPACE value in "image_types_advantech_imx8.bbclass".  
+
**User should extend boot partition size by modify BOOT_SPACE value in "'''image_types_advantech_imx8.bbclass'''" and [http://ess-wiki.advantech.com.tw/view/IoTGateway/BSP/Linux/iMX8/Yocto_LBVA_User_Guide#Build_Instructions '''Rebuild Yocto'''].  
 
**Here is an example :   
 
**Here is an example :   
  
[[File:Logo IMX8 Modify HowToModify BOOTSIZE.jpg]]
+
:
 
+
::[[File:Logo IMX8 Modify HowToModify BOOTSIZE.jpg|RTENOTITLE]]  
*Reference [http://ess-wiki.advantech.com.tw/view/IoTGateway/BSP/Linux/iMX8/Yocto_LBVA_User_Guide#Setting_up_SDK i.MX8 Yocto3.0 user guide] to build and replace u-boot code.  
+
<ul style="list-style-type: circle;">
 +
<li>After generating the image&nbsp;file, user can '''[http://ess-wiki.advantech.com.tw/view/IoTGateway/BSP/Linux/iMX8/Yocto_LBVA_User_Guide#Creating_boot-up_on-board_flash_from_built_sdcard_image Burn&nbsp;SD Card]''' and test.</li>
 +
</ul>
  
 
==== '''MIPI-DSI to LVDS (AUO/G070VW01)''' ====
 
==== '''MIPI-DSI to LVDS (AUO/G070VW01)''' ====
  
#Change the dtb file used from&nbsp;imx8mm-rom5721-a1.dtb to&nbsp;imx8mm-rom5721-a1-dsi2lvds-g070vw01.dtb by modify&nbsp;CONFIG_DEFAULT_DEVICE_TREE in "imx8mm_rom5721a1_${MEM_SIZE}_defconfig".  
+
#Change the dtb file used from&nbsp;imx8mm-rom5721-a1.dtb to&nbsp;'''imx8mm-rom5721-a1-dsi2lvds-g070vw01.dtb '''by modify&nbsp;CONFIG_DEFAULT_DEVICE_TREE in "imx8mm_rom5721a1_${MEM_SIZE}_defconfig".  
 
<pre style="margin-left: 40px;">CONFIG_DEFAULT_DEVICE_TREE="imx8mm-rom5721-a1-dsi2lvds-g070vw01"</pre>
 
<pre style="margin-left: 40px;">CONFIG_DEFAULT_DEVICE_TREE="imx8mm-rom5721-a1-dsi2lvds-g070vw01"</pre>
 
<ol start="2">
 
<ol start="2">
Line 44: Line 46:
 
==== '''MIPI-DSI (AUO/G101UAN02)''' ====
 
==== '''MIPI-DSI (AUO/G101UAN02)''' ====
  
#&nbsp;Change the dtb file used from&nbsp;imx8mm-rom5721-a1.dtb to&nbsp;imx8mm-rom5721-a1-auog101uan02.dtb&nbsp;by modify&nbsp;CONFIG_DEFAULT_DEVICE_TREE in "imx8mm_rom5721a1_${MEM_SIZE}_defconfig".  
+
#&nbsp;Change the dtb file used from&nbsp;imx8mm-rom5721-a1.dtb to&nbsp;'''imx8mm-rom5721-a1-auog101uan02.dtb'''&nbsp;by modify&nbsp;CONFIG_DEFAULT_DEVICE_TREE in "imx8mm_rom5721a1_${MEM_SIZE}_defconfig".  
 
<pre style="margin-left: 40px;">CONFIG_DEFAULT_DEVICE_TREE="imx8mm-rom5721-a1-auog101uan02"</pre>
 
<pre style="margin-left: 40px;">CONFIG_DEFAULT_DEVICE_TREE="imx8mm-rom5721-a1-auog101uan02"</pre>
 
<ol start="2" style="list-style-type: decimal;">
 
<ol start="2" style="list-style-type: decimal;">
Line 55: Line 57:
 
<ul style="list-style-type: square;">
 
<ul style="list-style-type: square;">
 
<li>Step 3. to Step 5.&nbsp;are the same as above [http://ess-wiki.advantech.com.tw/view/Logo_IMX8#MIPI-DSI_to_LVDS_.28AUO.2FG070VW01.29 LVDS panel]</li>
 
<li>Step 3. to Step 5.&nbsp;are the same as above [http://ess-wiki.advantech.com.tw/view/Logo_IMX8#MIPI-DSI_to_LVDS_.28AUO.2FG070VW01.29 LVDS panel]</li>
 +
</ul>
 +
 +
&nbsp;
 +
 +
=== ROM-5722 ===
 +
 +
*u-boot config
 +
**imx8mp_rom5722a1_${MEM_SIZE}_defconfig
 +
**MEM_SIZE&nbsp;: 2G/4G/6G 
 +
*Modify partitions size
 +
**The steps are same with [http://ess-wiki.advantech.com.tw/view/Logo_IMX8#ROM-5721 ROM-5721]. 
 +
*After generating the image&nbsp;file, user can '''[http://ess-wiki.advantech.com.tw/view/IoTGateway/BSP/Linux/iMX8/Yocto_LBVA_User_Guide#Creating_boot-up_on-board_flash_from_built_sdcard_image Burn&nbsp;SD Card]''' and test.
 +
 +
==== '''LVDS (AUO/G070VW01)''' ====
 +
 +
#Change the dtb file used from&nbsp;imx8mp-rom5722-a1.dtb to&nbsp;'''imx8mp-rom5722-a1-lvds0-auo'''''.'''dtb'''''&nbsp;by modify&nbsp;CONFIG_DEFAULT_DEVICE_TREE in "imx8mp_rom5722a1_${MEM_SIZE}_defconfig".
 +
<pre style="margin-left: 40px;">CONFIG_DEFAULT_DEVICE_TREE="imx8mp-rom5722-a1-lvds0-auo"</pre>
 +
<ol start="2">
 +
<li>Enable some options in config.</li>
 +
</ol>
 +
<pre style="margin-left: 40px;">CONFIG_VIDEO_IMX8MP_LVDS=y
 +
CONFIG_DM_PWM=y
 +
CONFIG_BACKLIGHT_PWM=y
 +
CONFIG_PWM_IMX=y
 +
CONFIG_ADVANTECH_LOGO=y</pre>
 +
 +
*Step 3. to Step 5.&nbsp;are the same as above ROM-5721&nbsp;[http://ess-wiki.advantech.com.tw/view/Logo_IMX8#MIPI-DSI_to_LVDS_.28AUO.2FG070VW01.29 LVDS panel]
 +
 +
==== '''&nbsp;MIPI-DSI (AUO/G101UAN02)''' ====
 +
 +
#Change the dtb file used from&nbsp;imx8mp-rom5722-a1.dtb to&nbsp;'''imx8mp-rom5722-a1-auog101uan02.dtb'''&nbsp;by modify&nbsp;CONFIG_DEFAULT_DEVICE_TREE in "imx8mp_rom5722a1_${MEM_SIZE}_defconfig".
 +
<pre style="margin-left: 40px;">CONFIG_DEFAULT_DEVICE_TREE="imx8mp-rom5722-a1-auog101uan02"</pre>
 +
<ol start="2" style="list-style-type: decimal;">
 +
<li>Enable some options in config.</li>
 +
</ol>
 +
<pre style="margin-left: 40px;">CONFIG_DM_PWM=y
 +
CONFIG_BACKLIGHT_PWM=y
 +
CONFIG_PWM_IMX=y
 +
CONFIG_ADVANTECH_LOGO=y</pre>
 +
<ul style="list-style-type: square;">
 +
<li>Step 3. to Step 5.&nbsp;are the same as above&nbsp;ROM-5721&nbsp;[http://ess-wiki.advantech.com.tw/view/Logo_IMX8#MIPI-DSI_to_LVDS_.28AUO.2FG070VW01.29 LVDS panel]</li>
 +
</ul>
 +
 +
&nbsp;
 +
 +
=== RSB-3720 ===
 +
 +
*u-boot config
 +
**imx8mp_rsb3720a1_${MEM_SIZE}_defconfig
 +
**MEM_SIZE&nbsp;: 2G/4G/6G 
 +
*Modify partitions size
 +
**The steps are same with [http://ess-wiki.advantech.com.tw/view/Logo_IMX8#ROM-5721 ROM-5721]. 
 +
*After generating the image&nbsp;file, user can '''[http://ess-wiki.advantech.com.tw/view/IoTGateway/BSP/Linux/iMX8/Yocto_LBVA_User_Guide#Creating_boot-up_on-board_flash_from_built_sdcard_image Burn&nbsp;SD Card]''' and test.
 +
 +
==== '''LVDS (AUO/G070VW01)''' ====
 +
 +
#Change the dtb file used from&nbsp;imx8mp-rsb3720-a1.dtb to&nbsp;'''imx8mp-rsb3720-a1-lvds0-auo'''''.'''dtb'''''&nbsp;by modify&nbsp;CONFIG_DEFAULT_DEVICE_TREE in "imx8mp_rsb3720a1_${MEM_SIZE}_defconfig".
 +
<pre style="margin-left: 40px;">CONFIG_DEFAULT_DEVICE_TREE="imx8mp-rsb3720-a1-lvds0-auo"</pre>
 +
 +
#Enable some options in config.
 +
<pre style="margin-left: 40px;">CONFIG_VIDEO_IMX8MP_LVDS=y
 +
CONFIG_DM_PWM=y
 +
CONFIG_BACKLIGHT_PWM=y
 +
CONFIG_PWM_IMX=y
 +
CONFIG_ADVANTECH_LOGO=y</pre>
 +
 +
*Step 3. to Step 5.&nbsp;are the same as above ROM-5721&nbsp;[http://ess-wiki.advantech.com.tw/view/Logo_IMX8#MIPI-DSI_to_LVDS_.28AUO.2FG070VW01.29 LVDS panel]
 +
 +
==== '''&nbsp;MIPI-DSI (AUO/G101UAN02)''' ====
 +
 +
#Change the dtb file used from&nbsp;imx8mp-rsb3720-a1.dtb to&nbsp;'''imx8mp-rsb3720-a1-auog101uan02.dtb'''&nbsp;by modify&nbsp;CONFIG_DEFAULT_DEVICE_TREE in "imx8mp_rsb3720a1_${MEM_SIZE}_defconfig".
 +
<pre style="margin-left: 40px;">CONFIG_DEFAULT_DEVICE_TREE="imx8mp-rsb3720-a1-auog101uan02"</pre>
 +
<ol start="2" style="list-style-type: decimal;">
 +
<li>Enable some options in config.</li>
 +
</ol>
 +
<pre style="margin-left: 40px;">CONFIG_DM_PWM=y
 +
CONFIG_BACKLIGHT_PWM=y
 +
CONFIG_PWM_IMX=y
 +
CONFIG_ADVANTECH_LOGO=y</pre>
 +
<ul style="list-style-type: square;">
 +
<li>Step 3. to Step 5.&nbsp;are the same as above&nbsp;ROM-5721&nbsp;[http://ess-wiki.advantech.com.tw/view/Logo_IMX8#MIPI-DSI_to_LVDS_.28AUO.2FG070VW01.29 LVDS panel]</li>
 
</ul>
 
</ul>
  

Latest revision as of 05:11, 14 December 2023

 

U-Boot Logo Customization

ROM-5721

  • u-boot config
    • imx8mm_rom5721a1_${MEM_SIZE}_defconfig
    • MEM_SIZE : 1G/2G/4G
  • Modify partitions size
    • After change the u-boot logo maybe cause flash.bin to be too large (more then 8MB).
    • User should extend boot partition size by modify BOOT_SPACE value in "image_types_advantech_imx8.bbclass" and Rebuild Yocto.
    • Here is an example :
RTENOTITLE
  • After generating the image file, user can Burn SD Card and test.

MIPI-DSI to LVDS (AUO/G070VW01)

  1. Change the dtb file used from imx8mm-rom5721-a1.dtb to imx8mm-rom5721-a1-dsi2lvds-g070vw01.dtb by modify CONFIG_DEFAULT_DEVICE_TREE in "imx8mm_rom5721a1_${MEM_SIZE}_defconfig".
CONFIG_DEFAULT_DEVICE_TREE="imx8mm-rom5721-a1-dsi2lvds-g070vw01"
  1. Enable some options in config.
CONFIG_DM_PWM=y
CONFIG_BACKLIGHT_PWM=y
CONFIG_PWM_IMX=y
CONFIG_VIDEO_TC358775=y
CONFIG_ADVANTECH_LOGO=y
  1. Put logo bmp file into the directory "tools/logos/".
  2. Overwrite LOGO_BMP definition at tools/Makefile to specific customer's logo.
RTENOTITLE
  1. Reference i.MX8 Yocto3.0 user guide to build and replace u-boot code.

MIPI-DSI (AUO/G101UAN02)

  1.  Change the dtb file used from imx8mm-rom5721-a1.dtb to imx8mm-rom5721-a1-auog101uan02.dtb by modify CONFIG_DEFAULT_DEVICE_TREE in "imx8mm_rom5721a1_${MEM_SIZE}_defconfig".
CONFIG_DEFAULT_DEVICE_TREE="imx8mm-rom5721-a1-auog101uan02"
  1. Enable some options in config.
CONFIG_DM_PWM=y
CONFIG_BACKLIGHT_PWM=y
CONFIG_PWM_IMX=y
CONFIG_ADVANTECH_LOGO=y
  • Step 3. to Step 5. are the same as above LVDS panel

 

ROM-5722

  • u-boot config
    • imx8mp_rom5722a1_${MEM_SIZE}_defconfig
    • MEM_SIZE : 2G/4G/6G
  • Modify partitions size
  • After generating the image file, user can Burn SD Card and test.

LVDS (AUO/G070VW01)

  1. Change the dtb file used from imx8mp-rom5722-a1.dtb to imx8mp-rom5722-a1-lvds0-auo.dtb by modify CONFIG_DEFAULT_DEVICE_TREE in "imx8mp_rom5722a1_${MEM_SIZE}_defconfig".
CONFIG_DEFAULT_DEVICE_TREE="imx8mp-rom5722-a1-lvds0-auo"
  1. Enable some options in config.
CONFIG_VIDEO_IMX8MP_LVDS=y
CONFIG_DM_PWM=y
CONFIG_BACKLIGHT_PWM=y
CONFIG_PWM_IMX=y
CONFIG_ADVANTECH_LOGO=y
  • Step 3. to Step 5. are the same as above ROM-5721 LVDS panel

 MIPI-DSI (AUO/G101UAN02)

  1. Change the dtb file used from imx8mp-rom5722-a1.dtb to imx8mp-rom5722-a1-auog101uan02.dtb by modify CONFIG_DEFAULT_DEVICE_TREE in "imx8mp_rom5722a1_${MEM_SIZE}_defconfig".
CONFIG_DEFAULT_DEVICE_TREE="imx8mp-rom5722-a1-auog101uan02"
  1. Enable some options in config.
CONFIG_DM_PWM=y
CONFIG_BACKLIGHT_PWM=y
CONFIG_PWM_IMX=y
CONFIG_ADVANTECH_LOGO=y
  • Step 3. to Step 5. are the same as above ROM-5721 LVDS panel

 

RSB-3720

  • u-boot config
    • imx8mp_rsb3720a1_${MEM_SIZE}_defconfig
    • MEM_SIZE : 2G/4G/6G
  • Modify partitions size
  • After generating the image file, user can Burn SD Card and test.

LVDS (AUO/G070VW01)

  1. Change the dtb file used from imx8mp-rsb3720-a1.dtb to imx8mp-rsb3720-a1-lvds0-auo.dtb by modify CONFIG_DEFAULT_DEVICE_TREE in "imx8mp_rsb3720a1_${MEM_SIZE}_defconfig".
CONFIG_DEFAULT_DEVICE_TREE="imx8mp-rsb3720-a1-lvds0-auo"
  1. Enable some options in config.
CONFIG_VIDEO_IMX8MP_LVDS=y
CONFIG_DM_PWM=y
CONFIG_BACKLIGHT_PWM=y
CONFIG_PWM_IMX=y
CONFIG_ADVANTECH_LOGO=y
  • Step 3. to Step 5. are the same as above ROM-5721 LVDS panel

 MIPI-DSI (AUO/G101UAN02)

  1. Change the dtb file used from imx8mp-rsb3720-a1.dtb to imx8mp-rsb3720-a1-auog101uan02.dtb by modify CONFIG_DEFAULT_DEVICE_TREE in "imx8mp_rsb3720a1_${MEM_SIZE}_defconfig".
CONFIG_DEFAULT_DEVICE_TREE="imx8mp-rsb3720-a1-auog101uan02"
  1. Enable some options in config.
CONFIG_DM_PWM=y
CONFIG_BACKLIGHT_PWM=y
CONFIG_PWM_IMX=y
CONFIG_ADVANTECH_LOGO=y
  • Step 3. to Step 5. are the same as above ROM-5721 LVDS panel

 

Kernel Solution

Modify the drivers/video/logo/logo_linux_clut224.ppm

客製化logo 圖片儲存成png格式

  1. pngtopnm linuxlogo.png > linuxlogo.pnm // **首次使用者需要apt-get install netpbm**
    # pnmquant 224 linuxlogo.pnm > linuxlogo224.pnm // **轉成224色**
    # pnmtoplainpnm linuxlogo224.pnm > linuxlogo224.ppm

mv linuxlogo224.ppm logo_linux_clut224.ppm
logo_linux_clut224.ppm替換kernel/drivers/video/logo/logo_linux_clut224.ppm


1、裝載pngtopnm工具。
$ sudo apt-get install netpbm
注:裝載完以后就會有pngtopnm,pnmquant,pnmtoplainpnm三個工具。

2、選取logo的圖片:
 首先選取一個自己喜歡的圖片,然后通過GIMP軟體將該圖片儲存為.png格式,
 比如儲存為linuxlogo.png.


3、制作.ppm格式的圖片:
$ pngtopnm linuxlogo.png > linuxlogo.pnm
$ pnmquant 224 linuxlogo.pnm > linuxlogo224.pnm
$ pnmtoplainpnm linuxlogo224.pnm > linuxlogo224.ppm

或者
$bmptoppm linuxlogo.bmp > linuxlogo.ppm //生成ppm
$ppmquant 224 linuxlogo.ppm > linuxlogo224.ppm //轉換成224色彩
$pnmnoraw linuxlogo224.ppm > linuxlogo224.ppm //轉換成ascii格式


4、替代原有的圖片。
$ make clean SUB_DIR=./drivers/video/logo/ //來清除logo目錄下的.c和.o檔案
注:apus板子的圖片名叫logo_dec_clut224.ppm,所以只要用第三步生成的圖片替代即可。

Yocto Openembedded Solution

Change Yocto Openembedded Logo Solution

1. Download psplash:git clone git://git.yoctoproject.org/psplash

2. Change Image to .c file and .h file  : ./make-image-header.sh xxlogo.h POKY ,then will be create Image file xxlogo.c , xxlogo.h

3. Chage xxlogo.c : #include "psplash-poky-img.h change #include "xxlogo.h"

4. Create autogen.sh shell script, will be create Makefile.

Example

 

 #!/bin/bash 
acloal 
autoheader
automake
autoconf

7. Run "make" and create the "psplash" "psplash-write".

8. Copy psplash and psplash-write to rootfs in /usr/bin/

9. If you will be remove "progress bar", please remark the code.

Remove psplash_draw_progress function define in psplash.c. In psplash.c.

/* Draw progress bar border */
/*
  psplash_fb_draw_image (fb,
                          (fb->width  - BAR_IMG_WIDTH)/2,
                          SPLIT_LINE_POS(fb),
                          BAR_IMG_WIDTH,
                          BAR_IMG_HEIGHT,
                          BAR_IMG_BYTES_PER_PIXEL,
                          BAR_IMG_ROWSTRIDE,
                          BAR_IMG_RLE_PIXEL_DATA);
*/