×

Discussion Board

Results 1 to 5 of 5
  1. #1
    Registered User
    Join Date
    Dec 2012
    Posts
    1

    [extracted] Location+localization problem, LWUIT

    Hello everyone,

    I am newbie with using this forum so I apologize if I ended up targeting this in the wrong place. As not having figured a way how to create a new topic, I decided to write about my problem under lwuit/tabbedpane -topic because I have been using lwuit while implementing the midlet based app.

    So here's a short description about my problem. I have been coding the midlet-based app using (emulator)/Eclipse/Nokia SDK 2.0. The app will be targeted for Asha 306-phone. On the emulator I am able to run the app without problems, but as soon as I download the app using Nokia PC Suite to the actual device and try to start up the app, I am encountering a weird behaviour that I don't have at all when using the emulator. Firstly "Searching for..." -window appears, after which I receive an alert window stating that the nearby located bluetooth-devices must be scanned. When saying yes to both of the questions, I am followed by the questions if I want allow the app to use network connection (this one I get when using emulator too). Saying yes finally causes the main window of my app to pop up. I am using localization with the help of L10nResources classes, but for some reason the localized texts don't show up correctly. I checked the (midlet) -jar file and it contains the localized inputs correctly. Also I am using in my app location (javax.microedition.location.Location) to receive users’ current coordinates (latitude+longitude), the functionality of which, breaks down, is not available on the actual device.

    As being new to midlet, lwuit programming, I am really puzzled with the problems. Could some of you experts stretch your opening hand and tell me what I should next to get the app running properly on my device?

    Br JanP

  2. #2
    Nokia Developer Moderator
    Join Date
    Feb 2006
    Location
    Budapest, Hungary
    Posts
    28,568

    Re: [extracted] Location+localization problem, LWUIT

    Hi, the "Post New Thread" button is just below the list of threads on http://www.developer.nokia.com/Commu...e-Java-General
    I am not really familiar with the things you have asked about, however the extra questions probably come because of the security settings applied to your midlet (which is "untrusted 3rd party" by default). Check http://www.developer.nokia.com/Commu...curity_Domains for some explanation.

  3. #3
    Registered User
    Join Date
    Sep 2012
    Posts
    31

    Re: [extracted] Location+localization problem, LWUIT

    Quote Originally Posted by jankkok View Post
    Hello everyone,

    I am newbie with using this forum so I apologize if I ended up targeting this in the wrong place. As not having figured a way how to create a new topic, I decided to write about my problem under lwuit/tabbedpane -topic because I have been using lwuit while implementing the midlet based app.

    So here's a short description about my problem. I have been coding the midlet-based app using (emulator)/Eclipse/Nokia SDK 2.0. The app will be targeted for Asha 306-phone. On the emulator I am able to run the app without problems, but as soon as I download the app using Nokia PC Suite to the actual device and try to start up the app, I am encountering a weird behaviour that I don't have at all when using the emulator. Firstly "Searching for..." -window appears, after which I receive an alert window stating that the nearby located bluetooth-devices must be scanned. When saying yes to both of the questions, I am followed by the questions if I want allow the app to use network connection (this one I get when using emulator too). Saying yes finally causes the main window of my app to pop up. I am using localization with the help of L10nResources classes, but for some reason the localized texts don't show up correctly. I checked the (midlet) -jar file and it contains the localized inputs correctly. Also I am using in my app location (javax.microedition.location.Location) to receive users’ current coordinates (latitude+longitude), the functionality of which, breaks down, is not available on the actual device.

    As being new to midlet, lwuit programming, I am really puzzled with the problems. Could some of you experts stretch your opening hand and tell me what I should next to get the app running properly on my device?

    Br JanP
    I have done the localization using LWUIT , it works for me without any issue.
    Following are the steps i followed
    1.I am creating the localized file using the resourece editor given by oracle with LWUIT and the name of the file should be according to the iso standards (like for us english en , hindi hi)
    2.After the creation the files , in my application i will be getting the current language used by the system ("microedtion.locale".. check for the exact property ) . so if iam using hindi in my device i will get hi-IN as the value and using hte apis provided by LWUIT i will load the proper reource file

    language = System.getProperty("microedition.locale");

    UIManager.getInstance().setResourceBundle(
    resource.getL10N("testlocale", language.substring(0, 2)));

    this is how i load the proper file .

    Hope this was helpful.
    Regards,
    Venkatesh

  4. #4
    Nokia Developer Champion
    Join Date
    Feb 2009
    Location
    Noida, India
    Posts
    3,073

    Re: [extracted] Location+localization problem, LWUIT

    Quote Originally Posted by jankkok View Post

    I am encountering a weird behaviour that I don't have at all when using the emulator. Firstly "Searching for..." -window appears, after which I receive an alert window stating that the nearby located bluetooth-devices must be scanned.

    Also I am using in my app location (javax.microedition.location.Location) to receive users’ current coordinates (latitude+longitude), the functionality of which, breaks down, is not available on the actual device.

    As being new to midlet, lwuit programming, I am really puzzled with the problems. Could some of you experts stretch your opening hand and tell me what I should next to get the app running properly on my device?

    Br JanP
    You are using javax.microedition.location.Location, but Asha 306-phone do not have in-built GPS for getting you users’ current coordinates (latitude+longitude)
    https://www.developer.nokia.com/Devi...ions/Asha_306/
    - hence it is searching for external BT enabled GPS devices if any - for getting you location data... try it on any device with in-built GPS chip and you will not face this Issue.

    Localization using LWUIT - check your implementation with codelet or provided by Venkatesh or see LWUIT localization example [http://sonomos.blogspot.in/2010/01/s...lization.html] .
    Last edited by wizard_hu_; 2012-12-13 at 09:10. Reason: QUOTE tag fixed
    thanks,
    ~Amitabh
    (Champion of the Month -Aug'13)
    Follow me on my blog for Innovative Mobile Apps

  5. #5
    Nokia Developer Champion
    Join Date
    Feb 2009
    Location
    Noida, India
    Posts
    3,073

    Re: [extracted] Location+localization problem, LWUIT

    Asha 306 .. device supports JSR 172 (location API's) it does not have GPS chip ..... but it supports CellID and WiFi positioning.

    Refer to wiki article - http://www.developer.nokia.com/Commu...on_via_Cell_ID

    Getting the device's current location via cell ID is done similarly to a GPS location retrieval by using a location provider object JSR 172 and extracting it's location object. The following retrieval methods can be used:

    //Online cell ID and/or WLAN
    int[] methods = {(Location.MTA_ASSISTED | Location.MTE_CELLID | Location.MTE_SHORTRANGE | Location.MTY_NETWORKBASED)};
    thanks,
    ~Amitabh
    (Champion of the Month -Aug'13)
    Follow me on my blog for Innovative Mobile Apps

Similar Threads

  1. Replies: 3
    Last Post: 2012-08-06, 07:25
  2. LWUIT and arabic localization
    By the_king2008 in forum Mobile Java Tools & SDKs
    Replies: 8
    Last Post: 2011-08-08, 20:51
  3. Help : LWUIT Localization
    By nilanchalapanigrahy in forum Mobile Java General
    Replies: 9
    Last Post: 2011-08-08, 20:51
  4. problem with LWUIT localization
    By thambirajan in forum Mobile Java Media (Graphics & Sounds)
    Replies: 1
    Last Post: 2010-10-19, 18:49
  5. Help for Localization in LWUIT..
    By nilanchalapanigrahy in forum Mobile Java General
    Replies: 4
    Last Post: 2010-06-25, 07:51

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •