Difference between revisions of "IoTGateway/BSP/Android/How to do about first porting"

From ESS-WIKI
Jump to: navigation, search
 
(4 intermediate revisions by the same user not shown)
Line 9: Line 9:
 
<span style="font-size:small;"><span style="font-family:times new roman,times,serif;">If you will be fast porting the new device in android 6.0.1_2.1.0, you can step by step to do.</span></span>
 
<span style="font-size:small;"><span style="font-family:times new roman,times,serif;">If you will be fast porting the new device in android 6.0.1_2.1.0, you can step by step to do.</span></span>
  
<span style="font-size:small;"><span style="font-family:times new roman,times,serif;"></span></span>
 
  
<span style="font-size:small;"><span style="font-family:times new roman,times,serif;">1. U-boot&nbsp;: Add your device android defconfig.</span></span>
+
 
 +
 
 +
 
 +
<span style="font-size:medium;"><span style="font-family:times new roman,times,serif;">1. U-boot&nbsp;: Add your device android defconfig.</span></span>
  
 
<span style="font-family:times new roman,times,serif;">&nbsp; &nbsp;Step 1 The android defconfig&nbsp;: copy the mx6q<span style="color:#FF0000;">xxxa1</span>_1G_defconfig&nbsp;to mx6q<span style="color:#FF0000;">xxxa1</span>android_1G_defconfig.</span>
 
<span style="font-family:times new roman,times,serif;">&nbsp; &nbsp;Step 1 The android defconfig&nbsp;: copy the mx6q<span style="color:#FF0000;">xxxa1</span>_1G_defconfig&nbsp;to mx6q<span style="color:#FF0000;">xxxa1</span>android_1G_defconfig.</span>
Line 17: Line 19:
 
<span style="font-family:times new roman,times,serif;">&nbsp; &nbsp;Step 2 (1) Remove SPL&nbsp; (2) Add ANDROID_SUPPORT</span>
 
<span style="font-family:times new roman,times,serif;">&nbsp; &nbsp;Step 2 (1) Remove SPL&nbsp; (2) Add ANDROID_SUPPORT</span>
  
<span style="font-size:small;"><span style="font-family:times new roman,times,serif;">2. Android &nbsp;&nbsp;: &nbsp;<span style="color:#0000FF;">device_name</span> is your new device name.</span></span>
 
  
<span style="font-size:small;"><span style="font-family:times new roman,times,serif;">&nbsp; &nbsp;(1)build/envsetup.sh<br/>&nbsp; &nbsp;(2)device/fsl/imx6/AndroidProducts.mk<br/>&nbsp; &nbsp;(3)device/fsl/imx6/vendorsetup.sh<br/>&nbsp; &nbsp;(4)device/fsl/imx6/<span style="color:#0000FF;">device_name.mk</span><br/>&nbsp; &nbsp;(5)device/fsl/<span style="color:#0000FF;">device_name</span></span></span>
 
  
<span style="font-size:small;"><span style="font-family:times new roman,times,serif;">(1) In /build/envsetup.sh, please add your device in PRODUCT_CHOICES</span></span>
 
  
<span style="font-size:small;"><span style="font-family:times new roman,times,serif;">&nbsp; &nbsp; &nbsp; Example&nbsp;: Your device name is <span style="color:#FF0000;">aaa_a1</span>, please modify PRODUCT_CHOICES=(rsb4410_a1 rsb4410_a2 rsb4411_a1 <span style="color:#FF0000;">aaa_a1</span>)</span></span>
 
  
<span style="font-size:small;"><span style="font-family:times new roman,times,serif;">(2) In /device/fsl/imx6/AndroidProducts.mk, please add "<span style="color:#0000FF;">$(LOCAL_DIR)/device_name.mk</span>"</span></span>
+
<span style="font-size:medium;"><span style="font-family:times new roman,times,serif;">2. Android &nbsp;&nbsp;: </span><span style="font-family:trebuchet ms,helvetica,sans-serif;">&nbsp;</span><span style="font-family:times new roman,times,serif;"><span style="color:#0000FF;">device_name</span> is your new device name.</span></span>
 +
 
 +
<span style="font-family:times new roman,times,serif;"><span style="font-size:small;">&nbsp; &nbsp;(1)build/envsetup.sh<br/>&nbsp; &nbsp;(2)device/fsl/imx6/AndroidProducts.mk<br/>&nbsp; &nbsp;(3)device/fsl/imx6/vendorsetup.sh<br/>&nbsp; &nbsp;(4)device/fsl/imx6/<span style="color:#0000FF;">device_name.mk</span><br/>&nbsp; &nbsp;(5)device/fsl/<span style="color:#0000FF;">device_name</span></span></span>
 +
 
 +
<span style="font-size:medium;"><span style="font-family:times new roman,times,serif;">(1) In /build/envsetup.sh, please add your device in PRODUCT_CHOICES</span></span>
 +
 
 +
<span style="font-family:times new roman,times,serif;"><span style="font-size:small;">&nbsp; &nbsp; &nbsp; Example&nbsp;: Your device name is <span style="color:#FF0000;">aaa_a1</span>, please modify PRODUCT_CHOICES=(rsb_4410_a2&nbsp;<span style="color:#FF0000;">aaa_a1</span>)</span></span>
 +
 
 +
 
 +
 
 +
 
 +
 
 +
<span style="font-size:medium;"><span style="font-family:times new roman,times,serif;">(2) In /device/fsl/imx6/AndroidProducts.mk, please add "<span style="color:#0000FF;">$(LOCAL_DIR)/device_name.mk</span>"</span></span>
 +
 
 +
<span style="font-family:times new roman,times,serif;"><span style="font-size:small;">&nbsp; &nbsp; &nbsp; Example&nbsp;: Your device name is <span style="color:#FF0000;">aaa_a1</span>, please add "$(LOCAL_DIR)/<span style="color:#FF0000;">aaa_a1.mk"</span></span></span>
 +
 
 +
 
 +
 
 +
 
 +
 
 +
<span style="font-size:medium;"><span style="font-family:times new roman,times,serif;">(3) In device/fsl/imx6/vendorsetup.sh, please add "<span style="color:#0000FF;">add_lunch_combo device_name-eng</span>"&nbsp;and "<span style="color:#0000FF;">add_lunch_combo device_name-user</span>"</span></span>
 +
 
 +
<span style="font-family:times new roman,times,serif;"><span style="font-size:small;">&nbsp; &nbsp; &nbsp; Example&nbsp;: Your device name is <span style="color:#FF0000;">aaa_a1</span>, please add&nbsp;"add_lunch_combo <span style="color:#FF0000;">aaa_a1</span>-eng"&nbsp;and "add_lunch_combo <span style="color:#FF0000;">aaa_a1</span>-user"</span></span>
 +
 
 +
 
 +
 
 +
 
 +
 
 +
<span style="font-size:medium;"><span style="font-family:times new roman,times,serif;">(4) In device/fsl/imx6/, please add <span style="color:#0000FF;">device_name.mk.</span></span></span>
  
<span style="font-size:small;"><span style="font-family:times new roman,times,serif;">&nbsp; &nbsp; &nbsp; Example&nbsp;: Your device name is <span style="color:#FF0000;">aaa_a1</span>, please add "$(LOCAL_DIR)/<span style="color:#FF0000;">aaa_a1.mk"</span></span></span>
+
<span style="font-family:times new roman,times,serif;"><span style="font-size:small;">&nbsp; &nbsp; &nbsp; Example&nbsp;: Your device name is <span style="color:#FF0000;">aaa_a1</span>, please add aaa_a1.mk</span></span>
  
<span style="font-size:small;"><span style="font-family:times new roman,times,serif;">(3) In device/fsl/imx6/vendorsetup.sh, please add "<span style="color:#0000FF;">add_lunch_combo device_name-eng</span>"&nbsp;and "<span style="color:#0000FF;">add_lunch_combo device_name-user</span>"</span></span>
 
  
<span style="font-size:small;"><span style="font-family:times new roman,times,serif;">&nbsp; &nbsp; &nbsp; Example&nbsp;: Your device name is <span style="color:#FF0000;">aaa_a1</span>, please add&nbsp;"add_lunch_combo <span style="color:#FF0000;">aaa_a1</span>-eng"&nbsp;and "add_lunch_combo <span style="color:#FF0000;">aaa_a1</span>-user"</span></span>
 
  
<span style="font-size:small;"><span style="font-family:times new roman,times,serif;">(4) In device/fsl/imx6/, please add <span style="color:#0000FF;">device_name.mk.</span></span></span>
 
  
<span style="font-size:small;"><span style="font-family:times new roman,times,serif;">&nbsp; &nbsp; &nbsp; Example&nbsp;: Your device name is <span style="color:#FF0000;">aaa_a1</span>, please add aaa_a1.mk</span></span>
 
  
<span style="font-size:small;"><span style="font-family:times new roman,times,serif;">(5) In device/fsl/, please add <span style="color:#0000FF;">device_name </span>folder<span style="color:#0000FF;">.</span></span></span>
+
<span style="font-size:medium;"><span style="font-family:times new roman,times,serif;">(5) In device/fsl/, please add <span style="color:#0000FF;">device_name </span>folder<span style="color:#0000FF;">.</span></span></span>
  
<span style="font-size:small;"><span style="font-family:times new roman,times,serif;">&nbsp; &nbsp; &nbsp; Example&nbsp;: Your device name is <span style="color:#FF0000;">aaa_a1</span>, please add <span style="color:#FF0000;">aaa_a1&nbsp;</span>folder.</span></span>
+
<span style="font-family:times new roman,times,serif;"><span style="font-size:small;">&nbsp; &nbsp; &nbsp; Example&nbsp;: Your device name is <span style="color:#FF0000;">aaa_a1</span>, please add <span style="color:#FF0000;">aaa_a1&nbsp;</span>folder.</span></span>
  
<span style="color:#0000FF;"><span style="font-family:times new roman,times,serif;">&lt; BoardConfig.mk&gt; &nbsp;Remeber modify BoardConfig.mk in&nbsp;</span><span style="font-size:small;"><span style="font-family:times new roman,times,serif;">device/fsl/</span></span></span><span style="color:#FF0000;"><span style="font-size:small;"><span style="font-family:times new roman,times,serif;">device_name</span></span></span><span style="color:#0000FF;"><span style="font-size:small;"><span style="font-family:times new roman,times,serif;">/</span></span></span>
+
<span style="font-family:times new roman,times,serif;"><span style="font-size:small;">&nbsp; &nbsp; &nbsp; In&nbsp;device/fsl/<span style="color:#0000FF;">device_name</span>/BoardConfig.mk,&nbsp;we need to modify.</span></span>
  
<span style="font-size:small;"><span style="font-family:times new roman,times,serif;">&nbsp; &nbsp;TARGET_BOOTLOADER_CONFIG&nbsp;:= imx6q:mx6q<span style="color:#0000FF;">device_namea1</span>android_1G_defconfig<br/>&nbsp; &nbsp;TARGET_BOARD_DTS_CONFIG&nbsp;:= imx6q:imx6q-<span style="color:#0000FF;">device_name</span>-a1.dtb<br/>&nbsp; &nbsp;TARGET_KERNEL_DEFCONF&nbsp;:= imx_v7_adv_android_defconfig</span></span>
+
<span style="font-family:times new roman,times,serif;"><span style="font-size:small;">&nbsp; &nbsp; &nbsp; &nbsp;TARGET_BOOTLOADER_CONFIG&nbsp;:= imx6q:mx6q<span style="color:#0000FF;">device_namea1</span>android_1G_defconfig<br/>&nbsp; &nbsp; &nbsp; &nbsp;TARGET_BOARD_DTS_CONFIG&nbsp;:= imx6q:imx6q-<span style="color:#0000FF;">device_name</span>-a1.dtb<br/>&nbsp; &nbsp; &nbsp; &nbsp;TARGET_KERNEL_DEFCONF&nbsp;:= imx_v7_adv_android_defconfig</span></span>

Latest revision as of 09:37, 19 December 2016

How to do about first porting on new device in Android 6.0.1_2.1.0

Setup Ubuntu host computer

In Android 6.0.1_2.1.0, we push the advantech risc platfrom in github.

https://github.com/ADVANTECH-Corp

If you will be fast porting the new device in android 6.0.1_2.1.0, you can step by step to do.



1. U-boot : Add your device android defconfig.

   Step 1 The android defconfig : copy the mx6qxxxa1_1G_defconfig to mx6qxxxa1android_1G_defconfig.

   Step 2 (1) Remove SPL  (2) Add ANDROID_SUPPORT



2. Android   :  device_name is your new device name.

   (1)build/envsetup.sh
   (2)device/fsl/imx6/AndroidProducts.mk
   (3)device/fsl/imx6/vendorsetup.sh
   (4)device/fsl/imx6/device_name.mk
   (5)device/fsl/device_name

(1) In /build/envsetup.sh, please add your device in PRODUCT_CHOICES

      Example : Your device name is aaa_a1, please modify PRODUCT_CHOICES=(rsb_4410_a2 aaa_a1)



(2) In /device/fsl/imx6/AndroidProducts.mk, please add "$(LOCAL_DIR)/device_name.mk"

      Example : Your device name is aaa_a1, please add "$(LOCAL_DIR)/aaa_a1.mk"



(3) In device/fsl/imx6/vendorsetup.sh, please add "add_lunch_combo device_name-eng" and "add_lunch_combo device_name-user"

      Example : Your device name is aaa_a1, please add "add_lunch_combo aaa_a1-eng" and "add_lunch_combo aaa_a1-user"



(4) In device/fsl/imx6/, please add device_name.mk.

      Example : Your device name is aaa_a1, please add aaa_a1.mk



(5) In device/fsl/, please add device_name folder.

      Example : Your device name is aaa_a1, please add aaa_a1 folder.

      In device/fsl/device_name/BoardConfig.mk, we need to modify.

       TARGET_BOOTLOADER_CONFIG := imx6q:mx6qdevice_namea1android_1G_defconfig
       TARGET_BOARD_DTS_CONFIG := imx6q:imx6q-device_name-a1.dtb
       TARGET_KERNEL_DEFCONF := imx_v7_adv_android_defconfig