This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

Android 2.3.4 on AM3517 - Ethernet configuration

Other Parts Discussed in Thread: AM3517, ADS7846

Hi,

we are testing Android 2.3.4 on AM3517 and we have seen from the following link

http://processors.wiki.ti.com/index.php/TI-Android-GingerBread-2.3.4-DevKit-2.1_UserGuide#Browser_Configuration,

that a user should configure manually the Internet connection eth0 before using a web browser with the following console command:

#> netcfg eth0 dhcp
#> setprop net.dns1 `getprop net.eth0.dns1`

My question is, how can I set "eth0" configuration at startup (with a static IP or with a dynamic IP address) without sending each time the above commands each time I switch on the machine ?

thank you,

Paolo.

  • Paolo,

    I add one of these two configurations to the end of the device/ti/am3517evm/init.rc file.  If you need dns (we don't) in the static case, you'll need to include that also.

    # dhcp IP

     service wired-ethernet  /system/bin/netcfg eth0 dhcp

    # static IP

    service wired-ethernet  /system/bin/ifconfig eth0 192.168.1.2 netmask 255.255.255.0 up
         oneshot

    Ron

  • Hi Ron,

    first of all thank you for your quickly reply.

    I try to add to the end of init.rc your  dhcp IP suggestion and it works also for me.

    The only strange issue is about the DNS configuration:

    net.eth0.dns1

    and

    net.eth0.dns2

    are set with a valid DNS IP address, but if I try to use the browser i'm not able to reach a web site (resolving address problem).

    To solve I need to send this command manually using the serial console:  setprop net.dns1 `getprop net.eth0.dns1'

    I know that you don't use the dns, but in your opinion is it a correct behaviours ?

    Thank you again,

    Paolo.

  • Paolo,

    Sorry, but I've not been down that path.  I would have thought the DNS setup would be ready to go after DHCP completes.  So, I suspect there's something about the kernel configuration somewhere that needs tweaking.

    As a work-around, you can probably issue that setprop command from init.rc, just like you issue the eth0 setup command.

    Ron

  • Hi Vishveshwar,

    thank you for your replay, your suggestion solve also our global dns issue.

    I don't know if you can help about other issues:

    1. My device is a non-phone device, for this reason I tried to remove the phone application modifying core.mk file as found here:

      http://processors.wiki.ti.com/index.php/Android_gingerbread_memory_analysis_for_non-phone_device

      but when I try to rebuild the AFS from <android-source> folder with the command
             make TARGET_PRODUCT=am3517evm OMAPES=3.x -j4
      the phone application still there.

      How can I remove the phone appllication from AFS ?

    2. Portrait mode issue
      I need to set my display device in portrait mode at startup (my device doesn't have any rotation sensor). For this reason I add on init.rc
                              setprop ro.sf.hwrotation 90
      At startup the display set itself in portrait mode, but when I touch an object on the screen, the UI doesn't response correctly as if the UI is still in landscape mode. I solved this issue adding the 90 degrees rotation on the kernel source code of the touch driver (ads7846.c).

      Is there any other way to solve the problem such as changing/adding some properties on init.rc file ?

      Thank you.

      Paolo

  • About touchscreen rotation, could you check if you have the following patch in your sources. This patch rotated the touchscreen values based on ro.sf.hwrotation value.

    http://gitorious.org/rowboat/frameworks-base/commit/eb175bc9dbe6d997bf248997a12ebd893f99b6ab

    We shall get back to you regarding your other query.

  • Hi,

    I don't have the patch in my sources.

    I just applyed the patch on my sources, removed from touch-screen kernel driver a few lines for the "90 degrees rotation" and re-built the AFS with:

    make TARGET_PRODUCT=am3517evm OMAPES=3.x -j4

    The display is still rotated to 90 degrees but touch-screen doesn't work. It seems that UI doesn't rotate the screen coordinate with ro.hw.rotation set to 90

    Do I need a make clean, before building AFS again ?

    Thank you.

    kind regards,

    Paolo.



  • We are able to have the touchscreen working even after rotation on the AM37x evm when this patch is applied.

    In my experience, any changes to frameworks/base generally requires a clean build. You could try with that.

  • Hi Vishveshwar,

    the rotation patch it works, after a clean build.

    Do you have any news about removing the Phone app from Gingerbread ?

    Thank you for your support.

    BR,

    Paolo.

  • If you have followed the wiki page instructions, the phone app should have been removed from the filesystem. Can you check if Phone.apk is present in /system/app of the final filesystem image (rootfs).

  • Hi,

    I removed from core.mk file all the apps as described on Step 2 of wiki page (Contacts, Phone, ContactsProvider, TelephonyProvider, UserDictionaryProvider)  but in /system/app folder of final filesystem the Phone.apk still there. Please see the core.mk file attached ( <rowboat-android>/build/target/product )

    I forgot something ? Do I need to apply also the Steps optional ?

    Thank you.

    BR,

    Paolo

    0247.core.txt

  • A comment after following some files paths.

    From

    ./mydroid/build/target/product/AndroidProducts.mk

    # Unbundled apps will be built with the default product config.
    ifneq ($(TARGET_BUILD_APPS),)
    PRODUCT_MAKEFILES := \
        $(LOCAL_DIR)/core.mk \
        $(LOCAL_DIR)/generic.mk \
        $(LOCAL_DIR)/full.mk
    else
    PRODUCT_MAKEFILES := \
        $(LOCAL_DIR)/core.mk \
        $(LOCAL_DIR)/generic.mk \
        $(LOCAL_DIR)/generic_armv5.mk \
        $(LOCAL_DIR)/generic_x86.mk \
        $(LOCAL_DIR)/full.mk \
        $(LOCAL_DIR)/full_x86.mk \
        $(LOCAL_DIR)/vbox_x86.mk \
        $(LOCAL_DIR)/sdk.mk \
        $(LOCAL_DIR)/sdk_x86.mk \
        $(LOCAL_DIR)/large_emu_hw.mk
    endif

    it makes reference to

        $(LOCAL_DIR)/generic.mk \

    then inside generic.mk

    ./mydroid/build/target/product/generic.mk
    $(call inherit-product, $(SRC_TARGET_DIR)/product/generic_no_telephony.mk)
    $(call inherit-product, $(SRC_TARGET_DIR)/product/telephony.mk)

    ./mydroid/build/target/product/telephony.mk
    # This is the list of product-level settings that are specific
    # to products that have telephony hardware.

    PRODUCT_PACKAGES := \
        Mms

    and since when looking for mms package definition inside build directory it is only defined in telephony.mk and sdk.mk, and not in core.mk, then these points are where it is defined, I suppose.

    you can try removing it, I haven't made any check or validation, just reading the files to provide a suggestion.

    And I remember similar threads and by doing a search for Android_gingerbread_memory_analysis_for_non-phone_device

    http://e2e.ti.com/support/embedded/android/f/509/p/120953/579131.aspx

    http://e2e.ti.com/support/embedded/android/f/509/t/166821.aspx

    http://e2e.ti.com/support/embedded/android/f/509/p/187733/675589.aspx

    http://e2e.ti.com/support/embedded/android/f/509/p/196655/701263.aspx

    http://e2e.ti.com/support/embedded/android/f/509/p/147985/536430.aspx

  • Hi Manuel,

    1. I doubt if you have deleted the complet out folder and rebuild the system. After doing the changes it requires clean and rebuild.

    2. Also as a manual step remove telephony,phone apk from /system/app folder using rm command before you prepare file system.

    BR,

    satish

  • Hi,

    thank you for your responses,

    Only to inform you that I have checked my files from the following path:

    $ ~/<rowboat-android>/build/target/product/

    this is the content of AndroidProduct.mk

    ......
    # An unbundled app build needs only generic.mk.
    ifneq ($(TARGET_BUILD_APPS),)
    PRODUCT_MAKEFILES := \
        $(LOCAL_DIR)/core.mk \
        $(LOCAL_DIR)/generic.mk
    else
    PRODUCT_MAKEFILES := \
        $(LOCAL_DIR)/core.mk \
        $(LOCAL_DIR)/generic.mk \
        $(LOCAL_DIR)/generic_x86.mk \
        $(LOCAL_DIR)/full.mk \
        $(LOCAL_DIR)/sdk.mk \
        $(LOCAL_DIR)/sim.mk
    endif

    it makes reference to

        $(LOCAL_DIR)/generic.mk \

    but the file generic.mk doesn't have your same information as you can see below:

    =========== generic.mk ==========
    # This is a generic product that isn't specialized for a specific device.
    # It includes the base Android platform.

    PRODUCT_PACKAGES := \
        AccountAndSyncSettings \
        DeskClock \
        AlarmProvider \
        Bluetooth \
        Calculator \
        Calendar \
        Camera \
        CertInstaller \
        DrmProvider \
        Email \
        Gallery3D \
        LatinIME \
        Launcher2 \
        Mms \
        Music \
        Provision \
        Protips \
        QuickSearchBox \
        Settings \
        Sync \
        SystemUI \
        Updater \
        CalendarProvider \
        SyncProvider

    $(call inherit-product, $(SRC_TARGET_DIR)/product/core.mk)

    # Overrides
    PRODUCT_BRAND := generic
    PRODUCT_DEVICE := generic
    PRODUCT_NAME := generic

    ===== end of my generic.mk ========

    I'm sorry but I haven't found any telephony.mk / generic_no_telephony.mk or similar files on

    $ ~/<rowboat-android>/build/target/product/

    This is the reason, I tried to remove the phone application modifying core.mk file as described here:

    http://processors.wiki.ti.com/index.php/Android_gingerbread_memory_analysis_for_non-phone_device

    I found very interesting one of the links suggested by you (http://e2e.ti.com/support/embedded/android/f/509/p/120953/579131.aspx) and the manual removing of Phone apps from the file system before preparing it.

    I'll try it.

    (Only to confirm your latest response: I use the command "make clean" after doing the changes, the "out" folder is completly deleted by clean action).

    Can I ask you another questions ?

    1) Actually I use a 7'' LCD with my board but I'm also interested to test the same board with a 10'' LCD (1024x600 px).

    Using 10'' LCD I have notice a problem with touchscreen, the LCD screen is correctly rotated to 90 degrees as on 7'' LCD but when I touch an object on the screen, the UI doesn't response correctly (It's seems that have a wrong rotation coordinates or a wrong calibration)

    What do you think about this ? It can be a kernel touch driver problem ?

    2) I use an SD-card of 4GB with only one partition, when I try to open the gallery I got the message

    "SD card unmounted or not present"

    I suppose this message is due to a partition missing on the same SD-card. My question is:

    Can I force the app gallery to read the media files in a folder on the same partition of filesystem ?

    Below vold.fstab content

    dev_mount sdcard /mnt/sdcard 3 /devices/platform/mmci-omap-hs.0/mmc_host/mmc0
    dev_mount usb /mnt/usb2 auto /devices/platform/ehci-omap.0/usb1/1-1/1-1.1
    dev_mount usb /mnt/usb3 auto /devices/platform/ehci-omap.0/usb1/1-1/1-1.2

    and partial content of init.rc

    # create mountpoints
        mkdir /mnt 0775 root system
        mkdir /mnt/sdcard 0000 system system
        mkdir /mnt/usb2 0000 system system
        mkdir /mnt/usb3 0000 system system

    ......


    # Backwards Compat - XXX: Going away in G*
        symlink /mnt/sdcard /sdcard
        symlink /mnt/usb2   /usb2
        symlink /mnt/usb3   /usb3

    4) I 'd like to create a service that checks for a file (ie new kernel) in a specific folder of filesystem. This file is then written in mtd partition of the kernel.
    How can I do this in Android? Do you have any suggestions?


    Many thanks,

    BR,

    Paolo

  • Satish,

    I agree about #1 and #2, my intention was to find the source of mms being compiled and added to avoid it being removed later, I don't have an build environment where I intended to reproduce the issue, just mentioned where mms package is defined.

  • Hi Manuel,

    1. I hope your query has been resolved. Let me know if you want more inputs.

    Paolo,

    1. when you are moving to 10'' LCD you need to recalibrate your touch screen.

    http://processors.wiki.ti.com/index.php/TI-Android-GingerBread-2.3.4-DevKit-2.1.1_PortingGuides#Touch_Calibration

    2. For changing a default mount point for gallery apps.

    Go to <android-src>/device/<your platform>/overlay/frameworks/base/core/res/res/xml/storage_list.xml

    and apply below patch with storage android:mountPoint as per your choice

    android:primary="true"

    android:emulated="true"

    android:mtpReserve="100" />

    + <storage android:mountPoint="/mnt/usb2"

    + android:storageDescription="@string/storage_usb"

    + android:removable="true" />

    </StorageList>

    3. You can always create a new service using NDK or putting your code in external folder and build as executable. Then launch service from init.rc file

     

    BR,

    satish 

  • Hi,

    About the non-phone device, I'll try to remove apk phone related file from AFS, but at startup i got the following error message:

    "The Application Android keyboard (process com.android.input.method.latin) has stopped unexspectly. Please try again"

    1) Is There a solution / patch for Gingerbread to integrate the ts_calibrate application and the integration of pointercal file ?

    2) I can't find any storage_list.xml file in my  <android-src>/ 

    Can I have a corrupted repo ?   I cloned sources from Gitorious.org/rowboat repository with

        $ repo init -u git://gitorious.org/rowboat/manifest.git -m TI-Android-GingerBread-2.3.4-DevKit-2.1.xml

       $ repo sync

    BR,

    Paolo.

  • Hi Paolo,

    1. There is no ts_calibrate application at present. One need to do calibration manually.

    2. Opps.. The file is only available for ICS port. Gingerbread this support is not there.

    You need to edit vold.fstab file manually for mount point.

     

    BR,

    satish

  • Hi Satish,

    About ICS, we are very interested to implement on AM3517.

    TI have a plans to porting ICS also for AM3517 ?

    BR,

    Paolo.

  • Hi Paolo,

    Sorry.. At present we do not have anly plan to support ICS for AM3517.

    But still you can take the code and try to port. It should not take much time for you.

     

    -

    satish

  • Hi Satish,

    about the ICS porting on AM3517, do I need to download the SGX 1.8 version and apply to ICS repo or is already present in the master branch of ICS ?

    thank you.

    BR,

    Paolo.

  • Hi,

     

    I need a way to find out the Wifi Ip and Ethernet Ip I get is static or dynamic? (android device)

    With the commands you specified I could get the ethernet Ip address, netmask,gateway , dns1 and dns2.

    But apart from tht how can I know if its statically configured one or not?

     

  • As we all know,While the mobile phone brings great conveniences to people, it also raises new challenge on the security of confidential work. In recent years, the wiretap, cheating in examination, medical negligence and gas station explosion with mobile phone occurred and it has aroused great concern of the society. Maybe it's one of the reasons that promoted the appearance of mobile phone signal jammer. You may be watching a nice movie or enjoying your nap when you get free for sometime. Still you have chances of getting disturbed with your most loved ones and close friend chatting near you on the cell phone. At such hours, if you really care for your free time then you need to buy a mobile phone signal jammer.

  • The activity of the animal beings has become acutely active everywhere on this earth. Bodies do not get time to booty a blow for a while. With the accretion use of altered gadgets of Gps Jammer, the possibilities of accepting the aboriginal of blow accept absolutely finished. The adaptable phones or the corpuscle phones are some of these accessories that accumulate the bodies consistently in blow with the alfresco world. The adaptable building are additionally accessible about everywhere these canicule and due to this the accessibility of the Cell Phone Jammer has become alike added quick and authentic. Today, you cannot break out of ability of these adaptable building as their signals can bolt your about anywhere. The bearings of bodies who accord to altered business professions has become actual analytical of jammer video as their authorities bolt them anywhere any moment.